libvirt.tests: Add a test for disk startupPolicy testing

libvirt domain disk XML may has a startupPolicy element:
    <disk type='file' device='floppy'>
      <source file='xxx' startupPolicy='mandatory'/>
      <target dev='fda' bus='fdc'/>
    </disk>
The value may be mandatory, requisite or optional, which corresponds to
differet behavior when start domain. This test case aim to test the three
different values for CD-ROM and floppy disks.

Signed-off-by: Yanbing Du <ydu@redhat.com>
Add PV related case for libguestfs
libvirt.tests: add new negative case into virsh domstate

Signed-off-by: Alex Jia <chuanchang.jia@gmail.com>
libvirt.test: Fix bugs in macvtap test
1.Fix the way to edit the file on remote
2.Remove unnecessary session creation

Signed-off-by: Li Yang <liyang.fnst@cn.fujitsu.com>
snapshot_disk: Add pool volume snapshot cases

Current test is with snapshot disk in a created tmp dir, for support
pool volume testing with snapshot, create certain type pool and use
volume in the pool for snapshot testing.

Skip specific cases since upstream and rhel7 change.

Covered pool: "dir", "fs", "netfs", "iscsi", "logical" and "disk"

Signed-off-by: Wayne Sun <gsun@redhat.com>
qemu_monitor_command: Add two more negative cases

Add a negative case for cover unknow cmd error, and another one
for invalid qmp command.

Signed-off-by: Wayne Sun <gsun@redhat.com>
Merge pull request #227 from chuanchang/add_cases_into_domstate

libvirt.tests: add new negative case into virsh domstate
Merge pull request #230 from waynesun09/qemu_monitor_cmd

qemu_monitor_command: Add two more negative cases
libvirt.test: Fix problem in virsh iface test

1.Skip OSError when delete a bridge
2.Filter 'net_restart' cases because it's dangerous

Signed-off-by: Li Yang <liyang.fnst@cn.fujitsu.com>
libvirt.test: Fix a typo in qemu agent command test

Signed-off-by: Li Yang <liyang.fnst@cn.fujitsu.com>
Merge pull request #238 from liyangfnst/agent_fix

libvirt.test: Fix a typo in qemu agent command test
Fix a typo of case name
Merge pull request #223 from vanbogithub/bfan-dev

Add PV related case for libguestfs
Merge pull request #188 from liyangfnst/macvtap_fix

libvirt.test: Fix bugs in macvtap test
Merge pull request #162 from will-Do/startupPolicy

libvirt.tests: Add a test for disk startupPolicy testing
Merge pull request #212 from waynesun09/snapshot_disk_with_pool

snapshot_disk: Add pool volume snapshot cases
snapshot_disk: Add snapshot cfg xml check for delete testing

Check snapshot cfg xml file after done snapshot delete.

Signed-off-by: Wayne Sun <gsun@redhat.com>
Merge pull request #244 from waynesun09/snapshot_delete_check

snapshot_disk: Add snapshot cfg xml check for delete testing
virsh.snapshot_disk: Raise NAError when we get a message about "not supported".

When we run test for virsh.snapshot_disk in RHEL6:
Compiled against library: libvirt 0.10.2
Using library: libvirt 0.10.2
Using API: QEMU 0.10.2
Running hypervisor: QEMU 0.12.1

We will get some FAILs and error message:
"live disk snapshot not supported with this QEMU binary"

In this case, we should raise an NAError rather than FailError.

We are testing libvirt in tp-libvirt, and libvirt works well in
this case, but qemu-kvm.0.12.1 does not support live snapshot. It
is out of our testing project, and it should be NAError.

Signed-off-by: Dongsheng Yang <yangds.fnst@cn.fujitsu.com>
Merge pull request #237 from liyangfnst/iface_fix

libvirt.test: Fix problem in virsh iface test