phpunit-selenium icon indicating copy to clipboard operation
phpunit-selenium copied to clipboard

No way to retrieve timeout values

Open keithdtyler opened this issue 13 years ago • 3 comments

While we can perform setTimeout() and even setHttpTimeout(), there is no way to get the current value. There is no getTimeout() or getHttpTimeout(), for example.

Because SeleniumTestCase passes all calls to a property object -- instead of inheriting -- and because that object (SeleniumTestCase_Driver) stores nearly everything as protected, it is impossible to get to without hacking the code.

in other words, the following will fail:

print $this->drivers[0]->seleniumTimeout;

with error "Cannot access protected property"

keithdtyler avatar May 20 '11 17:05 keithdtyler

Will the absence of commands for retrieving the timeouts make these values undefined when they are left to their defaults? Maybe it's out of the scope for the test case to retrieve timeouts.

giorgiosironi avatar Mar 23 '12 10:03 giorgiosironi

The idea was for the test to be agnostic of the settings but be able to know what the setting is so it knows whether to change it or not.

keithdtyler avatar Feb 09 '17 18:02 keithdtyler

If this is still a problem, feel free to open a PR to add the getters that are necessary for accessing these values from the tests.

giorgiosironi avatar Feb 12 '17 15:02 giorgiosironi