'Test creating a clone, ensure full size is copied from original.'

@mock.patch('socket.gethostbyname', return_value='123.123.123.123')
def test_create_cloned_volume(self, mock_ghn):

    ctxt = context.get_admin_context()
    extra_specs = {}
    type_ref = volume_types.create(ctxt, 'hgst-1', extra_specs)
    orig = {'id': '1', 'name': 'volume1', 'display_name': '', 'volume_type_id': type_ref['id'], 'size': 10, 'provider_id': 'space_orig'}
    clone = {'id': '2', 'name': 'clone1', 'display_name': '', 'volume_type_id': type_ref['id'], 'size': 10}
    pid = self.driver.create_cloned_volume(clone, orig)
    self.assertEqual((11444 * units.Mi), self.dd_count)
    self.assertEqual('1M', self.bs)
    expected = {'redundancy': '0', 'group': 'xanadu', 'name': 'clone1', 'mode': '0777', 'user': 'kane', 'net': 'net1', 'storageserver': 'stor1:gbd0,stor2:gbd0,', 'size': '12'}
    self.assertDictEqual(expected, self.created)
    expected_pid = {'provider_id': 'clone1'}
    self.assertDictEqual(expected_pid, pid)
