ci(tests): add test framework (#1603)

This commit is contained in:
ReenigneArcher 2024-03-24 19:52:24 -04:00 committed by GitHub
commit 89e8b9628c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
43 changed files with 1519 additions and 136 deletions

View file

@ -32,7 +32,9 @@ apt-get update -y
apt-get install -y --no-install-recommends \
build-essential \
cmake=3.25.* \
doxygen \
git \
graphviz \
libavdevice-dev \
libayatana-appindicator3-dev \
libboost-filesystem-dev=1.74.* \
@ -61,8 +63,12 @@ apt-get install -y --no-install-recommends \
libxtst-dev \
nodejs \
npm \
python3.11 \
python3.11-venv \
udev \
wget
wget \
x11-xserver-utils \
xvfb
if [[ "${TARGETPLATFORM}" == 'linux/amd64' ]]; then
apt-get install -y --no-install-recommends \
libmfx-dev
@ -120,6 +126,17 @@ make -j "$(nproc)"
cpack -G DEB
_MAKE
# run tests
WORKDIR /build/sunshine/build/tests
# hadolint ignore=SC1091
RUN <<_TEST
#!/bin/bash
set -e
export DISPLAY=:1
Xvfb ${DISPLAY} -screen 0 1024x768x24 &
./test_sunshine --gtest_color=yes
_TEST
FROM scratch AS artifacts
ARG BASE
ARG TAG