1010 test implementation

Signed-off-by: Guillaume de Rouville <guillaume.derouville@gmail.com>
This commit is contained in:
Guillaume de Rouville
2021-08-13 12:43:13 +02:00
parent 2bcd7a7dbf
commit 00f7e63c4a
4 changed files with 87 additions and 68 deletions

View File

@@ -141,4 +141,23 @@ setup() {
# Prepare and run cloudformation cleanup
dagger -e cloudformation input text stackRemoval.stackName $stackName
dagger -e cloudformation up
}
}
@test "doc-1010-dev-cue-package" {
setup_example_sandbox ""
# Initializing workspace
mkdir workspace
cd workspace
# Writing the package
dagger init
mkdir -p cue.mod/pkg/github.com/tjovicic/gcpcloudrun
cp $CODEBLOC_SRC/dev-cue-package/source.cue cue.mod/pkg/github.com/tjovicic/gcpcloudrun/source.cue
cp $CODEBLOC_SRC/dev-cue-package/script.sh .
chmod +x script.sh
./script.sh
run dagger up -e staging
assert_output --partial "environment=staging input=run.gcpConfig.serviceKey"
}