diff options
author | Niall Sheridan <nsheridan@gmail.com> | 2017-01-09 10:07:56 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-01-09 10:07:56 +0000 |
commit | fc190076448ebf1710910a89b584857cbc89d159 (patch) | |
tree | b82061b8a2af25fbc13f6f9792d42ed7a2ed9d54 /lib/util_test.go | |
parent | a4b5776500b1250b61c3dafd17e464fdf3f3aae8 (diff) | |
parent | 6dfe350cb5eefde3a99374d14c083d1906717ddd (diff) |
Merge branch 'master' into opts2
Diffstat (limited to 'lib/util_test.go')
-rw-r--r-- | lib/util_test.go | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/util_test.go b/lib/util_test.go new file mode 100644 index 0000000..9e89297 --- /dev/null +++ b/lib/util_test.go @@ -0,0 +1,16 @@ +package lib + +import ( + "testing" + + "github.com/nsheridan/cashier/testdata" + "golang.org/x/crypto/ssh" +) + +func TestGetPublicKey(t *testing.T) { + t.Parallel() + c, _, _, _, _ := ssh.ParseAuthorizedKey(testdata.Cert) + if GetPublicKey(c.(*ssh.Certificate)) != string(testdata.Cert) { + t.Fail() + } +} |