test/js/TestRunner.js:119
Runs test suites and test cases, providing events to allowing for the interpretation of test results.
_addTestCaseToTestTree
parentNode
testCase
Defined in
test/js/TestRunner.js:314
Adds a test case to the test tree as a child of the specified node.
parentNode
TestNode
The node to add the test case to as a child.
testCase
Test.TestCase
The test case to add.
_addTestSuiteToTestTree
parentNode
testSuite
Defined in
test/js/TestRunner.js:338
Adds a test suite to the test tree as a child of the specified node.
parentNode
TestNode
The node to add the test suite to as a child.
testSuite
Test.TestSuite
The test suite to add.
_buildTestTree
Defined in
test/js/TestRunner.js:361
Builds the test tree based on items in the master suite. The tree is a hierarchical representation of the test suites, test cases, and test functions. The resulting tree is stored in _root and the pointer _cur is set to the root initially.
_execNonTestMethod
node
methodName
allowAsync
Defined in
test/js/TestRunner.js:462
Executes a non-test method (init, setUp, tearDown, destroy) and traps an errors. If an error occurs, an error event is fired.
True if an async method was called, false if not.
_handleError
error
Defined in
test/js/TestRunner.js:734
Handles an error as if it occurred within the currently executing test. This is for mock methods that may be called asynchronously and therefore out of the scope of the TestRunner. Previously, this error would bubble up to the browser. Now, this method is used to tell TestRunner about the error. This should never be called by anyplace other than the Mock object.
error
Error
The error object.
_handleTestObjectComplete
node
Defined in
test/js/TestRunner.js:389
Handles the completion of a test object's tests. Tallies test results from one level up to the next.
node
TestNode
The TestNode representing the test object.
_next
Defined in
test/js/TestRunner.js:423
Retrieves the next node in the test tree.
The next node in the test tree or null if the end is reached.
_run
testObject
Defined in
test/js/TestRunner.js:499
Runs a test case or test suite, returning the results.
testObject
Test.TestCase | YUITest.TestSuite
The test case or test suite to run.
Results of the execution with properties passed, failed, and total.
_runTest
node
Defined in
test/js/TestRunner.js:758
Runs a single test based on the data provided in the node.
node
TestNode
The TestNode representing the test to run.
add
testObject
Defined in
test/js/TestRunner.js:843
Adds a test suite or test case to the list of test objects to run.
testObject
Object
Either a TestCase or a TestSuite that should be run.
callback
Defined in
test/js/TestRunner.js:933
Used to continue processing when a method marked with "async:" is executed. This should not be used in test methods, only in init(). Each argument is a string, and when the returned function is executed, the arguments are assigned to the context data object using the string as the key name (value is the argument itself).
A callback function.
getCoverage
format
Defined in
test/js/TestRunner.js:904
Returns the coverage report for the files that have been executed. This returns only coverage information for files that have been instrumented using YUI Test Coverage and only those that were run in the same pass.
format
Function
(Optional) A coverage format to return results in.
getName
Defined in
test/js/TestRunner.js:820
Retrieves the name of the current result set.
The name of the result set.
getResults
format
Defined in
test/js/TestRunner.js:883
Returns the last complete results set from the TestRunner. Null is returned if the TestRunner is running or no tests have been run.
format
Function
(Optional) A test format to return the results in.
isRunning
Defined in
test/js/TestRunner.js:873
Indicates that the TestRunner is busy running tests and therefore can't be stopped and results cannot be gathered.
True if the TestRunner is running, false if not.
isWaiting
Defined in
test/js/TestRunner.js:863
Indicates if the TestRunner is waiting for a test to resume
True if the TestRunner is waiting, false if not.
resume
segment
Defined in
test/js/TestRunner.js:957
Resumes the TestRunner after wait() was called.
segment
Function
The function to run as the rest of the haulted test.
setName
name
Defined in
test/js/TestRunner.js:829
The name assigned to the master suite of the TestRunner. This is the name that is output as the root's name when results are retrieved.
name
String
The name of the result set.
_cur
Defined in
test/js/TestRunner.js:141
Pointer to the current node in the test tree.
_data
Defined in
test/js/TestRunner.js:197
Data object that is passed around from method to method.
_groups
Defined in
test/js/TestRunner.js:206
The list of test groups to run. The list is represented by a comma delimited string with commas at the start and end.
_ignoreEmpty
Defined in
test/js/TestRunner.js:221
If true, YUITest will not fire an error for tests with no Asserts.
_lastResults
Defined in
test/js/TestRunner.js:187
Holds copy of the results object generated when all tests are complete.
_log
Defined in
test/js/TestRunner.js:159
Indicates if the TestRunner will log events or not.
_root
Defined in
test/js/TestRunner.js:150
Pointer to the root node in the test tree.
_running
Defined in
test/js/TestRunner.js:178
Indicates if the TestRunner is currently running tests.
_waiting
Defined in
test/js/TestRunner.js:168
Indicates if the TestRunner is waiting as a result of wait() being called.
masterSuite
Defined in
test/js/TestRunner.js:132
Suite on which to attach all TestSuites and TestCases to be run.
complete
Defined in
test/js/TestRunner.js:296
Fires when all test suites and test cases have been completed.
testcasebegin
Defined in
test/js/TestRunner.js:237
Fires when a test case is opened but before the first test is executed.
testcasecomplete
Defined in
test/js/TestRunner.js:245
Fires when all tests in a test case have been executed.
testsuitebegin
Defined in
test/js/TestRunner.js:252
Fires when a test suite is opened but before the first test is executed.
testsuitecomplete
Defined in
test/js/TestRunner.js:260
Fires when all test cases in a test suite have been completed.