ApprovalDart class final
A utility class for verifying test cases and saving approved test cases.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
approvedPath(
) → String - Returns the path to the approved test cases file.
-
deleteApprovedCasesIfExists(
{String? path}) → void - Deletes the approved test cases file if it exists.
-
directoryPath(
) → String - Returns the directory path of the script.
-
isValuesApproved(
{String? path}) → bool - Checks if the approved test cases file exists.
-
loadApprovedCasesIfExists(
{String? filePath}) → List - Loads approved test cases from a Dart file.
-
saveApprovedCase(
dynamic approvedCase, {String? filePath, String? fileName}) → void - Saves approved test cases to a Dart file.
-
saveCases(
dynamic receivedItems, dynamic expectedItems, {String? filePath, String? fileName}) → void - Saves approved test cases to a Dart file.
-
verify(
String output, {String? filePath}) → void - Verifies the output against the approved file.
-
verifyAllCombinations(
List< List> inputSets, void testFunction(Iterable<List> list)) → void - Executes tests on all combinations of given input sets.