aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Biggers <ebiggers@google.com>2021-12-22 20:36:28 -0600
committerEric Biggers <ebiggers@google.com>2021-12-22 20:36:31 -0600
commitf00ddd5823bd0e744746a2b778e0c47f430ecabb (patch)
tree24c4d0ced4f8b854745759a4b5eef25cf6938340
parent0c2b4e68cb5a1ae11e4132261712fc985b94b965 (diff)
context_text: remove pre-existing test.conf
This fixes a test failure in the case where test.conf gets left over.
-rw-r--r--actions/context_test.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/actions/context_test.go b/actions/context_test.go
index 4488a6b..7b56d92 100644
--- a/actions/context_test.go
+++ b/actions/context_test.go
@@ -47,6 +47,7 @@ func setupContext() (ctx *Context, err error) {
ConfigFileLocation = filepath.Join(mountpoint, "test.conf")
// Should not be able to setup without a config file
+ os.Remove(ConfigFileLocation)
if badCtx, badCtxErr := NewContextFromMountpoint(mountpoint, nil); badCtxErr == nil {
badCtx.Mount.RemoveAllMetadata()
return nil, fmt.Errorf("created context at %q without config file", badCtx.Mount.Path)