MCPcopy Create free account
hub / github.com/KhronosGroup/OpenCOLLADA / testFloat

Function testFloat

common/libftoa/src/unitTest/ftoaUnitTest.cpp:24–39  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

22
23
24static bool testFloat(float f, char* expectedString)
25{
26 int bytesWritten = Common::ftoa(f, ftoaBuffer);
27
28 if ( strcmp( ftoaBuffer, expectedString) == 0)
29 {
30 std::cout << "match " << f << ": " << ftoaBuffer << std::endl;
31 return true;
32 }
33 else
34 {
35 std::cout << " don't match " << f << ": " << ftoaBuffer << " and " << expectedString << std::endl;
36 errroCount++;
37 return false;
38 }
39}
40
41bool ftoaUnitTest()
42{

Callers 1

ftoaUnitTestFunction · 0.85

Calls 1

ftoaFunction · 0.85

Tested by

no test coverage detected