
com.foursoft.vecmodel.vec120.AbstractVecPinComponentReferenceAssert Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of vec120-assertions Show documentation
Show all versions of vec120-assertions Show documentation
The Assertions Library for VEC version 1.2.0.
package com.foursoft.vecmodel.vec120;
import org.assertj.core.internal.Iterables;
import org.assertj.core.util.Objects;
/**
* Abstract base class for {@link VecPinComponentReference} specific assertions - Generated by CustomAssertionGenerator.
*/
@javax.annotation.Generated(value="assertj-assertions-generator")
public abstract class AbstractVecPinComponentReferenceAssert, A extends VecPinComponentReference> extends AbstractVecConfigurableElementAssert {
/**
* Creates a new {@link AbstractVecPinComponentReferenceAssert}
to make assertions on actual VecPinComponentReference.
* @param actual the VecPinComponentReference we want to make assertions on.
*/
protected AbstractVecPinComponentReferenceAssert(A actual, Class selfType) {
super(actual, selfType);
}
/**
* Verifies that the actual VecPinComponentReference's identification is equal to the given one.
* @param identification the given identification to compare the actual VecPinComponentReference's identification to.
* @return this assertion object.
* @throws AssertionError - if the actual VecPinComponentReference's identification is not equal to the given one.
*/
public S hasIdentification(String identification) {
// check that actual VecPinComponentReference we want to make assertions on is not null.
isNotNull();
// overrides the default error message with a more explicit one
String assertjErrorMessage = "\nExpecting identification of:\n <%s>\nto be:\n <%s>\nbut was:\n <%s>";
// null safe check
String actualIdentification = actual.getIdentification();
if (!Objects.areEqual(actualIdentification, identification)) {
failWithMessage(assertjErrorMessage, actual, identification, actualIdentification);
}
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecPinComponentReference's parentHousingComponentReference is equal to the given one.
* @param parentHousingComponentReference the given parentHousingComponentReference to compare the actual VecPinComponentReference's parentHousingComponentReference to.
* @return this assertion object.
* @throws AssertionError - if the actual VecPinComponentReference's parentHousingComponentReference is not equal to the given one.
*/
public S hasParentHousingComponentReference(VecHousingComponentReference parentHousingComponentReference) {
// check that actual VecPinComponentReference we want to make assertions on is not null.
isNotNull();
// overrides the default error message with a more explicit one
String assertjErrorMessage = "\nExpecting parentHousingComponentReference of:\n <%s>\nto be:\n <%s>\nbut was:\n <%s>";
// null safe check
VecHousingComponentReference actualParentHousingComponentReference = actual.getParentHousingComponentReference();
if (!Objects.areEqual(actualParentHousingComponentReference, parentHousingComponentReference)) {
failWithMessage(assertjErrorMessage, actual, parentHousingComponentReference, actualParentHousingComponentReference);
}
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecPinComponentReference's pinComponent is equal to the given one.
* @param pinComponent the given pinComponent to compare the actual VecPinComponentReference's pinComponent to.
* @return this assertion object.
* @throws AssertionError - if the actual VecPinComponentReference's pinComponent is not equal to the given one.
*/
public S hasPinComponent(VecPinComponent pinComponent) {
// check that actual VecPinComponentReference we want to make assertions on is not null.
isNotNull();
// overrides the default error message with a more explicit one
String assertjErrorMessage = "\nExpecting pinComponent of:\n <%s>\nto be:\n <%s>\nbut was:\n <%s>";
// null safe check
VecPinComponent actualPinComponent = actual.getPinComponent();
if (!Objects.areEqual(actualPinComponent, pinComponent)) {
failWithMessage(assertjErrorMessage, actual, pinComponent, actualPinComponent);
}
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecPinComponentReference's refPinWireMappingPoint contains the given VecPinWireMappingPoint elements.
* @param refPinWireMappingPoint the given elements that should be contained in actual VecPinComponentReference's refPinWireMappingPoint.
* @return this assertion object.
* @throws AssertionError if the actual VecPinComponentReference's refPinWireMappingPoint does not contain all given VecPinWireMappingPoint elements.
*/
public S hasRefPinWireMappingPoint(VecPinWireMappingPoint... refPinWireMappingPoint) {
// check that actual VecPinComponentReference we want to make assertions on is not null.
isNotNull();
// check that given VecPinWireMappingPoint varargs is not null.
if (refPinWireMappingPoint == null) failWithMessage("Expecting refPinWireMappingPoint parameter not to be null.");
// check with standard error message, to set another message call: info.overridingErrorMessage("my error message");
Iterables.instance().assertContains(info, actual.getRefPinWireMappingPoint(), refPinWireMappingPoint);
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecPinComponentReference's refPinWireMappingPoint contains the given VecPinWireMappingPoint elements in Collection.
* @param refPinWireMappingPoint the given elements that should be contained in actual VecPinComponentReference's refPinWireMappingPoint.
* @return this assertion object.
* @throws AssertionError if the actual VecPinComponentReference's refPinWireMappingPoint does not contain all given VecPinWireMappingPoint elements.
*/
public S hasRefPinWireMappingPoint(java.util.Collection extends VecPinWireMappingPoint> refPinWireMappingPoint) {
// check that actual VecPinComponentReference we want to make assertions on is not null.
isNotNull();
// check that given VecPinWireMappingPoint collection is not null.
if (refPinWireMappingPoint == null) {
failWithMessage("Expecting refPinWireMappingPoint parameter not to be null.");
return myself; // to fool Eclipse "Null pointer access" warning on toArray.
}
// check with standard error message, to set another message call: info.overridingErrorMessage("my error message");
Iterables.instance().assertContains(info, actual.getRefPinWireMappingPoint(), refPinWireMappingPoint.toArray());
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecPinComponentReference's refPinWireMappingPoint contains only the given VecPinWireMappingPoint elements and nothing else in whatever order.
* @param refPinWireMappingPoint the given elements that should be contained in actual VecPinComponentReference's refPinWireMappingPoint.
* @return this assertion object.
* @throws AssertionError if the actual VecPinComponentReference's refPinWireMappingPoint does not contain all given VecPinWireMappingPoint elements.
*/
public S hasOnlyRefPinWireMappingPoint(VecPinWireMappingPoint... refPinWireMappingPoint) {
// check that actual VecPinComponentReference we want to make assertions on is not null.
isNotNull();
// check that given VecPinWireMappingPoint varargs is not null.
if (refPinWireMappingPoint == null) failWithMessage("Expecting refPinWireMappingPoint parameter not to be null.");
// check with standard error message, to set another message call: info.overridingErrorMessage("my error message");
Iterables.instance().assertContainsOnly(info, actual.getRefPinWireMappingPoint(), refPinWireMappingPoint);
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecPinComponentReference's refPinWireMappingPoint contains only the given VecPinWireMappingPoint elements in Collection and nothing else in whatever order.
* @param refPinWireMappingPoint the given elements that should be contained in actual VecPinComponentReference's refPinWireMappingPoint.
* @return this assertion object.
* @throws AssertionError if the actual VecPinComponentReference's refPinWireMappingPoint does not contain all given VecPinWireMappingPoint elements.
*/
public S hasOnlyRefPinWireMappingPoint(java.util.Collection extends VecPinWireMappingPoint> refPinWireMappingPoint) {
// check that actual VecPinComponentReference we want to make assertions on is not null.
isNotNull();
// check that given VecPinWireMappingPoint collection is not null.
if (refPinWireMappingPoint == null) {
failWithMessage("Expecting refPinWireMappingPoint parameter not to be null.");
return myself; // to fool Eclipse "Null pointer access" warning on toArray.
}
// check with standard error message, to set another message call: info.overridingErrorMessage("my error message");
Iterables.instance().assertContainsOnly(info, actual.getRefPinWireMappingPoint(), refPinWireMappingPoint.toArray());
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecPinComponentReference's refPinWireMappingPoint does not contain the given VecPinWireMappingPoint elements.
*
* @param refPinWireMappingPoint the given elements that should not be in actual VecPinComponentReference's refPinWireMappingPoint.
* @return this assertion object.
* @throws AssertionError if the actual VecPinComponentReference's refPinWireMappingPoint contains any given VecPinWireMappingPoint elements.
*/
public S doesNotHaveRefPinWireMappingPoint(VecPinWireMappingPoint... refPinWireMappingPoint) {
// check that actual VecPinComponentReference we want to make assertions on is not null.
isNotNull();
// check that given VecPinWireMappingPoint varargs is not null.
if (refPinWireMappingPoint == null) failWithMessage("Expecting refPinWireMappingPoint parameter not to be null.");
// check with standard error message (use overridingErrorMessage before contains to set your own message).
Iterables.instance().assertDoesNotContain(info, actual.getRefPinWireMappingPoint(), refPinWireMappingPoint);
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecPinComponentReference's refPinWireMappingPoint does not contain the given VecPinWireMappingPoint elements in Collection.
*
* @param refPinWireMappingPoint the given elements that should not be in actual VecPinComponentReference's refPinWireMappingPoint.
* @return this assertion object.
* @throws AssertionError if the actual VecPinComponentReference's refPinWireMappingPoint contains any given VecPinWireMappingPoint elements.
*/
public S doesNotHaveRefPinWireMappingPoint(java.util.Collection extends VecPinWireMappingPoint> refPinWireMappingPoint) {
// check that actual VecPinComponentReference we want to make assertions on is not null.
isNotNull();
// check that given VecPinWireMappingPoint collection is not null.
if (refPinWireMappingPoint == null) {
failWithMessage("Expecting refPinWireMappingPoint parameter not to be null.");
return myself; // to fool Eclipse "Null pointer access" warning on toArray.
}
// check with standard error message (use overridingErrorMessage before contains to set your own message).
Iterables.instance().assertDoesNotContain(info, actual.getRefPinWireMappingPoint(), refPinWireMappingPoint.toArray());
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecPinComponentReference has no refPinWireMappingPoint.
* @return this assertion object.
* @throws AssertionError if the actual VecPinComponentReference's refPinWireMappingPoint is not empty.
*/
public S hasNoRefPinWireMappingPoint() {
// check that actual VecPinComponentReference we want to make assertions on is not null.
isNotNull();
// we override the default error message with a more explicit one
String assertjErrorMessage = "\nExpecting :\n <%s>\nnot to have refPinWireMappingPoint but had :\n <%s>";
// check
if (actual.getRefPinWireMappingPoint().iterator().hasNext()) {
failWithMessage(assertjErrorMessage, actual, actual.getRefPinWireMappingPoint());
}
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecPinComponentReference's terminalRole is equal to the given one.
* @param terminalRole the given terminalRole to compare the actual VecPinComponentReference's terminalRole to.
* @return this assertion object.
* @throws AssertionError - if the actual VecPinComponentReference's terminalRole is not equal to the given one.
*/
public S hasTerminalRole(VecTerminalRole terminalRole) {
// check that actual VecPinComponentReference we want to make assertions on is not null.
isNotNull();
// overrides the default error message with a more explicit one
String assertjErrorMessage = "\nExpecting terminalRole of:\n <%s>\nto be:\n <%s>\nbut was:\n <%s>";
// null safe check
VecTerminalRole actualTerminalRole = actual.getTerminalRole();
if (!Objects.areEqual(actualTerminalRole, terminalRole)) {
failWithMessage(assertjErrorMessage, actual, terminalRole, actualTerminalRole);
}
// return the current assertion for method chaining
return myself;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy