diff --git a/examples/local-consumer/package.json b/examples/local-consumer/package.json index 6fb5186..080c4cd 100644 --- a/examples/local-consumer/package.json +++ b/examples/local-consumer/package.json @@ -9,7 +9,6 @@ }, "dependencies": { "aws-cdk-lib": "^2.196.0", - "aws-cdk-secure-constructs": "file:../../aws-cdk-secure-constructs-1.0.0.tgz", "constructs": "^10.3.0" }, "devDependencies": { diff --git a/scripts/test-local-build.sh b/scripts/test-local-build.sh index 4bf2463..c580c31 100755 --- a/scripts/test-local-build.sh +++ b/scripts/test-local-build.sh @@ -31,8 +31,11 @@ cd "$CONSUMER" echo "==> Installing consumer app dependencies..." npm install --no-fund --no-audit -echo "==> Installing packed library..." -npm install --no-fund --no-audit "$ROOT/$TARBALL" +# Install the freshly packed tarball into node_modules only (--no-save), so the +# consumer's package.json is never mutated and the check works regardless of the +# library version (the tarball name includes the version). +echo "==> Installing the packed library ($TARBALL)..." +npm install --no-fund --no-audit --no-save "$ROOT/$TARBALL" echo "==> Synthesizing CDK stack..." npx cdk synth >/dev/null