diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2022-01-18 10:30:08 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-18 10:30:08 -0500 |
commit | 0bbf8fa14035371cdc5bb04f5db51da8a8f94d48 (patch) | |
tree | cdf7ff6c61cd8b2ca914adea9fa70539f10e31f2 /test/system/272-system-connection.bats | |
parent | 55ad6188b067ba6594819c318dd2ae92dea2f27e (diff) | |
parent | 471a4356bfc57e37218afa6e2db4e9a58e53032b (diff) | |
download | podman-0bbf8fa14035371cdc5bb04f5db51da8a8f94d48.tar.gz podman-0bbf8fa14035371cdc5bb04f5db51da8a8f94d48.tar.bz2 podman-0bbf8fa14035371cdc5bb04f5db51da8a8f94d48.zip |
Merge pull request #12797 from edsantiago/test_image_scp_sudo
Tests for podman image scp (the sudo form)
Diffstat (limited to 'test/system/272-system-connection.bats')
-rw-r--r-- | test/system/272-system-connection.bats | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/test/system/272-system-connection.bats b/test/system/272-system-connection.bats index 4e9ac4dd6..7b70f60f4 100644 --- a/test/system/272-system-connection.bats +++ b/test/system/272-system-connection.bats @@ -124,10 +124,14 @@ $c2[ ]\+tcp://localhost:54321[ ]\+true" \ # If we have ssh access to localhost (unlikely in CI), test that. @test "podman system connection - ssh" { - rand=$(random_string 20) - echo $rand >$PODMAN_TMPDIR/testfile + # system connection only really works if we have an agent + run ssh-add -l + test "$status" -eq 0 || skip "Not running under ssh-agent" + test "${#lines[@]}" -ge 1 || skip "ssh agent has no identities" # Can we actually ssh to localhost? + rand=$(random_string 20) + echo $rand >$PODMAN_TMPDIR/testfile run ssh -q -o BatchMode=yes \ -o UserKnownHostsFile=/dev/null \ -o StrictHostKeyChecking=no \ |