public void Decode_InvalidDigit2() { byte[] decoded; var result = SortableBase64.TryDecode("\u2368", out decoded); result.Should().BeFalse(); decoded.Should().BeNull(); }
public void RoundTrip([Range(0, 32, 1)] int length) { var original = new byte[length]; lock (_random) _random.NextBytes(original); byte[] decoded; var code64 = SortableBase64.Encode(original); var result = SortableBase64.TryDecode(code64, out decoded); result.Should().BeTrue(); decoded.Should().Equal(original); }