- 23 8月, 2019 1 次提交
-
-
由 Roman Bolshakov 提交于
In preparation libtool "-module" flag removal, add lib prefix to all mock shared objects. While at it, introduce VIR_TEST_MOCK macros that makes path out of mock name to be used with VIR_TEST_PRELOAD or VIR_TEST_MAIN_PRELOAD. That, hopefully, improves readability, reduces line length and allows to tailor VIR_TEST_MOCK for specific platform if it has shared library suffix different from ".so". Signed-off-by: NRoman Bolshakov <r.bolshakov@yadro.com>
-
- 20 4月, 2019 1 次提交
-
-
由 Michal Privoznik 提交于
There's no need to keep @binary around. virQEMUCapsInitGuestFromBinary() duplicates the string anyway. 1,002 bytes in 36 blocks are definitely lost in loss record 54 of 59 at 0x483579F: malloc (vg_replace_malloc.c:299) by 0x796B1C7: vasprintf (vasprintf.c:73) by 0x4C3F2C6: virVasprintfInternal (virstring.c:740) by 0x4C3F3DC: virAsprintfInternal (virstring.c:761) by 0x13AFC9: testGetCaps (qemucaps2xmltest.c:105) by 0x13B200: testQemuCapsXML (qemucaps2xmltest.c:157) by 0x13B642: virTestRun (testutils.c:174) by 0x13B366: doCapsTest (qemucaps2xmltest.c:191) by 0x13FF2B: testQemuCapsIterate (testutilsqemu.c:941) by 0x13B427: mymain (qemucaps2xmltest.c:215) by 0x13D706: virTestMain (testutils.c:1096) by 0x13B489: main (qemucaps2xmltest.c:221) Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 17 4月, 2019 2 次提交
-
-
由 Andrea Bolognani 提交于
After the recent changes, there are only a few places left where we use the explicit path instead of taking advantage of the publicly available define; let's get rid of those too. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NCole Robinson <crobinso@redhat.com>
-
由 Andrea Bolognani 提交于
As evidenced by all existing callers, the only directory it makes sense to use is TEST_QEMU_CAPS_PATH, so let's just bake that into the function. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NCole Robinson <crobinso@redhat.com>
-
- 13 3月, 2019 7 次提交
-
-
由 Andrea Bolognani 提交于
With only a couple minor tweaks, we can make the existing doCapsTest() functions with testQemuCapsIterate() and finally remove the need to manually adjust the test programs every time a new input file is introduced; moreover, this means that the two lists can't possibly get out of sync anymore. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Acked-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Andrea Bolognani 提交于
We're not using any of the functionality offered by the module at the moment, but we will in just a second. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Acked-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Andrea Bolognani 提交于
This removes the awkard escaping and will allow us to perform some more refactoring later on. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Acked-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Andrea Bolognani 提交于
We're using static string concatenation at the moment, but that will no longer be a possibility in a bit. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Acked-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Andrea Bolognani 提交于
This removes a little duplication right away, and will allow us to avoid introducing more later on. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Acked-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Andrea Bolognani 提交于
This is not particularly useful right now, but will allow us to refactor some functionality later on. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Acked-by: NPeter Krempa <pkrempa@redhat.com>
-
由 Andrea Bolognani 提交于
These functions don't do anything too interesting right now, but will be extended later on. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Acked-by: NPeter Krempa <pkrempa@redhat.com>
-
- 06 2月, 2019 1 次提交
-
-
由 Andrea Bolognani 提交于
Turns out different versions of QEMU on the same architecture produce the same output, so we can have a single output file per architecture instead of duplicating the same data over and over again. Spotted-by: NJán Tomko <jtomko@redhat.com> Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
- 01 2月, 2019 2 次提交
-
-
由 Andrea Bolognani 提交于
Commit fb0d0d6c added capabilities data and updated qemucapabilitiestest but forgot to update qemucaps2xmltest at the same time. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
由 Andrea Bolognani 提交于
Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NJán Tomko <jtomko@redhat.com>
-
- 14 12月, 2018 1 次提交
-
-
由 Daniel P. Berrangé 提交于
In many files there are header comments that contain an Author: statement, supposedly reflecting who originally wrote the code. In a large collaborative project like libvirt, any non-trivial file will have been modified by a large number of different contributors. IOW, the Author: comments are quickly out of date, omitting people who have made significant contribitions. In some places Author: lines have been added despite the person merely being responsible for creating the file by moving existing code out of another file. IOW, the Author: lines give an incorrect record of authorship. With this all in mind, the comments are useless as a means to identify who to talk to about code in a particular file. Contributors will always be better off using 'git log' and 'git blame' if they need to find the author of a particular bit of code. This commit thus deletes all Author: comments from the source and adds a rule to prevent them reappearing. The Copyright headers are similarly misleading and inaccurate, however, we cannot delete these as they have legal meaning, despite being largely inaccurate. In addition only the copyright holder is permitted to change their respective copyright statement. Reviewed-by: NErik Skultety <eskultet@redhat.com> Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
-
- 29 11月, 2018 1 次提交
-
-
由 Andrea Bolognani 提交于
Commits d7434ae8 and 9c4afbda added replies files for QEMU 3.0.0 on s390x and QEMU 3.1.0 on x86_64 respectively, but only enabled the corresponding test in qemucapabilities and not in qemucaps2xml. Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
- 28 11月, 2018 1 次提交
-
-
由 Andrea Bolognani 提交于
Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
- 21 9月, 2018 1 次提交
-
-
由 Andrea Bolognani 提交于
We're only ever passing a single binary when calling this function, so we can remove all code dealing with the possibility of a second binary being specified. Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
- 17 9月, 2018 2 次提交
-
-
由 Andrea Bolognani 提交于
More specifically, everything that's tested by qemucapabilities now goes through qemucaps2xml as well. Ideally we'll rewrite both so that listing all test cases is unnecessary and they get picked up automatically by listing the contents of the input directory instead, but that's a refactor for another day :) Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NJiri Denemark <jdenemar@redhat.com>
-
由 Andrea Bolognani 提交于
While qemucaps2xml has a meager two test cases to its name, we have plenty of data from qemucapabilities which is taken from actual QEMU binaries, covers pretty much all supported QEMU versions and architectures and is even in the right format already! Rewrite qemucaps2xml so that it uses qemucapabilities data as input. Right now we have a single test case, but we're going to add a lot more next. Signed-off-by: NAndrea Bolognani <abologna@redhat.com> Reviewed-by: NJiri Denemark <jdenemar@redhat.com>
-
- 13 8月, 2018 1 次提交
-
-
由 Ján Tomko 提交于
This reverts commit 9cf38263. Jansson cannot parse QEMU's quirky JSON. Revert back to yajl. https://bugzilla.redhat.com/show_bug.cgi?id=1614569Signed-off-by: NJán Tomko <jtomko@redhat.com> Reviewed-by: NDaniel P. Berrangé <berrange@redhat.com>
-
- 18 7月, 2018 1 次提交
-
-
由 Ján Tomko 提交于
Yajl has not seen much activity upstream recently. Switch to using Jansson >= 2.5. All the platforms we target on https://libvirt.org/platforms.html have a version >= 2.7 listed on the sites below: https://repology.org/metapackage/jansson/versions https://build.opensuse.org/package/show/devel:libraries:c_c++/libjansson Additionally, Ubuntu 14.04 on Travis-CI has 2.5. Set the requirement to 2.5 since we don't use anything from newer versions. Implement virJSONValue{From,To}String using Jansson, delete the yajl code (and the related virJSONParser structure) and report an error if someone explicitly specifies --with-yajl. Also adjust the test data to account for Jansson's different whitespace usage for empty arrays and tune up the specfile to keep 'make rpm' working when bisecting. Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
- 11 5月, 2018 1 次提交
-
-
由 Ján Tomko 提交于
Use "libvirt not compiled with JSON support" instead of mentioning yajl specifically. Signed-off-by: NJán Tomko <jtomko@redhat.com>
-
- 03 11月, 2017 1 次提交
-
-
由 Andrea Bolognani 提交于
Right-aligning backslashes when defining macros or using complex commands in Makefiles looks cute, but as soon as any changes is required to the code you end up with either distractingly broken alignment or unnecessarily big diffs where most of the changes are just pushing all backslashes a few characters to one side. Generated using $ git grep -El '[[:blank:]][[:blank:]]\\$' | \ grep -E '*\.([chx]|am|mk)$$' | \ while read f; do \ sed -Ei 's/[[:blank:]]*[[:blank:]]\\$/ \\/g' "$f"; \ done Signed-off-by: NAndrea Bolognani <abologna@redhat.com>
-
- 04 4月, 2017 1 次提交
-
-
由 Andrea Bolognani 提交于
We use the "vir" prefix pretty consistently in our APIs, both external and internal, which made these macros stood out.
-
- 08 6月, 2016 3 次提交
-
-
由 Tomáš Ryšavý 提交于
This function doesn't follow our convention of naming functions.
-
由 Tomáš Ryšavý 提交于
This function doesn't follow our convention of naming functions.
-
由 Tomáš Ryšavý 提交于
This function doesn't follow our convention of naming functions.
-
- 24 9月, 2015 1 次提交
-
-
由 John Ferlan 提交于
In the error path need to unref the 'caps' as well Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
-
- 24 4月, 2015 1 次提交
-
-
由 Cole Robinson 提交于
Replaces a common pattern used in many test files
-
- 27 3月, 2015 2 次提交
-
-
由 Pavel Hrdina 提交于
We need to mock virFileExists to return true for "/dev/kvm" because the test should not depend on host system. Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
由 Pavel Hrdina 提交于
This reverts commit 49bf09d1. That commit is wrong and doesn't fix the issue. Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 25 3月, 2015 1 次提交
-
-
由 Pavel Hrdina 提交于
Function virQEMUCapsInitGuestFromBinary detect kvm support by testing whether /dev/kvm exists or whether we pass path to kvmbin. Provide the path we are testing via kvmbin for testing purpose instead of detecting presence of /dev/kvm to successfully run the tests on all hosts. Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 24 3月, 2015 1 次提交
-
-
由 Pavel Hrdina 提交于
Commit 2360fe5d updated formating of <domain> element but forgot to update qemucaps2xmldata xml files. In addition the test code was broken too. Update the xml files and return -1 if testCompareXMLToXML fails together with indentation fix. Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 14 7月, 2014 1 次提交
-
-
由 Eric Blake 提交于
While preparing to add a capability for active commit, I noticed that the existing code was abusing int for boolean values. * src/conf/capabilities.h (_virCapsGuestFeature, _virCapsHost) (virCapabilitiesNew, virCapabilitiesAddGuestFeature): Improve types. * src/conf/capabilities.c (virCapabilitiesNew) (virCapabilitiesAddGuestFeature): Adjust signature. * src/bhyve/bhyve_capabilities.c (virBhyveCapsBuild): Update clients. * src/esx/esx_driver.c (esxCapsInit): Likewise. * src/libxl/libxl_conf.c (libxlMakeCapabilities): Likewise. * src/lxc/lxc_conf.c (virLXCDriverCapsInit): Likewise. * src/openvz/openvz_conf.c (openvzCapsInit): Likewise. * src/parallels/parallels_driver.c (parallelsBuildCapabilities): Likewise. * src/phyp/phyp_driver.c (phypCapsInit): Likewise. * src/qemu/qemu_capabilities.c (virQEMUCapsInit) (virQEMUCapsInitGuestFromBinary): Likewise. * src/security/virt-aa-helper.c (get_definition): Likewise. * src/test/test_driver.c (testBuildCapabilities): Likewise. * src/uml/uml_conf.c (umlCapsInit): Likewise. * src/vbox/vbox_tmpl.c (vboxCapsInit): Likewise. * src/vmware/vmware_conf.c (vmwareCapsInit): Likewise. * src/xen/xen_hypervisor.c (xenHypervisorBuildCapabilities): Likewise. * src/xenapi/xenapi_driver.c (getCapsObject): Likewise. * tests/qemucaps2xmltest.c (testGetCaps): Likewise. * tests/testutils.c (virTestGenericCapsInit): Likewise. * tests/testutilslxc.c (testLXCCapsInit): Likewise. * tests/testutilsqemu.c (testQemuCapsInit): Likewise. * tests/testutilsxen.c (testXenCapsInit): Likewise. * tests/vircaps2xmltest.c (buildVirCapabilities): Likewise. * tests/vircapstest.c (buildNUMATopology): Likewise. * tests/vmx2xmltest.c (testCapsInit): Likewise. * tests/xml2vmxtest.c (testCapsInit): Likewise. Signed-off-by: NEric Blake <eblake@redhat.com>
-
- 27 3月, 2014 1 次提交
-
-
由 Nehal J Wani 提交于
While running qemucaps2xmltest, it was found that valgrind pointed out the following memory leaks: ==27045== 160 (112 direct, 48 indirect) bytes in 1 blocks are definitely lost in loss record 51 of 65 ==27045== at 0x4A0577B: calloc (vg_replace_malloc.c:593) ==27045== by 0x4C6BACD: virAllocVar (viralloc.c:560) ==27045== by 0x4CAF095: virObjectNew (virobject.c:193) ==27045== by 0x421453: virQEMUCapsNew (qemu_capabilities.c:1805) ==27045== by 0x41F04F: testQemuCapsXML (qemucaps2xmltest.c:72) ==27045== by 0x41FFD1: virtTestRun (testutils.c:201) ==27045== by 0x41EE7A: mymain (qemucaps2xmltest.c:203) ==27045== by 0x42074D: virtTestMain (testutils.c:789) ==27045== by 0x3E6CE1ED1C: (below main) (libc-start.c:226) ==27045== ==27045== 160 (112 direct, 48 indirect) bytes in 1 blocks are definitely lost in loss record 52 of 65 ==27045== at 0x4A0577B: calloc (vg_replace_malloc.c:593) ==27045== by 0x4C6BACD: virAllocVar (viralloc.c:560) ==27045== by 0x4CAF095: virObjectNew (virobject.c:193) ==27045== by 0x421453: virQEMUCapsNew (qemu_capabilities.c:1805) ==27045== by 0x41F04F: testQemuCapsXML (qemucaps2xmltest.c:72) ==27045== by 0x41FFD1: virtTestRun (testutils.c:201) ==27045== by 0x41EEA3: mymain (qemucaps2xmltest.c:204) ==27045== by 0x42074D: virtTestMain (testutils.c:789) ==27045== by 0x3E6CE1ED1C: (below main) (libc-start.c:226)
-
- 26 3月, 2014 1 次提交
-
-
由 Francesco Romani 提交于
The test is loosely inspired from qemucapabilitiestest and qemuxml2xmltest. Added a new test instead of extending an existing one because the feature being tested don't really fits nicely in any existing place.
-