Skip to content

Commit 0c311be

Browse files
Merge pull request #25848 from Luap99/system-pasta
test/system: remove pasta conditional
2 parents 18db1fd + 72fdc64 commit 0c311be

File tree

3 files changed

+1
-30
lines changed

3 files changed

+1
-30
lines changed

test/system/500-networking.bats

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -778,11 +778,7 @@ nameserver 8.8.8.8" "nameserver order is correct"
778778
fi
779779
# pasta only works rootless
780780
if is_rootless; then
781-
if has_pasta; then
782-
netmodes+=("pasta")
783-
else
784-
echo "# WARNING: pasta unavailable!" >&3
785-
fi
781+
netmodes+=("pasta")
786782
fi
787783

788784
for netmode in "${netmodes[@]}"; do
@@ -1112,7 +1108,6 @@ function wait_for_restart_count() {
11121108
@test "Podman unshare --rootless-netns with Pasta" {
11131109
skip_if_remote "unshare is local-only"
11141110
skip_if_not_rootless "pasta networking only available in rootless mode"
1115-
skip_if_no_pasta "pasta not found; this test requires pasta"
11161111

11171112
pasta_iface=$(default_ifname 4)
11181113
assert "$pasta_iface" != "" "pasta_iface is set"

test/system/505-networking-pasta.bats

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ load helpers.network
1616
function setup() {
1717
basic_setup
1818
skip_if_not_rootless "pasta networking only available in rootless mode"
19-
skip_if_no_pasta "pasta not found: install pasta(1) to run these tests"
2019

2120
XFER_FILE="${PODMAN_TMPDIR}/pasta.bin"
2221
}

test/system/helpers.network.bash

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
# -*- bash -*-
22

3-
_cached_has_pasta=
43
_cached_has_slirp4netns=
54

65
### Feature Checks #############################################################
@@ -45,28 +44,6 @@ function has_slirp4netns() {
4544
test "$_cached_has_slirp4netns" = "y"
4645
}
4746

48-
# has_pasta() - Check if the pasta(1) command is available
49-
function has_pasta() {
50-
if [[ -z "$_cached_has_pasta" ]]; then
51-
_cached_has_pasta=n
52-
run_podman info --format '{{.Host.Pasta.Executable}}'
53-
if [[ -n "$output" ]]; then
54-
_cached_has_pasta=y
55-
fi
56-
fi
57-
test "$_cached_has_pasta" = "y"
58-
}
59-
60-
# skip_if_no_pasta() - Skip current test if pasta(1) is not available
61-
# $1: Optional message to display
62-
function skip_if_no_pasta() {
63-
if ! has_pasta; then
64-
local msg=$(_add_label_if_missing "$1" "pasta")
65-
skip "${msg:-not applicable with no pasta binary}"
66-
fi
67-
}
68-
69-
7047
### procfs access ##############################################################
7148

7249
# ipv6_to_procfs() - RFC 5952 IPv6 address text representation to procfs format

0 commit comments

Comments
 (0)