File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2929use SilverStripe \BehatExtension \Utility \StepHelper ;
3030use SilverStripe \BehatExtension \Utility \DebugTools ;
3131use SilverStripe \MinkFacebookWebDriver \FacebookWebDriver ;
32+ use Facebook \WebDriver \Remote \RemoteWebElement ;
33+ use SilverStripe \Dev \Deprecation ;
34+
35+ use function PHPUnit \Framework \assertSame ;
3236
3337/**
3438 * BasicContext
@@ -1711,9 +1715,12 @@ public function iTypeInTheField(string $data)
17111715 * @Given /^the active element should be "([^"]+)"$/
17121716 *
17131717 * Example: And the active element should be "selector"
1718+ *
1719+ * @depreacted 6.1.0 Use theFieldShouldHaveFocus() instead which is more reliable
17141720 */
17151721 public function theActiveElementShouldBe (string $ selector )
17161722 {
1723+ Deprecation::notice ('6.1.0 ' , 'Use theFieldShouldHaveFocus() instead which is more reliable ' );
17171724 $ driver = $ this ->getSession ()->getDriver ()->getWebDriver ();
17181725 $ element = $ driver ->findElement (WebDriverBy::cssSelector ($ selector ));
17191726 Assert::assertNotNull ($ element , sprintf ('Element %s not found ' , $ selector ));
You can’t perform that action at this time.
0 commit comments