Namespace definitions
The rell.test namespace is only accessible within test modules
Example
@test module;
function test() {
rell.test.block().run();
}
Since
0.10.4
Properties
Time interval in milliseconds between current block and next block to be used.
Keypair that signs all blocks built in the test context.
Default time interval in milliseconds between each block. (10 seconds)
Timestamp in milliseconds of the first block by default. (2020-01-01 00:00:00 UTC)
Timestamp in milliseconds of the previous block. Read will fail if no block has been built.
Timestamp in milliseconds of the previous block or null
if no block has been built.
Timestamp in milliseconds which will be used for the next block.
Functions
Asserts that two values are equal.
Asserts that the expected events has been emitted during last block
Asserts that a function fails to evaluate
Asserts that a function fails with an expected message
Asserts that the value is false
.
Asserts that the value is greater than or equal to the expected value
Asserts that the value is greater than or equal to the first value and less than or equal to the second value.
Asserts that the value is greater than or equal to the first value and less than the second value.
Asserts that the value is greater than the expected value
Asserts that the value is greater than the first value and less than or equal to the second value.
Asserts that the value is greater than the first value and less than the second value.
Asserts that the value is less than or equal to the expected value
Asserts that the value is less than the expected value
Asserts that two values are not equal.
Asserts that the value is not null
.
Asserts that the value is null
.
Asserts that the value is true
.
Get all events that have been emitted from the last block.
Creates a new no-op operation.
Creates a new no-op operation with a given nonce.
Set the time interval in milliseconds between current block and the next one. This property is not respected if a timestamp has been explicitly set by calling rell.test.set_next_block_time
.
Explicitly set the timestamp in milliseconds to use on the next block.
Explicitly set the timestamp in milliseconds to use on next block by specifying a time delay from the last block.