This repository has been archived on 2024-04-08. You can view files and clone it, but cannot push or open issues or pull requests.
dagger/tests/stdlib/docker/dockerfile/dockerfile.cue
Tom Chauveau 24aee99ba9 Add test for docker example
Signed-off-by: Tom Chauveau <tom.chauveau@epitech.eu>
2021-05-13 16:34:51 +02:00

35 lines
445 B
CUE

package docker
import (
"dagger.io/dagger"
"dagger.io/dagger/op"
"dagger.io/docker"
)
source: dagger.#Artifact
TestImageFromDockerfile: {
image: docker.#ImageFromDockerfile & {
dockerfile: """
FROM alpine
COPY test.txt /test.txt
"""
context: source
}
verify: #up: [
op.#Load & {
from: image
},
op.#Exec & {
always: true
args: [
"sh", "-c", """
grep -q "test" /test.txt
""",
]
},
]
}