Beispiel #1
0
 def test_umount_all_unexpected_failure(self, mocked_spawnvp, mocked_scan_mounts):
     """ Tests that umount_all will fail if the command to unmount the mount points was successful
     but a second run of scan_mounts still shows some of the unmount mount points still mounted.
     """
     try:
         umount_all('/dev')
         raise Exception('A GenericError was not raised during the test')
     except koji.GenericError as e:
         self.assertEquals(e.args[0], 'Unmounting incomplete: [\'/dev/shm\', \'/dev/mqueue\']')
Beispiel #2
0
 def test_umount_all_failure(self, mocked_spawnvp, mocked_scan_mounts):
     """ Tests that umount_all raises an exception when a mount point can't be unmounted.
     """
     try:
         umount_all('/dev')
         raise Exception('A GenericError was not raised during the test')
     except koji.GenericError as e:
         self.assertEquals(e.args[0],
                           'umount failed (exit code 1) for /dev/shm')
Beispiel #3
0
 def test_umount_all_unexpected_failure(self, mocked_spawnvp, mocked_scan_mounts):
     """ Tests that umount_all will fail if the command to unmount the mount points was successful
     but a second run of scan_mounts still shows some of the unmount mount points still mounted.
     """
     try:
         umount_all('/dev')
         raise Exception('A GenericError was not raised during the test')
     except koji.GenericError as e:
         self.assertEquals(e.message, 'Unmounting incomplete: [\'/dev/shm\', \'/dev/mqueue\']')
Beispiel #4
0
 def test_umount_all_failure(self, mocked_spawnvp, mocked_scan_mounts):
     """ Tests that umount_all raises an exception when a mount point can't be unmounted.
     """
     try:
         umount_all('/dev')
         raise Exception('A GenericError was not raised during the test')
     except koji.GenericError as e:
         self.assertEquals(e.message,
                           'umount failed (exit code 1) for /dev/shm')
Beispiel #5
0
 def test_umount_all(self, mocked_spawnvp, mocked_scan_mounts):
     """ Tests that umount_all returns nothing when successful.
     """
     self.assertEquals(umount_all('/test'), None)
Beispiel #6
0
 def test_umount_all(self, mocked_spawnvp, mocked_scan_mounts):
     """ Tests that umount_all returns nothing when successful.
     """
     self.assertEquals(umount_all('/test'), None)