FloatingPointAssertions<T>.BeApproximately Method
Definition
Asserts that the floating-point value is approximately equal to the expected value within the specified precision.
public FloatingPointAssertionsChain<T> BeApproximately(T expected, T precision);
Parameters
| Name | Type | Description |
|---|---|---|
expected |
T |
The expected value. |
precision |
T |
The maximum allowed difference between the value and the expected value. |
Returns
FloatingPointAssertionsChain<T>
A FloatingPointAssertionsChain<T> for chaining further assertions.