summaryrefslogtreecommitdiff
path: root/test/system/helpers.bash
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2022-01-05 17:50:37 +0100
committerGitHub <noreply@github.com>2022-01-05 17:50:37 +0100
commitcbb2b68fc9630ef8cadd19674ab591b7fee9c7d0 (patch)
tree67523c28abe72177ca0138655e897eddacb656e0 /test/system/helpers.bash
parent6902d9d9093e1d977ba733a182969bea3489dfbe (diff)
parentf6d00ea6ef977bbaf167d1187d1e4e43632f6b5c (diff)
downloadpodman-cbb2b68fc9630ef8cadd19674ab591b7fee9c7d0.tar.gz
podman-cbb2b68fc9630ef8cadd19674ab591b7fee9c7d0.tar.bz2
podman-cbb2b68fc9630ef8cadd19674ab591b7fee9c7d0.zip
Merge pull request #12429 from cdoern/scp
podman image scp never enter podman user NS
Diffstat (limited to 'test/system/helpers.bash')
-rw-r--r--test/system/helpers.bash14
1 files changed, 14 insertions, 0 deletions
diff --git a/test/system/helpers.bash b/test/system/helpers.bash
index 415c9010e..958a0e87c 100644
--- a/test/system/helpers.bash
+++ b/test/system/helpers.bash
@@ -318,6 +318,10 @@ function wait_for_port() {
# BEGIN miscellaneous tools
# Shortcuts for common needs:
+function is_ubuntu() {
+ grep -qiw ubuntu /etc/os-release
+}
+
function is_rootless() {
[ "$(id -u)" -ne 0 ]
}
@@ -459,6 +463,16 @@ function skip_if_journald_unavailable {
fi
}
+function skip_if_root_ubuntu {
+ if is_ubuntu; then
+ if ! is_remote; then
+ if ! is_rootless; then
+ skip "Cannot run this test on rootful ubuntu, usually due to user errors"
+ fi
+ fi
+ fi
+}
+
#########
# die # Abort with helpful message
#########