Skip to content

Commit

Permalink
Fix typos and LGTM violations
Browse files Browse the repository at this point in the history
  • Loading branch information
Blueve committed Apr 9, 2020
1 parent bffe089 commit bb434bd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
4 changes: 2 additions & 2 deletions tests/common/devices.py
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ def shutdown(self, interface_name):
if not self.check_intf_link_state(interface_name):
logging.info('Shut interface [%s]' % interface_name)
return out
raise Exception("The interface state is Up but expect Down, detail output: %s" % out[self.hostname])
raise RunAnsibleModuleFail("The interface state is Up but expect Down, detail output: %s" % out[self.hostname])

def no_shutdown(self, interface_name):
out = self.host.eos_config(
Expand All @@ -383,7 +383,7 @@ def no_shutdown(self, interface_name):
if self.check_intf_link_state(interface_name):
logging.info('No shut interface [%s]' % interface_name)
return out
raise Exception("The interface state is Down but expect Up, detail output: %s" % out[self.hostname])
raise RunAnsibleModuleFail("The interface state is Down but expect Up, detail output: %s" % out[self.hostname])

def check_intf_link_state(self, interface_name):
show_int_result = self.host.eos_command(
Expand Down
1 change: 0 additions & 1 deletion tests/test_lag_2.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ def test_lag_2(common_setup_teardown, nbrhosts):
check_single_lag(common_setup_teardown, nbrhosts, lag_name)

try:
lag_facts['lags'][lag_name]['po_config']['runner']['fallback'] = False
lag_facts['lags'][lag_name]['po_config']['runner']['fallback']
except:
logging.info("Skip [check_lag_fallback] for lag (%s) due to fallback was not set for it" % lag_name)
Expand Down

0 comments on commit bb434bd

Please sign in to comment.