actions: remove coverage #482
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: ci | |
on: | |
pull_request: | |
paths-ignore: | |
- "**/*.asciidoc" | |
- "**/*.md" | |
push: | |
branches: | |
- main | |
paths-ignore: | |
- "**/*.asciidoc" | |
- "**/*.md" | |
permissions: | |
contents: read | |
jobs: | |
sanity-checks: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: elastic/oblt-actions/pre-commit@v1 | |
# Invokes the actual matrix workflow with the provided files. | |
matrix: | |
uses: ./.github/workflows/run-matrix.yml | |
with: | |
versionsFile: .ci/.ruby.yml | |
frameworksFile: .ci/.framework.yml | |
excludedFile: .ci/.exclude.yml | |
# Invokes the actual matrix workflow with the provided files. | |
# In this case it's for the main frameworks. | |
matrix-main-frameworks: | |
uses: ./.github/workflows/run-matrix.yml | |
with: | |
versionsFile: .ci/.ruby.yml | |
frameworksFile: .ci/.main_framework.yml | |
excludedFile: .ci/.exclude.yml | |
package: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: 2.6 | |
- name: Install build system | |
run: .ci/scripts/install-build-system.sh | |
- name: Create gem | |
run: rake build | |
- uses: actions/upload-artifact@v4 | |
with: | |
name: package | |
path: ./pkg/**/* | |
coverage: | |
name: Combine & check coverage. | |
needs: [ matrix, matrix-main-frameworks ] | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v5 | |
with: | |
# Use latest Python, so it understands all syntax. | |
python-version: 3.11 | |
- run: python -Im pip install --upgrade coverage[toml] | |
- uses: actions/download-artifact@v4 | |
with: | |
pattern: coverage-reports-* | |
merge-multiple: true | |
- name: Combine coverage | |
run: | | |
python -Im coverage combine | |
python -Im coverage html --skip-covered --skip-empty | |
# Report and write to summary. | |
python -Im coverage report | sed 's/^/ /' >> $GITHUB_STEP_SUMMARY | |
- name: Upload HTML report | |
uses: actions/upload-artifact@v4 | |
with: | |
name: html-coverage-report | |
path: htmlcov | |
- uses: geekyeggo/delete-artifact@f275313e70c08f6120db482d7a6b98377786765b # 5.1.0 | |
with: | |
name: coverage-reports-* | |
all: | |
if: always() | |
runs-on: ubuntu-latest | |
needs: | |
- sanity-checks | |
- matrix | |
- matrix-main-frameworks | |
- package | |
steps: | |
- id: check | |
uses: elastic/oblt-actions/check-dependent-jobs@v1 | |
with: | |
jobs: ${{ toJSON(needs) }} | |
- run: ${{ steps.check.outputs.is-success }} |