summaryrefslogtreecommitdiffhomepage
path: root/resources/internal/key_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'resources/internal/key_test.go')
-rw-r--r--resources/internal/key_test.go9
1 files changed, 8 insertions, 1 deletions
diff --git a/resources/internal/key_test.go b/resources/internal/key_test.go
index 9b6a23d87..11a52f2e6 100644
--- a/resources/internal/key_test.go
+++ b/resources/internal/key_test.go
@@ -32,5 +32,12 @@ func TestResourceTransformationKey(t *testing.T) {
key := NewResourceTransformationKey("testing",
testStruct{Name: "test", V1: int64(10), V2: int32(20), V3: 30, V4: uint64(40)})
c := qt.New(t)
- c.Assert("testing_518996646957295636", qt.Equals, key.Value())
+ c.Assert(key.Value(), qt.Equals, "testing_518996646957295636")
+}
+
+func TestHashString(t *testing.T) {
+ c := qt.New(t)
+
+ c.Assert(HashString("a", "b"), qt.Equals, "2712570657419664240")
+ c.Assert(HashString("ab"), qt.Equals, "590647783936702392")
}