[AS3] Class r1.rpc.testing.RPCTestCase |
Client API |
| Package | r1.rpc.testing |
| Class | public class RPCTestCase |
| Property | Defined by | ||
|---|---|---|---|
| callFacade : Function [write-only]
This is a function with such a signature:
In a test case generated by the R1-RPC/J test generation tool, a function is generated. | RPCTestCase | ||
| checkResult : Function [write-only]
This is a function with such a signature:
In a test case generated by the R1-RPC/J test generation tool, a
function is generated for the content in the For a manual test case, you should define this method, as it will be used by the test runner. | RPCTestCase | ||
| comment : String [read-only]
| RPCTestCase | ||
| displayTime : String [read-only]
The start time in the form of "hh:mm:ss".
| RPCTestCase | ||
| index : int | RPCTestCase | ||
| lapse : int
The duration of the run, in milliseconds.
| RPCTestCase | ||
| message : String
The message that is set by the test runner or the test case code.
| RPCTestCase | ||
| name : String [read-only]
| RPCTestCase | ||
| negative : Boolean [read-only]
If
true, this test case is a negative test that
expects an exception as the result of a run. | RPCTestCase | ||
| paramsGenerator : Function | RPCTestCase | ||
| state : int | RPCTestCase | ||
| stateName : String [read-only]
The current test case state name, which is one of these:
"not started", "in progress", "being run", "succeeded", and "failed".
| RPCTestCase | ||
| stateNameShort : String [read-only]
The current test case state name, which is one of these:
"NotStarted", "InProgress", "BeingRun", "Succeeded", and "Failed".
| RPCTestCase | ||
| success : Boolean | RPCTestCase | ||
| time : Date
The start time.
| RPCTestCase | ||
| Method | Defined by | ||
|---|---|---|---|
|
RPCTestCase(suite:RPCTestSuite, name:String, comment:String = null, negative:Boolean = false)
| RPCTestCase | ||
|
call():void
The invocation driver
| RPCTestCase | ||
|
reset():void
Clear the internal state to get ready for a new run.
| RPCTestCase | ||
| Constant | Defined by | ||
|---|---|---|---|
| BEING_RUN : int = 2 [static]
| RPCTestCase | ||
| FAILURE : int = 4 [static]
| RPCTestCase | ||
| IN_PROGRESS : int = 1 [static]
| RPCTestCase | ||
| NOT_STARTED : int = 0 [static]
| RPCTestCase | ||
| SUCCESS : int = 3 [static]
| RPCTestCase | ||
| callFacade | property |
callFacade:Function [write-only]
This is a function with such a signature:
function call_facade(facade:RPCFacade, cb:Function):void;
The cb is a normal RPC callback.
In a test case generated by the R1-RPC/J test generation tool, a
function is generated. In the generated code, it calls
paramsGenerator(), which is also generated for the
content in the &at;@ASTestInput tag.
For a manual test case, you should define this method, as it will
be used by the test runner, but paramsGenerator() is not
necessary.
public function set callFacade(value:Function):void
| checkResult | property |
checkResult:Function [write-only]
This is a function with such a signature:
function check_result(x: testCase:RPCTestCase):Boolean;
In a test case generated by the R1-RPC/J test generation tool, a
function is generated for the content in the @ASTestResult
tag.
For a manual test case, you should define this method, as it will be used by the test runner.
Implementation public function set checkResult(value:Function):void
| comment | property |
comment:String [read-only]Implementation
public function get comment():String
| displayTime | property |
displayTime:String [read-only]The start time in the form of "hh:mm:ss".
Implementation public function get displayTime():String
| index | property |
index:int [read-write]Implementation
public function get index():int
public function set index(value:int):void
| lapse | property |
lapse:int [read-write]The duration of the run, in milliseconds.
Implementation public function get lapse():int
public function set lapse(value:int):void
| message | property |
message:String [read-write]The message that is set by the test runner or the test case code.
Implementation public function get message():String
public function set message(value:String):void
| name | property |
name:String [read-only]Implementation
public function get name():String
| negative | property |
negative:Boolean [read-only]
If true, this test case is a negative test that
expects an exception as the result of a run.
public function get negative():Boolean
| paramsGenerator | property |
paramsGenerator:Function [read-write]Implementation
public function get paramsGenerator():Function
public function set paramsGenerator(value:Function):void
| state | property |
state:int [read-write]Implementation
public function get state():int
public function set state(value:int):void
| stateName | property |
stateName:String [read-only]The current test case state name, which is one of these: "not started", "in progress", "being run", "succeeded", and "failed".
Implementation public function get stateName():String
| stateNameShort | property |
stateNameShort:String [read-only]The current test case state name, which is one of these: "NotStarted", "InProgress", "BeingRun", "Succeeded", and "Failed".
Implementation public function get stateNameShort():String
| success | property |
success:Boolean [read-write]Implementation
public function get success():Boolean
public function set success(value:Boolean):void
| time | property |
time:Date [read-write]The start time.
Implementation public function get time():Date
public function set time(value:Date):void
| RPCTestCase | () | constructor |
public function RPCTestCase(suite:RPCTestSuite, name:String, comment:String = null, negative:Boolean = false)Parameters
suite:RPCTestSuite |
|
name:String |
|
comment:String (default = null) |
|
negative:Boolean (default = false) |
| call | () | method |
public function call():voidThe invocation driver
| reset | () | method |
public function reset():voidClear the internal state to get ready for a new run.
| BEING_RUN | constant |
public static const BEING_RUN:int = 2
| FAILURE | constant |
public static const FAILURE:int = 4
| IN_PROGRESS | constant |
public static const IN_PROGRESS:int = 1
| NOT_STARTED | constant |
public static const NOT_STARTED:int = 0
| SUCCESS | constant |
public static const SUCCESS:int = 3