Skip to content
This repository was archived by the owner on Jan 22, 2026. It is now read-only.

Commit 8ad6a40

Browse files
committed
Guest: Restructure XML building to match libvirt generated XML
Some of these inaccuracies are ages old so we have to touch a lot of test files.
1 parent 55a09b0 commit 8ad6a40

83 files changed

Lines changed: 307 additions & 298 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

tests/cli-test-xml/compare/default.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
<domain type='lxc'>
22
<name>foolxc</name>
3-
<currentMemory>65536</currentMemory>
4-
<memory>65536</memory>
53
<uuid>00000000-1111-2222-3333-444444444444</uuid>
4+
<memory>65536</memory>
5+
<currentMemory>65536</currentMemory>
6+
<vcpu>1</vcpu>
67
<os>
78
<type arch='x86_64'>exe</type>
89
<init>/bin/sh</init>
910
</os>
1011
<on_poweroff>destroy</on_poweroff>
1112
<on_reboot>restart</on_reboot>
1213
<on_crash>restart</on_crash>
13-
<vcpu>1</vcpu>
1414
<devices>
1515
<emulator>/usr/libexec/libvirt_lxc</emulator>
1616
<interface type='user'>

tests/cli-test-xml/compare/fs-default.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
<domain type='lxc'>
22
<name>foolxc</name>
3-
<currentMemory>65536</currentMemory>
4-
<memory>65536</memory>
53
<uuid>00000000-1111-2222-3333-444444444444</uuid>
4+
<memory>65536</memory>
5+
<currentMemory>65536</currentMemory>
6+
<vcpu>1</vcpu>
67
<os>
78
<type arch='x86_64'>exe</type>
89
<init>/sbin/init</init>
910
</os>
1011
<on_poweroff>destroy</on_poweroff>
1112
<on_reboot>restart</on_reboot>
1213
<on_crash>restart</on_crash>
13-
<vcpu>1</vcpu>
1414
<devices>
1515
<emulator>/usr/libexec/libvirt_lxc</emulator>
1616
<filesystem>

tests/cli-test-xml/compare/image-boot0.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
<domain type='test'>
22
<name>foobar</name>
3-
<currentMemory>65536</currentMemory>
4-
<memory>65536</memory>
53
<uuid>00000000-1111-2222-3333-444444444444</uuid>
4+
<memory>65536</memory>
5+
<currentMemory>65536</currentMemory>
6+
<vcpu>7</vcpu>
67
<bootloader>/usr/bin/pygrub</bootloader>
78
<features>
89
<pae/>
910
</features>
1011
<on_poweroff>destroy</on_poweroff>
1112
<on_reboot>restart</on_reboot>
1213
<on_crash>restart</on_crash>
13-
<vcpu>7</vcpu>
1414
<devices>
1515
<disk type='file' device='disk'>
1616
<source file='/tmp/__virtinst__cli_root.raw'/>

tests/cli-test-xml/compare/image-boot1.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
<domain type='test'>
22
<name>foobar</name>
3-
<currentMemory>65536</currentMemory>
4-
<memory>65536</memory>
53
<uuid>00000000-1111-2222-3333-444444444444</uuid>
4+
<memory>65536</memory>
5+
<currentMemory>65536</currentMemory>
6+
<vcpu>7</vcpu>
67
<os>
78
<type arch='i686'>hvm</type>
89
<boot dev='hd'/>
@@ -14,7 +15,6 @@
1415
<on_poweroff>destroy</on_poweroff>
1516
<on_reboot>restart</on_reboot>
1617
<on_crash>restart</on_crash>
17-
<vcpu>7</vcpu>
1818
<devices>
1919
<emulator>/usr/bin/test-hv</emulator>
2020
<disk type='file' device='disk'>

tests/cli-test-xml/compare/image-nogfx.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
<domain type='test'>
22
<name>foobar</name>
3-
<currentMemory>65536</currentMemory>
4-
<memory>65536</memory>
53
<uuid>00000000-1111-2222-3333-444444444444</uuid>
4+
<memory>65536</memory>
5+
<currentMemory>65536</currentMemory>
6+
<vcpu>7</vcpu>
67
<bootloader>/usr/bin/pygrub</bootloader>
78
<features>
89
<pae/>
910
</features>
1011
<on_poweroff>destroy</on_poweroff>
1112
<on_reboot>restart</on_reboot>
1213
<on_crash>restart</on_crash>
13-
<vcpu>7</vcpu>
1414
<devices>
1515
<disk type='file' device='disk'>
1616
<source file='/tmp/__virtinst__cli_root.raw'/>

tests/cli-test-xml/compare/kvm-f14-url.xml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
<domain type='kvm'>
22
<name>foobar</name>
3-
<currentMemory>65536</currentMemory>
4-
<memory>65536</memory>
53
<uuid>00000000-1111-2222-3333-444444444444</uuid>
4+
<memory>65536</memory>
5+
<currentMemory>65536</currentMemory>
6+
<vcpu>1</vcpu>
67
<os>
78
<type arch='x86_64'>hvm</type>
89
<kernel>./virtinst-vmlinuz.</kernel>
@@ -33,7 +34,6 @@
3334
<on_poweroff>destroy</on_poweroff>
3435
<on_reboot>destroy</on_reboot>
3536
<on_crash>destroy</on_crash>
36-
<vcpu>1</vcpu>
3737
<devices>
3838
<emulator>/usr/bin/qemu-kvm</emulator>
3939
<disk type='file' device='disk'>
@@ -56,9 +56,10 @@
5656
</domain>
5757
<domain type='kvm'>
5858
<name>foobar</name>
59-
<currentMemory>65536</currentMemory>
60-
<memory>65536</memory>
6159
<uuid>00000000-1111-2222-3333-444444444444</uuid>
60+
<memory>65536</memory>
61+
<currentMemory>65536</currentMemory>
62+
<vcpu>1</vcpu>
6263
<os>
6364
<type arch='x86_64'>hvm</type>
6465
<boot dev='hd'/>
@@ -87,7 +88,6 @@
8788
<on_poweroff>destroy</on_poweroff>
8889
<on_reboot>restart</on_reboot>
8990
<on_crash>restart</on_crash>
90-
<vcpu>1</vcpu>
9191
<devices>
9292
<emulator>/usr/bin/qemu-kvm</emulator>
9393
<disk type='file' device='disk'>

tests/cli-test-xml/compare/kvm-machine.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
<domain type='kvm'>
22
<name>foobar</name>
3-
<currentMemory>65536</currentMemory>
4-
<memory>65536</memory>
53
<uuid>00000000-1111-2222-3333-444444444444</uuid>
4+
<memory>65536</memory>
5+
<currentMemory>65536</currentMemory>
6+
<vcpu>1</vcpu>
67
<os>
78
<type arch='x86_64' machine='pc'>hvm</type>
89
<boot dev='fd'/>
@@ -14,7 +15,6 @@
1415
<on_poweroff>destroy</on_poweroff>
1516
<on_reboot>restart</on_reboot>
1617
<on_crash>restart</on_crash>
17-
<vcpu>1</vcpu>
1818
<devices>
1919
<emulator>/usr/bin/qemu-kvm</emulator>
2020
<interface type='network'>

tests/cli-test-xml/compare/kvm-win2k3-cdrom.xml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
<domain type='kvm'>
22
<name>foobar</name>
3-
<currentMemory>65536</currentMemory>
4-
<memory>65536</memory>
53
<uuid>00000000-1111-2222-3333-444444444444</uuid>
4+
<memory>65536</memory>
5+
<currentMemory>65536</currentMemory>
6+
<vcpu>1</vcpu>
67
<os>
78
<type arch='x86_64'>hvm</type>
89
<boot dev='cdrom'/>
@@ -15,7 +16,6 @@
1516
<on_poweroff>destroy</on_poweroff>
1617
<on_reboot>destroy</on_reboot>
1718
<on_crash>destroy</on_crash>
18-
<vcpu>1</vcpu>
1919
<devices>
2020
<emulator>/usr/bin/qemu-kvm</emulator>
2121
<disk type='file' device='disk'>
@@ -44,9 +44,10 @@
4444
</domain>
4545
<domain type='kvm'>
4646
<name>foobar</name>
47-
<currentMemory>65536</currentMemory>
48-
<memory>65536</memory>
4947
<uuid>00000000-1111-2222-3333-444444444444</uuid>
48+
<memory>65536</memory>
49+
<currentMemory>65536</currentMemory>
50+
<vcpu>1</vcpu>
5051
<os>
5152
<type arch='x86_64'>hvm</type>
5253
<boot dev='hd'/>
@@ -58,7 +59,6 @@
5859
<on_poweroff>destroy</on_poweroff>
5960
<on_reboot>destroy</on_reboot>
6061
<on_crash>destroy</on_crash>
61-
<vcpu>1</vcpu>
6262
<devices>
6363
<emulator>/usr/bin/qemu-kvm</emulator>
6464
<disk type='file' device='disk'>
@@ -87,9 +87,10 @@
8787
</domain>
8888
<domain type='kvm'>
8989
<name>foobar</name>
90-
<currentMemory>65536</currentMemory>
91-
<memory>65536</memory>
9290
<uuid>00000000-1111-2222-3333-444444444444</uuid>
91+
<memory>65536</memory>
92+
<currentMemory>65536</currentMemory>
93+
<vcpu>1</vcpu>
9394
<os>
9495
<type arch='x86_64'>hvm</type>
9596
<boot dev='hd'/>
@@ -101,7 +102,6 @@
101102
<on_poweroff>destroy</on_poweroff>
102103
<on_reboot>restart</on_reboot>
103104
<on_crash>restart</on_crash>
104-
<vcpu>1</vcpu>
105105
<devices>
106106
<emulator>/usr/bin/qemu-kvm</emulator>
107107
<disk type='file' device='disk'>

tests/cli-test-xml/compare/kvm-xenner.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
<domain type='kvm'>
22
<name>foobar</name>
3-
<currentMemory>65536</currentMemory>
4-
<memory>65536</memory>
53
<uuid>00000000-1111-2222-3333-444444444444</uuid>
4+
<memory>65536</memory>
5+
<currentMemory>65536</currentMemory>
6+
<vcpu>1</vcpu>
67
<bootloader>/usr/bin/pygrub</bootloader>
78
<features>
89
<acpi/><apic/>
910
</features>
1011
<on_poweroff>destroy</on_poweroff>
1112
<on_reboot>restart</on_reboot>
1213
<on_crash>restart</on_crash>
13-
<vcpu>1</vcpu>
1414
<devices>
1515
<interface type='network'>
1616
<source network='default'/>

tests/cli-test-xml/compare/manual-init.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
<domain type='lxc'>
22
<name>foolxc</name>
3-
<currentMemory>65536</currentMemory>
4-
<memory>65536</memory>
53
<uuid>00000000-1111-2222-3333-444444444444</uuid>
4+
<memory>65536</memory>
5+
<currentMemory>65536</currentMemory>
6+
<vcpu>1</vcpu>
67
<os>
78
<type arch='x86_64'>exe</type>
89
<init>/usr/bin/httpd</init>
910
</os>
1011
<on_poweroff>destroy</on_poweroff>
1112
<on_reboot>restart</on_reboot>
1213
<on_crash>restart</on_crash>
13-
<vcpu>1</vcpu>
1414
<devices>
1515
<emulator>/usr/libexec/libvirt_lxc</emulator>
1616
<interface type='user'>

0 commit comments

Comments
 (0)