ledisdb/ledis/t_hash_test.go

18 lines
253 B
Go
Raw Normal View History

2014-05-16 06:36:18 +04:00
package ledis
import (
"testing"
)
func TestDBHash(t *testing.T) {
db := getTestDB()
key := []byte("testdb_hash_a")
if n, err := db.HSet(key, []byte("a"), []byte("hello world")); err != nil {
t.Fatal(err)
} else if n != 1 {
t.Fatal(n)
}
}