Update ssh connection play_context alongside network_cli's (#72185)

Backport of https://github.com/ansible-collections/ansible.netcommon/pull/135

* Fix iosxr tests
pull/73903/head
Nathaniel Case 5 years ago committed by GitHub
parent 903f2e267b
commit a4ba6ace01
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -0,0 +1,4 @@
---
bugfixes:
- network_cli - Update paramiko play_context when network_cli's play context
is updated so that ssh parameters can be updated as well.

@ -418,6 +418,8 @@ class Connection(NetworkConnectionBase):
self.queue_message('vvvv', 'deauthorizing connection')
self._play_context = play_context
if self._paramiko_conn is not None:
self._paramiko_conn._play_context = play_context
if hasattr(self, 'reset_history'):
self.reset_history()

@ -10,7 +10,7 @@
set_fact: test_items="{{ test_cases.files | map(attribute='path') | list }}"
- name: run test case (connection=netconf)
include: "{{ test_case_to_run }}"
include: "{{ test_case_to_run }} ansible_connection=netconf"
with_items: "{{ test_items }}"
loop_control:
loop_var: test_case_to_run

Loading…
Cancel
Save