fix hashutil test
@@ -27,11 +27,7 @@ func TestHashCompare(t *testing.T) {
// Lets flip some runes in the hash to make it invalid
_hash := []byte(hash)
- _hash[10] = 'a'
- _hash[11] = 'b'
- _hash[12] = 'c'
- _hash[13] = 'd'
- _hash[14] = 'e'
+ _hash[10]++
hash = string(_hash)
ok, err = Compare(token, hash)
@@ -62,9 +58,11 @@ func TestHashComparePepper(t *testing.T) {
assert.Nil(t, err)
assert.True(t, ok)
- // Lets flip a rune in the hash to make it invalid
+ // Lets flip some runes in the hash to make it invalid
_hash := []byte(hash)
_hash[10] = 'a'
+ _hash[11] = 'b'
+ _hash[12] = 'c'
hash = string(_hash)
ok, err = Compare(token, hash, pepperGetter)
