X-Git-Url: http://git.meshlink.io/?a=blobdiff_plain;f=test%2Fblacklist.c;h=f9a3036f3d3b33cf604e018d2b9a32ab68e0af5f;hb=92bae04187d9ecd7900b5a28154a2c046001a7f3;hp=cd54585341148922894b7220a365a45b1b93c838;hpb=9d23fe58052b3ef971305699a00ea6dbd1111744;p=meshlink-tiny diff --git a/test/blacklist.c b/test/blacklist.c index cd54585..f9a3036 100644 --- a/test/blacklist.c +++ b/test/blacklist.c @@ -13,7 +13,7 @@ #include #include -#include "meshlink.h" +#include "meshlink-tiny.h" #include "devtools.h" #include "utils.h" @@ -113,12 +113,6 @@ int main(void) { assert(meshlink_get_node_blacklisted(mesh[1], meshlink_get_node(mesh[1], name[2]))); assert(meshlink_get_node_blacklisted(mesh[2], meshlink_get_node(mesh[2], name[1]))); - // Generate an invitation for a node that is about to be blacklisted - - char *invitation = meshlink_invite(mesh[0], NULL, "xyzzy"); - assert(invitation); - free(invitation); - // Whitelisting and blacklisting by name should work. assert(meshlink_whitelist_by_name(mesh[0], "quux")); @@ -142,20 +136,6 @@ int main(void) { free(nodes); - // Check that blacklisted nodes are not allowed to be invited, and no invitations are left on disk. - - assert(!meshlink_invite(mesh[0], NULL, "xyzzy")); - - DIR *dir = opendir("blacklist_conf.0/current/invitations"); - assert(dir); - struct dirent *ent; - - while((ent = readdir(dir))) { - assert(!strcmp(ent->d_name, ".") || !strcmp(ent->d_name, "..")); - } - - closedir(dir); - // Since these nodes now exist we should be able to forget them. assert(meshlink_forget_node(mesh[0], meshlink_get_node(mesh[0], "quux")));