Class: RegistrationBuilder
A utility class to set GameTest parameters for a test. Methods can be chained together to set multiple properties.
Constructors
new RegistrationBuilder()
private
new RegistrationBuilder():RegistrationBuilder
Returns
Methods
batch()
batch(
batchName
):RegistrationBuilder
Parameters
Parameter | Type | Description |
---|---|---|
batchName | string | Name of the batch for the test. |
Returns
RegistrationBuilder object where additional configuration methods can be called.
Remarks
Sets the batch for the test to run in.
This function can't be called in read-only mode.
maxAttempts()
maxAttempts(
attemptCount
):RegistrationBuilder
Parameters
Parameter | Type |
---|---|
attemptCount | number |
Returns
RegistrationBuilder object where additional configuration methods can be called.
Remarks
Sets the maximum number of times a test will try to rerun if it fails.
This function can't be called in read-only mode.
maxTicks()
maxTicks(
tickCount
):RegistrationBuilder
Parameters
Parameter | Type |
---|---|
tickCount | number |
Returns
RegistrationBuilder object where additional configuration methods can be called.
Remarks
Sets the maximum number of ticks a test will run for before timing out and failing.
This function can't be called in read-only mode.
padding()
padding(
paddingBlocks
):RegistrationBuilder
Parameters
Parameter | Type | Description |
---|---|---|
paddingBlocks | number | Size, in blocks, around the GameTest where additional GameTests should not be created. |
Returns
RegistrationBuilder object where additional configuration methods can be called.
Remarks
Size around the GameTest, in blocks, that should be reserved for the test when running multiple tests together.
This function can't be called in read-only mode.
required()
required(
isRequired
):RegistrationBuilder
Parameters
Parameter | Type | Description |
---|---|---|
isRequired | boolean | If set to true, the test must pass in order for the entire run of tests to pass. |
Returns
RegistrationBuilder object where additional configuration methods can be called.
Remarks
Whether this test is required to pass as part of its broader set of tests.
This function can't be called in read-only mode.
requiredSuccessfulAttempts()
requiredSuccessfulAttempts(
attemptCount
):RegistrationBuilder
Parameters
Parameter | Type |
---|---|
attemptCount | number |
Returns
RegistrationBuilder object where additional configuration methods can be called.
Remarks
Sets the number of successful test runs to be considered successful.
This function can't be called in read-only mode.
rotateTest()
rotateTest(
rotate
):RegistrationBuilder
Parameters
Parameter | Type |
---|---|
rotate | boolean |
Returns
Remarks
If true, runs the test in all four rotations when run via /gametest runset.
This function can't be called in read-only mode.
setupTicks()
setupTicks(
tickCount
):RegistrationBuilder