Пример #1
0
 def _initialize_doc_test(self, fname):
     self.doc = sprintDoc(fname)
     self.doc.initialize()
     fileIoStub.check_created_files(fname, sprintDoc.templates[fname])
     sysOutputStub.check_sys_output("- "+fname+" created\n")
Пример #2
0
 def _exist_doc_test(self, fname, filestate):
     doc = sprintDoc(fname)
     self.assertEqual(filestate, doc.check())
Пример #3
0
 def test_initialize_unknown_doc(self):
     self.doc = sprintDoc('123')
     self.assertRaises(NameError, self.doc.initialize)
Пример #4
0
 def test_doc_notexist(self):
     doc = sprintDoc('123')
     self.assertEqual('unavailable', doc.check())