fwupd/contrib/debian/fwupd-tests.postinst
Mario Limonciello 15e4b0caaf installed-tests: Adjust to actually use a remote for installed tests
By using a remote, this should allow using gnome-software to do the
installed tests without hacking around much.

Fixes: https://github.com/hughsie/fwupd/issues/862
Fixes: https://github.com/hughsie/fwupd/issues/809
2018-11-29 09:40:06 -06:00

24 lines
588 B
Bash

#!/bin/sh
set -e
#DEBHELPER#
#only enable on installation not upgrade
if [ "$1" = configure ] && [ -z "$2" ]; then
if [ -f /etc/fwupd/daemon.conf ]; then
if [ "$CI" = "true" ]; then
sed "s,^BlacklistPlugins=test,BlacklistPlugins=," -i /etc/fwupd/daemon.conf
else
echo "To enable test suite, modify /etc/fwupd/daemon.conf"
fi
fi
if [ -f /etc/fwupd/remotes.d/fwupd-tests.conf ]; then
if [ "$CI" = "true" ]; then
sed "s,^Enabled=false,Enabled=true," -i /etc/fwupd/remotes.d/fwupd-tests.conf
else
echo "To enable test suite, enable fwupd-tests remote"
fi
fi
fi