test/e2e: do not leak "hello" file

Because the test mounts the current dir it does not need to create a new
file in it. Just check if the current test file is there should fulfill
the same purpose.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
This commit is contained in:
Paul Holzinger 2023-04-13 12:11:15 +02:00
parent 08d6b7b27e
commit 6e97976ad4
No known key found for this signature in database
GPG Key ID: EB145DD938A3CAF2
1 changed files with 1 additions and 5 deletions

View File

@ -676,13 +676,9 @@ VOLUME /test/`, ALPINE)
session.WaitWithDefaultTimeout()
Expect(session).Should(Exit(0))
// Test overlay mount when lowerdir is relative path.
f, err = os.Create("hello")
Expect(err).ToNot(HaveOccurred(), "os.Create")
f.Close()
session = podmanTest.Podman([]string{"run", "--rm", "-v", ".:/app:O", ALPINE, "ls", "/app"})
session.WaitWithDefaultTimeout()
Expect(session.OutputToString()).To(ContainSubstring("hello"))
Expect(session.OutputToString()).To(ContainSubstring(filepath.Base(CurrentGinkgoTestDescription().FileName)))
Expect(session).Should(Exit(0))
// Make sure modifications in container do not show up on host