Skip to content

Commit

Permalink
Update existing test cases due to extra Errors
Browse files Browse the repository at this point in the history
  • Loading branch information
goodtune committed Feb 24, 2017
1 parent 9c3d674 commit 3a259ed
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion tenant_schemas/tests/test_apps.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,9 @@ def test_tenant_apps_empty(self):
self.assertBestPractice([
Error("TENANT_APPS is empty.",
hint="Maybe you don't need this app?"),
Error("You have INSTALLED_APPS that are not in either of "
"TENANT_APPS or SHARED_APPS",
hint=['dts_test_app']),
])

@override_settings(PG_EXTRA_SEARCH_PATHS=['public', 'demo1', 'demo2'])
Expand All @@ -98,10 +101,20 @@ def test_public_schema_on_extra_search_paths(self):
Critical("Do not include tenant schemas (demo1, demo2) on PG_EXTRA_SEARCH_PATHS."),
])

@override_settings(SHARED_APPS=())
@override_settings(SHARED_APPS=(), INSTALLED_APPS=(
'tenant_schemas',
'dts_test_app',
'django.contrib.contenttypes',
))
@modify_settings(TENANT_APPS={
'append': 'django.contrib.contenttypes',
})
def test_shared_apps_empty(self):
self.assertBestPractice([
Warning("SHARED_APPS is empty."),
Error("You have INSTALLED_APPS that are not in either of "
"TENANT_APPS or SHARED_APPS",
hint=['tenant_schemas']),
])

@override_settings(TENANT_APPS=(
Expand Down

0 comments on commit 3a259ed

Please sign in to comment.