Skip to content

Commit

Permalink
Attempt to run network tests in CI
Browse files Browse the repository at this point in the history
  • Loading branch information
sosthene-nitrokey committed Sep 3, 2024
1 parent 609893a commit 4a0464a
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 1 deletion.
30 changes: 30 additions & 0 deletions .github/workflows/rust-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -93,3 +93,33 @@ jobs:
run: cargo build --release
- name: run fork tests
run: cd fork-tests && make
test_network:
runs-on: ubuntu-latest
container: ubuntu:24.04
options: --privileged
env:
RUST_BACKTRACE: full
RUST_LOG: trace
services:
docker:
image: docker:dind
options: --privileged
ports:
- 2375:2375
steps:
- uses: actions/checkout@v2

- name: install opensc and dependencies
run: apt-get update && apt-get install -y curl opensc openssl gcc xxd jq gnutls-bin make docker.io

- name: Install Rust
uses: actions-rs/toolchain@v1
with:
toolchain: stable
components: rustfmt, clippy, llvm-tools-preview

- uses: Swatinem/rust-cache@v2
- name: build release
run: cargo build --release
- name: run network tests
run: cargo t -p nethsm_pkcs11 --test basic
2 changes: 1 addition & 1 deletion pkcs11/tests/tools/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,7 @@ pub fn run_tests(
};
let mut test_dropper = TestDropper {
serialize_test,
command_to_kill: Command::new("podman")
command_to_kill: Command::new("docker")
.args([
"run",
"--rm",
Expand Down

0 comments on commit 4a0464a

Please sign in to comment.