virsh_start: Fix pause bug in cleanup.

Signed-off-by: Dongsheng Yang <yangds.fnst@cn.fujitsu.com>
Add test for secret-dumpxml
virsh_start: add cases for more options.

Signed-off-by: Dongsheng Yang <yangds.fnst@cn.fujitsu.com>
Modify for secret-list wrap changed in
Add virsh command testcase virsh_secret_list
blockcopy: Resolve failing cases

Fail #1: blockcopy.positive_test.raw_format
For the raw format, the code mades a special check/call to QemuImg to
get the information about the blockcopy created.  The setup of the
params[] to the initializer was incorrect using 'image_filename'
instead of 'image_name' and the path to the file without the extension.

Had to adjust how the file was created to ensure it was created with
an extension ".raw"; otherwise, the 'image_format' would seem to default
to qcow2 which would be appended onto the "image_file' name passed.

Because the creation was adjusted to add the extenstion we have to
remove it when doing the check call...

Fail #2: blockcopy.negative_test.timeout_check
It seems libvirt commit id '4c297728' has resolved what used to be an
expected failure. The test passes for me now.  The commit in question
deals with blockcopy failing "unexpectedly" which would happen when
the timeout was fired and "quit" would be set in the code. So modify
the expected failure code to check for the expected failure message of
Copy aborted.  Additionally, add a bandwidth argument to hopefully
avoid the possibility that the copy completes very quickly and the
the message "Now in mirroring phase" is provided.
pool_create: Adjust location of --file pool

As of commit id 'c5f6c685' in virt-install (v1.0.0), virt-install
will attempt to create a storage pool for ease of management of
volumes. Thus if the test was started with --install or by chance
an 'images' pool exists using get_data_dir(), then the attempt
to define/create this pool will fail since two pools cannot use
the same path.  Therefore, rather than use the data dir for our
test, let's just use 'tmp' dir and create an images pool there.
domcontrol: fix process poll check problem

The process poll return None when process exist, else return negative
value if terminated. The check at cleanup got this wrong, so fix it.

Signed-off-by: Wayne Sun <gsun@redhat.com>
tp-libvirt: Skip test if tgtadm is not found

When the optional binary `tgtadm` is not available on the host, we don't
expect the test case fail and should skip it instead.

Signed-off-by: Hao Liu <hliu@redhat.com>
tp-libvirt: Fix iface-trans

Using `locate` utility to find a file could result into undesired
results and it also depends on whether the test system is indexed
properly. To find the `netcf-transaction` script, we use the autotest
`find_command()` to do the job. For system using SYSV init service
manager, we hard code the script location for a work around.

Also, alway cleanup enviroment in case a broken job influence
consecutive jobs.

Signed-off-by: Hao Liu <hliu@redhat.com>
Merge pull request #131 from jferlan/blockcopy

blockcopy: Resolve failing cases
Merge pull request #132 from jferlan/pool_create

pool_create: Adjust location of --file pool
Merge pull request #150 from waynesun09/domcontrol_fix

domcontrol: fix process poll check problem
Merge pull request #158 from Hao-Liu/fix_attach_detach_disk

tp-libvirt: Skip test if tgtadm is not found
Merge pull request #114 from kylazhang/secret-list

Add test for secret-list
Merge pull request #116 from kylazhang/secret-dumpxml

Add test for secret-dumpxml
Address the complain from inspekt style.

Signed-off-by: Dongsheng Yang <yangds.fnst@cn.fujitsu.com>
tp-libvirt: Fix libvirt network bandwidth

* The portgroup attribute is only applicable with virtual network
  interface, So skip the test if the default interface is not a
  'network' type.

Signed-off-by: Hao Liu <hliu@redhat.com>
snapshot_edit

Fix issue when/if the snapshot_create_as() fails the 'snapshot_oldlist'
wouldn't be generated resulting in a failure during the finally: segment
and not cleaning up after ourselves fully.
Merge pull request #160 from Hao-Liu/fix_iface_trans

tp-libvirt: Fix iface-trans