Skip to content

Commit 30e4fe9

Browse files
committed
ci: switch to rust integration tests
1 parent 1f87235 commit 30e4fe9

16 files changed

+118
-243
lines changed

.github/workflows/build.yml

+11-36
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,18 @@ jobs:
1818
build:
1919
name: 'Rust Build'
2020
runs-on: ubuntu-latest
21+
services:
22+
vault:
23+
image: hashicorp/vault:1.17.1
24+
ports:
25+
- 8200:8200
26+
options: --cap-add=IPC_LOCK
27+
env:
28+
VAULT_DEV_ROOT_TOKEN_ID: 'root-token'
2129
steps:
2230
- name: Check out code
2331
uses: actions/checkout@v4
24-
- name: Install stable toolchain
32+
- name: Install stable Toolchain
2533
uses: actions-rs/toolchain@v1
2634
with:
2735
profile: ${{ env.TOOLCHAIN_PROFILE }}
@@ -40,10 +48,11 @@ jobs:
4048
with:
4149
command: clippy
4250
# args: -- -D warnings
43-
- name: Unit- and Integration-Tests
51+
- name: Unit and Integration Tests
4452
uses: actions-rs/cargo@v1
4553
env:
4654
RUST_TEST_THREADS: 1
55+
VAULT_TOKEN: 'root-token'
4756
with:
4857
command: test
4958
- name: Build Binary
@@ -56,40 +65,6 @@ jobs:
5665
with:
5766
name: cli
5867
path: target/release/propeller
59-
test:
60-
name: 'Integration Test CLI'
61-
needs: build
62-
runs-on: ubuntu-latest
63-
services:
64-
vault:
65-
image: hashicorp/vault:1.17.1
66-
ports:
67-
- 8200:8200
68-
options: --cap-add=IPC_LOCK
69-
env:
70-
VAULT_DEV_ROOT_TOKEN_ID: 'root-token'
71-
steps:
72-
- name: Check out code
73-
uses: actions/checkout@v4
74-
with:
75-
name: cli
76-
- name: Setup Node.js
77-
uses: actions/setup-node@v4
78-
with:
79-
node-version: 20.15.0
80-
cache: 'npm'
81-
- name: Install node.js packages
82-
run: npm ci
83-
- name: Wait for Vault
84-
run: npm run ci:wait-for-vault
85-
- name: Download Binary
86-
uses: actions/download-artifact@v4
87-
- name: Run integration tests
88-
run: |
89-
chmod 755 ./cli/propeller
90-
./cli/propeller init-vault -c dev/config.yml
91-
env:
92-
VAULT_TOKEN: 'root-token'
9368
check:
9469
name: 'Resources Validation'
9570
runs-on: ubuntu-latest

.idea/runConfigurations/Test_propeller.xml .idea/runConfigurations/Build_propeller.xml

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/runConfigurations/Integration_Test_propeller.xml

+19
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/runConfigurations/Unit_Test_propeller.xml

+19
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/runConfigurations/Run_propeller__rotate.xml .idea/runConfigurations/propeller__init_vault.xml

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/runConfigurations/Run_propeller__init_vault.xml .idea/runConfigurations/propeller__rotate.xml

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

+4
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,7 @@ serde_yaml = "0.9.34+deprecated"
1313
tokio = { version = "1.38.0", features = ["macros", "rt"] }
1414
vaultrs = "0.7.2"
1515
rand = "0.9.0-alpha.1"
16+
17+
[dev-dependencies]
18+
assert_cmd = "2.0.14"
19+
predicates = "3.1.0"

0 commit comments

Comments
 (0)