Merge pull request #15376 from spowelljr/removeLicenesDir

tests: Remove license dir after test
pull/15384/head
Steven Powell 2022-11-21 08:50:27 -08:00 committed by GitHub
commit cf94ce53e6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -2215,6 +2215,7 @@ func validateLicenseCmd(ctx context.Context, t *testing.T, _ string) {
if rr, err := Run(t, exec.CommandContext(ctx, Target(), "license")); err != nil {
t.Fatalf("command %q failed: %v", rr.Stdout.String(), err)
}
defer os.Remove("./licenses")
files, err := os.ReadDir("./licenses")
if err != nil {
t.Fatalf("failed to read licenses dir: %v", err)