Nir Soffer has posted comments on this change.

Change subject: copy_data: Add qcow2_compat on convert.

Patch Set 24:


File tests/

Line 76: 
Line 77:     @contextmanager
Line 78:     def get_vols(self, storage_type, src_fmt, dst_fmt, chain_length=1,
Line 79:                  size=DEFAULT_SIZE, sd_version=3, 
Line 80:         with fake_env(storage_type, sd_version) as env:
sd_version is a kwarg, please always call it sd_version=value
Line 81:             rm = FakeResourceManager()
Line 82:             with MonkeyPatchScope([
Line 83:                 (guarded, 'context', fake_guarded_context()),
Line 84:                 (storage.sdm.api.copy_data, 'sdCache', env.sdcache),

Line 197:         ('block', 'cow', 'cow', '1.1', 4),
Line 198:         ('block', 'cow', 'cow', '0.10', 3),
Line 199:     ))
Line 200:     def test_volume_qcow2v3(self, env_type, src_fmt, dst_fmt, 
Line 201:                             dst_sd_version):
In this test we are actually testing coping in the same domain, so the source 
sd compat and destination sd compat are the same.

It would be more interesting to test copying form old domain (version=3) to a 
new domain (version=4), or the opposite (from 4 to 3), but we don't have 
infrastructure for this yet.

Please add a TODO for these tests.
Line 202:         src_fmt = sc.name2type(src_fmt)
Line 203:         dst_fmt = sc.name2type(dst_fmt)
Line 204:         job_id = make_uuid()
Line 205: 

Line 220:             job = storage.sdm.api.copy_data.Job(job_id, 0, source, 
Line 221: 
Line 222:   
Line 223:             wait_for_job(job)
Line 224:             self.assertEqual(jobs.STATUS.DONE, job.status)
Please add:


And also check that the destination images are using the correct compat. You 
can do this using["compat"]
Line 225: 
Line 226:     def test_bad_vm_configuration_volume(self):
Line 227:         """
Line 228:         When copying a volume containing VM configuration information 

To view, visit
To unsubscribe, visit

Gerrit-MessageType: comment
Gerrit-Change-Id: Ie26e5dcba6fc493b32ea7764889df2918c4dfdd3
Gerrit-PatchSet: 24
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Maor Lipchuk <>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Maor Lipchuk <>
Gerrit-Reviewer: Nir Soffer <>
Gerrit-Reviewer: gerrit-hooks <>
Gerrit-HasComments: Yes
vdsm-patches mailing list --
To unsubscribe send an email to

Reply via email to