Skip to content

Commit bb0b46f

Browse files
committed
Updated the driver for the Mink 2.0 API
1 parent 7b2b7db commit bb0b46f

File tree

2 files changed

+2
-13
lines changed

2 files changed

+2
-13
lines changed

Diff for: composer.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
"require": {
1818
"php": ">=5.3.1",
19-
"behat/mink": "~1.6@dev",
19+
"behat/mink": "dev-2-architecture-changes",
2020
"symfony/browser-kit": "~2.0",
2121
"symfony/dom-crawler": "~2.0"
2222
},

Diff for: src/Behat/Mink/Driver/BrowserKitDriver.php

+1-12
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,8 @@
1010

1111
namespace Behat\Mink\Driver;
1212

13-
use Behat\Mink\Element\NodeElement;
1413
use Behat\Mink\Exception\DriverException;
1514
use Behat\Mink\Exception\UnsupportedDriverActionException;
16-
use Behat\Mink\Session;
1715
use Symfony\Component\BrowserKit\Client;
1816
use Symfony\Component\BrowserKit\Cookie;
1917
use Symfony\Component\BrowserKit\Request;
@@ -36,7 +34,6 @@
3634
*/
3735
class BrowserKitDriver extends CoreDriver
3836
{
39-
private $session;
4037
private $client;
4138

4239
/**
@@ -74,14 +71,6 @@ public function getClient()
7471
return $this->client;
7572
}
7673

77-
/**
78-
* {@inheritdoc}
79-
*/
80-
public function setSession(Session $session)
81-
{
82-
$this->session = $session;
83-
}
84-
8574
/**
8675
* Tells driver to remove hostname from URL.
8776
*
@@ -351,7 +340,7 @@ public function find($xpath)
351340

352341
$elements = array();
353342
foreach ($nodes as $i => $node) {
354-
$elements[] = new NodeElement(sprintf('(%s)[%d]', $xpath, $i + 1), $this->session);
343+
$elements[] = sprintf('(%s)[%d]', $xpath, $i + 1);
355344
}
356345

357346
return $elements;

0 commit comments

Comments
 (0)