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

Wifi 1335 #679

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
11 changes: 11 additions & 0 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Pytest fixtures: High level Resource Management and base setup fixtures
"""
import datetime
import json
import os
import random
import string
Expand Down Expand Up @@ -891,6 +892,16 @@ def collect_logs():
# Adding memory Profile code after every test completion
output = ap_ssh.get_memory_profile()
allure.attach(name="ucode /usr/share/ucentral/sysinfo.uc ", body=str(output))
# Adding Ifconfig, ip route show and ip addr show commands info after every test completion
output = ap_ssh.run_generic_command(cmd="ifconfig")
output = '\n'.join(output)
allure.attach(name="ifconfig after every test completion", body=str(output))
output = ap_ssh.run_generic_command(cmd="ip route show")
output = '\n'.join(output)
allure.attach(name="ip route show after every test completion", body=str(output))
output = ap_ssh.run_generic_command(cmd="ip addr show")
output = '\n'.join(output)
allure.attach(name="ip addr show after every test completion", body=str(output))

request.addfinalizer(collect_logs)

Expand Down
21 changes: 21 additions & 0 deletions tests/fixtures_2x.py
Original file line number Diff line number Diff line change
Expand Up @@ -701,6 +701,17 @@ def setup_profiles(self, request, param, setup_controller, testbed, get_equipmen
output = ap_ssh.get_memory_profile()
allure.attach(name="ucode /usr/share/ucentral/sysinfo.uc ", body=str(output))

#Adding Ifconfig, ip route show and ip addr show commands info before applying config
output = ap_ssh.run_generic_command(cmd="ifconfig")
output = '\n'.join(output)
allure.attach(name="ifconfig before applying config", body=str(output))
output = ap_ssh.run_generic_command(cmd="ip route show")
output = '\n'.join(output)
allure.attach(name="ip route show before applying config", body=str(output))
output = ap_ssh.run_generic_command(cmd="ip addr show")
output = '\n'.join(output)
allure.attach(name="ip addr show before applying config", body=str(output))

time_1 = time.time()

# Apply config
Expand Down Expand Up @@ -833,6 +844,16 @@ def setup_profiles(self, request, param, setup_controller, testbed, get_equipmen
# Adding memory Profile code after applying config
output = ap_ssh.get_memory_profile()
allure.attach(name="ucode /usr/share/ucentral/sysinfo.uc ", body=str(output))
# Adding Ifconfig, ip route show and ip addr show commands info after applying config
output = ap_ssh.run_generic_command(cmd="ifconfig")
output = '\n'.join(output)
allure.attach(name="ifconfig after applying config", body=str(output))
output = ap_ssh.run_generic_command(cmd="ip route show")
output = '\n'.join(output)
allure.attach(name="ip route show after applying config", body=str(output))
output = ap_ssh.run_generic_command(cmd="ip addr show")
output = '\n'.join(output)
allure.attach(name="ip addr show after applying config", body=str(output))

def teardown_session():
wifi_status = ap_ssh.get_wifi_status()
Expand Down