
com.foursoft.vecmodel.vec120.AbstractVecCapacitorSpecificationAssert 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.util.Objects;
/**
* Abstract base class for {@link VecCapacitorSpecification} specific assertions - Generated by CustomAssertionGenerator.
*/
@javax.annotation.Generated(value="assertj-assertions-generator")
public abstract class AbstractVecCapacitorSpecificationAssert, A extends VecCapacitorSpecification> extends AbstractVecEEComponentSpecificationAssert {
/**
* Creates a new {@link AbstractVecCapacitorSpecificationAssert}
to make assertions on actual VecCapacitorSpecification.
* @param actual the VecCapacitorSpecification we want to make assertions on.
*/
protected AbstractVecCapacitorSpecificationAssert(A actual, Class selfType) {
super(actual, selfType);
}
/**
* Verifies that the actual VecCapacitorSpecification's capacity is equal to the given one.
* @param capacity the given capacity to compare the actual VecCapacitorSpecification's capacity to.
* @return this assertion object.
* @throws AssertionError - if the actual VecCapacitorSpecification's capacity is not equal to the given one.
*/
public S hasCapacity(VecNumericalValue capacity) {
// check that actual VecCapacitorSpecification we want to make assertions on is not null.
isNotNull();
// overrides the default error message with a more explicit one
String assertjErrorMessage = "\nExpecting capacity of:\n <%s>\nto be:\n <%s>\nbut was:\n <%s>";
// null safe check
VecNumericalValue actualCapacity = actual.getCapacity();
if (!Objects.areEqual(actualCapacity, capacity)) {
failWithMessage(assertjErrorMessage, actual, capacity, actualCapacity);
}
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecCapacitorSpecification's impedance is equal to the given one.
* @param impedance the given impedance to compare the actual VecCapacitorSpecification's impedance to.
* @return this assertion object.
* @throws AssertionError - if the actual VecCapacitorSpecification's impedance is not equal to the given one.
*/
public S hasImpedance(VecNumericalValue impedance) {
// check that actual VecCapacitorSpecification we want to make assertions on is not null.
isNotNull();
// overrides the default error message with a more explicit one
String assertjErrorMessage = "\nExpecting impedance of:\n <%s>\nto be:\n <%s>\nbut was:\n <%s>";
// null safe check
VecNumericalValue actualImpedance = actual.getImpedance();
if (!Objects.areEqual(actualImpedance, impedance)) {
failWithMessage(assertjErrorMessage, actual, impedance, actualImpedance);
}
// return the current assertion for method chaining
return myself;
}
/**
* Verifies that the actual VecCapacitorSpecification's uMax is equal to the given one.
* @param uMax the given uMax to compare the actual VecCapacitorSpecification's uMax to.
* @return this assertion object.
* @throws AssertionError - if the actual VecCapacitorSpecification's uMax is not equal to the given one.
*/
public S hasUMax(VecNumericalValue uMax) {
// check that actual VecCapacitorSpecification we want to make assertions on is not null.
isNotNull();
// overrides the default error message with a more explicit one
String assertjErrorMessage = "\nExpecting uMax of:\n <%s>\nto be:\n <%s>\nbut was:\n <%s>";
// null safe check
VecNumericalValue actualUMax = actual.getUMax();
if (!Objects.areEqual(actualUMax, uMax)) {
failWithMessage(assertjErrorMessage, actual, uMax, actualUMax);
}
// return the current assertion for method chaining
return myself;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy