webkit
2cdf99a9e3038c7e01b3c37e8ad903ecbe5eecf1
https://github.com/WebKit/webkit
|
Public Member Functions | |
NavEnv (TestFile f, TestSuite s, NavDrv d) | |
synchronized void | runTest () |
Object | createContext () |
Object | executeTestFile () |
boolean | waitForCompletion () |
synchronized boolean | parseResult () |
void | close () |
String | getRandomWindowName () |
TestEnvironment for running JavaScript tests in Navigator. NavDrv uses LiveConnect to create Navigator windows in which JavaScript tests are opened and evaluated.
Constructor a new NavEnv.
|
inline |
Close Navigator window.
Implements com.netscape.javascript.qa.drivers.TestEnvironment.
|
inline |
Creates a new JavaScript context, in this case a Navigator window, and returns the JSObject associated with that window.
Implements com.netscape.javascript.qa.drivers.TestEnvironment.
|
inline |
Open the current TestFile in the window by using LiveConnect to set the window's location.href property to a URL where the TestFile can be found.
Implements com.netscape.javascript.qa.drivers.TestEnvironment.
|
inline |
Generate a random window name, so that each test is associated with a unique window.
|
inline |
Use LiveConnect to get the Navigator window's testcases property, which is defined in all tests. Parse the testcases array, and create a new TestCase object for each TestCase object it finds.
Implements com.netscape.javascript.qa.drivers.TestEnvironment.
|
inline |
Called by NavDrv to run the current TestFile.
Implements com.netscape.javascript.qa.drivers.TestEnvironment.
|
inline |
Checks the value of the variable "completed", which is set by the stopTest() function in each test.
If the stopTest() function is not called in 20 seconds, the test fails.
Negative tests will still succeed, since the onerror handler should call the stopTest() function.