This repository was archived by the owner on Apr 20, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +16
-7
lines changed
Expand file tree Collapse file tree 4 files changed +16
-7
lines changed Original file line number Diff line number Diff line change @@ -44,8 +44,9 @@ matrix:
4444before_script :
4545 - Xvfb $DISPLAY -extension RANDR &> /dev/null &
4646
47- - LATEST_CHROMEDRIVER_VERSION=`curl http://chromedriver.storage.googleapis.com/LATEST_RELEASE`
48- - wget --no-verbose https://chromedriver.storage.googleapis.com/$LATEST_CHROMEDRIVER_VERSION/chromedriver_linux64.zip
47+ - CHROME_MAIN_VERSION=`google-chrome-stable --version | sed -E 's/(^Google Chrome |\.[0-9]+ )//g'`
48+ - CHROMEDRIVER_VERSION=`curl -s "https://chromedriver.storage.googleapis.com/LATEST_RELEASE_$CHROME_MAIN_VERSION"`
49+ - wget --no-verbose "https://chromedriver.storage.googleapis.com/${CHROMEDRIVER_VERSION}/chromedriver_linux64.zip"
4950 - unzip chromedriver_linux64.zip -d ~/bin
5051
5152 - wget "https://selenium-release.storage.googleapis.com/${SELENIUM_VERSION%%.[[:digit:]]}/selenium-server-standalone-${SELENIUM_VERSION}.jar" -O selenium.jar
Original file line number Diff line number Diff line change @@ -25,7 +25,9 @@ public function __construct($timeout = 1)
2525 */
2626 public function closeBrowser ()
2727 {
28- $ this ->getSession ()->stop ();
28+ if ($ this ->getMink ()->isSessionStarted ()) {
29+ $ this ->getSession ()->stop ();
30+ }
2931 }
3032
3133 /**
Original file line number Diff line number Diff line change @@ -51,9 +51,11 @@ public function afterStep(AfterStepTested $event)
5151 // For now to avoid modification on MinkContext
5252 // We add fallback on Mink
5353 try {
54- $ this ->httpCallResultPool ->store (
55- new HttpCallResult ($ this ->mink ->getSession ()->getPage ()->getContent ())
56- );
54+ if ($ this ->mink ->getSession ()->isStarted ()) {
55+ $ this ->httpCallResultPool ->store (
56+ new HttpCallResult ($ this ->mink ->getSession ()->getPage ()->getContent ())
57+ );
58+ }
5759 } catch (\LogicException $ e ) {
5860 // Mink has no response
5961 } catch (\Behat \Mink \Exception \DriverException $ e ) {
Original file line number Diff line number Diff line change 11Feature : Browser Feature
22
3+ @javascript
4+ Scenario : Testing when scenario has no HTTP call
5+ Given I wait 0.1 seconds
6+
37 # If this scenario fails
48 # It's probably because your web environment is not properly setup
5- # You will find the necessery help in README.md
9+ # You will find the necessary help in README.md
610 @javascript
711 Scenario : Testing simple web access
812 Given I am on "/index.html"
You can’t perform that action at this time.
0 commit comments