diff --git a/composer.json b/composer.json index 67808a21..b4e29a5f 100644 --- a/composer.json +++ b/composer.json @@ -21,7 +21,7 @@ "require": { "php": ">=5.3.1", - "behat/mink": "~1.5.0@dev", + "behat/mink": "dev-2-architecture-changes", "instaclick/php-webdriver": "~1.1" }, diff --git a/src/Behat/Mink/Driver/Selenium2Driver.php b/src/Behat/Mink/Driver/Selenium2Driver.php index c077eca3..a4a94a0a 100755 --- a/src/Behat/Mink/Driver/Selenium2Driver.php +++ b/src/Behat/Mink/Driver/Selenium2Driver.php @@ -2,9 +2,7 @@ namespace Behat\Mink\Driver; -use Behat\Mink\Element\NodeElement; use Behat\Mink\Exception\DriverException; -use Behat\Mink\Session; use WebDriver\Exception\UnknownError; use WebDriver\Key; use WebDriver\WebDriver; @@ -24,12 +22,6 @@ */ class Selenium2Driver extends CoreDriver { - /** - * The current Mink session - * @var \Behat\Mink\Session - */ - private $session; - /** * Whether the browser has been started * @var Boolean @@ -103,7 +95,7 @@ protected function setBrowserName($browserName = 'firefox') /** * Sets the desired capabilities - called on construction. If null is provided, will set the - * defaults as dsesired. + * defaults as desired. * * See http://code.google.com/p/selenium/wiki/DesiredCapabilities * @@ -262,14 +254,6 @@ protected function executeJsOnXpath($xpath, $script, $sync = true) )); } - /** - * @see Behat\Mink\Driver\DriverInterface::setSession() - */ - public function setSession(Session $session) - { - $this->session = $session; - } - /** * Starts driver. */ @@ -498,11 +482,7 @@ public function getWindowName() } /** - * Finds elements with specified XPath query. - * - * @param string $xpath - * - * @return array array of Behat\Mink\Element\NodeElement + * {@inheritdoc} */ public function find($xpath) { @@ -510,7 +490,7 @@ public function find($xpath) $elements = array(); foreach ($nodes as $i => $node) { - $elements[] = new NodeElement(sprintf('(%s)[%d]', $xpath, $i+1), $this->session); + $elements[] = sprintf('(%s)[%d]', $xpath, $i+1); } return $elements;