mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-10-03 09:10:11 +03:00
style: use not-in membership tests
This commit is contained in:
parent
7a1e79a8a0
commit
06ef803ee9
@ -323,7 +323,7 @@ class Cloud(BaseNode):
|
||||
|
||||
if port_info["type"] == "ethernet":
|
||||
network_interfaces = [interface["name"] for interface in self._interfaces()]
|
||||
if not port_info["interface"] in network_interfaces:
|
||||
if port_info["interface"] not in network_interfaces:
|
||||
raise NodeError(
|
||||
f"Interface '{port_info['interface']}' could not be found on this system, please update '{self.name}'"
|
||||
)
|
||||
|
||||
@ -413,4 +413,4 @@ async def test_export_with_ignoring_snapshots(tmpdir, project):
|
||||
await write_file(str(tmpdir / "zipfile.zip"), z)
|
||||
|
||||
with zipfile.ZipFile(str(tmpdir / "zipfile.zip")) as myzip:
|
||||
assert not os.path.join("snapshots", "snap.gns3project") in [f.filename for f in myzip.filelist]
|
||||
assert os.path.join("snapshots", "snap.gns3project") not in [f.filename for f in myzip.filelist]
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user