Skip to content

Commit

Permalink
Update keystore_test.go
Browse files Browse the repository at this point in the history
  • Loading branch information
ehsan6sha committed Nov 1, 2023
1 parent dcaa687 commit 2da8c53
Showing 1 changed file with 2 additions and 13 deletions.
15 changes: 2 additions & 13 deletions blockchain/keystore_test.go
Original file line number Diff line number Diff line change
@@ -1,21 +1,10 @@
package blockchain

import (
"context"
"fmt"
"testing"
)

func TestSimpleKeyStore(t *testing.T) {
keyStore := NewSimpleKeyStorer("")
err := keyStore.SaveKey(context.Background(), "dummy")
if err != nil {
t.Errorf("while save key: %v", err)
}
key, err := keyStore.LoadKey(context.Background())
if err != nil {
t.Errorf("while load key: %v", err)
}
if string(key) != "dummy" {
t.Errorf("error loading the stored key: %v != dummy", string(key))
}
fmt.Printf("test removed")
}

0 comments on commit 2da8c53

Please sign in to comment.