Update stale broken URLs in docs directory (#1337) #538
This file contains hidden or 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: Test | |
| on: | |
| pull_request: | |
| branches: | |
| - main | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| check-changes: | |
| name: Check whether tests need to be run based on diff | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: antrea-io/has-changes@v2 | |
| id: check_diff | |
| with: | |
| paths-ignore: docs/* *.md | |
| outputs: | |
| has_changes: ${{ steps.check_diff.outputs.has_changes }} | |
| test: | |
| needs: check-changes | |
| if: ${{ needs.check-changes.outputs.has_changes == 'yes' }} | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| include: | |
| - cxx: g++ | |
| cc: gcc | |
| - cxx: clang++-8 | |
| cc: clang-8 | |
| - cxx: clang++-10 | |
| cc: clang-10 | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| submodules: 'recursive' | |
| - name: Build test Docker image | |
| env: | |
| CC: ${{ matrix.cc }} | |
| CXX: ${{ matrix.cxx }} | |
| run: | | |
| docker build -t bm --build-arg IMAGE_TYPE=test --build-arg CC=$CC --build-arg CXX=$CXX --build-arg GCOV=$GCOV --build-arg BUILDER=autoconf . | |
| - name: Run tests | |
| run: | | |
| ci_env=`bash <(curl -s https://codecov.io/env)` | |
| docker run --rm $ci_env --env GCOV -w /behavioral-model bm /bin/bash -c \ | |
| "make check -j$(nproc) && ./ci/codecov.sh" | |
| # FIXME: replace the command above with the following when switching to cmake | |
| # "cd build && make -j$(nproc) && ctest -j$(nproc) --output-on-failure && cd .. && ./ci/codecov.sh" | |
| - name: Check style | |
| run: | | |
| ./tools/check_style.sh | |
| test-no-pi: | |
| needs: check-changes | |
| if: ${{ needs.check-changes.outputs.has_changes == 'yes' }} | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| submodules: 'recursive' | |
| - name: Build Dockerfile.noPI image | |
| run: docker build -t bm-no-pi --build-arg IMAGE_TYPE=test -f Dockerfile.noPI . | |
| - name: Run tests | |
| run: docker run --rm -w /behavioral-model bm-no-pi /bin/bash -c "make check -j$(nproc)" | |
| # FIXME: replace the command above with the following when switching to cmake | |
| # "cd build && make -j$(nproc) && ctest -j$(nproc) --output-on-failure" | |
| test-ubuntu22: | |
| needs: check-changes | |
| if: ${{ needs.check-changes.outputs.has_changes == 'yes' }} | |
| runs-on: ubuntu-22.04 | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| submodules: 'recursive' | |
| - name: Install dependencies | |
| run: sudo ./install_deps_ubuntu_22.04.sh | |
| - name: Build BMv2 | |
| run: | | |
| mkdir -p build | |
| cd build | |
| cmake -DWITH_PDFIXED=ON -DWITH_PI=ON -DWITH_STRESS_TESTS=ON -DENABLE_DEBUGGER=ON -DENABLE_WERROR=ON .. | |
| make -j$(nproc) | |
| - name: Run tests | |
| run: cd build && make -j$(nproc) && ctest -j$(nproc) --output-on-failure |