diff options
author | Ori Bernstein <ori@markovcorp.com> | 2017-07-18 11:04:09 -0700 |
---|---|---|
committer | Ori Bernstein <ori@markovcorp.com> | 2017-07-18 11:04:09 -0700 |
commit | 80e1f20064f435fba7b4c7be70fd6b19c5218cc3 (patch) | |
tree | f39b4416f37844337003cc3bf15316731881ed23 | |
parent | 9fef96e3fc0e48ed435bda6345c0a50b1876a436 (diff) | |
download | mc-80e1f20064f435fba7b4c7be70fd6b19c5218cc3.tar.gz |
Update hashes in tests to match fixed algorithm.
-rw-r--r-- | lib/std/test/bitset.myr | 6 | ||||
-rw-r--r-- | lib/std/test/hashfuncs.myr | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/lib/std/test/bitset.myr b/lib/std/test/bitset.myr index 13706a6..9112537 100644 --- a/lib/std/test/bitset.myr +++ b/lib/std/test/bitset.myr @@ -49,11 +49,11 @@ const main = { }], [.name="hash", .fn={ctx var bs = mkset([][:]) - testr.check(ctx, std.bshash(bs) == 493832887, "wrong hash, expected {}", std.bshash(bs)) + testr.check(ctx, std.bshash(bs) == 2580988821, "wrong hash, got {}", std.bshash(bs)) std.bsput(bs, 123456) - testr.check(ctx, std.bshash(bs) == 746495367, "wrong hash, expected {}", std.bshash(bs)) + testr.check(ctx, std.bshash(bs) == 2020624217, "wrong hash, got {}", std.bshash(bs)) std.bsdel(bs, 123456) - testr.check(ctx, std.bshash(bs) == 493832887, "wrong hash, expected {}", std.bshash(bs)) + testr.check(ctx, std.bshash(bs) == 2580988821, "wrong hash, got {}", std.bshash(bs)) std.bsfree(bs) }] ][:]) diff --git a/lib/std/test/hashfuncs.myr b/lib/std/test/hashfuncs.myr index 9132f2b..d2b1161 100644 --- a/lib/std/test/hashfuncs.myr +++ b/lib/std/test/hashfuncs.myr @@ -15,7 +15,7 @@ const main = { std.assert(std.ptreq(&x, &x), "equal pointers not equal") std.assert(!std.ptreq(&x, &y), "unequal pointers are equal") - std.assert(std.inthash(123) == 2379201998, "wrong int hash") + std.assert(std.inthash(123) == 3497506805, "wrong int hash") std.assert(std.inteq(123, 123), "equal integers not equal") std.assert(!std.inteq(123, 456), "unequal integers are equal") |