Skip to content
Snippets Groups Projects
Commit db29c222 authored by Guido Gunther's avatar Guido Gunther :zzz:
Browse files

smoketest: Take screenshots during CI

parent 977372fe
No related branches found
No related tags found
1 merge request!92Take screenshots during CI
......@@ -8,7 +8,7 @@ variables:
variables: &smoketest_vars
DEPS: libwlroots-examples wget gnome-session gdb weston valgrind
libhandy-0.0-0-dbgsym libgtk-3-0-dbgsym libglib2.0-0-dbgsym
xvfb
xvfb imagemagick
WANT_BUILD_DEPS: "false"
before_script:
......@@ -60,6 +60,7 @@ test:smoke:one-output:
artifacts:
paths:
- output/*.log
- output/*.png
when: always
test:smoke:two-outputs:
......@@ -76,6 +77,7 @@ test:smoke:two-outputs:
artifacts:
paths:
- output/*.log
- output/*.png
when: always
test:smoke:valgrind:
......@@ -93,5 +95,6 @@ test:smoke:valgrind:
paths:
- vgdump
- output/*.log
- output/*.png
when: always
......@@ -11,6 +11,7 @@ WLROOTS_LOG="${OUTDIR}/rootston.log"
ROOTSTON_CONFIG="${WORKDIR}/rootston.ini"
VGDUMP="./vgdump"
TIMEOUT=5
DISPLAY=:99
function cleanup () {
[ ! -f core ] || echo bt | gdb -c core _build/src/phosh | tee >& "${OUTDIR}"/backtrace.log
......@@ -64,7 +65,7 @@ mode = 768x1024
mode = 1280x800
EOF
XVFB_OPTS="-screen 0 768x1024x24 -ac +extension GLX +render -noreset"
XVFB_OPTS="${DISPLAY} -screen 0 768x1024x24 -ac +extension GLX +render -noreset"
export WLR_BACKENDS=x11
export XDG_RUNTIME_DIR="${WORKDIR}"
xvfb-run -s "${XVFB_OPTS}" -a /usr/lib/wlroots/rootston \
......@@ -73,6 +74,7 @@ xvfb-run -s "${XVFB_OPTS}" -a /usr/lib/wlroots/rootston \
>& "${WLROOTS_LOG}" &
XVFB_PID=$!
echo "xvfb PID is $XVFB_PID"
export DISPLAY
echo -n "Waiting for rootston to start..."
# Wait for startup
......@@ -118,6 +120,8 @@ if ! kill -0 $PHOSH_PID; then
fi
echo "yes."
import -display "${DISPLAY}" -window root "${OUTDIR}"/lockscreen.png
echo "Checking if phosh shuts down..."
kill -15 $PHOSH_PID
echo -n "Waiting ${TIMEOUT} seconds for phosh to stop..."
......@@ -128,6 +132,8 @@ if kill -0 $PHOSH_PID >&/dev/null; then
fi
echo "yes."
import -display "${DISPLAY}" -window root "${OUTDIR}"/empty.png
echo "Started/stopped phosh successfully"
RET=0
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment