Conditions | 2 |
Paths | 2 |
Total Lines | 15 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 2.0438 |
Changes | 3 | ||
Bugs | 1 | Features | 0 |
1 | <?php |
||
54 | 1 | public function createDriver(BrowserConfiguration $browser) |
|
55 | { |
||
56 | 1 | if ( !class_exists('Zumba\Mink\Driver\PhantomJSDriver') ) { |
|
57 | throw new \RuntimeException( |
||
58 | 'Install MinkPhantomJSDriver in order to use phantomjs driver.' |
||
59 | ); |
||
60 | } |
||
61 | |||
62 | 1 | return new \Zumba\Mink\Driver\PhantomJSDriver(sprintf( |
|
63 | 1 | 'http://%s:%s%s', |
|
64 | 1 | $browser->getHost(), |
|
65 | 1 | $browser->getPort(), |
|
66 | '/api' |
||
67 | 1 | )); |
|
68 | } |
||
69 | |||
71 |