Commits

Rafael Martins  committed bb6ae53

fix tests for python 2.6

  • Participants
  • Parent commits 2133cc7

Comments (0)

Files changed (1)

File blohg/testsuite.py

         app = create_app(self.repo_path)
 
         with app.test_request_context():
-            with self.assertRaises(TemplateNotFound):
-                app.jinja_loader.get_source(app.jinja_env, 'test.html')
+            self.assertRaises(TemplateNotFound, app.jinja_loader.get_source,
+                              app.jinja_env, 'test.html')
 
         new_file = os.path.join(self.repo_path, app.config['TEMPLATES_DIR'],
                                 'test.html')
 
         app.hg.reload()
         with app.test_request_context():
-            with self.assertRaises(TemplateNotFound):
-                app.jinja_loader.get_source(app.jinja_env, 'test.html')
+            self.assertRaises(TemplateNotFound, app.jinja_loader.get_source,
+                              app.jinja_env, 'test.html')
 
         app.debug = True
         app.hg.reload()