Test class
PODO for a test that can be executed.
Constructors
Properties
- active → bool
-
Sets whether or not this test is currently active. The interal system
will always create active tests but loaders may return inactive tests.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → String
-
Returns the id of the test which is a concatenation of the suite
name and the test name.
no setter
- name → String?
-
The name for the test
final
- pinnedStepIndex ↔ int
-
The index of the currently pinned step. The pinned step is the step after
which steps will be added via
addStep
. This is intended to allow users to add steps in the middle of an existing step as opposed to always having to add steps to the end of a test and then manually reorder them.getter/setter pair - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
steps
→ List<
TestStep> -
The list of steps for the test
final
- suiteName → String?
-
The name of the test suite this test is a part of; may be
null
or empty.final - timestamp → DateTime
-
The timestamp for the test step.
final
- version → int
-
The test version.
final
Methods
-
addTestStep(
TestStep step) → void - Adds a test step to this test at the current pinnedStepIndex and increments pinnedStepIndex by one.
-
clearTestSteps(
) → void - Clears all test steps from this test.
-
copyWith(
{bool? active, String? name, int? pinnedStepIndex, List< TestStep> ? steps, String? suiteName, DateTime? timestamp, int? version}) → Test - Copies this test with the given values.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> - Converts this test to a JSON compatible format. See fromDynamic for the structure.
-
toString(
) → String -
Returns the string encoded JSON representation for this class. This will
remove all null values and empty collections from the returned string.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
fromDynamic(
dynamic map, {bool ignoreImages = false}) → Test -
Creates a test from a map-like object. The
map
must support the[]
operator if it is notnull
.