Merge pull request #370 from AnnMarieW/chart-tests #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Run tests | |
on: | |
push: | |
branches: [master] | |
tags: | |
- v* | |
pull_request: | |
branches: [master] | |
jobs: | |
test-react: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v3 | |
with: | |
python-version: 3.12 | |
- name: 'Setup Chrome and chromedriver' | |
uses: nanasess/setup-chromedriver@v2 | |
- name: 'Setup chromedriver environment' | |
run: | | |
export DISPLAY=:99 | |
chromedriver --url-base=/wd/hub & | |
- name: Start XVFB | |
run: Xvfb :99 & | |
- name: Setup uv | |
run: | | |
curl -LsSf https://astral.sh/uv/install.sh | sh | |
uv venv | |
- name: Install package | |
run: | | |
source .venv/bin/activate | |
uv pip install --upgrade pip | |
uv pip install wheel | |
uv pip install ".[dev]" | |
npm i | |
npm run build | |
timeout-minutes: 20 | |
- name: Run tests | |
run: | | |
source .venv/bin/activate | |
uv pip install -e . | |
pytest --headless | |