File tree 5 files changed +9
-19
lines changed
com/thoughtworks/selenium/corebased
5 files changed +9
-19
lines changed Original file line number Diff line number Diff line change @@ -38,8 +38,11 @@ public class InternetExplorerDriver extends RemoteWebDriver {
38
38
39
39
/**
40
40
* Capability that defines to use whether to use native or javascript events during operations.
41
+ *
42
+ * @deprecated Non W3C compliant
41
43
*/
42
- public static final String NATIVE_EVENTS = CapabilityType .HAS_NATIVE_EVENTS ;
44
+ @ Deprecated
45
+ public static final String NATIVE_EVENTS = "nativeEvents" ;
43
46
44
47
/**
45
48
* Capability that defines the initial URL to be used when IE is launched.
Original file line number Diff line number Diff line change @@ -57,11 +57,6 @@ public interface CapabilityType {
57
57
*/
58
58
@ Deprecated
59
59
String SUPPORTS_WEB_STORAGE = "webStorageEnabled" ;
60
- /**
61
- * @deprecated Non W3C compliant
62
- */
63
- @ Deprecated
64
- String HAS_NATIVE_EVENTS = "nativeEvents" ;
65
60
/**
66
61
* @deprecated Use {@link CapabilityType#UNHANDLED_PROMPT_BEHAVIOUR}
67
62
*/
Original file line number Diff line number Diff line change 18
18
package com .thoughtworks .selenium .corebased ;
19
19
20
20
import com .thoughtworks .selenium .InternalSelenseTestBase ;
21
+
21
22
import org .junit .jupiter .api .Disabled ;
22
23
import org .junit .jupiter .api .Test ;
23
24
import org .junit .jupiter .api .Timeout ;
24
25
import org .openqa .selenium .Capabilities ;
25
26
import org .openqa .selenium .HasCapabilities ;
26
27
import org .openqa .selenium .WebDriver ;
27
28
import org .openqa .selenium .WrapsDriver ;
28
- import org .openqa .selenium .remote .CapabilityType ;
29
29
30
30
@ Disabled ()
31
31
public class TestClickAt extends InternalSelenseTestBase {
@@ -118,6 +118,6 @@ private boolean isUsingNativeEvents() {
118
118
}
119
119
120
120
Capabilities capabilities = ((HasCapabilities ) driver ).getCapabilities ();
121
- return capabilities .is (CapabilityType . HAS_NATIVE_EVENTS );
121
+ return capabilities .is ("nativeEvents" );
122
122
}
123
123
}
Original file line number Diff line number Diff line change 42
42
import static org .openqa .selenium .testing .TestUtilities .getEffectivePlatform ;
43
43
import static org .openqa .selenium .testing .TestUtilities .getIEVersion ;
44
44
import static org .openqa .selenium .testing .TestUtilities .isInternetExplorer ;
45
- import static org .openqa .selenium .testing .TestUtilities .isNativeEventsEnabled ;
46
45
import static org .openqa .selenium .testing .drivers .Browser .CHROME ;
47
46
import static org .openqa .selenium .testing .drivers .Browser .FIREFOX ;
48
47
import static org .openqa .selenium .testing .drivers .Browser .HTMLUNIT ;
@@ -334,9 +333,9 @@ public void testMouseMovementWorksWhenNavigatingToAnotherPage() {
334
333
@ NotYetImplemented (CHROME )
335
334
public void testChordControlCutAndPaste () {
336
335
assumeFalse (getEffectivePlatform (driver ).is (Platform .MAC ), "FIXME: macs don't have CONTROL key" );
337
- assumeFalse (isNativeEventsEnabled (driver ) &&
338
- getEffectivePlatform (driver ). is ( Platform . WINDOWS ) &&
339
- isInternetExplorer ( driver ), "Windows: native events library does not support storing modifiers state yet" );
336
+ assumeFalse (getEffectivePlatform (driver ). is ( Platform . WINDOWS ) &&
337
+ isInternetExplorer (driver ),
338
+ "Windows: native events library does not support storing modifiers state yet" );
340
339
341
340
driver .get (pages .javascriptPage );
342
341
Original file line number Diff line number Diff line change 23
23
import org .openqa .selenium .Platform ;
24
24
import org .openqa .selenium .WebDriver ;
25
25
import org .openqa .selenium .htmlunit .HtmlUnitDriver ;
26
- import org .openqa .selenium .remote .CapabilityType ;
27
26
28
27
import java .io .File ;
29
28
import java .io .IOException ;
36
35
37
36
public class TestUtilities {
38
37
39
- public static boolean isNativeEventsEnabled (WebDriver driver ) {
40
- return driver instanceof HasCapabilities &&
41
- ((HasCapabilities ) driver ).getCapabilities ().is (CapabilityType .HAS_NATIVE_EVENTS );
42
-
43
- }
44
-
45
38
public static String getUserAgent (WebDriver driver ) {
46
39
try {
47
40
return (String ) ((JavascriptExecutor ) driver ).executeScript (
You can’t perform that action at this time.
0 commit comments