From 745db24eaf76762a3c500fe3a88919c1baf1dec7 Mon Sep 17 00:00:00 2001 From: Olivier Mangin Date: Mon, 25 Jan 2021 23:05:19 -0800 Subject: [PATCH] Add install test to github action with cron trigger. The install test is only run when the cron event is the trigger. --- .github/workflows/tests.yaml | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index fb2b8e0..28dbaeb 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -1,9 +1,15 @@ name: Pubs tests -on: [push, pull_request] +on: + push: + pull_request: + schedule: + - cron: '0 8 * * *' + jobs: unit-test: + name: Run unit tests strategy: matrix: os: [macos-latest, ubuntu-latest] @@ -35,3 +41,20 @@ jobs: env: PUBS_TESTS_MODE: COLLECT run: pytest + + install-test: + name: Test installation + strategy: + matrix: + os: [macos-latest, ubuntu-latest] + runs-on: ${{ matrix.os }} + if: github.event_name == 'cron' + + steps: + - uses: actions/setup-python@v2 + - name: install test + run: | + pip install -U pip + pip install pubs + pubs --help + pip uninstall -y pubs