Class MavenBuildAssert
java.lang.Object
org.assertj.core.api.AbstractAssert<SELF,ACTUAL>
org.assertj.core.api.AbstractCharSequenceAssert<SELF,String>
org.assertj.core.api.AbstractStringAssert<SELF>
io.spring.initializr.generator.test.io.AbstractTextAssert<MavenBuildAssert>
io.spring.initializr.generator.test.buildsystem.maven.MavenBuildAssert
- All Implemented Interfaces:
org.assertj.core.api.Assert<MavenBuildAssert,
,String> org.assertj.core.api.Descriptable<MavenBuildAssert>
,org.assertj.core.api.EnumerableAssert<MavenBuildAssert,
,Character> org.assertj.core.api.ExtensionPoints<MavenBuildAssert,
String>
Assertions for a Maven build.
- Author:
- Stephane Nicoll
-
Field Summary
Fields inherited from class org.assertj.core.api.AbstractAssert
actual, info, myself, objects, throwUnsupportedExceptionOnEquals
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoesNotHaveBom
(String groupId, String artifactId) Assert thatpom.xml
does not define the specified bom.doesNotHaveDependency
(String groupId, String artifactId) Assert thatpom.xml
does not define a dependency with the specifiedgroupId
andartifactId
.doesNotHaveNode
(String path) Assertpom.xml
does not define a node with the specifiedpath
.Assertpom.xml
does not define a profile with the specifiedid
.doesNotHaveProperty
(String name) Assertpom.xml
does not define the specified property.hasArtifactId
(String artifactId) Assertpom.xml
uses the specifiedartifactId
.Assertpom.xml
defines the specified bom.hasBomsSize
(int size) Assertpom.xml
defines the specified number of boms.hasDependenciesSize
(int size) Assertpom.xml
defines the specified number of dependencies.hasDependency
(Dependency dependency) Assertpom.xml
defines the specified dependency.hasDependency
(String groupId, String artifactId) Assertpom.xml
defines the specified dependency with no version and compile scope.hasDependency
(String groupId, String artifactId, String version) Assertpom.xml
defines the specified dependency with compile scope.hasDependency
(String groupId, String artifactId, String version, String scope) Assertpom.xml
defines the specified dependency with the specified scope.hasDescription
(String description) Assertpom.xml
uses the specifieddescription
.hasGroupId
(String groupId) Assertpom.xml
uses the specifiedgroupId
.Assertpom.xml
uses the specifiedname
.hasPackaging
(String packaging) Assertpom.xml
uses the specifiedpackaging
.Assertpom.xml
defines the specified parent.hasProfile
(String id) Assertpom.xml
defines a profile with the specifiedid
.hasProperty
(String name, String value) Assertpom.xml
defines the specified property.hasRepositoriesSize
(int size) Assertpom.xml
defines the specified number of repositories.hasRepository
(String id, String name, String url, Boolean snapshotsEnabled) Assertpom.xml
defines the specified repository.Assertpom.xml
contains the specified value at the specified path.hasVersion
(String version) Assertpom.xml
uses the specifiedversion
.Methods inherited from class io.spring.initializr.generator.test.io.AbstractTextAssert
contains, containsExactly, hasSameContentAs, lines
Methods inherited from class org.assertj.core.api.AbstractStringAssert
asBase64Decoded, decodedAsBase64, isBase64, isBetween, isEqualTo, isEqualTo, isGreaterThan, isGreaterThanOrEqualTo, isLessThan, isLessThanOrEqualTo, isStrictlyBetween, usingComparator, usingComparator, usingDefaultComparator
Methods inherited from class org.assertj.core.api.AbstractCharSequenceAssert
contains, contains, containsAnyOf, containsIgnoringCase, containsIgnoringNewLines, containsIgnoringWhitespaces, containsOnlyDigits, containsOnlyOnce, containsOnlyWhitespaces, containsPattern, containsPattern, containsPatternSatisfying, containsPatternSatisfying, containsSequence, containsSequence, containsSubsequence, containsSubsequence, containsWhitespaces, doesNotContain, doesNotContain, doesNotContainAnyWhitespaces, doesNotContainIgnoringCase, doesNotContainOnlyWhitespaces, doesNotContainPattern, doesNotContainPattern, doesNotEndWith, doesNotEndWithIgnoringCase, doesNotMatch, doesNotMatch, doesNotStartWith, doesNotStartWithIgnoringCase, endsWith, endsWithIgnoringCase, hasLineCount, hasSameSizeAs, hasSameSizeAs, hasSameSizeAs, hasSize, hasSizeBetween, hasSizeGreaterThan, hasSizeGreaterThanOrEqualTo, hasSizeLessThan, hasSizeLessThanOrEqualTo, inHexadecimal, inUnicode, isAlphabetic, isAlphanumeric, isASCII, isBlank, isEmpty, isEqualToIgnoringCase, isEqualToIgnoringNewLines, isEqualToIgnoringWhitespace, isEqualToNormalizingNewlines, isEqualToNormalizingPunctuationAndWhitespace, isEqualToNormalizingUnicode, isEqualToNormalizingWhitespace, isHexadecimal, isJavaBlank, isLowerCase, isMixedCase, isNotBlank, isNotEmpty, isNotEqualToIgnoringCase, isNotEqualToIgnoringWhitespace, isNotEqualToNormalizingWhitespace, isNotJavaBlank, isNullOrEmpty, isPrintable, isSubstringOf, isUpperCase, isVisible, isXmlEqualTo, isXmlEqualToContentOf, matches, matches, matchesSatisfying, matchesSatisfying, startsWith, startsWithIgnoringCase, usingDefaultElementComparator, usingElementComparator
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, 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, usingRecursiveAssertion, usingRecursiveAssertion, usingRecursiveComparison, usingRecursiveComparison, withFailMessage, withFailMessage, withRepresentation, withThreadDumpOnError
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.assertj.core.api.Descriptable
as, as, as, describedAs
-
Constructor Details
-
MavenBuildAssert
-
MavenBuildAssert
-
-
Method Details
-
hasParent
Assertpom.xml
defines the specified parent.- Parameters:
groupId
- the groupId of the parentartifactId
- the artifactId of the parentversion
- the version of the parent- Returns:
this
assertion object
-
hasGroupId
Assertpom.xml
uses the specifiedgroupId
.- Parameters:
groupId
- the groupId of the project- Returns:
this
assertion object
-
hasArtifactId
Assertpom.xml
uses the specifiedartifactId
.- Parameters:
artifactId
- the artifactId of the project- Returns:
this
assertion object
-
hasVersion
Assertpom.xml
uses the specifiedversion
.- Parameters:
version
- the version of the project- Returns:
this
assertion object
-
hasPackaging
Assertpom.xml
uses the specifiedpackaging
.- Parameters:
packaging
- the packaging of the project- Returns:
this
assertion object
-
hasName
Assertpom.xml
uses the specifiedname
.- Parameters:
name
- the name of the project- Returns:
this
assertion object
-
hasDescription
Assertpom.xml
uses the specifieddescription
.- Parameters:
description
- the description of the project- Returns:
this
assertion object
-
hasProperty
Assertpom.xml
defines the specified property.- Parameters:
name
- the name of the propertyvalue
- the value of the property- Returns:
this
assertion object
-
doesNotHaveProperty
Assertpom.xml
does not define the specified property.- Parameters:
name
- the name of the property- Returns:
this
assertion object
-
hasDependenciesSize
Assertpom.xml
defines the specified number of dependencies.- Parameters:
size
- the number of dependencies- Returns:
this
assertion object
-
hasDependency
Assertpom.xml
defines the specified dependency with no version and compile scope.- Parameters:
groupId
- the groupId of the dependencyartifactId
- the artifactId of the dependency- Returns:
this
assertion object
-
hasDependency
Assertpom.xml
defines the specified dependency with compile scope.- Parameters:
groupId
- the groupId of the dependencyartifactId
- the artifactId of the dependencyversion
- the version of the dependency- Returns:
this
assertion object
-
hasDependency
public MavenBuildAssert hasDependency(String groupId, String artifactId, String version, String scope) Assertpom.xml
defines the specified dependency with the specified scope.- Parameters:
groupId
- the groupId of the dependencyartifactId
- the artifactId of the dependencyversion
- the version of the dependencyscope
- the scope of the dependency- Returns:
this
assertion object
-
hasDependency
Assertpom.xml
defines the specified dependency.- Parameters:
dependency
- the dependency- Returns:
this
assertion object
-
doesNotHaveDependency
Assert thatpom.xml
does not define a dependency with the specifiedgroupId
andartifactId
.- Parameters:
groupId
- the dependency's groupIdartifactId
- the dependency's artifactId- Returns:
this
assertion object
-
hasBomsSize
Assertpom.xml
defines the specified number of boms.- Parameters:
size
- the number of boms- Returns:
this
assertion object
-
hasBom
Assertpom.xml
defines the specified bom.- Parameters:
groupId
- the groupId of the bomartifactId
- the artifactId of the bomversion
- the version of the bom- Returns:
this
assertion object
-
doesNotHaveBom
Assert thatpom.xml
does not define the specified bom.- Parameters:
groupId
- the groupId of the bomartifactId
- the artifactId of the bom- Returns:
this
assertion object
-
hasRepositoriesSize
Assertpom.xml
defines the specified number of repositories.- Parameters:
size
- the number of repositories- Returns:
this
assertion object
-
hasRepository
Assertpom.xml
defines the specified repository.- Parameters:
id
- the id of the repositoryname
- the name of the repositoryurl
- the url of the repositorysnapshotsEnabled
- whether snapshot is enabled for the repository- Returns:
this
assertion object
-
hasProfile
Assertpom.xml
defines a profile with the specifiedid
.- Parameters:
id
- the id of the profile- Returns:
this
assertion object
-
doesNotHaveProfile
Assertpom.xml
does not define a profile with the specifiedid
.- Parameters:
id
- the id of the profile- Returns:
this
assertion object
-
doesNotHaveNode
Assertpom.xml
does not define a node with the specifiedpath
.- Parameters:
path
- the path of the node- Returns:
- this
-
hasText
Assertpom.xml
contains the specified value at the specified path.- Parameters:
path
- the path to the elementvalue
- the expected value of the element- Returns:
- this
-