Here are the examples of the csharp api class NUnit.Framework.Assert.AreEqual(long, long, string, params object[]) taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.
2 Examples
0
1. Example
View licensevoid AssertSeekResults (string operation) { int n = (int) Math.Min (master.Length - master.Position, mbuf.Length); int nread = chained.Read (cbuf, 0, n); int mread = master.Read (mbuf, 0, n); Assert.AreEqual (mread, nread, "Did not read the expected number of bytes from the chained stream after {0}", operation); Assert.AreEqual (master.Position, chained.Position, "The chained stream's position did not match after {0}", operation); for (int i = 0; i < n; i++) Assert.AreEqual (mbuf[i], cbuf[i], "The bytes read do not match after {0}", operation); }
0
2. Example
View licenseasync Task AssertSeekResultsAsync (string operation) { int n = (int) Math.Min (master.Length - master.Position, mbuf.Length); int nread = await chained.ReadAsync (cbuf, 0, n); int mread = await master.ReadAsync (mbuf, 0, n); Assert.AreEqual (mread, nread, "Did not read the expected number of bytes from the chained stream after {0}", operation); Assert.AreEqual (master.Position, chained.Position, "The chained stream's position did not match after {0}", operation); for (int i = 0; i < n; i++) Assert.AreEqual (mbuf[i], cbuf[i], "The bytes read do not match after {0}", operation); }