• E
    tests: be more explicit on qcow2 versions in virstoragetest · 979d1bac
    Eric Blake 提交于
    While working on v1.0.5-maint (the branch in use on Fedora 19)
    with the host at Fedora 20, I got a failure in virstoragetest.
    I traced it to the fact that we were using qemu-img to create a
    qcow2 file, but qemu-img changed from creating v2 files by
    default in F19 to creating v3 files in F20.  Rather than leaving
    it up to qemu-img, it is better to write the test to force
    testing of BOTH file formats (better code coverage and all).
    
    This patch alone does not fix all the failures in v1.0.5-maint;
    for that, we must decide to either teach the older branch to
    understand v3 files, or to reject them outright as unsupported.
    But for upstream, making the test less dependent on changing
    qemu-img defaults is always a good thing.
    
    * tests/virstoragetest.c (testPrepImages): Simplify creation of
    raw file; check if qemu supports compat and if so use it.
    Signed-off-by: NEric Blake <eblake@redhat.com>
    (cherry picked from commit 974e5914)
    
    Conflicts:
    	tests/virstoragetest.c - hardcode test to v2, since this branch doesn't handle v3 correctly
    979d1bac
virstoragetest.c 19.4 KB