summaryrefslogtreecommitdiff
path: root/pkg/vpn/bonafide/gateways_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/vpn/bonafide/gateways_test.go')
-rw-r--r--pkg/vpn/bonafide/gateways_test.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/pkg/vpn/bonafide/gateways_test.go b/pkg/vpn/bonafide/gateways_test.go
index b88423f..42a7a95 100644
--- a/pkg/vpn/bonafide/gateways_test.go
+++ b/pkg/vpn/bonafide/gateways_test.go
@@ -37,28 +37,28 @@ func TestGatewayPool(t *testing.T) {
t.Fatal("gatewayPool labels not what expected. Got:", labels)
}
- if pool.userChoice != "" {
+ if pool.userChoice != nil {
t.Fatal("userChoice should be empty by default")
}
- err = pool.setUserChoice("foo")
+ err = pool.setUserChoice([]byte("foo"))
if err == nil {
t.Fatal("gatewayPool should not let you set a foo gateway")
}
- err = pool.setUserChoice("a-1")
+ err = pool.setUserChoice([]byte("a-1"))
if err != nil {
t.Fatal("location 'a-1' should be a valid label")
}
- err = pool.setUserChoice("c-2")
+ err = pool.setUserChoice([]byte("c-2"))
if err != nil {
t.Fatal("location 'c-2' should be a valid label")
}
- if pool.userChoice != "c-2" {
+ if string(pool.userChoice) != "c-2" {
t.Fatal("userChoice should be c-2")
}
pool.setAutomaticChoice()
- if pool.userChoice != "" {
+ if string(pool.userChoice) != "" {
t.Fatal("userChoice should be empty after auto selection")
}