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

Function RunTest

tensorflow/core/platform/platform_strings_test.cc:112–130  ·  view source on GitHub ↗

Run the test, and return 0 on success, 2 otherwise.

Source from the content-addressed store, hash-verified

110
111// Run the test, and return 0 on success, 2 otherwise.
112static int RunTest(const std::string &binary_name) {
113 int rc = 0;
114 string_vec str;
115
116 if (!tensorflow::GetPlatformStrings(binary_name, &str)) {
117 CheckStr(str, "__linux__", AS_STR(__linux__));
118 CheckStr(str, "_WIN32", AS_STR(_WIN32));
119 CheckStr(str, "__APPLE__", AS_STR(__APPLE__));
120 CheckStr(str, "__x86_64__", AS_STR(__x86_64__));
121 CheckStr(str, "__aarch64__", AS_STR(__aarch64__));
122 CheckStr(str, "__powerpc64__", AS_STR(__powerpc64__));
123 CheckStr(str, "TF_PLAT_STR_VERSION", TF_PLAT_STR_VERSION_);
124 } else {
125 perror(binary_name.c_str());
126 rc = 2;
127 }
128
129 return rc;
130}
131
132int main(int argc, char *argv[]) {
133 tensorflow::Env *env = tensorflow::Env::Default();

Callers 10

mainFunction · 0.70
testEvenSplitMethod · 0.50
TEST_FFunction · 0.50
TEST_FFunction · 0.50
TEST_FFunction · 0.50
TEST_FFunction · 0.50
TEST_FFunction · 0.50
TEST_FFunction · 0.50
TEST_FFunction · 0.50
TEST_PFunction · 0.50

Calls 3

GetPlatformStringsFunction · 0.85
CheckStrFunction · 0.85
c_strMethod · 0.80

Tested by

no test coverage detected