Update CI tests
This commit is contained in:
parent
7362b821b4
commit
276e8071bf
@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
Name: ibus-hangul
|
Name: ibus-hangul
|
||||||
Version: 1.5.5
|
Version: 1.5.5
|
||||||
Release: 7%{?dist}
|
Release: 8%{?dist}
|
||||||
Summary: The Hangul engine for IBus input platform
|
Summary: The Hangul engine for IBus input platform
|
||||||
License: GPL-2.0-or-later
|
License: GPL-2.0-or-later
|
||||||
URL: https://github.com/libhangul/ibus-hangul
|
URL: https://github.com/libhangul/ibus-hangul
|
||||||
@ -87,6 +87,10 @@ make check \
|
|||||||
%{_datadir}/installed-tests/ibus-hangul
|
%{_datadir}/installed-tests/ibus-hangul
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Dec 9 2024 Peng Wu <pwu@redhat.com> - 1.5.5-8
|
||||||
|
- Update CI tests
|
||||||
|
- Resolves: RHEL-70370
|
||||||
|
|
||||||
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 1.5.5-7
|
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 1.5.5-7
|
||||||
- Bump release for October 2024 mass rebuild:
|
- Bump release for October 2024 mass rebuild:
|
||||||
Resolves: RHEL-64018
|
Resolves: RHEL-64018
|
||||||
|
@ -24,7 +24,8 @@ require:
|
|||||||
- ibus-hangul
|
- ibus-hangul
|
||||||
- ibus-hangul-tests
|
- ibus-hangul-tests
|
||||||
- rsync
|
- rsync
|
||||||
- xorg-x11-server-Xvfb
|
- xorg-x11-server-Xwayland
|
||||||
|
- xwayland-run
|
||||||
- appstream
|
- appstream
|
||||||
- libappstream-glib
|
- libappstream-glib
|
||||||
- desktop-file-utils
|
- desktop-file-utils
|
||||||
@ -36,4 +37,3 @@ require:
|
|||||||
- dbus-x11
|
- dbus-x11
|
||||||
- python3-devel
|
- python3-devel
|
||||||
- python3-pyxdg
|
- python3-pyxdg
|
||||||
- xorg-x11-server-Xvfb
|
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||||
|
|
||||||
NAME=ibus-hangul
|
NAME=ibus-hangul
|
||||||
|
XFWB_SCRIPT=$(pwd)/xwfb-script.sh
|
||||||
|
|
||||||
rlJournalStart
|
rlJournalStart
|
||||||
rlPhaseStartSetup
|
rlPhaseStartSetup
|
||||||
@ -14,23 +15,25 @@ rlJournalStart
|
|||||||
rlPhaseEnd
|
rlPhaseEnd
|
||||||
|
|
||||||
rlPhaseStartTest
|
rlPhaseStartTest
|
||||||
rlRun "ibus-desktop-testing-runner \
|
rlRun -t -l "pushd /usr/libexec/installed-tests/ibus-hangul" \
|
||||||
--no-graphics \
|
0 "Change to directory of installed tests"
|
||||||
--runner=gnome \
|
if [ -z "${DISPLAY:-}" ]; then
|
||||||
--timeout=1500 \
|
rlLogInfo "DISPLAY is empty or unset."
|
||||||
--tests=${NAME} \
|
rlLogInfo "Therefore, use xfwb-run to run the graphical ibus-hangul test:"
|
||||||
--output=${NAME}.log \
|
rlRun -t -s "xwfb-run -c mutter -e $tmp/xwfb-run.log -n 99 $XFWB_SCRIPT" \
|
||||||
--result=test.log \
|
0 "Running ibus-hangul test in xfwb-run"
|
||||||
" 0 "Running ${NAME} tests"
|
echo "==== START of `cat ${rlRun_LOG}`: log of xwfb-run ===="
|
||||||
echo "==== ${NAME}.log: ===="
|
cat ${rlRun_LOG}
|
||||||
cat ${NAME}.log
|
echo "==== END of `cat ${rlRun_LOG}`: log of xwfb-run ===="
|
||||||
echo "==== EOF ${NAME}.log: ===="
|
rlAssertNotGrep FAIL ${rlRun_LOG}
|
||||||
echo "==== test.log ===="
|
rlGetTestState
|
||||||
cat test.log
|
rlLog "Total number of failed asserts: ${ECODE}"
|
||||||
echo "==== EOF test.log: ===="
|
rlFileSubmit ${rlRun_LOG}
|
||||||
rlAssertNotGrep FAIL test.log
|
rlFileSubmit xwfb-run.log
|
||||||
rlFileSubmit ${NAME}.log
|
fi
|
||||||
rlFileSubmit test.log
|
rlGetTestState
|
||||||
|
rlLog "Total number of failed asserts: ${ECODE}"
|
||||||
|
rlRun "popd" 0
|
||||||
rlPhaseEnd
|
rlPhaseEnd
|
||||||
|
|
||||||
rlPhaseStartCleanup
|
rlPhaseStartCleanup
|
||||||
|
31
tests/xwfb-script.sh
Executable file
31
tests/xwfb-script.sh
Executable file
@ -0,0 +1,31 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# Run this with `xwfb-run -e /tmp/xwfb-run.log -n 99 xwfb-script.sh`
|
||||||
|
|
||||||
|
# Redirect stderr to stdout:
|
||||||
|
exec 2>&1
|
||||||
|
# without setting GDK_BACKEND=x11, Gtk programs cannot open windows in xfwb-run:
|
||||||
|
export GDK_BACKEND=x11
|
||||||
|
export XDG_SESSION_TYPE=x11
|
||||||
|
echo "starting mutter ..."
|
||||||
|
mutter --x11 &
|
||||||
|
sleep 5
|
||||||
|
echo "mutter started"
|
||||||
|
ibus-daemon --verbose \
|
||||||
|
--replace \
|
||||||
|
--single \
|
||||||
|
--desktop=mutter \
|
||||||
|
--panel=disable \
|
||||||
|
--config=disable &
|
||||||
|
sleep 5
|
||||||
|
echo "ibus-daemon started."
|
||||||
|
/usr/libexec/installed-tests/ibus-hangul/ibus-hangul --tap &
|
||||||
|
TEST_PID=$!
|
||||||
|
# A screenshot for debugging can be made here:
|
||||||
|
#sleep 1
|
||||||
|
#import -window root /tmp/screenshot.png
|
||||||
|
#echo "screenshot done."
|
||||||
|
# Wait for ibus-hangul tests to finish and get its exit code
|
||||||
|
wait $TEST_PID
|
||||||
|
EXIT_CODE=$?
|
||||||
|
echo "The exit code of ibus-hangul: $EXIT_CODE"
|
||||||
|
exit $EXIT_CODE
|
Loading…
Reference in New Issue
Block a user