This repository has been archived by the owner on Oct 5, 2024. It is now read-only.
Testing GitHub action yaml file #1495
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: 🧪 Build and Test | |
on: | |
push: | |
branches: | |
- test | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
# Relies on the master branch built docker image for build-deps | |
- name: Start Docker Compose & build | |
run: cd docker && docker-compose up -d | |
# Build tests | |
- name: Build tests | |
run: docker-compose -f docker-compose.yml exec -T underpass sh -c "cd /code/build && make check -j `nproc`" | |
# Copy Underpass library | |
- name: Copy library | |
run: docker-compose -f docker-compose.yml exec -T underpass sh -c "cp /code/build/.libs/libunderpass.so /usr/lib" | |
# Run individual test for testing | |
- name: Run individual test | |
run: | | |
docker-compose -f docker-compose.yml exec -T underpass sh -c "/code/build/src/testsuite/libunderpass.all/yaml-test" | |
exit_code=$? | |
if [ $exit_code -ne 0 ]; then | |
echo "Test failed with exit code $exit_code" | |
exit $exit_code | |
fi |