I have made the following changes intended for : nemo:devel:mw / telepathy-glib
Please review and accept or decline. BOSS has already run some checks on this request. See the "Messages from BOSS" section below. https://build.merproject.org//request/show/216 Thank You, Reto Zingg [This message was auto-generated] --- Request # 216: Messages from BOSS: State: review at 2013-04-16T07:32:16 by cibot Reviews: accepted by cibot : Prechecks succeeded. new for nemo:devel:mw : Please replace this text with a review and approve/reject the review (not the SR). BOSS will take care of the rest Changes: submit: home:kontio:Telepathy / telepathy-glib -> nemo:devel:mw / telepathy-glib changes files: -------------- --- telepathy-glib.changes +++ telepathy-glib.changes @@ -0,0 +1,3 @@ +* Tue Apr 16 2013 Reto Zingg <[email protected]> - 0.20.0 +- create -tests package for auto testing + new: ---- INSIGNIFICANT mktests.sh nemo-test-packaging.patch spec files: ----------- --- telepathy-glib.spec +++ telepathy-glib.spec @@ -15,8 +15,11 @@ License: LGPLv2+ URL: http://telepathy.freedesktop.org/wiki/ Source0: http://telepathy.freedesktop.org/releases/telepathy-glib/%{name}-%{version}.tar.gz +Source1: INSIGNIFICANT +Source2: mktests.sh Source100: telepathy-glib.yaml Patch0: pkgconfig.patch +Patch1: nemo-test-packaging.patch Requires: glib2 >= 2.32.0 Requires(post): /sbin/ldconfig Requires(postun): /sbin/ldconfig @@ -45,13 +48,40 @@ that use Telepathy-GLib. +%package tests +Summary: Tests package for %{name} +Group: Development/Libraries +Requires: %{name} = %{version}-%{release} +Requires: %{name}-examples + +%description tests +The %{name}-tests package contains tests and +tests.xml for automated testing. + + +%package examples +Summary: Example programs for %{name} +Group: Development/Libraries +Requires: %{name} = %{version}-%{release} + +%description examples +The %{name}-examples package contains example +programs. Some are needed for the tests. + + %prep %setup -q -n %{name}-%{version} # pkgconfig.patch %patch0 -p1 +# nemo-test-packaging.patch +%patch1 -p1 # >> setup +%__cp $RPM_SOURCE_DIR/mktests.sh tests/ +%__cp $RPM_SOURCE_DIR/INSIGNIFICANT tests/ +%__chmod 0755 tests/mktests.sh +%__chmod 0644 tests/INSIGNIFICANT # << setup %build @@ -59,11 +89,13 @@ # << build pre %configure --disable-static \ - --enable-silent-rules + --enable-silent-rules \ + --enable-installed-tests make %{?jobs:-j%jobs} # >> build post +tests/mktests.sh > tests/tests.xml # << build post %install @@ -73,14 +105,12 @@ %make_install # >> install post +install -m 0644 tests/tests.xml $RPM_BUILD_ROOT/opt/tests/telepathy-glib/tests.xml +install -m 0644 tests/INSIGNIFICANT $RPM_BUILD_ROOT/opt/tests/telepathy-glib/INSIGNIFICANT +install -m 0644 tests/README $RPM_BUILD_ROOT/opt/tests/telepathy-glib/README # << install post -%check -# >> check -make check -# << check - %post -p /sbin/ldconfig %postun -p /sbin/ldconfig @@ -100,3 +130,18 @@ %{_includedir}/telepathy-1.0/%{name}/ %doc /usr/share/gtk-doc/html/* # << files devel + +%files tests +%defattr(-,root,root,-) +/opt/tests/%{name}/* +# >> files tests +# << files tests + +%files examples +%defattr(-,root,root,-) +%{_bindir}/telepathy-example* +%{_libexecdir}/telepathy-example* +%{_datadir}/dbus-1/services/org.freedesktop.Telepathy.ConnectionManager.example* +%{_datadir}/telepathy/managers/example* +# >> files examples +# << files examples other changes: -------------- ++++++ INSIGNIFICANT (new) --- INSIGNIFICANT +++ INSIGNIFICANT ++++++ mktests.sh (new) --- mktests.sh +++ mktests.sh @@ -0,0 +1,52 @@ +#!/bin/sh + +cat <<EOF +<?xml version="1.0" encoding="UTF-8"?> +<testdefinition version="1.0"> + <suite name="telepathy-glib-tests"> + <description>Telepathy Glib tests</description> + <set name="telepathy-glib-C-tests"> +EOF + +for testcase in $(cat tests/tpglib-tests.list) +do + attributes="name=\"$testcase\"" + insignificant=`grep "^$testcase" tests/INSIGNIFICANT || true` + if test -n "$insignificant" + then + continue + attributes="$attributes insignificant=\"true\"" + fi + cat <<EOF + <case $attributes> + <step>/opt/tests/telepathy-glib/$testcase</step> + </case> +EOF +done + +cat <<EOF + </set> + <set name="telepathy-glib-dbus-tests"> +EOF + +for testcase in $(cat tests/dbus/tpglib-dbus-tests.list) +do + attributes="name=\"$testcase\"" + insignificant=`grep "^$testcase" tests/INSIGNIFICANT || true` + if test -n "$insignificant" + then + continue + attributes="$attributes insignificant=\"true\"" + fi + cat <<EOF + <case $attributes> + <step>/opt/tests/telepathy-glib/run-test.sh $testcase</step> + </case> +EOF +done + +cat <<EOF + </set> + </suite> +</testdefinition> +EOF ++++++ nemo-test-packaging.patch (new) --- nemo-test-packaging.patch +++ nemo-test-packaging.patch @@ -0,0 +1,12 @@ +diff -Naur telepathy-glib-0.20.0/configure telepathy-glib-0.20.0-nemo-tests-packaging/configure +--- telepathy-glib-0.20.0/configure 2012-10-03 12:05:09.000000000 +0000 ++++ telepathy-glib-0.20.0-nemo-tests-packaging/configure 2013-04-15 19:31:10.000000000 +0000 +@@ -13048,7 +13048,7 @@ + fi + + +-tpglibtestsdir=${libdir}/telepathy-glib-tests ++tpglibtestsdir=/opt/tests/telepathy-glib + + + ++++++ telepathy-glib.yaml --- telepathy-glib.yaml +++ telepathy-glib.yaml @@ -7,8 +7,11 @@ URL: http://telepathy.freedesktop.org/wiki/ Sources: - http://telepathy.freedesktop.org/releases/telepathy-glib/%{name}-%{version}.tar.gz + - INSIGNIFICANT + - mktests.sh Patches: - pkgconfig.patch + - nemo-test-packaging.patch Description: | Telepathy-GLib is a GObject-based C binding for Telepathy, @@ -30,8 +33,8 @@ ConfigOptions: - --enable-silent-rules - -Check: true + - --enable-installed-tests +Check: false SubPackages: - Name: devel @@ -42,4 +45,24 @@ that use Telepathy-GLib. Requires: - telepathy-filesystem - + - Name: tests + Summary: Tests package for %{name} + Group: Development/Libraries + Requires: + - "%{name}-examples" + Description: | + The %{name}-tests package contains tests and + tests.xml for automated testing. + Files: + - /opt/tests/%{name}/* + - Name: examples + Summary: Example programs for %{name} + Group: Development/Libraries + Description: | + The %{name}-examples package contains example + programs. Some are needed for the tests. + Files: + - "%{_bindir}/telepathy-example*" + - "%{_libexecdir}/telepathy-example*" + - "%{_datadir}/dbus-1/services/org.freedesktop.Telepathy.ConnectionManager.example*" + - "%{_datadir}/telepathy/managers/example*"
