Skip to content

functional tests

functional tests #161

Workflow file for this run

name: functional tests
on:
workflow_dispatch:
pull_request:
paths-ignore:
- '.github/workflows/*.ya?ml'
- '!.github/workflows/test_functional.yml'
- 'cylc/flow/etc/syntax/**'
- 'etc/syntax/**'
- 'tests/conftest.py'
- 'tests/unit/**'
- 'tests/integration/**'
- '**.md'
- '**/README*/**'
push:
branches:
- master
- '8.*.x'
paths-ignore:
- '.github/workflows/*.ya?ml'
- '!.github/workflows/test_functional.yml'
- 'cylc/flow/etc/syntax/**'
- 'etc/syntax/**'
- 'tests/conftest.py'
- 'tests/unit/**'
- 'tests/integration/**'
- '**.md'
- '**/README*/**'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
defaults:
run:
shell: bash -c "exec $CONDA_PREFIX/bin/bash -elo pipefail {0}"
env:
FORCE_COLOR: 2
PIP_PROGRESS_BAR: off
jobs:
test:
runs-on: ${{ matrix.os }}
name: python-${{ matrix.python-version }} cov-${{ matrix.coverage }}
timeout-minutes: 45
strategy:
fail-fast: false
matrix:
os: ['ubuntu-latest']
python-version: ['3.13', '3.14']
coverage: [1]
env:
# these vars are used by etc/bin/run-functional-tests
CYLC_TEST_PLATFORMS: ${{ matrix.platform }}
CYLC_COVERAGE: ${{ matrix.coverage }}
REMOTE_PLATFORM: ${{ contains(matrix.platform, '_remote') }}
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Configure Python
uses: mamba-org/setup-micromamba@v2
with:
cache-environment: true
post-cleanup: 'all'
environment-name: cylc-functional-test
create-args: >-
python=${{ matrix.python-version }}
pip
bash
coreutils
grep
sed
sqlite
subversion
tree
- name: Create global config
run: |
CONF_PATH="$HOME/.cylc/flow/8"
mkdir -p "$CONF_PATH"
touch "$CONF_PATH/global.cylc"
ln -s "$CONF_PATH/global.cylc" "$CONF_PATH/global-tests.cylc"
echo "GLOBAL_CFG_PATH=${CONF_PATH}/global.cylc" >> "$GITHUB_ENV"
- name: Add .github/bin/ to PATH
# Sets up mocked mail command & any other custom executables
# Adding to $GITHUB_PATH does not work when using setup-micromamba and/or login shell
run: |
echo "export PATH=\"${{ github.workspace }}/.github/bin:$PATH\"" >> ~/.bash_profile
- name: Install
run: |
pip install -e ."[all]"
mkdir "$HOME/cylc-run"
- name: Swarm Configure
run: |
etc/bin/swarm --yes --debug configure
- name: Configure git # Needed by the odd test
uses: cylc/release-actions/configure-git@v1
- timeout-minutes: 30
run: |
etc/bin/run-functional-tests -j 8 --state=save \
tests/functional/cylc-config
- timeout-minutes: 30
run: |
etc/bin/run-functional-tests -j 8 --state=save \
tests/functional/validate