Class ContainsAssertion
java.lang.Object
org.opensearch.test.rest.yaml.section.Assertion
org.opensearch.test.rest.yaml.section.ContainsAssertion
- All Implemented Interfaces:
ExecutableSection
public class ContainsAssertion extends Assertion
-
Field Summary
Fields inherited from interface org.opensearch.test.rest.yaml.section.ExecutableSection
DEFAULT_EXECUTABLE_CONTEXTS, XCONTENT_REGISTRY -
Constructor Summary
Constructors Constructor Description ContainsAssertion(org.opensearch.common.xcontent.XContentLocation location, java.lang.String field, java.lang.Object expectedValue) -
Method Summary
Modifier and Type Method Description protected voiddoAssert(java.lang.Object actualValue, java.lang.Object expectedValue)Executes the assertion comparing the actual value (parsed from the response) with the expected onestatic ContainsAssertionparse(org.opensearch.common.xcontent.XContentParser parser)Methods inherited from class org.opensearch.test.rest.yaml.section.Assertion
execute, getActualValue, getExpectedValue, getField, getLocation, resolveExpectedValue, safeClass
-
Constructor Details
-
ContainsAssertion
public ContainsAssertion(org.opensearch.common.xcontent.XContentLocation location, java.lang.String field, java.lang.Object expectedValue)
-
-
Method Details
-
parse
public static ContainsAssertion parse(org.opensearch.common.xcontent.XContentParser parser) throws java.io.IOException- Throws:
java.io.IOException
-
doAssert
protected void doAssert(java.lang.Object actualValue, java.lang.Object expectedValue)Description copied from class:AssertionExecutes the assertion comparing the actual value (parsed from the response) with the expected one
-