Files
galaxy/.github/workflows/framework.yaml
T
mvdbeek 3a2e936401 Install node from setup-node action in more tests
Should help with nodeenv failing in CI tests, e.g.
```
Installing node into /home/runner/work/galaxy/galaxy/galaxy root/.tox/unit-coverage with nodeenv.
 * Install prebuilt node (18.12.1) .Incomplete read while readingfrom https://nodejs.org/download/release/v18.12.1/node-v18.12.1-linux-x64.tar.gz
.
Traceback (most recent call last):
  File "/home/runner/work/galaxy/galaxy/galaxy root/.tox/unit-coverage/bin/nodeenv", line 10, in <module>
    sys.exit(main())
  File "/home/runner/work/galaxy/galaxy/galaxy root/.tox/unit-coverage/lib/python3.7/site-packages/nodeenv.py", line 1104, in main
    create_environment(env_dir, args)
  File "/home/runner/work/galaxy/galaxy/galaxy root/.tox/unit-coverage/lib/python3.7/site-packages/nodeenv.py", line 980, in create_environment
    install_node(env_dir, src_dir, args)
  File "/home/runner/work/galaxy/galaxy/galaxy root/.tox/unit-coverage/lib/python3.7/site-packages/nodeenv.py", line 739, in install_node
    install_node_wrapped(env_dir, src_dir, args)
  File "/home/runner/work/galaxy/galaxy/galaxy root/.tox/unit-coverage/lib/python3.7/site-packages/nodeenv.py", line 762, in install_node_wrapped
    download_node_src(node_url, src_dir, args)
  File "/home/runner/work/galaxy/galaxy/galaxy root/.tox/unit-coverage/lib/python3.7/site-packages/nodeenv.py", line 602, in download_node_src
    with ctx as archive:
  File "/opt/hostedtoolcache/Python/3.7.16/x64/lib/python3.7/contextlib.py", line 112, in __enter__
    return next(self.gen)
  File "/home/runner/work/galaxy/galaxy/galaxy root/.tox/unit-coverage/lib/python3.7/site-packages/nodeenv.py", line 573, in tarfile_open
    tf = tarfile.open(*args, **kwargs)
  File "/opt/hostedtoolcache/Python/3.7.16/x64/lib/python3.7/tarfile.py", line 1573, in open
    saved_pos = fileobj.tell()
AttributeError: 'bytes' object has no attribute 'tell'
```
from https://github.com/galaxyproject/galaxy/actions/runs/4883207488/jobs/8714237674?pr=16036
2023-05-04 17:35:06 +02:00

80 lines
2.5 KiB
YAML

name: Framework tests
on:
push:
paths-ignore:
- 'client/**'
- 'doc/**'
- 'lib/galaxy_test/selenium/**'
pull_request:
paths-ignore:
- 'client/**'
- 'doc/**'
- 'lib/galaxy_test/selenium/**'
schedule:
# Run at midnight UTC every Tuesday
- cron: '0 0 * * 2'
env:
GALAXY_TEST_DBURI: 'postgresql://postgres:postgres@localhost:5432/galaxy?client_encoding=utf8'
GALAXY_TEST_RAISE_EXCEPTION_ON_HISTORYLESS_HDA: '1'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
name: Test
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.7']
services:
postgres:
image: postgres:13
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: postgres
ports:
- 5432:5432
steps:
- if: github.event_name == 'schedule'
run: |
echo "GALAXY_CONFIG_OVERRIDE_METADATA_STRATEGY=extended" >> $GITHUB_ENV
echo "GALAXY_CONFIG_OVERRIDE_OUTPUTS_TO_WORKING_DIRECTORY=true" >> $GITHUB_ENV
- uses: actions/checkout@v3
with:
path: 'galaxy root'
- uses: actions/setup-node@v3
with:
node-version: '18.12.1'
cache: 'yarn'
cache-dependency-path: 'galaxy root/client/yarn.lock'
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Get full Python version
id: full-python-version
shell: bash
run: echo "version=$(python -c 'import sys; print("-".join(str(v) for v in sys.version_info))')" >> $GITHUB_OUTPUT
- name: Cache pip dir
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: pip-cache-${{ matrix.python-version }}-${{ hashFiles('galaxy root/requirements.txt') }}
- name: Cache galaxy venv
uses: actions/cache@v3
with:
path: 'galaxy root/.venv'
key: gxy-venv-${{ runner.os }}-${{ steps.full-python-version.outputs.version }}-${{ hashFiles('galaxy root/requirements.txt') }}-framework
- name: Run tests
run: ./run_tests.sh --coverage --framework
working-directory: 'galaxy root'
- uses: codecov/codecov-action@v3
with:
flags: framework
working-directory: 'galaxy root'
- uses: actions/upload-artifact@v3
if: failure()
with:
name: Framework test results (${{ matrix.python-version }})
path: 'galaxy root/run_framework_tests.html'