Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:smarty12:Python
python-pyramid_beaker
upstream-fix-test_includeme.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File upstream-fix-test_includeme.patch of Package python-pyramid_beaker
diff -rup a/pyramid_beaker/tests.py b/pyramid_beaker/tests.py --- a/pyramid_beaker/tests.py 2017-09-16 17:44:18.618816296 +0200 +++ b/pyramid_beaker/tests.py 2017-09-16 17:44:39.866914407 +0200 @@ -345,12 +345,20 @@ class TestCacheConfiguration(unittest.Te self.assertFalse(default_term.get('enabled')) class TestIncludeMe(unittest.TestCase): - def test_includeme(self): - from pyramid.interfaces import ISessionFactory + def setUp(self): from pyramid import testing + self.config = testing.setUp() + + def _callFUT(self, config): from pyramid_beaker import includeme - config = testing.setUp(settings={}) - includeme(config) - session_factory = config.registry.queryUtility(ISessionFactory) - self.assertEqual(str(session_factory), - "<class 'pyramid_beaker.PyramidBeakerSessionObject'>") + return includeme(self.config) + + def test_it(self): + from pyramid.interfaces import ISessionFactory + from pyramid_beaker import BeakerSessionFactoryConfig + self._callFUT(self.config) + session_factory = self.config.registry.queryUtility(ISessionFactory) + self.assertEqual( + str(session_factory), + str(BeakerSessionFactoryConfig()) + )
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor