various tests: skip if temp directory lacks xattr support
Some autobuilder environments place the entire build chroot on tmpfs, so even /var/tmp might not have this. Signed-off-by: Simon McVittie <smcv@debian.org> Closes: #232 Approved by: cgwalters
This commit is contained in:
1 parent
c276025466
commit
3e3755c497
7 files changed
+25
-4
No files matched your search
@@ -324,3 +324,11 @@ os_repository_new_commit ()
|
|||||||
${CMD_PREFIX} ostree --repo=${test_tmpdir}/testos-repo commit --add-metadata-string "version=${version}" -b testos/buildmaster/x86_64-runtime -s "Build"
|
${CMD_PREFIX} ostree --repo=${test_tmpdir}/testos-repo commit --add-metadata-string "version=${version}" -b testos/buildmaster/x86_64-runtime -s "Build"
|
||||||
cd ${test_tmpdir}
|
cd ${test_tmpdir}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
skip_without_user_xattrs () {
|
||||||
|
touch test-xattrs
|
||||||
|
if ! setfattr -n user.testvalue -v somevalue test-xattrs; then
|
||||||
|
echo "1..0 # SKIP this test requires xattr support"
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
}
|
||||||
@@ -19,10 +19,12 @@
|
|||||||
|
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
|
|
||||||
echo "1..1"
|
|
||||||
|
|
||||||
. $(dirname $0)/libtest.sh
|
. $(dirname $0)/libtest.sh
|
||||||
|
|
||||||
|
skip_without_user_xattrs
|
||||||
|
|
||||||
|
echo "1..1"
|
||||||
|
|
||||||
setup_test_repository "bare-user"
|
setup_test_repository "bare-user"
|
||||||
echo "ok setup"
|
echo "ok setup"
|
||||||
|
|
||||||
|
|||||||
@@ -21,6 +21,8 @@ set -euo pipefail
|
|||||||
|
|
||||||
. $(dirname $0)/libtest.sh
|
. $(dirname $0)/libtest.sh
|
||||||
|
|
||||||
|
skip_without_user_xattrs
|
||||||
|
|
||||||
bindatafiles="bash true ostree"
|
bindatafiles="bash true ostree"
|
||||||
morebindatafiles="false ls"
|
morebindatafiles="false ls"
|
||||||
|
|
||||||
|
|||||||
@@ -26,6 +26,8 @@ fi
|
|||||||
|
|
||||||
. $(dirname $0)/libtest.sh
|
. $(dirname $0)/libtest.sh
|
||||||
|
|
||||||
|
skip_without_user_xattrs
|
||||||
|
|
||||||
echo "1..1"
|
echo "1..1"
|
||||||
|
|
||||||
# Run "triggers" like ldconfig, gtk-update-icon-cache, etc.
|
# Run "triggers" like ldconfig, gtk-update-icon-cache, etc.
|
||||||
|
|||||||
@@ -19,10 +19,12 @@
|
|||||||
|
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
|
|
||||||
echo "1..1"
|
|
||||||
|
|
||||||
. $(dirname $0)/libtest.sh
|
. $(dirname $0)/libtest.sh
|
||||||
|
|
||||||
|
skip_without_user_xattrs
|
||||||
|
|
||||||
|
echo "1..1"
|
||||||
|
|
||||||
setup_test_repository "archive-z2"
|
setup_test_repository "archive-z2"
|
||||||
echo "ok setup"
|
echo "ok setup"
|
||||||
|
|
||||||
|
|||||||
@@ -21,6 +21,8 @@ set -euo pipefail
|
|||||||
|
|
||||||
. $(dirname $0)/libtest.sh
|
. $(dirname $0)/libtest.sh
|
||||||
|
|
||||||
|
skip_without_user_xattrs
|
||||||
|
|
||||||
setup_fake_remote_repo1 "archive-z2"
|
setup_fake_remote_repo1 "archive-z2"
|
||||||
|
|
||||||
echo '1..2'
|
echo '1..2'
|
||||||
|
|||||||
@@ -25,6 +25,9 @@ if ! fusermount --version >/dev/null 2>&1; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
. $(dirname $0)/libtest.sh
|
. $(dirname $0)/libtest.sh
|
||||||
|
|
||||||
|
skip_without_user_xattrs
|
||||||
|
|
||||||
setup_test_repository "bare-user"
|
setup_test_repository "bare-user"
|
||||||
|
|
||||||
echo "1..5"
|
echo "1..5"
|
||||||
|
|||||||
Reference in new issue
Block a user