1
0
Fork 0
mirror of https://github.com/imjasonh/krust synced 2026-07-08 23:05:41 +00:00
krust/tests/testdata/apply_basic.txt
Jason Hall 1ed99cbe07 implement resolve and apply
Signed-off-by: Jason Hall <jason@chainguard.dev>
2025-10-15 14:46:18 -04:00

32 lines
694 B
Text

# Test basic apply command (requires kubectl)
[!exec:kubectl] skip 'kubectl not available'
-- Cargo.toml --
[package]
name = "test-app"
version = "0.1.0"
edition = "2021"
[dependencies]
-- src/main.rs --
fn main() {
println!("Hello from test-app!");
}
-- deployment.yaml --
apiVersion: v1
kind: ConfigMap
metadata:
name: test-config
data:
key: value
# Apply should resolve and apply with kubectl
# Note: This test only verifies the command runs, not the actual k8s deployment
# since we don't have a test cluster
env KRUST_REPO=ttl.sh/test
! exec ./krust apply -f deployment.yaml
# kubectl will fail with connection error in test environment, but that's expected
stderr 'kubectl'