11// Copyright (c) Jeevanandam M. (https://github.com/jeevatkm)
2- // aahframework.org/cache/inmemory source code and usage is governed by a MIT style
2+ // Source code and usage is governed by a MIT style
33// license that can be found in the LICENSE file.
44
55package inmemory
@@ -9,10 +9,9 @@ import (
99 "testing"
1010 "time"
1111
12- "aahframework.org/essentials.v0"
13-
14- "aahframework.org/aah.v0/cache"
15- "aahframework.org/test.v0/assert"
12+ "aahframe.work/aah/cache"
13+ "aahframe.work/aah/essentials"
14+ "github.com/stretchr/testify/assert"
1615)
1716
1817func TestInmemoryCacheAddAndGet (t * testing.T ) {
@@ -91,7 +90,7 @@ func TestInmemoryMultipleCache(t *testing.T) {
9190 names := []string {"testcache1" , "testcache2" , "testcache3" }
9291 for _ , name := range names {
9392 err := mgr .CreateCache (& cache.Config {Name : name , ProviderName : "inmemory" })
94- assert .FailNowOnError (t , err , "unable to create cache" )
93+ assert .Nil (t , err , "unable to create cache" )
9594
9695 c := mgr .Cache (name )
9796 assert .NotNil (t , c )
@@ -120,7 +119,7 @@ func TestInmemorySlideEvictionMode(t *testing.T) {
120119 EvictionMode : cache .EvictionModeSlide ,
121120 SweepInterval : 2 * time .Second ,
122121 })
123- assert .FailNowOnError (t , err , "unable to create cache" )
122+ assert .Nil (t , err , "unable to create cache" )
124123
125124 c := mgr .Cache ("testslidemode" )
126125 assert .NotNil (t , c )
@@ -174,7 +173,7 @@ func createTestCache(t *testing.T, name string) cache.Cache {
174173 mgr := createCacheMgr ()
175174
176175 err := mgr .CreateCache (& cache.Config {Name : name , ProviderName : "inmemory" , SweepInterval : 2 * time .Second })
177- assert .FailNowOnError (t , err , "unable to create cache" )
176+ assert .Nil (t , err , "unable to create cache" )
178177
179178 c := mgr .Cache (name )
180179 assert .NotNil (t , c )
0 commit comments