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