cwtch/client/cwtch_peer_test.go

16 lines
368 B
Go
Raw Normal View History

2018-03-09 20:44:13 +00:00
package client
import (
"testing"
)
func TestCwtchPeerGenerate(t *testing.T) {
sarah := NewCwtchPeer("sarah")
sarah.Save("test_profile")
sarahLoaded, err := LoadCwtchPeer("test_profile")
if err != nil || sarahLoaded.Profile.Name != "sarah" {
t.Errorf("something went wrong saving and loading profiles %v %v", err, sarahLoaded)
}
t.Logf("%v", sarahLoaded)
}