From 0e05dd0e4d67d88ca51780dafe4029744269e6fa Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Mon, 15 Apr 2024 07:55:35 +0200 Subject: Adding debian version 4:24.2.0-1. Signed-off-by: Daniel Baumann --- debian/tests/test-extension | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100755 debian/tests/test-extension (limited to 'debian/tests/test-extension') diff --git a/debian/tests/test-extension b/debian/tests/test-extension new file mode 100755 index 0000000000..460ed0fb77 --- /dev/null +++ b/debian/tests/test-extension @@ -0,0 +1,40 @@ +#!/bin/bash +# autopkgtest check: Install a test extension (as smoketest would do) +# (c) 2017 Software in the Public Interest, Inc. +# Authors: Rene Engelhard + +set -e +set -E + +if [ -n "$AUTOPKGTEST_TMP" ]; then + TMP=`mktemp -q -p $AUTOPKGTEST_TMP` +else + TMP=`mktemp -q` +fi + +# skip if building as root: +# unopkg errors out with "ERROR: Cannot run unopkg as root without --shared or --bundled option." +# if ran as root +if [ `id -u` = "0" ]; then + exit 77 +fi + +echo +echo "====== Add the extension ======" +# does it install fine? +unopkg add -v /usr/share/libreoffice/TestExtension.oxt + +echo +echo "====== Show extension status ======" +# does it list? For whatever reason unopkg leaves a stale .lock behind when +# doing this grep directly on the output so do it on a tmpfile +unopkg list | tee $TMP +grep -q org.libreoffice.smoketest.TestExtension $TMP || exit 1 +rm $TMP + +echo +echo "====== Remove the extension ======" +# does it remove? +unopkg remove -v org.libreoffice.smoketest.TestExtension + + -- cgit v1.2.3