Commit d00a3d74 authored by Adin Schmahmann's avatar Adin Schmahmann

update datastore interface

parent 9ad1663b
......@@ -79,6 +79,10 @@ func (a *accessor) Put(key ds.Key, value []byte) (err error) {
return a.ldb.Put(key.Bytes(), value, nil)
}
func (a *accessor) Sync(prefix ds.Key) error {
return nil
}
func (a *accessor) Get(key ds.Key) (value []byte, err error) {
val, err := a.ldb.Get(key.Bytes(), nil)
if err != nil {
......
......@@ -30,7 +30,7 @@ var testcases = map[string]string{
// d, close := newDS(t)
// defer close()
func newDS(t *testing.T) (*Datastore, func()) {
path, err := ioutil.TempDir("/tmp", "testing_leveldb_")
path, err := ioutil.TempDir("", "testing_leveldb_")
if err != nil {
t.Fatal(err)
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment