MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / TEST

Function TEST

tensorflow/core/lib/io/path_test.cc:22–35  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

20namespace io {
21
22TEST(PathTest, JoinPath) {
23 EXPECT_EQ("/foo/bar", JoinPath("/foo", "bar"));
24 EXPECT_EQ("foo/bar", JoinPath("foo", "bar"));
25 EXPECT_EQ("foo/bar", JoinPath("foo", "/bar"));
26 EXPECT_EQ("/foo/bar", JoinPath("/foo", "/bar"));
27
28 EXPECT_EQ("/bar", JoinPath("", "/bar"));
29 EXPECT_EQ("bar", JoinPath("", "bar"));
30 EXPECT_EQ("/foo", JoinPath("/foo", ""));
31
32 EXPECT_EQ("/foo/bar/baz/blah/blink/biz",
33 JoinPath("/foo/bar/baz/", "/blah/blink/biz"));
34 EXPECT_EQ("/foo/bar/baz/blah", JoinPath("/foo", "bar", "baz", "blah"));
35}
36
37TEST(PathTest, IsAbsolutePath) {
38 EXPECT_FALSE(IsAbsolutePath(""));

Callers

nothing calls this directly

Calls 6

DirnameFunction · 0.85
BasenameFunction · 0.85
ExtensionFunction · 0.85
CleanPathFunction · 0.85
JoinPathFunction · 0.70
IsAbsolutePathFunction · 0.70

Tested by

no test coverage detected