public void CompareBytes_DifferentInputInArguments_ReturnsFalse() { AesCryptography aes = new AesCryptography(); // Test that different inputs will result in 'false' being returned eventhough the input length are identical. Assert.IsFalse(aes.CompareBytes(Encoding.UTF8.GetBytes(BYTE_STREAM1), Encoding.UTF8.GetBytes(BYTE_STREAM2))); // Test that identical inputs will result in 'true' being returned. Assert.IsTrue(aes.CompareBytes(Encoding.UTF8.GetBytes(BYTE_STREAM1), Encoding.UTF8.GetBytes(BYTE_STREAM_IDENTICAL_TO_STREAM1))); }
public void CompareBytes_DifferentLengthOfArguments_ReturnsFalse() { AesCryptography aes = new AesCryptography(); // Test that different length of inputs will result in 'false' being returned. Assert.IsFalse(aes.CompareBytes(Encoding.UTF8.GetBytes(BYTE_STREAM1), Encoding.UTF8.GetBytes(LONGER_BYTE_STREAM))); }
public void CompareBytes_IdenticalInput_ReturnsTrue() { AesCryptography aes = new AesCryptography(); // Test that identical inputs will result in 'true' being returned. Assert.IsTrue(aes.CompareBytes(Encoding.UTF8.GetBytes(BYTE_STREAM1), Encoding.UTF8.GetBytes(BYTE_STREAM_IDENTICAL_TO_STREAM1))); }