This repository has been archived on 2020-04-20. You can view files and clone it, but cannot push or open issues or pull requests.
2017-12-05 19:00:04 +00:00
|
|
|
package identity
|
|
|
|
|
|
|
|
import (
|
|
|
|
"testing"
|
|
|
|
)
|
|
|
|
|
|
|
|
func TestIdentity(t *testing.T) {
|
2018-01-13 20:35:48 +00:00
|
|
|
id := Init("../testing/private_key")
|
|
|
|
if id.Initialized() == false {
|
|
|
|
t.Errorf("Identity should be initialized")
|
|
|
|
}
|
|
|
|
|
2017-12-05 19:00:04 +00:00
|
|
|
if id.Hostname() != "kwke2hntvyfqm7dr" {
|
2018-01-07 00:37:07 +00:00
|
|
|
t.Errorf("Expected %v as Hostname() got: %v", "kwke2hntvyfqm7dr", id.Hostname())
|
2017-12-05 19:00:04 +00:00
|
|
|
}
|
|
|
|
}
|