Borrowed from https://github.com/sysrepo/sysrepo-netopeer2-smoketests with some minor fixes