giorgiosironi / phpunit-selenium

Selenium RC integration for PHPUnit
http://www.phpunit.de/
Other
602 stars 271 forks source link

Add FullyShared Session Strategy (even in case of failures) #378

Open amenk opened 8 years ago

amenk commented 8 years ago

I am testing on VMs (BrowserStack) and the overhead for one session is quite high (booting up a full ne VM, takes around 20 seconds).

So I am using \PHPUnit_Extensions_Selenium2TestCase_SessionStrategy_Shared to share session. Unfortunately there is code to restart the session in case the last test was not successful.

While this makes sense in some cases, in my case it does not.

Could we add a session strategy to not restart the session on failures? Or is it possible to add an own session strategy on-the-fly? (I did not yet succeed in this, as the session strategy does not seem to be pluggable)

Shall I (try to) make a pull request?

Current workaround:

Comment the function \PHPUnit_Extensions_Selenium2TestCase_SessionStrategy_Shared::notSuccessfulTest

giorgiosironi commented 8 years ago

Indeed, PR welcome. Ideally should make it pluggable by specifying a Strategy object.