mirror of
https://gitea.com/Lydanne/buildx.git
synced 2025-07-09 21:17:09 +08:00
test: tmpdir can be a test helper
Signed-off-by: Justin Chadwell <me@jedevc.com>
This commit is contained in:
@ -148,11 +148,10 @@ RUN cp /etc/foo /etc/bar
|
||||
FROM scratch
|
||||
COPY --from=base /etc/bar /bar
|
||||
`)
|
||||
dir, err := tmpdir(
|
||||
dir := tmpdir(
|
||||
t,
|
||||
fstest.CreateFile("Dockerfile", dockerfile, 0600),
|
||||
fstest.CreateFile("foo", []byte("foo"), 0600),
|
||||
)
|
||||
require.NoError(t, err)
|
||||
return dir
|
||||
}
|
||||
|
Reference in New Issue
Block a user