5 const char test_name[] = "dir-rm-vine";
10 const char *filename = "/0/1/2/3/4/5/6/7/8/9/test";
15 for (tmp[0] = '0'; tmp[0] <= '9'; tmp[0]++)
17 check (mkdir (tmp), "mkdir \"%s\"", tmp);
18 check (chdir (tmp), "chdir \"%s\"", tmp);
20 check (create ("test", 512), "create \"test\"");
22 check (chdir ("/"), "chdir \"/\"");
23 check ((fd = open (filename)) > 1, "open \"%s\"", filename);
24 msg ("close \"%s\"", filename);
27 strlcpy (tmp, filename, sizeof tmp);
28 while (strlen (tmp) > 0)
30 check (remove (tmp), "remove \"%s\"", tmp);
31 *strrchr (tmp, '/') = 0;
34 check (open (filename) == 1, "open \"%s\" (must return -1)", filename);