diff --git a/src/Managed.UnitTests/AssertHelpers.cs b/src/Managed.UnitTests/AssertHelpers.cs
index 5d3c397e..05f5b971 100644
--- a/src/Managed.UnitTests/AssertHelpers.cs
+++ b/src/Managed.UnitTests/AssertHelpers.cs
@@ -98,6 +98,24 @@ namespace MathNet.Numerics.UnitTests
}
}
+ ///
+ /// Asserts that the expected value and the actual value are equal up to a certain
+ /// maximum error.
+ ///
+ /// The expected value list.
+ /// The actual value list.
+ /// The accuracy required for being almost equal.
+ public static void AlmostEqualList(IList expected, IList actual, double maximumError)
+ {
+ for (int i = 0; i < expected.Count; i++)
+ {
+ if (!actual[i].AlmostEqualWithError(expected[i], maximumError))
+ {
+ Assert.Fail("Not equal within a maximum error {0}. Expected:{1}; Actual:{2}", maximumError, expected[i], actual[i]);
+ }
+ }
+ }
+
///
/// Asserts that the expected value and the actual value are equal up to a certain
/// maximum error.