Skip to content

Commit

Permalink
restructure the setup and teardown functions for network.py scripts (…
Browse files Browse the repository at this point in the history
…Bugfix) (#1342)

* restructure the setup and teardown functions

restructure the setup and teardown functions with context manager
library. Another improvement is not bring up the network interfaces if it
was down before testing.

* fix wait_for_iface_up did not return status

fix issue that the wait_for_iface_up function will not return correct status

* correct function name for checking underspeed

correct the function name for checking the underspeed issue

* fix the return value of check_underspeed func

fix the ruturn value of check_underspeed function

* fix check_underspeed

fix check_underspeed

* update error messages

update error messages

* correct shutdown nets condition

correct the condition to shutdown all other netifs

* correct conduit network interface

correct conduit network interface

* update variable name

update variable name

* revise variable name

revise variable name

* fix calledprocess error

fix calledprocess error

* add unittest for network.py

add unittest for network.py

* fix unittest failed on python3.5

fix unittest failed on python3.5

* add more unit tests

add more unit tests

* fix unit test

fix unit test

* Update providers/base/bin/network.py

Co-authored-by: Massimiliano <massimiliano.girardi@canonical.com>

* Fix issue

fix issue

* fix unit tests

fix unit tests

* fix black issue

fix black issue

---------

Co-authored-by: Massimiliano <massimiliano.girardi@canonical.com>
  • Loading branch information
stanley31huang and Hook25 authored Sep 9, 2024
1 parent 0881101 commit d7d5c8c
Show file tree
Hide file tree
Showing 2 changed files with 875 additions and 132 deletions.
Loading

0 comments on commit d7d5c8c

Please sign in to comment.