"Fossies" - the Fresh Open Source Software Archive

Member "selenium-selenium-4.8.1/common/src/web/rc/tests/TestErrorChecking.html" (17 Feb 2023, 3389 Bytes) of package /linux/www/selenium-selenium-4.8.1.tar.gz:


Caution: In this restricted "Fossies" environment the current HTML page may not be correctly presentated and may have some non-functional links. You can here alternatively try to browse the pure source code or just view or download the uninterpreted raw source code. If the rendering is insufficient you may try to find and view the page on the selenium-selenium-4.8.1.tar.gz project site itself.

This test should fail!

The following test script checks that when verifyFailureOnNext and verifyErrorOnNext are used, the following command should fail and the verified error message must match the actual message.

If this functionality is working correctly, each of the following verifyText commands should fail because the verifyFailure/Error doesn't match.

Tests for expectError and expectFailure commands
open ../tests/html/test_click_page1.html  
verifyFailureOnNext The next command actually succeeds so this verify is wrong
verifyText link Click here for next page
verifyErrorOnNext The next command is an action that succeeds (instead of an accessor)
echo foo
verifyFailureOnNext The next command does fail, but this is the wrong message
verifyText link foo
verifyErrorOnNext The next command actually succeeds so this verify is wrong
verifyText link Click here for next page
verifyErrorOnNext The next command has a failure, not an error
verifyText link foo
This next command must come last, because it causes a real error.
verifyErrorOnNext The next command does error, but this is the wrong message
verifyText notAlink foo