diff options
author | Peter Krempa <pkrempa@redhat.com> | 2012-02-01 14:03:49 +0100 |
---|---|---|
committer | Eric Blake <eblake@redhat.com> | 2012-02-01 14:41:13 -0700 |
commit | b79ba8382e2205c416d7c4836ac9ee08c72e2c56 (patch) | |
tree | 1250314b73c6e042a032a16c99066e9962952b85 /tests | |
parent | build: add missing virStorageFileResize to libvirt_private.syms (diff) | |
download | libvirt-b79ba8382e2205c416d7c4836ac9ee08c72e2c56.tar.gz libvirt-b79ba8382e2205c416d7c4836ac9ee08c72e2c56.tar.bz2 libvirt-b79ba8382e2205c416d7c4836ac9ee08c72e2c56.zip |
xml: Add element <title> to allow short description of domains
This patch adds a new element <title> to the domain XML. This attribute
can hold a short title defined by the user to ease the identification of
domains. The title may not contain newlines and should be reasonably short.
*docs/formatdomain.html.in
*docs/schemas/domaincommon.rng
- add schema grammar for the new element and documentation
*src/conf/domain_conf.c
*src/conf/domain_conf.h
- add field to hold the new attribute
- add code to parse and create XML with the new attribute
Diffstat (limited to 'tests')
-rw-r--r-- | tests/domainschemadata/qemu-simple-description-title.xml | 27 | ||||
-rw-r--r-- | tests/qemuxml2argvdata/qemuxml2argv-minimal.xml | 5 |
2 files changed, 32 insertions, 0 deletions
diff --git a/tests/domainschemadata/qemu-simple-description-title.xml b/tests/domainschemadata/qemu-simple-description-title.xml new file mode 100644 index 000000000..a8a9cac45 --- /dev/null +++ b/tests/domainschemadata/qemu-simple-description-title.xml @@ -0,0 +1,27 @@ +<domain type='qemu'> + <name>qemu-demo</name> + <uuid>603cc28c-9841-864e-0949-8cc7d3bae9f8</uuid> + <memory>65536</memory> + <currentMemory>65536</currentMemory> + <title>A short description of this domain</title> + <description> + A longer explanation that this domain is a test domain + for validating domain schemas. + </description> + <vcpu>1</vcpu> + <os> + <type arch='x86_64' machine='pc-0.14'>hvm</type> + </os> + <features> + <acpi/> + <apic/> + <pae/> + </features> + <clock offset='utc'/> + <on_poweroff>destroy</on_poweroff> + <on_reboot>restart</on_reboot> + <on_crash>restart</on_crash> + <devices> + <emulator>/usr/bin/qemu-kvm</emulator> + </devices> +</domain> diff --git a/tests/qemuxml2argvdata/qemuxml2argv-minimal.xml b/tests/qemuxml2argvdata/qemuxml2argv-minimal.xml index 2f13d46a0..51eb59a5e 100644 --- a/tests/qemuxml2argvdata/qemuxml2argv-minimal.xml +++ b/tests/qemuxml2argvdata/qemuxml2argv-minimal.xml @@ -1,6 +1,11 @@ <domain type='qemu'> <name>QEMUGuest1</name> <uuid>c7a5fdbd-edaf-9455-926a-d65c16db1809</uuid> + <title>A description of the test machine.</title> + <description> + A test of qemu's minimal configuration. + This test also tests the description and title elements. + </description> <memory>219100</memory> <currentMemory>219100</currentMemory> <vcpu cpuset='1-4,8-20,525'>1</vcpu> |