File tree Expand file tree Collapse file tree 5 files changed +9
-19
lines changed
com/thoughtworks/selenium/corebased Expand file tree Collapse file tree 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 {
3838
3939 /**
4040 * Capability that defines to use whether to use native or javascript events during operations.
41+ *
42+ * @deprecated Non W3C compliant
4143 */
42- public static final String NATIVE_EVENTS = CapabilityType .HAS_NATIVE_EVENTS ;
44+ @ Deprecated
45+ public static final String NATIVE_EVENTS = "nativeEvents" ;
4346
4447 /**
4548 * 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 {
5757 */
5858 @ Deprecated
5959 String SUPPORTS_WEB_STORAGE = "webStorageEnabled" ;
60- /**
61- * @deprecated Non W3C compliant
62- */
63- @ Deprecated
64- String HAS_NATIVE_EVENTS = "nativeEvents" ;
6560 /**
6661 * @deprecated Use {@link CapabilityType#UNHANDLED_PROMPT_BEHAVIOUR}
6762 */
Original file line number Diff line number Diff line change 1818package com .thoughtworks .selenium .corebased ;
1919
2020import com .thoughtworks .selenium .InternalSelenseTestBase ;
21+
2122import org .junit .jupiter .api .Disabled ;
2223import org .junit .jupiter .api .Test ;
2324import org .junit .jupiter .api .Timeout ;
2425import org .openqa .selenium .Capabilities ;
2526import org .openqa .selenium .HasCapabilities ;
2627import org .openqa .selenium .WebDriver ;
2728import org .openqa .selenium .WrapsDriver ;
28- import org .openqa .selenium .remote .CapabilityType ;
2929
3030@ Disabled ()
3131public class TestClickAt extends InternalSelenseTestBase {
@@ -118,6 +118,6 @@ private boolean isUsingNativeEvents() {
118118 }
119119
120120 Capabilities capabilities = ((HasCapabilities ) driver ).getCapabilities ();
121- return capabilities .is (CapabilityType . HAS_NATIVE_EVENTS );
121+ return capabilities .is ("nativeEvents" );
122122 }
123123}
Original file line number Diff line number Diff line change 4242import static org .openqa .selenium .testing .TestUtilities .getEffectivePlatform ;
4343import static org .openqa .selenium .testing .TestUtilities .getIEVersion ;
4444import static org .openqa .selenium .testing .TestUtilities .isInternetExplorer ;
45- import static org .openqa .selenium .testing .TestUtilities .isNativeEventsEnabled ;
4645import static org .openqa .selenium .testing .drivers .Browser .CHROME ;
4746import static org .openqa .selenium .testing .drivers .Browser .FIREFOX ;
4847import static org .openqa .selenium .testing .drivers .Browser .HTMLUNIT ;
@@ -334,9 +333,9 @@ public void testMouseMovementWorksWhenNavigatingToAnotherPage() {
334333 @ NotYetImplemented (CHROME )
335334 public void testChordControlCutAndPaste () {
336335 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" );
340339
341340 driver .get (pages .javascriptPage );
342341
Original file line number Diff line number Diff line change 2323import org .openqa .selenium .Platform ;
2424import org .openqa .selenium .WebDriver ;
2525import org .openqa .selenium .htmlunit .HtmlUnitDriver ;
26- import org .openqa .selenium .remote .CapabilityType ;
2726
2827import java .io .File ;
2928import java .io .IOException ;
3635
3736public class TestUtilities {
3837
39- public static boolean isNativeEventsEnabled (WebDriver driver ) {
40- return driver instanceof HasCapabilities &&
41- ((HasCapabilities ) driver ).getCapabilities ().is (CapabilityType .HAS_NATIVE_EVENTS );
42-
43- }
44-
4538 public static String getUserAgent (WebDriver driver ) {
4639 try {
4740 return (String ) ((JavascriptExecutor ) driver ).executeScript (
You can’t perform that action at this time.
0 commit comments