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

Function TestAllApiDefsHaveCorrespondingOp

tensorflow/core/api_def/api_test.cc:69–80  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

67}
68
69void TestAllApiDefsHaveCorrespondingOp(
70 const OpList& ops, const std::unordered_map<string, ApiDef>& api_defs_map) {
71 std::unordered_set<string> op_names;
72 for (const auto& op : ops.op()) {
73 op_names.insert(op.name());
74 }
75 for (const auto& name_and_api_def : api_defs_map) {
76 ASSERT_TRUE(op_names.find(name_and_api_def.first) != op_names.end())
77 << name_and_api_def.first << " op has ApiDef but missing from ops. "
78 << "Does api_def_" << name_and_api_def.first << " need to be deleted?";
79 }
80}
81
82void TestAllApiDefInputArgsAreValid(
83 const OpList& ops, const std::unordered_map<string, ApiDef>& api_defs_map) {

Callers 1

TEST_FFunction · 0.85

Calls 5

nameMethod · 0.65
opMethod · 0.45
insertMethod · 0.45
findMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected