libvirt: Confirm network exists before testing

Signed-off-by: Li Yang <liyang.fnst@cn.fujitsu.com>