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

Function TEST_F

tensorflow/core/profiler/internal/tfprof_timeline_test.cc:63–75  ·  view source on GitHub ↗

Before adding test, first dump the json file and manually check it's correct

Source from the content-addressed store, hash-verified

61// Before adding test, first dump the json file and
62// manually check it's correct
63TEST_F(TFProfTimelineTest, GraphView) {
64 string dump_file = io::JoinPath(testing::TmpDir(), "dump");
65 Options opts(10000, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, "name",
66 {".*"}, // accout_type_regexes
67 {".*"}, {""}, {".*"}, {""}, false,
68 {"params", "bytes", "micros", "float_ops"}, "timeline",
69 {{"outfile", dump_file}});
70 tf_stats_->ShowGraphNode("graph", opts);
71
72 string dump_str;
73 TF_CHECK_OK(ReadFileToString(Env::Default(), dump_file + "_0", &dump_str));
74 EXPECT_EQ(16556121177519539380ull, Hash64(dump_str));
75}
76
77TEST_F(TFProfTimelineTest, ScopeView) {
78 string dump_file = io::JoinPath(testing::TmpDir(), "dump");

Callers

nothing calls this directly

Calls 5

TmpDirFunction · 0.85
ReadFileToStringFunction · 0.85
DefaultFunction · 0.85
JoinPathFunction · 0.50
Hash64Function · 0.50

Tested by

no test coverage detected