Add CI
This commit is contained in:
parent
eaed25c45a
commit
b26f672937
1
.fmf/version
Normal file
1
.fmf/version
Normal file
@ -0,0 +1 @@
|
||||
1
|
@ -16,7 +16,7 @@
|
||||
|
||||
Name: libdbusmenu
|
||||
Version: %{ubuntu_release}.0
|
||||
Release: 27%{?dist}
|
||||
Release: 28%{?dist}
|
||||
Summary: Library for passing menus over DBus
|
||||
|
||||
# All files installed in final rpms use C sources with dual licensing headers.
|
||||
@ -52,6 +52,9 @@ BuildRequires: pkgconfig(gtk+-3.0) >= 2.91
|
||||
BuildRequires: pkgconfig(json-glib-1.0) >= 0.13.4
|
||||
BuildRequires: pkgconfig(x11) >= 1.3
|
||||
BuildRequires: vala
|
||||
%if 0%{?rhel} > 9
|
||||
BuildRequires: xorg-x11-server-Xvfb
|
||||
%endif
|
||||
|
||||
# pkgconfig file is checked for valgrind, but is actually only used for tests
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1262274
|
||||
@ -281,6 +284,9 @@ done
|
||||
%{_datadir}/%{name}/json/test-gtk-label.json
|
||||
|
||||
%changelog
|
||||
* Sat May 11 2024 Takao Fujiwara <fujiwara@redhat.com> - 16.04.0-28
|
||||
- Add CI
|
||||
|
||||
* Thu Jan 25 2024 Fedora Release Engineering <releng@fedoraproject.org> - 16.04.0-27
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
||||
|
||||
|
5
plans/test.fmf
Normal file
5
plans/test.fmf
Normal file
@ -0,0 +1,5 @@
|
||||
summary: Basic smoke test
|
||||
discover:
|
||||
how: fmf
|
||||
execute:
|
||||
how: tmt
|
8
tests/test-glib-simple-items/main.fmf
Normal file
8
tests/test-glib-simple-items/main.fmf
Normal file
@ -0,0 +1,8 @@
|
||||
summary: libdbusmenu-gtk3-tests tests
|
||||
test: ./test.sh
|
||||
framework: beakerlib
|
||||
require:
|
||||
- tmt
|
||||
- git
|
||||
- libdbusmenu-gtk3-tests
|
||||
- xorg-x11-server-Xvfb
|
26
tests/test-glib-simple-items/test.sh
Executable file
26
tests/test-glib-simple-items/test.sh
Executable file
@ -0,0 +1,26 @@
|
||||
#!/bin/bash
|
||||
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||
|
||||
rlJournalStart
|
||||
rlPhaseStartSetup
|
||||
rlRun "tmp=\$(mktemp -d)" 0 "Create tmp directory"
|
||||
rlRun "pushd $tmp"
|
||||
rlRun "export DISPLAY=:99.0"
|
||||
rlRun "/usr/bin/Xvfb $DISPLAY -noreset +extension GLX +extension RANDR +extension RENDER -screen 0 1280x1024x24 &"
|
||||
rlRun "echo $! > X_PID"
|
||||
rlRun "sleep 5"
|
||||
rlRun "set -o pipefail"
|
||||
rlPhaseEnd
|
||||
|
||||
rlPhaseStartTest
|
||||
rlRun "export DISPLAY=:99.0"
|
||||
rlRun "/usr/libexec/libdbusmenu-gtk3/test-glib-simple-items >output 2>&1" 0
|
||||
rlPhaseEnd
|
||||
|
||||
rlPhaseStartCleanup
|
||||
rlRun "kill -9 $(cat X_PID)"
|
||||
rlRun "popd"
|
||||
rlRun "rm -r $tmp" 0 "Remove tmp directory"
|
||||
rlPhaseEnd
|
||||
rlJournalEnd
|
Loading…
Reference in New Issue
Block a user