diff options
Diffstat (limited to 'mediagoblin/tests/test_pluginapi.py')
-rw-r--r-- | mediagoblin/tests/test_pluginapi.py | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/mediagoblin/tests/test_pluginapi.py b/mediagoblin/tests/test_pluginapi.py index 308151a7..de43534f 100644 --- a/mediagoblin/tests/test_pluginapi.py +++ b/mediagoblin/tests/test_pluginapi.py @@ -328,10 +328,24 @@ def test_plugin_config(): @pytest.fixture() def context_modified_app(request): - get_app( + return get_app( request, mgoblin_config=pkg_resources.resource_filename( 'mediagoblin.tests', 'appconfig_context_modified.ini')) + def test_modify_context(context_modified_app): - pytest.set_trace() + # Specific thing passed into a page + result = context_modified_app.get("/modify_context/specific/") + assert result.body.strip() == """Specific page! + +specific thing: in yer specificpage +global thing: globally appended! +something: orother""" + + # General test, should have global context variable only + result = context_modified_app.get("/modify_context/") + assert result.body.strip() == """General page! + +global thing: globally appended! +lol: cats""" |