mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-21 21:45:20 +02:00
Refactor tests
* Use pytest-aiohttp * Use the async def / await syntax. * Fix tests to run with Python 3.8
This commit is contained in:
1 parent
f498ab06b4
commit
d3ea67da24
87 files changed
+3697
-3528
No files matched your search
@@ -21,6 +21,7 @@ from gns3server.utils.interfaces import interfaces, is_interface_up, has_netmask
|
||||
|
||||
|
||||
def test_interfaces():
|
||||
|
||||
# This test should pass on all platforms without crash
|
||||
interface_list = interfaces()
|
||||
assert isinstance(interface_list, list)
|
||||
@@ -39,6 +40,7 @@ def test_interfaces():
|
||||
|
||||
|
||||
def test_has_netmask():
|
||||
|
||||
if sys.platform.startswith("win"):
|
||||
# No loopback
|
||||
pass
|
||||
@@ -49,6 +51,7 @@ def test_has_netmask():
|
||||
|
||||
|
||||
def test_is_interface_up():
|
||||
|
||||
if sys.platform.startswith("win"):
|
||||
# is_interface_up() always returns True on Windows
|
||||
pass
|
||||
|
||||
Reference in new issue
Block a user