
com.foursoft.vecmodel.vec120.AbstractVecSlotCouplingAssert 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 VecSlotCoupling} specific assertions - Generated by CustomAssertionGenerator.
*/
@javax.annotation.Generated(value="assertj-assertions-generator")
public abstract class AbstractVecSlotCouplingAssert, A extends VecSlotCoupling> extends AbstractVecConfigurableElementAssert {
/**
* Creates a new {@link AbstractVecSlotCouplingAssert}
to make assertions on actual VecSlotCoupling.
* @param actual the VecSlotCoupling we want to make assertions on.
*/
protected AbstractVecSlotCouplingAssert(A actual, Class selfType) {
super(actual, selfType);
}
/**
* Verifies that the actual VecSlotCoupling's cavityCouplings contains the given VecCavityCoupling elements.
* @param cavityCouplings the given elements that should be contained in actual VecSlotCoupling's cavityCouplings.
* @return this assertion object.
* @throws AssertionError if the actual VecSlotCoupling's cavityCouplings does not contain all given VecCavityCoupling elements.
*/
public S hasCavityCouplings(VecCavityCoupling... cavityCouplings) {
// check that actual VecSlotCoupling we want to make assertions on is not null.
isNotNull();
// check that given VecCavityCoupling varargs is not null.
if (cavityCouplings == null) failWithMessage("Expecting cavityCouplings 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.getCavityCouplings(), cavityCouplings);
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecSlotCoupling's cavityCouplings contains the given VecCavityCoupling elements in Collection.
* @param cavityCouplings the given elements that should be contained in actual VecSlotCoupling's cavityCouplings.
* @return this assertion object.
* @throws AssertionError if the actual VecSlotCoupling's cavityCouplings does not contain all given VecCavityCoupling elements.
*/
public S hasCavityCouplings(java.util.Collection extends VecCavityCoupling> cavityCouplings) {
// check that actual VecSlotCoupling we want to make assertions on is not null.
isNotNull();
// check that given VecCavityCoupling collection is not null.
if (cavityCouplings == null) {
failWithMessage("Expecting cavityCouplings 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.getCavityCouplings(), cavityCouplings.toArray());
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecSlotCoupling's cavityCouplings contains only the given VecCavityCoupling elements and nothing else in whatever order.
* @param cavityCouplings the given elements that should be contained in actual VecSlotCoupling's cavityCouplings.
* @return this assertion object.
* @throws AssertionError if the actual VecSlotCoupling's cavityCouplings does not contain all given VecCavityCoupling elements.
*/
public S hasOnlyCavityCouplings(VecCavityCoupling... cavityCouplings) {
// check that actual VecSlotCoupling we want to make assertions on is not null.
isNotNull();
// check that given VecCavityCoupling varargs is not null.
if (cavityCouplings == null) failWithMessage("Expecting cavityCouplings 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.getCavityCouplings(), cavityCouplings);
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecSlotCoupling's cavityCouplings contains only the given VecCavityCoupling elements in Collection and nothing else in whatever order.
* @param cavityCouplings the given elements that should be contained in actual VecSlotCoupling's cavityCouplings.
* @return this assertion object.
* @throws AssertionError if the actual VecSlotCoupling's cavityCouplings does not contain all given VecCavityCoupling elements.
*/
public S hasOnlyCavityCouplings(java.util.Collection extends VecCavityCoupling> cavityCouplings) {
// check that actual VecSlotCoupling we want to make assertions on is not null.
isNotNull();
// check that given VecCavityCoupling collection is not null.
if (cavityCouplings == null) {
failWithMessage("Expecting cavityCouplings 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.getCavityCouplings(), cavityCouplings.toArray());
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecSlotCoupling's cavityCouplings does not contain the given VecCavityCoupling elements.
*
* @param cavityCouplings the given elements that should not be in actual VecSlotCoupling's cavityCouplings.
* @return this assertion object.
* @throws AssertionError if the actual VecSlotCoupling's cavityCouplings contains any given VecCavityCoupling elements.
*/
public S doesNotHaveCavityCouplings(VecCavityCoupling... cavityCouplings) {
// check that actual VecSlotCoupling we want to make assertions on is not null.
isNotNull();
// check that given VecCavityCoupling varargs is not null.
if (cavityCouplings == null) failWithMessage("Expecting cavityCouplings parameter not to be null.");
// check with standard error message (use overridingErrorMessage before contains to set your own message).
Iterables.instance().assertDoesNotContain(info, actual.getCavityCouplings(), cavityCouplings);
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecSlotCoupling's cavityCouplings does not contain the given VecCavityCoupling elements in Collection.
*
* @param cavityCouplings the given elements that should not be in actual VecSlotCoupling's cavityCouplings.
* @return this assertion object.
* @throws AssertionError if the actual VecSlotCoupling's cavityCouplings contains any given VecCavityCoupling elements.
*/
public S doesNotHaveCavityCouplings(java.util.Collection extends VecCavityCoupling> cavityCouplings) {
// check that actual VecSlotCoupling we want to make assertions on is not null.
isNotNull();
// check that given VecCavityCoupling collection is not null.
if (cavityCouplings == null) {
failWithMessage("Expecting cavityCouplings 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.getCavityCouplings(), cavityCouplings.toArray());
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecSlotCoupling has no cavityCouplings.
* @return this assertion object.
* @throws AssertionError if the actual VecSlotCoupling's cavityCouplings is not empty.
*/
public S hasNoCavityCouplings() {
// check that actual VecSlotCoupling 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 cavityCouplings but had :\n <%s>";
// check
if (actual.getCavityCouplings().iterator().hasNext()) {
failWithMessage(assertjErrorMessage, actual, actual.getCavityCouplings());
}
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecSlotCoupling's firstSlot is equal to the given one.
* @param firstSlot the given firstSlot to compare the actual VecSlotCoupling's firstSlot to.
* @return this assertion object.
* @throws AssertionError - if the actual VecSlotCoupling's firstSlot is not equal to the given one.
*/
public S hasFirstSlot(VecAbstractSlotReference firstSlot) {
// check that actual VecSlotCoupling we want to make assertions on is not null.
isNotNull();
// overrides the default error message with a more explicit one
String assertjErrorMessage = "\nExpecting firstSlot of:\n <%s>\nto be:\n <%s>\nbut was:\n <%s>";
// null safe check
VecAbstractSlotReference actualFirstSlot = actual.getFirstSlot();
if (!Objects.areEqual(actualFirstSlot, firstSlot)) {
failWithMessage(assertjErrorMessage, actual, firstSlot, actualFirstSlot);
}
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecSlotCoupling's identification is equal to the given one.
* @param identification the given identification to compare the actual VecSlotCoupling's identification to.
* @return this assertion object.
* @throws AssertionError - if the actual VecSlotCoupling's identification is not equal to the given one.
*/
public S hasIdentification(String identification) {
// check that actual VecSlotCoupling 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 VecSlotCoupling's parentCouplingPoint is equal to the given one.
* @param parentCouplingPoint the given parentCouplingPoint to compare the actual VecSlotCoupling's parentCouplingPoint to.
* @return this assertion object.
* @throws AssertionError - if the actual VecSlotCoupling's parentCouplingPoint is not equal to the given one.
*/
public S hasParentCouplingPoint(VecCouplingPoint parentCouplingPoint) {
// check that actual VecSlotCoupling we want to make assertions on is not null.
isNotNull();
// overrides the default error message with a more explicit one
String assertjErrorMessage = "\nExpecting parentCouplingPoint of:\n <%s>\nto be:\n <%s>\nbut was:\n <%s>";
// null safe check
VecCouplingPoint actualParentCouplingPoint = actual.getParentCouplingPoint();
if (!Objects.areEqual(actualParentCouplingPoint, parentCouplingPoint)) {
failWithMessage(assertjErrorMessage, actual, parentCouplingPoint, actualParentCouplingPoint);
}
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecSlotCoupling's secondSlot is equal to the given one.
* @param secondSlot the given secondSlot to compare the actual VecSlotCoupling's secondSlot to.
* @return this assertion object.
* @throws AssertionError - if the actual VecSlotCoupling's secondSlot is not equal to the given one.
*/
public S hasSecondSlot(VecAbstractSlotReference secondSlot) {
// check that actual VecSlotCoupling we want to make assertions on is not null.
isNotNull();
// overrides the default error message with a more explicit one
String assertjErrorMessage = "\nExpecting secondSlot of:\n <%s>\nto be:\n <%s>\nbut was:\n <%s>";
// null safe check
VecAbstractSlotReference actualSecondSlot = actual.getSecondSlot();
if (!Objects.areEqual(actualSecondSlot, secondSlot)) {
failWithMessage(assertjErrorMessage, actual, secondSlot, actualSecondSlot);
}
// return the current assertion for method chaining
return myself;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy