Beispiel #1
0
 def testDoesNotSyntacticallyIncorrectLineHasFilesystem(self):
     self.assertFalse(fstab.Line("yo").has_filesystem())
Beispiel #2
0
 def testDoesNotAllowSettingDeviceWhenUnset(self):
     line = fstab.Line("yo")
     self.assertRaises(Exception, setattr, line, "device", "/dev")
Beispiel #3
0
 def testDoesNotThinkCommentHasFilesystem(self):
     self.assertFalse(fstab.Line("# foo").has_filesystem())
Beispiel #4
0
 def testDoesNotThinkLineWithWhiteSpaceHasFilesystem(self):
     self.assertFalse(fstab.Line("   \t").has_filesystem())
Beispiel #5
0
 def testDoesNotThinkEmptyLineHasFilesystem(self):
     self.assertFalse(fstab.Line("").has_filesystem())
Beispiel #6
0
 def testSetsRawToWhateverTheConstructorIsGiven(self):
     # Note that we set the line to something syntactically incorrect.
     # This is on purpose. The class is supposed to handle that.
     line = fstab.Line("yo")
     self.assertEqual(line.raw, "yo")
Beispiel #7
0
 def setUp(self):
     self.line = fstab.Line("/dev / type opt,ions 0 1")