public void TestMethod1() { string expectedOutputFile = "outputfile1.txt"; string actualOutputFile = Guid.NewGuid() + ".txt"; Substitute.Process( new[] { "inputfile1.txt", "inputdata1.txt", actualOutputFile }); var expected = File.ReadAllBytes(expectedOutputFile); var actual = File.ReadAllBytes(actualOutputFile); Assert.AreEqual <int>(expected.Length, actual.Length); for (int i = 0; i < expected.Length; i++) { Assert.AreEqual <byte>(expected[i], actual[i]); } }