Skip to content

Instantly share code, notes, and snippets.

View DrOzturk's full-sized avatar

Ozgur Ozturk DrOzturk

View GitHub Profile
@DrOzturk
DrOzturk / StreamHelpers
Created January 8, 2015 15:43
Compare two streams for equality
public static class StreamHelpers
{
//http://stackoverflow.com/questions/968935/c-sharp-binary-file-compare
/// <summary>
/// Compares two streams, returns true if equal.
/// </summary>
/// <param name="expectedStream"></param>
/// <param name="actualStream"></param>
/// <returns></returns>
public static bool AssertEquals(this Stream expectedStream, Stream actualStream, string errorMessage)