File tree 1 file changed +18
-0
lines changed
java/client/src/org/openqa/selenium/firefox
1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change 24
24
import static org .openqa .selenium .Platform .UNIX ;
25
25
import static org .openqa .selenium .Platform .WINDOWS ;
26
26
import static org .openqa .selenium .os .WindowsUtils .getPathsInProgramFiles ;
27
+ import org .openqa .selenium .remote .service .DriverService ;
27
28
28
29
import com .google .common .collect .ImmutableList ;
29
30
import com .google .common .collect .Iterables ;
@@ -138,6 +139,19 @@ public FirefoxBinary(File pathToFirefoxBinary) {
138
139
executable = new Executable (pathToFirefoxBinary );
139
140
}
140
141
142
+ /**
143
+ * deprecated Use {@link DriverService.Builder#withEnvironment(Map)} instead:
144
+ * <p>
145
+ * new FirefoxDriver(
146
+ * new GeckoDriverService.Builder()
147
+ * .usingDriverExecutable(new File("path/to/geckodriver.exe"))
148
+ * .usingFirefoxBinary(new FirefoxBinary(new File("path/to/firefox.exe")))
149
+ * .withEnvironment(ImmutableMap.of("DISPLAY", "0:0"))
150
+ * .build());
151
+ * @param propertyName
152
+ * @param value
153
+ */
154
+ @ Deprecated
141
155
public void setEnvironmentProperty (String propertyName , String value ) {
142
156
if (propertyName == null || value == null ) {
143
157
throw new WebDriverException (
@@ -206,6 +220,10 @@ protected String getPath() {
206
220
return executable .getPath ();
207
221
}
208
222
223
+ /**
224
+ * @deprecated No replacement. Environment should be configured in {@link DriverService} instance.
225
+ */
226
+ @ Deprecated
209
227
public Map <String , String > getExtraEnv () {
210
228
return Collections .unmodifiableMap (extraEnv );
211
229
}
You can’t perform that action at this time.
0 commit comments