Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix junos netconf port issue in integration test #32610

Merged
merged 1 commit into from
Nov 7, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
16 changes: 4 additions & 12 deletions test/integration/targets/junos_netconf/tests/cli/changeport.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
- name: Change port
junos_netconf:
state: present
netconf_port: 22
netconf_port: 8080
register: result

- assert:
Expand All @@ -22,23 +22,19 @@
- name: idempotent tests
junos_netconf:
state: present
netconf_port: 22
netconf_port: 8080
register: result

- assert:
that:
- "result.changed == false"

- name: wait for persistent socket to timeout, this ensures new socket creation with connection type netconf
pause:
seconds: 120

- name: Ensure we can communicate over 22
- name: Ensure we can communicate over 8080
junos_command:
rpcs:
- get-software-information
provider: "{{ netconf }}"
port: 22
port: 8080

# This protects against the port override above not being honoured and a bug setting the port
- name: Ensure we can NOT communicate over default port
Expand All @@ -53,10 +49,6 @@
- "result.failed == true"
- "'unable to open shell' in result.msg"

- name: wait for persistent socket to timeout, this ensures new socket creation with connection type netconf
pause:
seconds: 120

- name: Set back netconf to default port
junos_netconf:
state: present
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@

- name: wait for persistent socket to timeout
pause:
seconds: 120
seconds: 150

- name: Ensure we can NOT talk via netconf
junos_command:
Expand Down