Re: [libvirt] PATCH: Support VNC password for QEMU guests

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



"Daniel P. Berrange" <berrange@xxxxxxxxxx> wrote:
> No need - ADD_ARG() owns the pointer - ADD_ARG_LIT() strdups, hence why
> I changed it.

Ah.  glad you didn't add it ;-)

>> BTW, can you outline what you do to test this?
>> and I'll see about adding something to exercise the new code.
>
> There's two parts to testing
>
>  - The ARGV for QEMU - trivially to add more datafiles to qemuxml2argvtest.c

I've just done that.

>  - The monitor interaction
>
> We have no way to testing monitor interaction, and definitely do not want
> to be in the business of running real QEMU instances to test this. What
> I think we should do is to create a fake / mock QEMU binary in the tests
> directory, which simulates the monitor console. It would output pre-defined
> responses for each of the monitor commands we care about. This would let
> us unit test each of the individual functions that process monitor commands
> in isolation. It actally might be best to just use a self-pipe in the test
> case and have a thread to provide the server end of the monitor - that
> would let us trivially tell it what response we want to get back to each
> command we're about to test.

Sounds reasonable.

--
Libvir-list mailing list
Libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]