[libvirt] [libvirt-test-API][PATCH] Remove redundant colon in inteface list

hongming honzhang at redhat.com
Thu Jan 8 03:14:36 UTC 2015


On 01/07/2015 10:00 PM, jiahu wrote:
> The interface list should be:
> ['em1', 'lo', 'virbr0', 'wlp3s0']
> rather than below:
> ['em1:', 'lo:', 'virbr0:', 'wlp3s0:']
> ---
>   repos/interface/iface_list.py | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/repos/interface/iface_list.py b/repos/interface/iface_list.py
> index 49f0c05..7041535 100644
> --- a/repos/interface/iface_list.py
> +++ b/repos/interface/iface_list.py
> @@ -10,7 +10,8 @@ optional_params = {}
>   
>   VIRSH_QUIET_IFACE_LIST = "virsh --quiet iface-list %s | awk '{print ""$%s""}'"
>   NETWORK_CONFIG = "/etc/sysconfig/network-scripts/"
> -IFCONFIG_DRIVER = "ifconfig %s | sed 's/[ \t].*//;/^$/d'"
> +IFCONFIG_DRIVER = "ifconfig %s | sed 's/[ \t].*//;/^$/d'\
> +|awk -F\":\" '{print $1}'"
>   GET_MAC = "ip link show %s |sed -n '2p'| awk '{print $2}'"
>   VIRSH_IFACE_LIST = "virsh iface-list %s"
>   
Actually, the iface_list is a invalid case in libvirt-test-API . The 
original  author of it didn't call any python api , but verify the 
result of "virsh iface-list".
We need to rewrite it to verify python api - listAllInterface
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20150108/e53850ff/attachment-0001.htm>


More information about the libvir-list mailing list