tests: add test for builder-pack:set projectoml-path

This commit is contained in:
Jose Diaz-Gonzalez
2021-07-10 15:32:59 -04:00
parent 84ca9ff7e5
commit 7292eaefc3
8 changed files with 151 additions and 0 deletions

View File

@@ -0,0 +1,15 @@
#!/usr/bin/env bash
layers_dir=$1
echo "Building with buildpack 1"
bp_layer=$layers_dir/1
bp_env_dir=$bp_layer/env
mkdir -p $bp_env_dir
echo "TESTENV_1" > $bp_env_dir/TESTENV
echo "[types]" > ${bp_layer}.toml
echo "launch = true" >> ${bp_layer}.toml
echo "build = true" >> ${bp_layer}.toml
echo "cache = true" >> ${bp_layer}.toml

View File

@@ -0,0 +1,3 @@
#!/usr/bin/env bash
echo "1" && exit 0

View File

@@ -0,0 +1,9 @@
api = "0.6"
[buildpack]
id = "1"
version = "0.1.0"
name = "1 Packages Buildpack"
[[stacks]]
id = "heroku-20"

View File

@@ -0,0 +1,21 @@
#!/usr/bin/env bash
layers_dir=$1
echo "Building with buildpack 2"
bp_layer=$layers_dir/2
bp_env_dir=$bp_layer/env
mkdir -p $bp_env_dir
export TESTENV="$TESTENV:anotherenv"
echo "===> env start"
env
echo "===> env end"
echo "TESTENV_2" > $bp_env_dir/TESTENV
echo "[types]" > ${bp_layer}.toml
echo "launch = true" >> ${bp_layer}.toml
echo "build = true" >> ${bp_layer}.toml
echo "cache = true" >> ${bp_layer}.toml

View File

@@ -0,0 +1,3 @@
#!/usr/bin/env bash
echo "2" && exit 0

View File

@@ -0,0 +1,9 @@
api = "0.6"
[buildpack]
id = "2"
version = "0.1.0"
name = "2 Packages Buildpack"
[[stacks]]
id = "heroku-20"

View File

@@ -0,0 +1,10 @@
[project]
id = "python"
name = "python"
version = "1.0.0"
[[build.buildpacks]]
uri = "./cnb/1"
[[build.buildpacks]]
uri = "./cnb/1"