Fix equivalent test on OS X and FreeBSD

llvm-svn: 307119
This commit is contained in:
Eric Fiselier 2017-07-05 03:54:38 +00:00
parent 635430895a
commit 57495596bd
1 changed files with 7 additions and 7 deletions

View File

@ -99,14 +99,14 @@ TEST_CASE(equivalent_hardlink_succeeds) {
TEST_CASE(equivalent_is_other_succeeds) {
scoped_test_env env;
path const file = env.create_file("file", 42);
const path sock1 = env.create_socket("sock1");
const path sock2 = env.create_socket("sock2");
const path fifo1 = env.create_fifo("fifo1");
const path fifo2 = env.create_fifo("fifo2");
// Required to test behavior for inputs where is_other(p) is true.
TEST_REQUIRE(is_other(sock1));
TEST_CHECK(!equivalent(file, sock1));
TEST_CHECK(!equivalent(sock2, file));
TEST_CHECK(!equivalent(sock1, sock2));
TEST_CHECK(equivalent(sock1, sock1));
TEST_REQUIRE(is_other(fifo1));
TEST_CHECK(!equivalent(file, fifo1));
TEST_CHECK(!equivalent(fifo2, file));
TEST_CHECK(!equivalent(fifo1, fifo2));
TEST_CHECK(equivalent(fifo1, fifo1));
}
TEST_SUITE_END()