summaryrefslogtreecommitdiffstats
path: root/utils/license_test.go
diff options
context:
space:
mode:
authorJoram Wilander <jwawilander@gmail.com>2016-04-15 08:48:14 -0400
committerHarrison Healey <harrisonmhealey@gmail.com>2016-04-15 08:48:14 -0400
commitc6c3f1e47829bba9b332da3d4c61193532e87032 (patch)
treeadbbbf666eb0f25ae98be9e7df8642975bdb46c5 /utils/license_test.go
parent9243b8761a8062a864a882dbab2aa4edc2780d73 (diff)
downloadchat-c6c3f1e47829bba9b332da3d4c61193532e87032.tar.gz
chat-c6c3f1e47829bba9b332da3d4c61193532e87032.tar.bz2
chat-c6c3f1e47829bba9b332da3d4c61193532e87032.zip
Update client license etag to handle new features (#2716)
Diffstat (limited to 'utils/license_test.go')
-rw-r--r--utils/license_test.go18
1 files changed, 18 insertions, 0 deletions
diff --git a/utils/license_test.go b/utils/license_test.go
index 826107032..237ee5fb2 100644
--- a/utils/license_test.go
+++ b/utils/license_test.go
@@ -48,3 +48,21 @@ func TestValidateLicense(t *testing.T) {
t.Fatal("should have failed - bad license")
}
}
+
+func TestClientLicenseEtag(t *testing.T) {
+ etag1 := GetClientLicenseEtag()
+
+ ClientLicense["SomeFeature"] = "true"
+
+ etag2 := GetClientLicenseEtag()
+ if etag1 == etag2 {
+ t.Fatal("etags should not match")
+ }
+
+ ClientLicense["SomeFeature"] = "false"
+
+ etag3 := GetClientLicenseEtag()
+ if etag2 == etag3 {
+ t.Fatal("etags should not match")
+ }
+}