Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions verify/backend/iosxe.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,14 @@ def verify() -> bool:
for device in devices:
print("Testing Device {}".format(device["host"]))
# Test: Is device pingable
response = os.system(
"ping -c 2 {} >> iosxe_tests.txt".format(device["host"])
)
if os.name == 'nt':
response = os.system(
"ping {} >> iosxe_tests.txt".format(device["host"])
)
else:
response = os.system(
"ping -c 2 {} >> iosxe_tests.txt".format(device["host"])
)
# and then check the response...
if response == 0:
pingstatus = "Ping Success"
Expand Down
11 changes: 8 additions & 3 deletions verify/backend/nfvis.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,14 @@ def verify() -> bool:
s.verify = False

# Test: Is device pingable
response = os.system(
"ping -c 2 {} >> nfvis_tests.txt".format(nip)
)
if os.name == 'nt':
response = os.system(
"ping -n 2 {} >> nfvis_tests.txt".format(nip)
)
else:
response = os.system(
"ping -c 2 {} >> nfvis_tests.txt".format(nip)
)
# and then check the response...
if response == 0:
pingstatus = "Ping Success"
Expand Down