Package org.japprove.verifier
Class StringVerifier
java.lang.Object
org.japprove.verifier.Verifier
org.japprove.verifier.StringVerifier
public class StringVerifier extends Verifier
The
StringVerifier provides methods to verify String objects or String lists within
Approval Tests.-
Constructor Summary
Constructors Constructor Description StringVerifier(ApprovalTestingEngine approvalTestingEngine) -
Method Summary
-
Constructor Details
-
Method Details
-
verify
public void verify(java.lang.String data)Receives a String that should be verified within an Approval Test.Within the verification process, the passed data is compared to the data in the corresponding baseline. In the case the versions are equal, the test passes. If no baseline exists, a
VersionNotApprovedErroris thrown. If there is a baseline that is not equal to the current version, aVerificationFailedErroris thrown.- Parameters:
data- The String that should be verified
-
verify
public void verify(java.util.List<java.lang.String> data)Receives a List of Strings that should be verified within an Approval Test.Within the verification process, the passed data is compared to the data in the corresponding baseline. In the case the versions are equal, the test passes. If no baseline exists, a
VersionNotApprovedErroris thrown. If there is a baseline that is not equal to the current version, aVerificationFailedErroris thrown.- Parameters:
data- The String that should be verified
-