Split pytest and pkcs11 test suites.
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
2
.github/workflows/test.yml
vendored
2
.github/workflows/test.yml
vendored
@@ -35,3 +35,5 @@ jobs:
|
|||||||
run: ./tests/build-in-docker.sh
|
run: ./tests/build-in-docker.sh
|
||||||
- name: Start emulation and test
|
- name: Start emulation and test
|
||||||
run: ./tests/run-test-in-docker.sh
|
run: ./tests/run-test-in-docker.sh
|
||||||
|
- name: Test PKCS11
|
||||||
|
run: ./tests/run-test-pkcs11-in-docker.sh
|
||||||
|
|||||||
5
tests/run-test-pkcs11-in-docker.sh
Normal file
5
tests/run-test-pkcs11-in-docker.sh
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
#!/bin/bash -eu
|
||||||
|
|
||||||
|
source tests/docker_env.sh
|
||||||
|
run_in_docker ./tests/start-up-and-test.sh
|
||||||
|
|
||||||
15
tests/start-up-and-test-pkcs11.sh
Normal file
15
tests/start-up-and-test-pkcs11.sh
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
rm -rf pypicohsm
|
||||||
|
git clone https://github.com/polhenarejos/pypicohsm.git
|
||||||
|
pip3 install -e pypicohsm
|
||||||
|
/usr/sbin/pcscd &
|
||||||
|
sleep 2
|
||||||
|
rm -f memory.flash
|
||||||
|
tar -xf tests/memory.tar.gz
|
||||||
|
./build_in_docker/pico_hsm > /dev/null 2>&1 &
|
||||||
|
|
||||||
|
chmod a+x tests/scripts/*.sh
|
||||||
|
|
||||||
|
echo "======== PKCS11 Test suite ========"
|
||||||
|
./tests/scripts/pkcs11.sh
|
||||||
@@ -9,8 +9,3 @@ rm -f memory.flash
|
|||||||
tar -xf tests/memory.tar.gz
|
tar -xf tests/memory.tar.gz
|
||||||
./build_in_docker/pico_hsm > /dev/null 2>&1 &
|
./build_in_docker/pico_hsm > /dev/null 2>&1 &
|
||||||
pytest tests -W ignore::DeprecationWarning
|
pytest tests -W ignore::DeprecationWarning
|
||||||
|
|
||||||
chmod a+x tests/scripts/*.sh
|
|
||||||
|
|
||||||
echo "======== PKCS11 Test suite ========"
|
|
||||||
./tests/scripts/pkcs11.sh
|
|
||||||
|
|||||||
Reference in New Issue
Block a user