mirror of
https://github.com/seemoo-lab/opendrop.git
synced 2026-09-16 08:06:12 -04:00
Replace yapf with black as formatter
This commit is contained in:
@@ -4,15 +4,16 @@ from opendrop.config import AirDropConfig
|
||||
|
||||
def get_loopback():
|
||||
import ifaddr
|
||||
|
||||
for adapter in ifaddr.get_adapters():
|
||||
if adapter.name.startswith('lo'):
|
||||
if adapter.name.startswith("lo"):
|
||||
return adapter.name
|
||||
return None
|
||||
|
||||
|
||||
def test_server_setup():
|
||||
loopback = get_loopback()
|
||||
assert loopback is not None, 'Could not find loopback interface'
|
||||
assert loopback is not None, "Could not find loopback interface"
|
||||
config = AirDropConfig(interface=loopback)
|
||||
server = AirDropServer(config)
|
||||
server.start_service()
|
||||
|
||||
Reference in New Issue
Block a user