webkit
2cdf99a9e3038c7e01b3c37e8ad903ecbe5eecf1
https://github.com/WebKit/webkit
|
Public Member Functions | |
RhinoEnv (TestFile f, TestSuite s, TestDriver d) | |
synchronized void | runTest () |
Object | createContext () |
Object | executeTestFile () |
Object | executeTestFile (String s) |
boolean | parseResult () |
void | close () |
String | getString (Object object) |
Public Attributes | |
Global | global |
This class creates a javax.javascript.Context, which evaluates the helper and RhinoFile and returns a result.
If the test throws a Java exception or JavaScript runtime or compilation error, the RhinoFile fails, and the exception is stored in that RhinoFile's exception variable.
If the test succeeds, the result is parsed and the RhinoFile's test result variables are populated.
|
inline |
|
inline |
Close the context.
Implements com.netscape.javascript.qa.drivers.TestEnvironment.
|
inline |
Create a new com.netscape.javascript.Context.
Implements com.netscape.javascript.qa.drivers.TestEnvironment.
|
inline |
Given a filename, evaluate the file's contents as a JavaScript program.
Implements com.netscape.javascript.qa.drivers.TestEnvironment.
|
inline |
Given a filename, evaluate the file's contents as a JavaScript program. Return the value of the program. If the test throws a Java exception or JavaScript runtime or compilation error, return the string value of the error message.
s | full path to the file that will be exectued. |
|
inline |
Get the JavaScript string associated with a JavaScript object.
object | a Java identifier for a JavaScript object |
|
inline |
Evaluates the RhinoFile result. If the result is an instance of javax.javascript.Scriptable, assume it is a JavaScript Array of TestCase objects, as described in RhinoDrv.java. For each test case in the array, add an element to the RhinoFile's test case vector. If all test cases passed, set the RhinoFile's passed value to true; else set its passed value to false.
If the result is not a Scriptable object, the test failed. Set the the RhinoFile's exception property to the string value of the result. However, negative tests, which should have a "-n.js" extension, are expected to fail.
Implements com.netscape.javascript.qa.drivers.TestEnvironment.
|
inline |
Creates the JavaScript Context, which evaluates the contents of a RhinoFile and returns a result. The RhinoEnv parses the test result, and sets values of the RhinoFile test result properties.
Implements com.netscape.javascript.qa.drivers.TestEnvironment.
Global com.netscape.javascript.qa.drivers.RhinoEnv.global |