TEST="1 - It wants to make pre and post snapshots"
rm -f mock-snapperd.log
-test_pre_post_snapshots | runit ../../data/zypp-plugin.conf > /dev/null
+test_pre_post_snapshots | runit zypp-plugin-maxcover.conf > /dev/null
if [ "${PIPESTATUS[1]}" != 0 ]; then
echo -n "not "
fi
TEST="3 - It wants to make and delete pre snapshot"
rm -f mock-snapperd.log
-test_pre_del_snapshots | runit ../../data/zypp-plugin.conf > /dev/null
+test_pre_del_snapshots | runit zypp-plugin-maxcover.conf > /dev/null
if [ "${PIPESTATUS[1]}" != 0 ]; then
echo -n "not "
fi
check_SCRIPTS = 1-happy.test 2-malformed-xml.test 3-invalid-xml.test 4-badjson.test 99-shell.test
noinst_SCRIPTS = mock-snapperd test-helper.sh
-noinst_DATA = zypp-plugin-malformed.conf zypp-plugin-invalid.conf
+noinst_DATA = \
+ zypp-plugin-invalid.conf \
+ zypp-plugin-malformed.conf \
+ zypp-plugin-maxcover.conf
# Hack: these tests both use mock-snapperd which is not paralellized
# so serialize them
stomp_message COMMITBEGIN "" "$(json mypkg)"
stomp_message COMMITEND "" "$(json mypkg)"
stomp_message PLUGINEND "" ""
+ stomp_message UNKNOWNMESSAGE "" ""
+ stomp_message _DISCONNECT "" ""
}
test_pre_del_snapshots() {
--- /dev/null
+<?xml version="1.0" encoding="utf-8"?>
+<snapper-zypp-plugin-conf>
+ <!--
+ A default config extended so that more code paths are tested
+ -->
+ <solvables>
+ <solvable match="w" important="true">kernel-*</solvable>
+ <solvable match="w" important="true">dracut</solvable>
+ <solvable match="w" important="true">glibc</solvable>
+ <solvable match="w" important="true">systemd*</solvable>
+ <solvable match="w" important="true">udev</solvable>
+ <solvable match="re" important="true">my[_-]?pkg</solvable>
+ <solvable>ignored-no-match-attr</solvable>
+ <solvable match="w">*</solvable>
+ </solvables>
+
+</snapper-zypp-plugin-conf>