From 0e0bc446517124150bfd95b71763c3624328cd98 Mon Sep 17 00:00:00 2001 From: Peter Conrad Date: Mon, 18 Nov 2019 11:33:29 +0100 Subject: [PATCH] Added initial workflow --- .github/workflows/build-and-test.yml | 60 ++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 .github/workflows/build-and-test.yml diff --git a/.github/workflows/build-and-test.yml b/.github/workflows/build-and-test.yml new file mode 100644 index 0000000..9639aea --- /dev/null +++ b/.github/workflows/build-and-test.yml @@ -0,0 +1,60 @@ +on: [ push, pull_request ] +jobs: + test-release: + name: Build and run tests in Release mode + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v1 + with: + submodules: recursive + - name: Configure + run: | + mkdir -p _build + pushd _build + cmake -D CMAKE_BUILD_TYPE=Release \ + -D CMAKE_CXX_OUTPUT_EXTENSION_REPLACE=ON \ + -D CMAKE_C_COMPILER=gcc \ + -D CMAKE_CXX_COMPILER=g++ \ + .. + popd + - name: Build + run: | + make -C _build + - name: Test + run: | + pushd _build + tests/all_tests + tests/bloom_test ../README.md + tests/ecc_test ../README.md + tests/hmac_test + tests/task_cancel_test + popd + test-debug: + name: Build and run tests in Debug mode + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v1 + with: + submodules: recursive + - name: Configure + run: | + mkdir -p _build + pushd _build + cmake -D CMAKE_BUILD_TYPE=Debug \ + -D CMAKE_CXX_OUTPUT_EXTENSION_REPLACE=ON \ + -D CMAKE_C_COMPILER=gcc \ + -D CMAKE_CXX_COMPILER=g++ \ + .. + popd + - name: Build + run: | + make -C _build + - name: Test + run: | + pushd _build + tests/all_tests + tests/bloom_test ../README.md + tests/ecc_test ../README.md + tests/hmac_test + tests/task_cancel_test + popd