forked from p53841790/wheat-cache
test(lru): update test
This commit is contained in:
parent
99dd878bb3
commit
29c5aca40d
|
@ -1,8 +1,8 @@
|
||||||
package lru
|
package lru
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/structure/stringx"
|
"gitee.com/timedb/wheatCache/pkg/structure/stringx"
|
||||||
|
"github.com/stretchr/testify/require"
|
||||||
"testing"
|
"testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -16,5 +16,6 @@ func TestNewLRUCache(t *testing.T) {
|
||||||
cache.Add("3", v3)
|
cache.Add("3", v3)
|
||||||
cache.Add("1", v1)
|
cache.Add("1", v1)
|
||||||
cache.Del()
|
cache.Del()
|
||||||
fmt.Println(cache.Get("1"))
|
_, isTrue := cache.Get("1")
|
||||||
|
require.Equal(t, isTrue, true)
|
||||||
}
|
}
|
Loading…
Reference in New Issue