-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: supporting testing docker image in bin tests
Added the ability to override `tests/bin/agent/start.test.ts` to target a docker image for testing. 3 env variables need to be set to facilitate this. `PK_TEST_DOCKER_IMAGE=$image`, `PK_TEST_COMMAND=scripts/docker-run.sh`, and `PK_TEST_COMMAND_DOCKER=DOCKER`. The dataDir in each tests needs to be set via env with `PK_TEST_DATA_PATH: dataDir`. The `integration:docker` CI/CD job has been updated to use these tests. Related #389
- Loading branch information
1 parent
0bc3af5
commit 4a88ccb
Showing
7 changed files
with
75 additions
and
55 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env bash | ||
|
||
exec docker run -i --network host --pid host --userns host --user "$(id -u)" --mount type=bind,src="$PK_TEST_DATA_PATH",dst="$PK_TEST_DATA_PATH" --env PK_PASSWORD --env PK_NODE_PATH --env PK_RECOVERY_CODE "$PK_TEST_DOCKER_IMAGE" polykey "$@" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters