Skip to content

Commit

Permalink
TST: Add RC testing workflow
Browse files Browse the repository at this point in the history
and update existing
  • Loading branch information
pllim committed Feb 7, 2023
1 parent 3fc9a92 commit eafa22a
Show file tree
Hide file tree
Showing 5 changed files with 67 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .github/workflows/ci_cron_weekly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ on:
# run at 9am UTC on Mondays
- cron: '0 9 * * 1'

permissions:
contents: read

jobs:
# The linkcheck job tests that the links in the docs point to real places
# The if statement is to prevent cron from running on forks.
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/ci_workflows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

permissions:
contents: read

jobs:
# Github Actions supports ubuntu, windows, and macos virtual environments:
# https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ on:
# run every Monday at 3am UTC
- cron: '0 3 * * 1'

permissions:
contents: read

jobs:
analyze:
name: Analyze
Expand Down
53 changes: 53 additions & 0 deletions .github/workflows/predeps_workflows.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: rc-testing

on:
workflow_dispatch:
# REMOVE ME
pull_request:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

permissions:
contents: read

jobs:
# Github Actions supports ubuntu, windows, and macos virtual environments:
# https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners
ci_tests:
name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:

- name: RC testing on Linux with remote data
os: ubuntu-latest
python: '3.11'
toxenv: py311-test-predeps
toxposargs: --remote-data

- name: RC testing on OSX
os: macos-latest
python: 3.9
toxenv: py39-test-predeps

- name: RC testing on Windows
os: windows-latest
python: '3.10'
toxenv: py310-test-predeps

steps:
- name: Checkout code
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up python ${{ matrix.python }} on ${{ matrix.os }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
- name: Install base dependencies
run: python -m pip install --upgrade pip tox
- name: Test/run with tox
run: tox -e ${{ matrix.toxenv }} -- ${{ matrix.toxposargs }}
6 changes: 5 additions & 1 deletion tox.ini
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tox]
envlist =
py{38,39,310,311}-test{,-alldeps,-devdeps}{,-cov}
py{38,39,310,311}-test{,-alldeps,-devdeps,-predeps}{,-cov}
linkcheck
codestyle
pep517
Expand Down Expand Up @@ -71,6 +71,10 @@ commands =
cov: pytest --pyargs jdaviz {toxinidir}/docs --cov jdaviz --cov-config={toxinidir}/setup.cfg {posargs}
cov: coverage xml -o {toxinidir}/coverage.xml

pip_pre =
predeps: true
!predeps: false

[testenv:linkcheck]
changedir = docs
description = check the links in the HTML docs
Expand Down

0 comments on commit eafa22a

Please sign in to comment.