Skip to content

Commit

Permalink
Refactor the use of our own MD5 Implementation
Browse files Browse the repository at this point in the history
There are subsequent pull requests that expect the Md5CryptographicService to exit. Rather than rename that file (from a P/R), a better approach is to separate the MD5 implementation into it's own
file, then restore the MD5Service and just have it change the algorithm it uses.
  • Loading branch information
BiggerNoise committed Oct 9, 2017
1 parent 7174087 commit d5678b4
Show file tree
Hide file tree
Showing 6 changed files with 597 additions and 594 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public class when_using_MD5_to_do_cryptography
[SetUp]
public void we_set_the_context()
{
md5_crypto = new ManagedMD5CryptographicService();
md5_crypto = new MD5CryptographicService();
}

[Test]
Expand All @@ -62,7 +62,7 @@ public class when_using_an_unofficial_md5_implementation

private ThreadLocal<Random> _rng;
private ThreadLocal<byte[]> _bytes = new ThreadLocal<byte[]>(() => new byte[max_len]);
private ThreadLocal<ManagedMD5CryptographicService.MD5> _unofficial = new ThreadLocal<ManagedMD5CryptographicService.MD5>(() => new ManagedMD5CryptographicService.MD5());
private ThreadLocal<LocalMD5Implementation> _unofficial = new ThreadLocal<LocalMD5Implementation>(() => new LocalMD5Implementation());
private ThreadLocal<MD5> _official = new ThreadLocal<MD5>(() => MD5.Create());

[SetUp]
Expand Down
Loading

0 comments on commit d5678b4

Please sign in to comment.