diff --git a/changelogs/fragments/control_path.yml b/changelogs/fragments/control_path.yml index 16190a08701..d8edbc5e9a6 100644 --- a/changelogs/fragments/control_path.yml +++ b/changelogs/fragments/control_path.yml @@ -1,4 +1,3 @@ --- bugfixes: - connection - use inventory_hostname while generating control path directory name to make it more unique (https://github.com/ansible/ansible/issues/76956). - diff --git a/test/integration/targets/connection_ssh/runme.sh b/test/integration/targets/connection_ssh/runme.sh index 54a1bafbc0c..664fd87b825 100755 --- a/test/integration/targets/connection_ssh/runme.sh +++ b/test/integration/targets/connection_ssh/runme.sh @@ -82,6 +82,6 @@ ANSIBLE_SSH_CONTROL_PATH='/tmp/ssh cp with spaces' ansible -m ping all -e ansibl # Check if control path is different ansible -m ping -i control_path.inventory web -vvv 1> stdout.txt 2> /dev/null -first=$(cat stdout.txt|grep ControlPath= | head -1) -second=$(cat stdout.txt|grep ControlPath= | tail -1) +first=$(grep stdout.txt -c "ControlPath=" | head -1) +second=$(grep stdout.txt -c "ControlPath=" | tail -1) test "$first" != "$second"