mirror of
https://github.com/adamhathcock/sharpcompress.git
synced 2026-09-22 15:04:43 +00:00
Use more meaningful error message
This commit is contained in:
@@ -122,14 +122,14 @@ namespace SharpCompress.Test
|
||||
using (var file2Stream = File.OpenRead(file2))
|
||||
{
|
||||
Assert.AreEqual(file1Stream.Length, file2Stream.Length);
|
||||
|
||||
int byte1 = 0;
|
||||
int byte2 = 0;
|
||||
while (byte1 != -1)
|
||||
for (int counter = 0; byte1 != -1; counter++ )
|
||||
{
|
||||
byte1 = file1Stream.ReadByte();
|
||||
byte2 = file2Stream.ReadByte();
|
||||
Assert.AreEqual(byte1, byte2);
|
||||
if (byte1 != byte2) Assert.AreEqual(byte1, byte2, string.Format("Byte {0} differ between {1} and {2}",
|
||||
counter, file1, file2));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user