Skip to content

Commit

Permalink
feat: New folder for selfhosted
Browse files Browse the repository at this point in the history
  • Loading branch information
andrea-pasquale committed Feb 6, 2025
1 parent cb89902 commit 9dd2a11
Showing 1 changed file with 13 additions and 6 deletions.
19 changes: 13 additions & 6 deletions selfhosted
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,24 @@
# Script for running the selfhosted tests on QPUs directly from GitHub
# Tests need to be copied to /tmp/ because coverage does not work with NFS

cp -r src/qibojit/tests /tmp/
cp pyproject.toml /tmp/
cd /tmp/tests
TMP_DIR=$(mktemp -d /tmp/qibojit.XXXXXX)

cp -r src/qibojit/tests "$TMP_DIR"
cp pyproject.toml "$TMP_DIR/"
cd "$TMP_DIR/tests"

source /nfs/users/github/actions-runner/_work/qibojit/qibojit/testenv/bin/activate

pytest
pytest_status=$?

if [[ $pytest_status -ne 0 ]]
then
exit $pytest_status
fi

cd -
mv /tmp/tests/coverage.xml .
mv /tmp/tests/htmlcov .
rm -r /tmp/tests

mv "$TMP_DIR/tests/coverage.xml" .
mv "$TMP_DIR/tests/htmlcov" .
rm -r "$TMP_DIR"

0 comments on commit 9dd2a11

Please sign in to comment.