Hello!
One of the tests in the script is failing, when run as part of the
full test-suit:
tests/test_pluginapi.py ........F..
...
_____________________________ test_modify_context
______________________________
Traceback (most recent call last):
File
"/spare/usr/ports/www/py-mediagoblin/work/mediagoblin-0.8.1/mediagoblin/tests/test_pluginapi.py",
line 352, in test_modify_context
result =
context_modified_app.get("/modify_context/specific/")
File "/opt/lib/python2.7/site-packages/webtest/app.py",
line 212, in get
expect_errors=expect_errors)
File "/opt/lib/python2.7/site-packages/webtest/app.py",
line 495, in do_request
res = req.get_response(app, catch_exc_info=True)
File
"/opt/lib/python2.7/site-packages/webob/request.py", line 1316,
in send
application, catch_exc_info=True)
File
"/opt/lib/python2.7/site-packages/webob/request.py", line 1284,
in call_application
app_iter = application(self.environ, start_response)
File
"/opt/lib/python2.7/site-packages/webtest/lint.py", line 198, in
lint_app
iterator = application(environ,
start_response_wrapper)
File
"/spare/usr/ports/www/py-mediagoblin/work/mediagoblin-0.8.1/mediagoblin/app.py",
line 342, in __call__
return self.call_backend(environ, start_response)
File
"/opt/lib/python2.7/site-packages/werkzeug/wsgi.py", line 599,
in __call__
return self.app(environ, start_response)
File
"/spare/usr/ports/www/py-mediagoblin/work/mediagoblin-0.8.1/mediagoblin/app.py",
line 276, in call_backend
return self._finish_call_backend(request, environ,
start_response)
File
"/spare/usr/ports/www/py-mediagoblin/work/mediagoblin-0.8.1/mediagoblin/app.py",
line 318, in _finish_call_backend
response = controller(request)
File
"/spare/usr/ports/www/py-mediagoblin/work/mediagoblin-0.8.1/mediagoblin/tests/testplugins/modify_context/views.py",
line 25, in specific
"doubleme": "happy"})
File
"/spare/usr/ports/www/py-mediagoblin/work/mediagoblin-0.8.1/mediagoblin/tools/response.py",
line 36, in render_to_response
render_template(request, template, context),
File
"/spare/usr/ports/www/py-mediagoblin/work/mediagoblin-0.8.1/mediagoblin/tools/template.py",
line 125, in render_template
template_path)
File
"/opt/lib/python2.7/site-packages/jinja2/environment.py", line
812, in get_template
return self._load_template(name,
self.make_globals(globals))
File
"/opt/lib/python2.7/site-packages/jinja2/environment.py", line
774, in _load_template
cache_key = self.loader.get_source(self, name)[1]
File
"/opt/lib/python2.7/site-packages/jinja2/loaders.py", line 399,
in get_source
raise TemplateNotFound(template)
TemplateNotFound:
contextplugin/specific.html
But when I run just that test-collection by itself, all 11 tests in
it pass:
cd
/spare/usr/ports/www/py-mediagoblin/work/mediagoblin-0.8.1/mediagoblin
&& \
/usr/bin/env
PYTHONPATH=/spare/usr/ports/www/py-mediagoblin/work/mediagoblin-0.8.1
py.test-2.7 tests/test_pluginapi.py
=================== test session starts
===================================
platform freebsd10 -- Python 2.7.11, pytest-2.8.5,
py-1.4.30, pluggy-0.3.1
rootdir:
/spare/usr/ports/www/py-mediagoblin/work/mediagoblin-0.8.1/mediagoblin/tests,
inifile: pytest.ini
plugins: xdist-1.13.1
collected 11 items
tests/test_pluginapi.py ...........
=================== 11 passed in
1.06 seconds =============================
Why would the test fail to find its file, when run as part of the
full test-suit? Is there an environment variable, perhaps, which I
can set to help it? I'm working with 0.8.1, but this particular
test_pluginapi.py is identical to master... Please, advise.
Thanks! Yours,
-mi
|