Updated stop method moved admin_up to correct place

This commit is contained in:
Logan Lipke
2020-08-27 14:17:16 -07:00
parent a115f1fe7a
commit 6cf34bd242

View File

@@ -101,6 +101,7 @@ class IPV4L4(LFCliBase):
def start(self, print_pass=False, print_fail=False): def start(self, print_pass=False, print_fail=False):
temp_stas = self.sta_list.copy() temp_stas = self.sta_list.copy()
temp_stas.append(self.local_realm.name_to_eid(self.upstream_port)[2]) temp_stas.append(self.local_realm.name_to_eid(self.upstream_port)[2])
self.station_profile.admin_up()
if self.local_realm.wait_for_ip(temp_stas): if self.local_realm.wait_for_ip(temp_stas):
self._pass("All stations got IPs", print_pass) self._pass("All stations got IPs", print_pass)
else: else:
@@ -109,7 +110,6 @@ class IPV4L4(LFCliBase):
cur_time = datetime.datetime.now() cur_time = datetime.datetime.now()
old_rx_values = self.__get_values() old_rx_values = self.__get_values()
end_time = self.local_realm.parse_time(self.test_duration) + cur_time end_time = self.local_realm.parse_time(self.test_duration) + cur_time
self.station_profile.admin_up()
self.cx_profile.start_cx() self.cx_profile.start_cx()
passes = 0 passes = 0
expected_passes = 0 expected_passes = 0
@@ -138,10 +138,7 @@ class IPV4L4(LFCliBase):
def stop(self): def stop(self):
self.cx_profile.stop_cx() self.cx_profile.stop_cx()
for sta_name in self.sta_list: self.station_profile.admin_down()
data = LFUtils.port_down_request(1, self.local_realm.name_to_eid(sta_name)[2])
url = "cli-json/set_port"
self.json_post(url, data)
def cleanup(self, sta_list): def cleanup(self, sta_list):
self.cx_profile.cleanup() self.cx_profile.cleanup()