def testMountAndUnmount(self): self._img = fixture.MakeZeroFile(1024**3) self.assertIsNotNone(self._img) self.assertTrue(fixture.MakeXFS(self._img)) self._mnt = tempfile.mkdtemp() self.assertIsNotNone(self._mnt) self.assertTrue(fixture.MountLoopbackXFS(self._img, self._mnt)) self.assertTrue(fixture.UnmountFS(self._mnt))
def testMakeZeroFile1G(self): self._path = fixture.MakeZeroFile(1024**3) self.assertIsNotNone(self._path) self.assertEquals(1024**3, os.stat(self._path).st_size)
def testMakeXFS(self): self._path = fixture.MakeZeroFile(1024**3) self.assertIsNotNone(self._path) self.assertTrue(fixture.MakeXFS(self._path))
def testMakeZeroFile0(self): self._path = fixture.MakeZeroFile(0) self.assertIsNotNone(self._path) self.assertEquals(0, os.stat(self._path).st_size)