Commit 94fc06ec authored by Fred Wright's avatar Fred Wright
Browse files

Fixes refid_str tests for big-endian machines.

TESTED:
Tests now pass on both x86 and PPC.
parent 5f2db02d
Pipeline #28694362 passed with stages
in 3 minutes and 40 seconds
......@@ -15,10 +15,10 @@ TEST(numtoa, RefidStr) {
const char *res;
// Test stratum > 1
res = refid_str(0x11223344, 8);
res = refid_str(htonl(0x44332211), 8);
TEST_ASSERT_EQUAL_STRING("68.51.34.17", res);
// Test !(stratum > 1)
res = refid_str(0x535047, 0);
res = refid_str(htonl(0x47505300), 0);
TEST_ASSERT_EQUAL_STRING(".GPS.", res);
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment