MCPcopy Create free account
hub / github.com/ROCm/AMDMIGraphX / test_equality

Function test_equality

test/float_equal.cpp:55–70  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

53
54template <class T, class U>
55static void test_equality()
56{
57 auto x1 = T(0.125);
58 auto x2 = U(0.0);
59 auto x3 = U(1.0);
60 EXPECT(test_float_equal(x1, x1));
61 EXPECT(test_float_equal(x2, x2));
62 EXPECT(test_float_equal(x3, x3));
63
64 EXPECT(not test_float_equal(x1, x2));
65 EXPECT(not test_float_equal(x2, x1));
66 EXPECT(not test_float_equal(x1, x3));
67 EXPECT(not test_float_equal(x3, x1));
68 EXPECT(not test_float_equal(x2, x3));
69 EXPECT(not test_float_equal(x3, x2));
70}
71
72TEST_CASE_REGISTER(test_equality<double, float>);
73TEST_CASE_REGISTER(test_equality<double, int>);

Callers

nothing calls this directly

Calls 2

TClass · 0.85
test_float_equalFunction · 0.85

Tested by

no test coverage detected