On 1/12/24 17:05, Peter Krempa wrote:
The main goal of part 3 is to add testing based on parsing of the
libvirt-formatted files from tests/qemuxml2xmloutdata and formatting
them back, and checking that they are identical.
Firstly, sorry for resurrecting an old thread.
Secondly, sorry for hijacking it. BUT.
There were patches sent to the list recently [1] and I realized, the way
we usually used to do things is disturbed. I mean, whenever new device,
device knob, ... was introduced the patch series consisted (roughly) of
the following patches:
1) config, XML parser & formatter, RNG, docs AND xml2xml test case,
2) qemu caps
3) qemu cmd line AND xml2argv test case.
Now, since we have this one huge qemuxmlconftest.c it's not as easy. If
I try to introduce a test case in 1), the test case fails as there's no
corresponding .args file. Fair, but also not fair - the feature is not
finished at the time of 1) so .args shouldn't even be considered. But if
a test case is added at step 3) - well, then anybody backporting 1)
won't get the xml2xml test case. Pity. I mean, that's the whole point we
split the change into "frontend" and "backend", right?
Okay, you may add step 4), which introduces new qemuxmlconftest.c test
case. But it bundles both xml2xml AND xml2argv steps rendering it yet
again unsuitable for backport.
One way out might be to add new testcases to genericxml2xmltest.c, but
somehow that feels wrong.
Michal
1:
https://lists.libvirt.org/archives/list/devel@lists.libvirt.org/thread/LE...