fix netmask and pep8 in test setup
This commit is contained in:
parent
b6797bbc94
commit
5291eacb06
@ -91,10 +91,10 @@ def db_init(db): # note: db is a predefined fixture and required here to have t
|
|||||||
)
|
)
|
||||||
# a Host for api / session update tests
|
# a Host for api / session update tests
|
||||||
hostname = TEST_HOST.host
|
hostname = TEST_HOST.host
|
||||||
h = Host(name=hostname, domain=dt, created_by=u)
|
h = Host(name=hostname, domain=dt, created_by=u, netmask_ipv4=29, netmask_ipv6=64)
|
||||||
h.generate_secret(secret=TEST_SECRET)
|
h.generate_secret(secret=TEST_SECRET)
|
||||||
hostname2 = TEST_HOST2.host
|
hostname2 = TEST_HOST2.host
|
||||||
h2 = Host(name=hostname2, domain=dt, created_by=u2)
|
h2 = Host(name=hostname2, domain=dt, created_by=u2, netmask_ipv4=29, netmask_ipv6=64)
|
||||||
h2.generate_secret(secret=TEST_SECRET2)
|
h2.generate_secret(secret=TEST_SECRET2)
|
||||||
|
|
||||||
# "update other service" ddns_client feature
|
# "update other service" ddns_client feature
|
||||||
@ -117,7 +117,8 @@ def db_init(db): # note: db is a predefined fixture and required here to have t
|
|||||||
created_by=u,
|
created_by=u,
|
||||||
)
|
)
|
||||||
|
|
||||||
RelatedHost.objects.create(name=RELATED_HOST_NAME, interface_id_ipv4="0.0.0.1", interface_id_ipv6="::1", main_host=h)
|
RelatedHost.objects.create(name=RELATED_HOST_NAME,
|
||||||
|
interface_id_ipv4="0.0.0.1", interface_id_ipv6="::1", main_host=h)
|
||||||
|
|
||||||
|
|
||||||
def pytest_runtest_setup(item):
|
def pytest_runtest_setup(item):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user