Skip to content

Commit

Permalink
Verbose docker test
Browse files Browse the repository at this point in the history
  • Loading branch information
messense committed Feb 28, 2021
1 parent e5b8fc3 commit 93e8822
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/test-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ jobs:
with:
python-version: 3.8
- name: Build Docker container
run: docker build --cache-from konstin2/maturin -t maturin .
run: |
docker pull konstin2/maturin
docker build --cache-from konstin2/maturin -t maturin .
- name: Test the Docker container
run: ./test-dockerfile.sh
10 changes: 5 additions & 5 deletions test-dockerfile.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,39 +13,39 @@ source venv-docker/bin/activate

venv-docker/bin/pip install -U pip cffi

docker run --rm -v $(pwd)/test-crates/hello-world:/io maturin build --no-sdist -b bin
docker run -e RUST_BACKTRACE=1 --rm -v $(pwd)/test-crates/hello-world:/io maturin build --no-sdist -b bin

venv-docker/bin/pip install hello-world --no-index --find-links test-crates/hello-world/target/wheels/

if [[ $(venv-docker/bin/python test-crates/hello-world/check_installed/check_installed.py) != 'SUCCESS' ]]; then
exit 1
fi

docker run --rm -v $(pwd)/test-crates/cffi-pure:/io maturin build --no-sdist -b cffi
docker run -e RUST_BACKTRACE=1 --rm -v $(pwd)/test-crates/cffi-pure:/io maturin build --no-sdist -b cffi

venv-docker/bin/pip install cffi-pure --no-index --find-links test-crates/cffi-pure/target/wheels/

if [[ $(venv-docker/bin/python test-crates/cffi-pure/check_installed/check_installed.py) != 'SUCCESS' ]]; then
exit 1
fi

docker run --rm -v $(pwd)/test-crates/cffi-mixed:/io maturin build --no-sdist -b cffi
docker run -e RUST_BACKTRACE=1 --rm -v $(pwd)/test-crates/cffi-mixed:/io maturin build --no-sdist -b cffi

venv-docker/bin/pip install cffi-mixed --no-index --find-links test-crates/cffi-mixed/target/wheels/

if [[ $(venv-docker/bin/python test-crates/cffi-mixed/check_installed/check_installed.py) != 'SUCCESS' ]]; then
exit 1
fi

docker run --rm -v $(pwd)/test-crates/pyo3-pure:/io maturin build --no-sdist -i python3.8
docker run -e RUST_BACKTRACE=1 --rm -v $(pwd)/test-crates/pyo3-pure:/io maturin build --no-sdist -i python3.8

venv-docker/bin/pip install pyo3-pure --no-index --find-links test-crates/pyo3-pure/target/wheels/

if [[ $(venv-docker/bin/python test-crates/pyo3-pure/check_installed/check_installed.py) != 'SUCCESS' ]]; then
exit 1
fi

docker run --rm -v $(pwd)/test-crates/pyo3-mixed:/io maturin build --no-sdist -i python3.8
docker run -e RUST_BACKTRACE=1 --rm -v $(pwd)/test-crates/pyo3-mixed:/io maturin build --no-sdist -i python3.8

venv-docker/bin/pip install pyo3-mixed --find-links test-crates/pyo3-mixed/target/wheels/

Expand Down

0 comments on commit 93e8822

Please sign in to comment.