Ejemplo n.º 1
0
    def test_create_detailed(self):
        sot = snapshot.SnapshotDetail(**DETAILED_SNAPSHOT)

        self.assertEqual(
            DETAILED_SNAPSHOT["os-extended-snapshot-attributes:progress"],
            sot.progress)
        self.assertEqual(
            DETAILED_SNAPSHOT["os-extended-snapshot-attributes:project_id"],
            sot.project_id)
Ejemplo n.º 2
0
 def test_basic(self):
     sot = snapshot.SnapshotDetail(DETAILED_SNAPSHOT)
     self.assertIsInstance(sot, snapshot.Snapshot)
     self.assertEqual("/snapshots/detail", sot.base_path)
     self.assertFalse(sot.allow_fetch)
     self.assertFalse(sot.allow_commit)
     self.assertFalse(sot.allow_create)
     self.assertFalse(sot.allow_delete)
     self.assertTrue(sot.allow_list)
Ejemplo n.º 3
0
 def test_basic(self):
     sot = snapshot.SnapshotDetail(DETAILED_SNAPSHOT)
     self.assertIsInstance(sot, snapshot.Snapshot)
     self.assertEqual("/snapshots/detail", sot.base_path)