From 0fe972c03bd6ddf2dc84c7c59d5b0d2952c36160 Mon Sep 17 00:00:00 2001 From: Luca Della Vedova Date: Thu, 17 Oct 2024 09:46:41 +0800 Subject: [PATCH] Revert to upstream action Signed-off-by: Luca Della Vedova --- .github/actions/local_pytest/action.yml | 11 ---- .github/actions/local_pytest/strategy.json | 12 ---- .github/workflows/ci.yaml | 2 +- .github/workflows/pytest.yaml | 76 ---------------------- 4 files changed, 1 insertion(+), 100 deletions(-) delete mode 100644 .github/actions/local_pytest/action.yml delete mode 100644 .github/actions/local_pytest/strategy.json delete mode 100644 .github/workflows/pytest.yaml diff --git a/.github/actions/local_pytest/action.yml b/.github/actions/local_pytest/action.yml deleted file mode 100644 index 9d585b3..0000000 --- a/.github/actions/local_pytest/action.yml +++ /dev/null @@ -1,11 +0,0 @@ -inputs: - codecov_token: - description: Codecov secret token - required: true - -runs: - using: composite - steps: - - uses: colcon/ci/.github/workflows/pytest.yaml@main - env: - CODECOV_TOKEN: ${{ inputs.codecov_token }} diff --git a/.github/actions/local_pytest/strategy.json b/.github/actions/local_pytest/strategy.json deleted file mode 100644 index 5d24c22..0000000 --- a/.github/actions/local_pytest/strategy.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "matrix": { - "os": ["macos-latest", "ubuntu-latest", "windows-latest"], - "python": ["3.8", "3.9", "3.10", "3.11", "3.12"], - "include": [ - { - "os": "ubuntu-latest", - "stdeb-check": "1" - } - ] - } -} diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index eba59d9..ec8f82b 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -8,6 +8,6 @@ on: jobs: pytest: - uses: ./.github/workflows/pytest.yaml + uses: colcon/ci/.github/workflows/pytest.yaml@main secrets: CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} diff --git a/.github/workflows/pytest.yaml b/.github/workflows/pytest.yaml deleted file mode 100644 index 0907086..0000000 --- a/.github/workflows/pytest.yaml +++ /dev/null @@ -1,76 +0,0 @@ -# Forked from colcon/ci to allow cargo install step, ref https://github.com/colcon/ci/pull/33 -# TODO(anyone) revisit if a better solution pops up from the upstream PR ---- -name: Run tests - -on: # yamllint disable-line rule:truthy - workflow_call: - inputs: - codecov: - description: 'run codecov action after testing' - default: true - required: false - type: boolean - matrix-filter: - description: 'jq filter string indicating which configuration(s) - should be included' - default: '.' - required: false - type: string - repository: - description: 'repository to test if different from current' - default: '' - required: false - type: string - setup-repository: - description: 'repository used during job setup' - default: 'colcon/ci' - required: false - type: string - prerun-step: - description: 'instruction to run before the testing' - default: '' - required: false - type: string - secrets: - CODECOV_TOKEN: - description: 'token to use when running codecov action after testing' - required: false - -jobs: - setup: - runs-on: ubuntu-latest - outputs: - strategy: ${{ steps.load.outputs.strategy }} - steps: - - uses: actions/checkout@v4 - with: - repository: ${{ inputs.setup-repository }} - - id: load - run: | - strategy=$(jq -c -M '${{ inputs.matrix-filter }}' strategy.json) - echo "strategy=${strategy}" >> $GITHUB_OUTPUT - - pytest: - needs: [setup] - strategy: ${{ fromJson(needs.setup.outputs.strategy) }} - runs-on: ${{ matrix.os }} - - steps: - - uses: actions/checkout@v4 - with: - repository: ${{ inputs.repository }} - - run: bash -c "${{ inputs.prerun-step }}" - if: ${{ inputs.prerun-step != ''}} - - uses: actions/setup-python@v5 - with: - python-version: ${{ matrix.python }} - - uses: actions/checkout@v4 - with: - repository: ${{ inputs.setup-repository }} - path: ./.github-ci-action-repo - - uses: ./.github-ci-action-repo - - uses: codecov/codecov-action@v4 - env: - CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} - if: ${{ inputs.codecov }}