diff options
author | Jan Niklas Hasse <jhasse@bixense.com> | 2020-10-30 23:43:23 (GMT) |
---|---|---|
committer | Jan Niklas Hasse <jhasse@bixense.com> | 2020-10-31 00:03:09 (GMT) |
commit | ee2e2faa13a63168bcf63b6ec612881ea6ad7ae6 (patch) | |
tree | 3d4ddf4c87a179ce5e4ca6d294dbde2cd63fc0f9 /.github/workflows | |
parent | d45ff8ebf88ef4add46a80ccdfc2d97a8b4b091b (diff) | |
download | Ninja-ee2e2faa13a63168bcf63b6ec612881ea6ad7ae6.zip Ninja-ee2e2faa13a63168bcf63b6ec612881ea6ad7ae6.tar.gz Ninja-ee2e2faa13a63168bcf63b6ec612881ea6ad7ae6.tar.bz2 |
GitHub Actions: Run more tests on Ubuntu 20.04 (Docker)
Diffstat (limited to '.github/workflows')
-rw-r--r-- | .github/workflows/linux.yml | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 511b92b..9062d98 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -70,3 +70,56 @@ jobs: asset_path: ./artifact/ninja-linux.zip asset_name: ninja-linux.zip asset_content_type: application/zip + + test: + runs-on: [ubuntu-latest] + container: + image: ubuntu:20.04 + steps: + - uses: actions/checkout@v2 + - name: Install dependencies + run: | + apt update + apt install -y python3-pytest ninja-build clang-tidy python3-pip clang + pip3 install cmake==3.17.* + - name: Configure (GCC) + run: cmake -Bbuild-gcc -DCMAKE_BUILD_TYPE=Debug -G'Ninja Multi-Config' + + - name: Build (GCC, Debug) + run: cmake --build build-gcc --config Debug + - name: Unit tests (GCC, Debug) + run: ./build-gcc/Debug/ninja_test + - name: Python tests (GCC, Debug) + run: pytest-3 --color=yes ../.. + working-directory: build-gcc/Debug + + - name: Build (GCC, Release) + run: cmake --build build-gcc --config Release + - name: Unit tests (GCC, Release) + run: ./build-gcc/Release/ninja_test + - name: Python tests (GCC, Release) + run: pytest-3 --color=yes ../.. + working-directory: build-gcc/Release + + - name: Configure (Clang) + run: CC=clang CXX=clang++ cmake -Bbuild-clang -DCMAKE_BUILD_TYPE=Debug -G'Ninja Multi-Config' -DCMAKE_EXPORT_COMPILE_COMMANDS=1 + + - name: Build (Clang, Debug) + run: cmake --build build-clang --config Debug + - name: Unit tests (Clang, Debug) + run: ./build-clang/Debug/ninja_test + - name: Python tests (Clang, Debug) + run: pytest-3 --color=yes ../.. + working-directory: build-clang/Debug + + - name: Build (Clang, Release) + run: cmake --build build-clang --config Release + - name: Unit tests (Clang, Release) + run: ./build-clang/Release/ninja_test + - name: Python tests (Clang, Release) + run: pytest-3 --color=yes ../.. + working-directory: build-clang/Release + + - name: clang-tidy + run: /usr/lib/llvm-10/share/clang/run-clang-tidy.py -header-filter=src + working-directory: build-clang |