I saw this function in another patch.
How about moving these functions to utils_test.libvirt module or other public modules?