Skip to content

Commit

Permalink
TMP
Browse files Browse the repository at this point in the history
  • Loading branch information
MetRonnie committed Jul 1, 2024
1 parent 79338bc commit 3550397
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 166 deletions.
88 changes: 2 additions & 86 deletions .github/workflows/test_fast.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,8 @@ jobs:
strategy:
fail-fast: false # don't stop on first failure
matrix:
os: ['ubuntu-latest']
python-version: ['3.7', '3.8', '3.10', '3.11', '3']
include:
# mac os test
- os: 'macos-latest'
python-version: '3.9' # oldest supported version
# non-utc timezone test
- os: 'ubuntu-latest'
python-version: '3.9' # not the oldest, not the most recent version
time-zone: 'XXX-09:35'
os: ['macos-latest']
python-version: ['3.9']

env:
TZ: ${{ matrix.time-zone }}
Expand Down Expand Up @@ -75,79 +67,3 @@ jobs:
with:
name: cylc-run (${{ matrix.os }} py-${{ matrix.python-version }})
path: ~/cylc-run/

- name: Coverage report
run: |
coverage xml
coverage report
- name: Upload coverage artifact
uses: actions/upload-artifact@v4
with:
name: coverage_${{ matrix.os }}_py-${{ matrix.python-version }}
path: coverage.xml
retention-days: 7

lint:
runs-on: 'ubuntu-latest'
timeout-minutes: 10
steps:
- name: Apt-Get Install
run: |
sudo apt-get update
sudo apt-get install -y shellcheck
- name: Checkout
uses: actions/checkout@v4

# note: exclude python 3.10+ from mypy checks as these produce false
# positives in installed libraries for python 3.7
- name: Configure Python
uses: actions/setup-python@v5
with:
python-version: 3.9

- name: Install
run: |
pip install -e ."[tests]"
- name: Flake8
run: flake8

- name: Bandit
run: |
bandit -r --ini .bandit cylc/flow
- name: Shellchecker
run: etc/bin/shellchecker

- name: MyPy
run: mypy

- name: Towncrier - draft changelog
uses: cylc/release-actions/towncrier-draft@v1

- name: Linkcheck
run: pytest -m linkcheck --dist=load --color=yes -n 10 tests/unit/test_links.py

codecov:
needs: test
runs-on: ubuntu-latest
timeout-minutes: 2
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Download coverage artifacts
uses: actions/download-artifact@v4

- name: Codecov upload
uses: codecov/codecov-action@v4
with:
name: ${{ github.workflow }}
flags: fast-tests
fail_ci_if_error: true
verbose: true
# Token not required for public repos, but avoids upload failure due
# to rate-limiting (but not for PRs opened from forks)
token: ${{ secrets.CODECOV_TOKEN }}
83 changes: 3 additions & 80 deletions .github/workflows/test_functional.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,53 +38,11 @@ jobs:
strategy:
fail-fast: false
matrix:
os: ['ubuntu-latest']
python-version: ['3.7']
os: ['macos-latest']
python-version: ['3.9']
test-base: ['tests/f']
chunk: ['1/4', '2/4', '3/4', '4/4']
platform: ['_local_background* _local_at*']
# NOTE: includes must define ALL of the matrix values
include:
# latest python
- name: 'py-3-latest'
os: 'ubuntu-latest'
python-version: '3'
test-base: 'tests/f'
chunk: '1/4'
platform: '_local_background*'
# tests/k
- name: 'flaky'
os: 'ubuntu-latest'
python-version: '3.7'
test-base: 'tests/k'
chunk: '1/1'
platform: '_local_background* _local_at*'
# remote platforms
- name: '_remote_background_indep_poll'
os: 'ubuntu-latest'
python-version: '3.7'
test-base: 'tests/f tests/k'
chunk: '1/1'
platform: '_remote_background_indep_poll _remote_at_indep_poll'
- name: '_remote_background_indep_tcp'
os: 'ubuntu-latest'
test-base: 'tests/f tests/k'
python-version: '3.7'
chunk: '1/1'
platform: '_remote_background_indep_tcp _remote_at_indep_tcp'
# macos
- name: 'macos 1/5'
os: 'macos-latest'
python-version: '3.9'
test-base: 'tests/f'
chunk: '1/5'
platform: '_local_background*'
- name: 'macos 2/5'
os: 'macos-latest'
python-version: '3.9'
test-base: 'tests/f'
chunk: '2/5'
platform: '_local_background*'
platform: ['_local_background*']

env:
# Use non-UTC time zone
Expand Down Expand Up @@ -306,38 +264,3 @@ jobs:
if: always()
run: |
etc/bin/swarm kill
- name: Combine coverage & report
run: |
coverage combine -a
coverage xml
coverage report
- name: Upload coverage artifact
uses: actions/upload-artifact@v4
with:
name: coverage_${{ steps.uploadname.outputs.uploadname }}
path: coverage.xml
retention-days: 7

codecov:
needs: test
runs-on: ubuntu-latest
timeout-minutes: 2
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Download coverage artifacts
uses: actions/download-artifact@v4

- name: Codecov upload
uses: codecov/codecov-action@v4
with:
name: ${{ github.workflow }}
flags: functional-tests
fail_ci_if_error: true
verbose: true
# Token not required for public repos, but avoids upload failure due
# to rate-limiting (but not for PRs opened from forks)
token: ${{ secrets.CODECOV_TOKEN }}

0 comments on commit 3550397

Please sign in to comment.