Lines Matching refs:link
51 ASSERT_EQ(link(oldpath, newpath), 0, "");
55 // Confirm that both the old link and the new links exist
61 // Remove the old link
67 // Open the link by its new name, and verify that the contents have
68 // not been altered by the removal of the old link.
92 // Adding a file won't change the parent link count...
99 // But adding a directory WILL change the parent link count.
110 // Demonstrate that unwinding also reduces the link count.
128 // Demonstrate that unwinding also reduces the link count.
149 // Check that link count does not change with simple rename
249 ASSERT_EQ(link(oldpath, newpath), 0, "");
251 // Confirm that both the old link and the new links exist
257 // Remove the old link
262 // Open the link by its new name
289 ASSERT_EQ(link(dirpath, newpath), -1, "");
293 ASSERT_EQ(link(oldpath, newpath), -1, "");
300 // We should not be able to link to or from . or ..
301 ASSERT_EQ(link(oldpath, "::."), -1, "");
302 ASSERT_EQ(link(oldpath, "::.."), -1, "");
303 ASSERT_EQ(link("::.", newpath), -1, "");
304 ASSERT_EQ(link("::..", newpath), -1, "");
306 // We should not be able to link a file to itself
307 ASSERT_EQ(link(oldpath, oldpath), -1, "");
310 // We should not be able to link a file to a path that implies it must be a directory
311 ASSERT_EQ(link(oldpath, newpathdir), -1, "");
313 // After linking, we shouldn't be able to link again
314 ASSERT_EQ(link(oldpath, newpath), 0, "");
315 ASSERT_EQ(link(oldpath, newpath), -1, "");
318 ASSERT_EQ(link(newpath, oldpath), -1, "");