Ejemplo n.º 1
0
 def test_empty_error_context(self):
     context = StatikErrorContext()
     self.assertIsNone(context.render())
Ejemplo n.º 2
0
 def test_complete_error_context(self):
     context = StatikErrorContext(filename="somefilename.yml", line_no=12)
     self.assertEqual("in file \"somefilename.yml\", line 12",
                      context.render())
Ejemplo n.º 3
0
 def test_error_context_with_filename_only(self):
     context = StatikErrorContext(filename="somefilename.yml")
     self.assertEqual("in file \"somefilename.yml\"", context.render())
Ejemplo n.º 4
0
 def test_empty_error_context(self):
     context = StatikErrorContext()
     self.assertIsNone(context.render())
Ejemplo n.º 5
0
 def test_complete_error_context(self):
     context = StatikErrorContext(filename="somefilename.yml", line_no=12)
     self.assertEqual("in file \"somefilename.yml\", line 12", context.render())
Ejemplo n.º 6
0
 def test_error_context_with_filename_only(self):
     context = StatikErrorContext(filename="somefilename.yml")
     self.assertEqual("in file \"somefilename.yml\"", context.render())