Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
18 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
from ckan.lib.app_globals import app_globals as g | ||
|
||
|
||
class TestGlobals(object): | ||
def test_config_not_set(self): | ||
# ckan.site_about has not been configured. | ||
# Behaviour has always been to return an empty string. | ||
assert g.site_about == '' | ||
|
||
def test_config_set_to_blank(self): | ||
# ckan.site_description is configured but with no value. | ||
# Behaviour has always been to return an empty string. | ||
assert g.site_description == '' | ||
|
||
def test_set_from_ini(self): | ||
# ckan.template_head_end is configured in test-core.ini | ||
assert g.template_head_end == '<link rel="stylesheet" href="TEST_TEMPLATE_HEAD_END.css" type="text/css">' |