HotTestDriver
hotstaq / Modules / HotTestDriver
Class: HotTestDriver
This actually executes the tests.
Hierarchy​
HotTestDriver
Table of contents​
Constructors​
Properties​
Methods​
- assert
- assertElementValue
- destroy
- findTestElement
- navigateToUrl
- parseTestObject
- println
- run
- runCommand
- wait
- waitForTestElement
Constructors​
constructor​
• new HotTestDriver(page?
)
Parameters​
Name | Type | Default value |
---|---|---|
page | HotTestPage | null |
Defined in​
Properties​
page​
• page: HotTestPage
The current page.
Defined in​
Methods​
assert​
â–¸ assert(value
, errorMessage?
): Promise
<any
>
An expression to test.
Parameters​
Name | Type | Default value |
---|---|---|
value | any | undefined |
errorMessage | string | "" |
Returns​
Promise
<any
>
Defined in​
assertElementValue​
â–¸ Abstract
assertElementValue(name
, value
, errorMessage?
, options?
): Promise
<any
>
An expression to test.
Parameters​
Name | Type |
---|---|
name | string | HotTestElement |
value | any |
errorMessage? | string |
options? | HotTestElementOptions |
Returns​
Promise
<any
>
Defined in​
destroy​
â–¸ Abstract
destroy(): Promise
<void
>
Disconnect this server or destroy anything associated with this HotTestDriver.
Returns​
Promise
<void
>
Defined in​
findTestElement​
â–¸ Abstract
findTestElement(name
, options?
): Promise
<any
>
Find a HotTestElement to utilize.
Parameters​
Name | Type |
---|---|
name | string | HotTestElement |
options? | HotTestElementOptions |
Returns​
Promise
<any
>
Defined in​
navigateToUrl​
â–¸ Abstract
navigateToUrl(url
): Promise
<void
>
Navigate to a url.
Parameters​
Name | Type |
---|---|
url | string |
Returns​
Promise
<void
>
Defined in​
parseTestObject​
â–¸ parseTestObject(name
): string
Get a test object by it's name. If a * is used, it will be used as a wildcard for the object's name. If a > is used, then the name will be treated as a CSS selector.
Parameters​
Name | Type |
---|---|
name | string |
Returns​
string
Defined in​
print​
â–¸ print(message
): Promise
<void
>
Print a message.
Parameters​
Name | Type |
---|---|
message | string |
Returns​
Promise
<void
>
Defined in​
println​
â–¸ println(message
): Promise
<void
>
Print a message line.
Parameters​
Name | Type |
---|---|
message | string |
Returns​
Promise
<void
>
Defined in​
run​
â–¸ run(executions
): Promise
<any
[]>
Run a series of test elements.
Parameters​
Name | Type |
---|---|
executions | string [] | string [][] |
Returns​
Promise
<any
[]>
Defined in​
runCommand​
â–¸ Abstract
runCommand(testElm
, funcName?
, valueStr?
): Promise
<any
>
Run a HotTestElement command.
Parameters​
Name | Type |
---|---|
testElm | string | HotTestElement |
funcName? | string |
valueStr? | string |
Returns​
Promise
<any
>
Defined in​
wait​
â–¸ wait(numMilliseconds
): Promise
<void
>
Wait for a number of milliseconds.
Parameters​
Name | Type |
---|---|
numMilliseconds | number |
Returns​
Promise
<void
>
Defined in​
waitForTestElement​
â–¸ Abstract
waitForTestElement(name
, options?
): Promise
<any
>
Wait for a HotTestElement to load.
Parameters​
Name | Type |
---|---|
name | string | HotTestElement |
options? | HotTestElementOptions |
Returns​
Promise
<any
>