Package org.xmlunit.assertj3
Class ValidationAssert
java.lang.Object
org.assertj.core.api.AbstractAssert<ValidationAssert,Source>
org.xmlunit.assertj3.ValidationAssert
- All Implemented Interfaces:
org.assertj.core.api.Assert<ValidationAssert,,Source> org.assertj.core.api.Descriptable<ValidationAssert>,org.assertj.core.api.ExtensionPoints<ValidationAssert,Source>
Assertion methods for XML validation.
Simple Example
import static org.xmlunit.assertj.XmlAssert.assertThat; final String xml = "<a><b attr=\"abc\"></b></a>"; assertThat(xml).isValid();
- Since:
- XMLUnit 2.8.1
-
Field Summary
FieldsFields inherited from class org.assertj.core.api.AbstractAssert
actual, info, myself, objects, throwUnsupportedExceptionOnEquals -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateValidationAssert(Source actual, Source[] schemaSources, Schema schema) -
Method Summary
Modifier and TypeMethodDescription(package private) static ValidationAssertcreate(Object xmlSource, Schema schema, XmlAssertConfig config) (package private) static ValidationAssertcreate(Object xmlSource, XmlAssertConfig config) (package private) static ValidationAssertcreate(Object xmlSource, XmlAssertConfig config, Object... schemaSources) voidVerifies that actual value is not valid against given schemaisValid()Verifies that actual value is valid against given schemaprivate ValidationResultvalidate()Methods inherited from class org.assertj.core.api.AbstractAssert
areEqual, asInstanceOf, asList, assertionError, asString, describedAs, descriptionText, doesNotHave, doesNotHaveSameClassAs, doesNotHaveSameHashCodeAs, doesNotHaveToString, equals, extracting, extracting, failure, failureWithActualExpected, failWithActualExpectedAndMessage, failWithMessage, getWritableAssertionInfo, has, hashCode, hasSameClassAs, hasSameHashCodeAs, hasToString, inBinary, inHexadecimal, is, isElementOfCustomAssert, isEqualTo, isExactlyInstanceOf, isIn, isIn, isInstanceOf, isInstanceOfAny, isInstanceOfSatisfying, isNot, isNotEqualTo, isNotExactlyInstanceOf, isNotIn, isNotIn, isNotInstanceOf, isNotInstanceOfAny, isNotNull, isNotOfAnyClassIn, isNotSameAs, isNull, isOfAnyClassIn, isSameAs, matches, matches, newListAssertInstance, overridingErrorMessage, overridingErrorMessage, satisfies, satisfies, satisfies, satisfiesAnyOf, satisfiesAnyOf, satisfiesAnyOfForProxy, satisfiesForProxy, setCustomRepresentation, setDescriptionConsumer, setPrintAssertionsDescription, throwAssertionError, usingComparator, usingComparator, usingDefaultComparator, usingRecursiveAssertion, usingRecursiveAssertion, usingRecursiveComparison, usingRecursiveComparison, withFailMessage, withFailMessage, withRepresentation, withThreadDumpOnErrorMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.assertj.core.api.Descriptable
as, as, as, describedAs
-
Field Details
-
schemaSources
-
schema
-
-
Constructor Details
-
ValidationAssert
-
-
Method Details
-
create
-
create
-
create
-
validate
-
isValid
Verifies that actual value is valid against given schema- Returns:
- this
- Throws:
AssertionError- if the actual value is not valid against schema
-
isInvalid
public void isInvalid()Verifies that actual value is not valid against given schema- Throws:
AssertionError- if the actual value is valid against schema
-