Skip to content

Commit

Permalink
update tests to orange-ci-cd
Browse files Browse the repository at this point in the history
  • Loading branch information
markotoplak committed Dec 22, 2023
1 parent df48022 commit d7f0822
Show file tree
Hide file tree
Showing 6 changed files with 64 additions and 354 deletions.
205 changes: 0 additions & 205 deletions .github/workflows/check_pylint_diff.sh

This file was deleted.

30 changes: 30 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Lint

on:
push:
branches:
- master
pull_request:
branches:
- master

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.11]

steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install pre-commit
- name: Lint
run: pre-commit run --all-files --show-diff-on-failure
34 changes: 0 additions & 34 deletions .github/workflows/lint_workflow.yml

This file was deleted.

101 changes: 2 additions & 99 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,104 +7,7 @@ on:
pull_request:
branches:
- master
workflow_dispatch:
schedule:
- cron: '0 6 1 * *'

jobs:
build:
runs-on: ${{ matrix.os }}
continue-on-error: ${{ matrix.experimental }}
timeout-minutes: 20
name: ${{ matrix.name }} (${{ matrix.os }}, ${{ matrix.python-version }})
strategy:
fail-fast: false
matrix:
os: [ubuntu-20.04, macos-11, windows-2019]
python-version: [3.8, 3.9]
tox_env: [py-orange-released]
experimental: [false]
name: [Released]
include:
- os: ubuntu-20.04
python-version: 3.9
tox_env: py-orange-dask
name: Dask
experimental: false

- os: windows-2019
python-version: 3.8
tox_env: py-orange-oldest
experimental: false
name: Oldest
- os: macos-11
python-version: 3.8
tox_env: py-orange-oldest
name: Oldest
experimental: false
- os: ubuntu-20.04
python-version: 3.8
tox_env: py-orange-oldest
name: Oldest
experimental: false

- os: windows-2019
python-version: 3.9
tox_env: py-orange-latest
experimental: false
name: Latest
- os: macos-11
python-version: 3.9
tox_env: py-orange-latest
experimental: false
name: Latest
- os: ubuntu-20.04
python-version: 3.9
tox_env: py-orange-latest
experimental: false
name: Latest

steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Install linux system dependencies
if: |
matrix.os == 'ubuntu-20.04'
run: |
sudo apt-get update
sudo apt-get install -y libxkbcommon-x11-0 libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-xinerama0 libxcb-xfixes0 libegl1-mesa libxcb-shape0
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install --upgrade tox
- name: Set environment variable
# this step sets QT_QPA_PLATFORM env which is required on Ubuntu and
# it is skipped on Windows - QLabel font issues
if: runner.os != 'Windows'
run: |
echo "QT_QPA_PLATFORM=offscreen" >> $GITHUB_ENV
- name: Test with Tox
run: |
tox -e ${{ matrix.tox_env }}
env:
# Raise deprecations as errors in our tests only when testing orange-oldest and orange-released.
ORANGE_DEPRECATIONS_ERROR: "${{ matrix.tox_env != 'py-orange-latest' && '1' || '' }}"
# Need this otherwise unittest installs a warning filter that overrides
# our desire to have OrangeDeprecationWarnings raised
PYTHONWARNINGS: module

- name: Upload code coverage
if: |
matrix.python-version == '3.9' &&
matrix.os == 'ubuntu-20.04' &&
matrix.tox_env == 'py-orange-dask'
uses: codecov/codecov-action@v3
with:
fail_ci_if_error: true
test:
uses: biolab/orange-ci-cd/.github/workflows/test-addons.yml@master
Loading

0 comments on commit d7f0822

Please sign in to comment.