From ef12247ec40150355d2c0c217b1aa0008e6fdf14 Mon Sep 17 00:00:00 2001 From: Avi Vaid Date: Wed, 10 Aug 2016 22:43:17 -0700 Subject: [PATCH] fixed test purge integration test wrt flatKS. need to change the import style and corresponding tests Signed-off-by: Avi Vaid --- cmd/notary/integration_test.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cmd/notary/integration_test.go b/cmd/notary/integration_test.go index 497f83c94..01c02a2b8 100644 --- a/cmd/notary/integration_test.go +++ b/cmd/notary/integration_test.go @@ -1440,6 +1440,7 @@ func TestPurge(t *testing.T) { if len(lines) == 1 && lines[0] == "No signing keys found." { t.Fail() } + var targetsKeyID string for _, line := range lines[2:] { parts := strings.Fields(line) @@ -1453,7 +1454,7 @@ func TestPurge(t *testing.T) { t.Fail() } - err = os.Remove(filepath.Join(tempDir, notary.PrivDir, notary.NonRootKeysSubdir, "gun", targetsKeyID+".key")) + err = os.Remove(filepath.Join(tempDir, notary.PrivDir, targetsKeyID+".key")) require.NoError(t, err) _, err = runCommand(t, tempDir, "delegation", "purge", "gun", "--key", keyID)