|
18 | 18 |
|
19 | 19 | import org.junit.Before;
|
20 | 20 | import org.junit.Test;
|
21 |
| -import org.openqa.selenium.Proxy; |
22 | 21 | import org.openqa.selenium.io.FileHandler;
|
23 | 22 | import org.openqa.selenium.io.TemporaryFilesystem;
|
24 | 23 | import org.openqa.selenium.io.Zip;
|
|
33 | 32 | import java.util.ArrayList;
|
34 | 33 | import java.util.List;
|
35 | 34 |
|
36 |
| -import static org.hamcrest.Matchers.containsString; |
37 | 35 | import static org.junit.Assert.assertEquals;
|
38 | 36 | import static org.junit.Assert.assertNotNull;
|
39 |
| -import static org.junit.Assert.assertThat; |
40 | 37 | import static org.junit.Assert.assertTrue;
|
41 | 38 |
|
42 | 39 | public class FirefoxProfileTest {
|
@@ -81,47 +78,6 @@ public void shouldSetIntegerPreferences() throws Exception {
|
81 | 78 | assertTrue("Did not see integer value being set correctly", seenCheese);
|
82 | 79 | }
|
83 | 80 |
|
84 |
| - @Test |
85 |
| - public void manualProxy() throws Exception { |
86 |
| - profile.setProxyPreferences( |
87 |
| - new Proxy() |
88 |
| - .setHttpProxy("foo:123") |
89 |
| - .setFtpProxy("bar:234") |
90 |
| - .setSslProxy("baz:345") |
91 |
| - .setNoProxy("localhost")); |
92 |
| - List<String> prefLines = readGeneratedProperties(profile); |
93 |
| - String prefs = new ArrayList<String>(prefLines).toString(); |
94 |
| - assertThat(prefs, containsString("network.proxy.http\", \"foo\"")); |
95 |
| - assertThat(prefs, containsString("network.proxy.http_port\", 123")); |
96 |
| - assertThat(prefs, containsString("network.proxy.ftp\", \"bar\"")); |
97 |
| - assertThat(prefs, containsString("network.proxy.ftp_port\", 234")); |
98 |
| - assertThat(prefs, containsString("network.proxy.ssl\", \"baz\"")); |
99 |
| - assertThat(prefs, containsString("network.proxy.ssl_port\", 345")); |
100 |
| - assertThat(prefs, containsString("network.proxy.no_proxies_on\", \"localhost\"")); |
101 |
| - assertThat(prefs, containsString("network.proxy.type\", 1")); |
102 |
| - } |
103 |
| - |
104 |
| - @Test |
105 |
| - public void proxyAutoconfigUrl() throws Exception { |
106 |
| - profile.setProxyPreferences( |
107 |
| - new Proxy() |
108 |
| - .setProxyAutoconfigUrl("http://foo/bar.pac")); |
109 |
| - List<String> prefLines = readGeneratedProperties(profile); |
110 |
| - String prefs = new ArrayList<String>(prefLines).toString(); |
111 |
| - assertThat(prefs, containsString("network.proxy.autoconfig_url\", \"http://foo/bar.pac\"")); |
112 |
| - assertThat(prefs, containsString("network.proxy.type\", 2")); |
113 |
| - } |
114 |
| - |
115 |
| - @Test |
116 |
| - public void proxyAutodetect() throws Exception { |
117 |
| - profile.setProxyPreferences( |
118 |
| - new Proxy() |
119 |
| - .setAutodetect(true)); |
120 |
| - List<String> prefLines = readGeneratedProperties(profile); |
121 |
| - String prefs = new ArrayList<String>(prefLines).toString(); |
122 |
| - assertThat(prefs, containsString("network.proxy.type\", 4")); |
123 |
| - } |
124 |
| - |
125 | 81 | @Test
|
126 | 82 | public void shouldSetBooleanPreferences() throws Exception {
|
127 | 83 | profile.setPreference("cheese", false);
|
|
0 commit comments