Skip to content

Commit

Permalink
GIT: tests from troubleshooting
Browse files Browse the repository at this point in the history
  • Loading branch information
rpartzsch committed Jan 19, 2025
1 parent 2b857f0 commit 23b20d3
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 25 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/pre_commit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Tests

on:
pull_request:
push:
branches: [main, ui_tests_action]

jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- uses: pre-commit/[email protected]


pytest:
runs-on: ubuntu-latest
env:
DISPLAY: ':99.0'
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- run: |
sudo apt install libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-xinerama0 libxcb-xfixes0 x11-utils
pip install -e .[test]
pytest -sv
45 changes: 20 additions & 25 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,22 @@
name: Tests

on:
pull_request:
push:
branches: [main, ui_tests]

on: [push, pull_request]
jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- uses: pre-commit/[email protected]


pytest:
runs-on: ubuntu-latest
env:
DISPLAY: ':99.0'
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
- run: |
sudo apt install libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-xinerama0 libxcb-xfixes0 x11-utils
pip install -e .[test]
pytest -sv
Linux:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os : [ubuntu-latest]
python: ["3.10"]
env:
DISPLAY: ':99.0'
steps:
- name: get repo
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
- name: setup ${{ matrix.os }}
run: |
sudo apt install libxkbcommon-x11-0 libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-xinerama0 libxcb-xfixes0 x11-utils
/sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_99.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -screen 0 1920x1200x24 -ac +extension GLX

0 comments on commit 23b20d3

Please sign in to comment.