github.com/vicanso/lru-ttl@v1.5.1/memhash_test.go (about) 1 package lruttl 2 3 import ( 4 "testing" 5 6 "github.com/stretchr/testify/assert" 7 ) 8 9 func TestMemhash(t *testing.T) { 10 assert := assert.New(t) 11 value := MemHashString("abc") 12 13 assert.Equal(value, MemHashString("abc")) 14 assert.Equal(value, MemHashString("abc")) 15 assert.NotEqual(value, MemHashString("bcd")) 16 }