This commit is contained in:
parent
a35ab6d8fa
commit
ced232eed0
|
@ -305,6 +305,7 @@ if PROJECT_NAME != 'wcs':
|
|||
|
||||
TENANT_BASE = os.path.join(VAR_DIR, 'tenants')
|
||||
TENANT_MODEL = 'multitenant.Tenant'
|
||||
TENANT_LIMIT_SET_CALLS = True
|
||||
|
||||
MIDDLEWARE = (
|
||||
'hobo.multitenant.middleware.TenantMiddleware',
|
||||
|
|
|
@ -242,7 +242,7 @@ def test_hobo_notify_roles_db_queries(caplog, tenants):
|
|||
}
|
||||
with CaptureQueriesContext(connection) as ctx:
|
||||
Command.process_notification(tenant, notification)
|
||||
assert len(ctx.captured_queries) == 33
|
||||
assert len(ctx.captured_queries) == 13
|
||||
assert Group.objects.count() == 2
|
||||
assert Role.objects.count() == 2
|
||||
|
||||
|
@ -267,7 +267,7 @@ def test_hobo_notify_roles_db_queries(caplog, tenants):
|
|||
}
|
||||
with CaptureQueriesContext(connection) as ctx:
|
||||
Command.process_notification(tenant, notification)
|
||||
assert len(ctx.captured_queries) == 36
|
||||
assert len(ctx.captured_queries) == 14
|
||||
assert Group.objects.count() == 1
|
||||
assert Role.objects.count() == 1
|
||||
|
||||
|
@ -337,7 +337,7 @@ def test_hobo_notify_roles_db_queries(caplog, tenants):
|
|||
}
|
||||
with CaptureQueriesContext(connection) as ctx:
|
||||
Command.process_notification(tenant, notification)
|
||||
assert len(ctx.captured_queries) == 18
|
||||
assert len(ctx.captured_queries) == 8
|
||||
|
||||
assert Group.objects.count() == 0
|
||||
assert Role.objects.count() == 0
|
||||
|
|
Loading…
Reference in New Issue