Add a live-platform integration test for the app lifecycle #2
Loading…
Reference in a new issue
No description provided.
Delete branch "feature/integration-test"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The acceptance tests (
acc_test.go) drive OpenTofu through the provider against an in-memory/clistub — which can only ever agree with itself. This adds the same round-trip against a real, seeded someones.computer, so we catch drift in the actual wire contract.What
internal/provider/integration_test.go—TestIntegrationApplicationLifecycle:terraform applyan application + a variableImportStateVerify)CheckDestroyconfirms an explained 404 after destroyThis is the declarative half of "deploy an app": the provider owns the application, its variables and bindings — not the running revision (immutable revisions come from
sc deploy), so the test stops at provisioning.Gating & safety
SC_INTEGRATION=1andSC_ENDPOINT+SC_TOKENare set (the plugin-testingTF_ACCgate applies on top). Sogo test ./...and the coverage gate stay hermetic — verified they still skip and coverage is unchanged at 72.8%.tf-int-<base36 nanos>) so parallel or shared-swarm stacks never collide and a crashed run never wedges the next.SC_INTEGRATION_ORG; a single-org account (the dev seed) leaves it unset.make testintruns it.Verified
go vet,golangci-lint(0 issues), clean skips with and withoutTF_ACC, coverage 72.8%. Not yet run against a live platform — the dedicated dev-seeded CI job that does that is a follow-up in the platform repo.