Skip to content

Commit 0e7b362

Browse files
committed
chore(build.yaml): merge 'Run Tests' and 'Build Vector' steps in GitHub Actions workflow
This change was made to optimize the workflow by building the vector package once before running the tests, instead of building it separately in the 'Build Vector' step. This reduces redundancy and improves the efficiency of the workflow.
1 parent 42289f3 commit 0e7b362

File tree

1 file changed

+13
-12
lines changed

1 file changed

+13
-12
lines changed

.github/workflows/build.yaml

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -87,21 +87,22 @@ jobs:
8787
# sudo make install_sw
8888
# cd ..
8989

90-
- name: Run Tests
90+
- name: Build Vector and Run Tests
9191
run: |
92-
cargo nextest run --release --workspace --no-fail-fast --no-default-features --features default -E 'test(blackbox_exporter)'
92+
cargo build --release -p vector
93+
cargo nextest run --release --workspace --no-fail-fast -E 'test(blackbox_exporter)'
9394
echo "All tests passed"
9495
95-
- name: Build Vector
96-
# env:
97-
# RUSTFLAGS: "-C target-feature=+crt-static"
98-
# CC_x86_64_unknown_linux_musl: musl-gcc
99-
# OPENSSL_STATIC: "1"
100-
# OPENSSL_DIR: /musl
101-
# OPENSSL_NO_VENDOR: "1"
102-
run: |
103-
cargo build --release
104-
echo "Build completed successfully"
96+
# - name: Build Vector
97+
# # env:
98+
# # RUSTFLAGS: "-C target-feature=+crt-static"
99+
# # CC_x86_64_unknown_linux_musl: musl-gcc
100+
# # OPENSSL_STATIC: "1"
101+
# # OPENSSL_DIR: /musl
102+
# # OPENSSL_NO_VENDOR: "1"
103+
# run: |
104+
# cargo build --release
105+
# echo "Build completed successfully"
105106

106107
- name: Create Release Archive
107108
run: |

0 commit comments

Comments
 (0)