mirror of
https://github.com/hashicorp/vault.git
synced 2025-12-25 19:31:14 +01:00
Fix test on 1.6 by comparing to nil instead of a nil-defined map
This commit is contained in:
parent
d343e5f4df
commit
98fada78e4
@ -166,7 +166,7 @@ func TestGenerateRoot_OTP(t *testing.T) {
|
||||
if resp.Data["orphan"].(bool) != true ||
|
||||
resp.Data["ttl"].(int64) != 0 ||
|
||||
resp.Data["num_uses"].(int) != 0 ||
|
||||
resp.Data["meta"].(map[string]string) != map[string]string(nil) ||
|
||||
resp.Data["meta"].(map[string]string) != nil ||
|
||||
len(resp.Data["policies"].([]string)) != 1 ||
|
||||
resp.Data["policies"].([]string)[0] != "root" {
|
||||
t.Fatalf("bad: %#v", resp.Data)
|
||||
@ -270,7 +270,7 @@ func TestGenerateRoot_PGP(t *testing.T) {
|
||||
if resp.Data["orphan"].(bool) != true ||
|
||||
resp.Data["ttl"].(int64) != 0 ||
|
||||
resp.Data["num_uses"].(int) != 0 ||
|
||||
resp.Data["meta"].(map[string]string) != map[string]string(nil) ||
|
||||
resp.Data["meta"].(map[string]string) != nil ||
|
||||
len(resp.Data["policies"].([]string)) != 1 ||
|
||||
resp.Data["policies"].([]string)[0] != "root" {
|
||||
t.Fatalf("bad: %#v", resp.Data)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user