Beispiel #1
0
def _find_share_snapshot(cs, snapshot):
    """Get a snapshot by ID."""
    return utils.find_resource(cs.share_snapshots, snapshot)
def _find_share_snapshot(cs, snapshot):
    """Get a snapshot by ID."""
    return utils.find_resource(cs.share_snapshots, snapshot)
Beispiel #3
0
def _find_share(cs, share):
    """Get a share by ID."""
    return utils.find_resource(cs.shares, share)
Beispiel #4
0
 def test_find_by_str_displayname(self):
     output = utils.find_resource(self.manager, 'entity_three')
     self.assertEqual(output, self.manager.get('4242'))
def _find_share(cs, share):
    """Get a share by ID."""
    return utils.find_resource(cs.shares, share)
Beispiel #6
0
 def test_find_by_str_name(self):
     output = utils.find_resource(self.manager, 'entity_one')
     self.assertEqual(output, self.manager.get('1234'))
Beispiel #7
0
 def test_find_by_uuid(self):
     output = utils.find_resource(self.manager, UUID)
     self.assertEqual(output, self.manager.get(UUID))
Beispiel #8
0
 def test_find_by_integer_id(self):
     output = utils.find_resource(self.manager, 1234)
     self.assertEqual(output, self.manager.get('1234'))
Beispiel #9
0
def _find_share_network(cs, share_network):
    "Get a share network by ID or name."
    return utils.find_resource(cs.share_networks, share_network)
Beispiel #10
0
def _find_volume_type(cs, vtype):
    """Get a volume type by name or ID."""
    return utils.find_resource(cs.volume_types, vtype)