From 03196fd08c776baaa8aff91c10b801dabc909bbd Mon Sep 17 00:00:00 2001 From: Pierre Mavro Date: Fri, 30 Oct 2020 17:35:45 +0100 Subject: [PATCH] feat: adding GH action functionnal tests --- .github/workflows/functionnal_tests.yml | 45 ++++++++ helper.sh | 132 +++++++++++++----------- 2 files changed, 117 insertions(+), 60 deletions(-) create mode 100644 .github/workflows/functionnal_tests.yml diff --git a/.github/workflows/functionnal_tests.yml b/.github/workflows/functionnal_tests.yml new file mode 100644 index 00000000..875afc60 --- /dev/null +++ b/.github/workflows/functionnal_tests.yml @@ -0,0 +1,45 @@ +name: functionnal-tests + +on: + push: + branches-ignore: [ main ] + pull_request: + branches-ignore: [ main ] + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions-rs/toolchain@v1 + with: + toolchain: stable + - uses: actions-rs/cargo@v1 + with: + command: build + args: --release --all-features +# fast-tests: +# #if: contains(!github.event.pull_request.labels.*.name, 'full-tests') +# #needs: build +# runs-on: ubuntu-latest +# steps: +# - uses: actions/checkout@v2 +# - name: Run a multi-line script +# env: +# GITHUB_CONTEXT: ${{ toJson(github) }} +# timeout-minutes: 30 +# run: | +# env +# echo "$GITHUB_CONTEXT" +# ./helper.sh fast_tests + full-tests: + #if: contains(github.event.pull_request.labels.*.name, 'full-tests') + needs: build + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Run a multi-line script + env: + GITHUB_CONTEXT: ${{ toJson(github) }} + timeout-minutes: 120 + run: ./helper.sh full_tests diff --git a/helper.sh b/helper.sh index 2f1125bf..cdfeb3e3 100755 --- a/helper.sh +++ b/helper.sh @@ -11,80 +11,92 @@ if [ "$(uname)" == "Darwin" ] ; then sed='gsed' fi -ARGS_NUM=$# - -function print_help() { - echo "Usage: $0