[libvirt] [PATCH for 6.0.0] qemuxml2*test: Fix hugepages-default-system-size tests

Jiri Denemark posted 1 patch 1 week ago
Test syntax-check failed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/libvirt tags/patchew/37e1d9495ec9469fa5d99cfcb7cdbcfe2fd72670.1578914482.git.jdenemar@redhat.com
tests/qemuxml2argvtest.c | 2 +-
tests/qemuxml2xmltest.c  | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)

[libvirt] [PATCH for 6.0.0] qemuxml2*test: Fix hugepages-default-system-size tests

Posted by Jiri Denemark 1 week ago
Commit v5.10.0-269-g62065a6cb5 moved NUMA validation code to domain
definition time and appropriately adjusted affected test cases except
for hugepages-default-system-size. And since we don't mock
virGetSystemPageSizeKB in our tests, hugepages-default-system-size test
would fail on architectures (ppc64le) with default page size other than
4KiB.

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
---
 tests/qemuxml2argvtest.c | 2 +-
 tests/qemuxml2xmltest.c  | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c
index 8af2ba38d3..560a012149 100644
--- a/tests/qemuxml2argvtest.c
+++ b/tests/qemuxml2argvtest.c
@@ -946,7 +946,7 @@ mymain(void)
             QEMU_CAPS_OBJECT_MEMORY_FILE_DISCARD);
     DO_TEST("hugepages-default", QEMU_CAPS_OBJECT_MEMORY_FILE);
     DO_TEST("hugepages-default-2M", QEMU_CAPS_OBJECT_MEMORY_FILE);
-    DO_TEST("hugepages-default-system-size", NONE);
+    DO_TEST("hugepages-default-system-size", QEMU_CAPS_OBJECT_MEMORY_FILE);
     DO_TEST_PARSE_ERROR("hugepages-default-1G-nodeset-2M", NONE);
     DO_TEST("hugepages-nodeset", QEMU_CAPS_OBJECT_MEMORY_FILE);
     DO_TEST_PARSE_ERROR("hugepages-nodeset-nonexist",
diff --git a/tests/qemuxml2xmltest.c b/tests/qemuxml2xmltest.c
index 262fc835f5..f7b6022819 100644
--- a/tests/qemuxml2xmltest.c
+++ b/tests/qemuxml2xmltest.c
@@ -293,7 +293,7 @@ mymain(void)
     DO_TEST("pages-dimm-discard", NONE);
     DO_TEST("hugepages-default", QEMU_CAPS_OBJECT_MEMORY_FILE);
     DO_TEST("hugepages-default-2M", QEMU_CAPS_OBJECT_MEMORY_FILE);
-    DO_TEST("hugepages-default-system-size", NONE);
+    DO_TEST("hugepages-default-system-size", QEMU_CAPS_OBJECT_MEMORY_FILE);
     DO_TEST("hugepages-nodeset", QEMU_CAPS_OBJECT_MEMORY_FILE);
     DO_TEST("hugepages-numa-default-2M", QEMU_CAPS_OBJECT_MEMORY_FILE);
     DO_TEST("hugepages-numa-default-dimm", QEMU_CAPS_OBJECT_MEMORY_FILE);
-- 
2.24.1

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

Re: [libvirt] [PATCH for 6.0.0] qemuxml2*test: Fix hugepages-default-system-size tests

Posted by Pavel Hrdina 1 week ago
On Mon, Jan 13, 2020 at 12:21:50PM +0100, Jiri Denemark wrote:
> Commit v5.10.0-269-g62065a6cb5 moved NUMA validation code to domain
> definition time and appropriately adjusted affected test cases except
> for hugepages-default-system-size. And since we don't mock
> virGetSystemPageSizeKB in our tests, hugepages-default-system-size test
> would fail on architectures (ppc64le) with default page size other than
> 4KiB.
> 
> Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
> ---
>  tests/qemuxml2argvtest.c | 2 +-
>  tests/qemuxml2xmltest.c  | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)

Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list