
com.foursoft.vecmodel.vec120.AbstractVecConnectorHousingCapSpecificationAssert 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 VecConnectorHousingCapSpecification} specific assertions - Generated by CustomAssertionGenerator.
*/
@javax.annotation.Generated(value="assertj-assertions-generator")
public abstract class AbstractVecConnectorHousingCapSpecificationAssert, A extends VecConnectorHousingCapSpecification> extends AbstractVecPartOrUsageRelatedSpecificationAssert {
/**
* Creates a new {@link AbstractVecConnectorHousingCapSpecificationAssert}
to make assertions on actual VecConnectorHousingCapSpecification.
* @param actual the VecConnectorHousingCapSpecification we want to make assertions on.
*/
protected AbstractVecConnectorHousingCapSpecificationAssert(A actual, Class selfType) {
super(actual, selfType);
}
/**
* Verifies that the actual VecConnectorHousingCapSpecification's outletDirection is equal to the given one.
* @param outletDirection the given outletDirection to compare the actual VecConnectorHousingCapSpecification's outletDirection to.
* @return this assertion object.
* @throws AssertionError - if the actual VecConnectorHousingCapSpecification's outletDirection is not equal to the given one.
*/
public S hasOutletDirection(String outletDirection) {
// check that actual VecConnectorHousingCapSpecification we want to make assertions on is not null.
isNotNull();
// overrides the default error message with a more explicit one
String assertjErrorMessage = "\nExpecting outletDirection of:\n <%s>\nto be:\n <%s>\nbut was:\n <%s>";
// null safe check
String actualOutletDirection = actual.getOutletDirection();
if (!Objects.areEqual(actualOutletDirection, outletDirection)) {
failWithMessage(assertjErrorMessage, actual, outletDirection, actualOutletDirection);
}
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole contains the given VecConnectorHousingCapRole elements.
* @param refConnectorHousingCapRole the given elements that should be contained in actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole.
* @return this assertion object.
* @throws AssertionError if the actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole does not contain all given VecConnectorHousingCapRole elements.
*/
public S hasRefConnectorHousingCapRole(VecConnectorHousingCapRole... refConnectorHousingCapRole) {
// check that actual VecConnectorHousingCapSpecification we want to make assertions on is not null.
isNotNull();
// check that given VecConnectorHousingCapRole varargs is not null.
if (refConnectorHousingCapRole == null) failWithMessage("Expecting refConnectorHousingCapRole 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.getRefConnectorHousingCapRole(), refConnectorHousingCapRole);
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole contains the given VecConnectorHousingCapRole elements in Collection.
* @param refConnectorHousingCapRole the given elements that should be contained in actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole.
* @return this assertion object.
* @throws AssertionError if the actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole does not contain all given VecConnectorHousingCapRole elements.
*/
public S hasRefConnectorHousingCapRole(java.util.Collection extends VecConnectorHousingCapRole> refConnectorHousingCapRole) {
// check that actual VecConnectorHousingCapSpecification we want to make assertions on is not null.
isNotNull();
// check that given VecConnectorHousingCapRole collection is not null.
if (refConnectorHousingCapRole == null) {
failWithMessage("Expecting refConnectorHousingCapRole 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.getRefConnectorHousingCapRole(), refConnectorHousingCapRole.toArray());
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole contains only the given VecConnectorHousingCapRole elements and nothing else in whatever order.
* @param refConnectorHousingCapRole the given elements that should be contained in actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole.
* @return this assertion object.
* @throws AssertionError if the actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole does not contain all given VecConnectorHousingCapRole elements.
*/
public S hasOnlyRefConnectorHousingCapRole(VecConnectorHousingCapRole... refConnectorHousingCapRole) {
// check that actual VecConnectorHousingCapSpecification we want to make assertions on is not null.
isNotNull();
// check that given VecConnectorHousingCapRole varargs is not null.
if (refConnectorHousingCapRole == null) failWithMessage("Expecting refConnectorHousingCapRole 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.getRefConnectorHousingCapRole(), refConnectorHousingCapRole);
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole contains only the given VecConnectorHousingCapRole elements in Collection and nothing else in whatever order.
* @param refConnectorHousingCapRole the given elements that should be contained in actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole.
* @return this assertion object.
* @throws AssertionError if the actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole does not contain all given VecConnectorHousingCapRole elements.
*/
public S hasOnlyRefConnectorHousingCapRole(java.util.Collection extends VecConnectorHousingCapRole> refConnectorHousingCapRole) {
// check that actual VecConnectorHousingCapSpecification we want to make assertions on is not null.
isNotNull();
// check that given VecConnectorHousingCapRole collection is not null.
if (refConnectorHousingCapRole == null) {
failWithMessage("Expecting refConnectorHousingCapRole 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.getRefConnectorHousingCapRole(), refConnectorHousingCapRole.toArray());
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole does not contain the given VecConnectorHousingCapRole elements.
*
* @param refConnectorHousingCapRole the given elements that should not be in actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole.
* @return this assertion object.
* @throws AssertionError if the actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole contains any given VecConnectorHousingCapRole elements.
*/
public S doesNotHaveRefConnectorHousingCapRole(VecConnectorHousingCapRole... refConnectorHousingCapRole) {
// check that actual VecConnectorHousingCapSpecification we want to make assertions on is not null.
isNotNull();
// check that given VecConnectorHousingCapRole varargs is not null.
if (refConnectorHousingCapRole == null) failWithMessage("Expecting refConnectorHousingCapRole parameter not to be null.");
// check with standard error message (use overridingErrorMessage before contains to set your own message).
Iterables.instance().assertDoesNotContain(info, actual.getRefConnectorHousingCapRole(), refConnectorHousingCapRole);
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole does not contain the given VecConnectorHousingCapRole elements in Collection.
*
* @param refConnectorHousingCapRole the given elements that should not be in actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole.
* @return this assertion object.
* @throws AssertionError if the actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole contains any given VecConnectorHousingCapRole elements.
*/
public S doesNotHaveRefConnectorHousingCapRole(java.util.Collection extends VecConnectorHousingCapRole> refConnectorHousingCapRole) {
// check that actual VecConnectorHousingCapSpecification we want to make assertions on is not null.
isNotNull();
// check that given VecConnectorHousingCapRole collection is not null.
if (refConnectorHousingCapRole == null) {
failWithMessage("Expecting refConnectorHousingCapRole 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.getRefConnectorHousingCapRole(), refConnectorHousingCapRole.toArray());
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecConnectorHousingCapSpecification has no refConnectorHousingCapRole.
* @return this assertion object.
* @throws AssertionError if the actual VecConnectorHousingCapSpecification's refConnectorHousingCapRole is not empty.
*/
public S hasNoRefConnectorHousingCapRole() {
// check that actual VecConnectorHousingCapSpecification 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 refConnectorHousingCapRole but had :\n <%s>";
// check
if (actual.getRefConnectorHousingCapRole().iterator().hasNext()) {
failWithMessage(assertjErrorMessage, actual, actual.getRefConnectorHousingCapRole());
}
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecConnectorHousingCapSpecification's wireAddOn is equal to the given one.
* @param wireAddOn the given wireAddOn to compare the actual VecConnectorHousingCapSpecification's wireAddOn to.
* @return this assertion object.
* @throws AssertionError - if the actual VecConnectorHousingCapSpecification's wireAddOn is not equal to the given one.
*/
public S hasWireAddOn(VecNumericalValue wireAddOn) {
// check that actual VecConnectorHousingCapSpecification we want to make assertions on is not null.
isNotNull();
// overrides the default error message with a more explicit one
String assertjErrorMessage = "\nExpecting wireAddOn of:\n <%s>\nto be:\n <%s>\nbut was:\n <%s>";
// null safe check
VecNumericalValue actualWireAddOn = actual.getWireAddOn();
if (!Objects.areEqual(actualWireAddOn, wireAddOn)) {
failWithMessage(assertjErrorMessage, actual, wireAddOn, actualWireAddOn);
}
// return the current assertion for method chaining
return myself;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy