public void CompressStringCompressesAString() { var service = new ZipCompressionService(); var inputString = "This is a string to compress - with multiple data, data, data!"; var expected = "eJxNxEEKwCAMBMCvrPf6m34gtGICRsWs9PvtsTDMqRb4CILLegUHruFzlQhkPEaF70abreAWyvE7vbhUFbg="; var actual = service.CompressString(inputString); Assert.AreEqual(expected, actual); }
public void CompressStringValidatesInput() { var service = new ZipCompressionService(); var error = Assert.Throws<ArgumentNullException>(() => { service.CompressString(null); }); Assert.AreEqual("value", error.ParamName); }