Start Xvfb before running tests

This commit is contained in:
Elias Müller 2022-07-09 18:31:42 +02:00 committed by jaseg
parent dffd89630b
commit e91fd16f35

View file

@ -12,6 +12,9 @@ defaults:
jobs: jobs:
build:
env:
DISPLAY: :0
test-python: test-python:
runs-on: ubuntu-22.04 runs-on: ubuntu-22.04
strategy: strategy:
@ -36,6 +39,10 @@ jobs:
run: | run: |
function execute() { echo -e "\033[0;34m$*\033[0m"; "$@"; } function execute() { echo -e "\033[0;34m$*\033[0m"; "$@"; }
execute sudo apt install -y libmpv1 xvfb execute sudo apt install -y libmpv1 xvfb
- name: 'Start Xvfb'
run: |
echo -e "\033[0;34msudo /usr/bin/Xvfb $DISPLAY -screen 0 1920x1080x24 &\033[0m";
sudo /usr/bin/Xvfb $DISPLAY -screen 0 1920x1080x24 &
- name: 'Create Virtual Environment' - name: 'Create Virtual Environment'
run: | run: |
function execute() { echo -e "\033[0;34m$*\033[0m"; "$@"; } function execute() { echo -e "\033[0;34m$*\033[0m"; "$@"; }