Kernel::Test::Role::IsTestCase::Selenium

NAME

Kernel::Test::Role::IsTestCase::Selenium – base role for all test cases.

ATTRIBUTES

has 'QuitRetries'

Count of maximum retries for the quit() call

METHODS

around 'SkipTest'

modify SkipTest to abort the test early if Selenium testing is not active.

around 'StartHook'

sets some Selenium-relevant settings via "SeleniumSettingsSet()".

around 'FinishHook'

quits selenium driver.

around 'HandleException'

modifies the default exception handler to call the one from the Selenium driver instead, e. g. to take a screenshot.

has 'Selenium'

provides a default "main" Selenium instance. Use this in tests that only need one instance. Other tests should use "CreateSeleniumInstance()" to create additional browser windows.

CreateSeleniumInstance()

use this to create additional instances other than the main, if needed.

SeleniumSettingsSet()

Sets needed settings when selenium tests are executed.

_PushEventCleanup()

Remove all push event related database entries.

_CloseSeleniumSession()

Selenium::Remote::Driver::quit() produces a Timeout Exception on some scenarios.

Selenium::Remote::Driver::quit() also produces an Exception if the Selenium Session does not have any open windows.

This method closes all windows and removes the Selenium Session ID which will avoid any exceptions which in the test are counted as Failure.

Scroll to Top