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