Diff between 51c416390f9c481af8403c470f892ed24a770435 and 75cfe39fa7974d10b925e5e3ab5bd4e3ffab6b54

Changed Files

File Additions Deletions Status
unit/test-lib.c +4 -0 modified

Full Patch

diff --git a/unit/test-lib.c b/unit/test-lib.c
index 8b039cb..ef0cffc 100644
--- a/unit/test-lib.c
+++ b/unit/test-lib.c
@@ -30,6 +30,8 @@
 #include <stdlib.h>
 #include <errno.h>
 
+#include "src/shared/util.h"
+
 #include "lib/sdp.h"
 #include "lib/sdp_lib.h"
 
@@ -38,6 +40,7 @@ static void test_ntoh64(void)
 	uint64_t test = 0x123456789abcdef;
 
 	g_assert(ntoh64(test) == be64toh(test));
+	g_assert(ntoh64(test) == be64_to_cpu(test));
 }
 
 static void test_hton64(void)
@@ -45,6 +48,7 @@ static void test_hton64(void)
 	uint64_t test = 0x123456789abcdef;
 
 	g_assert(hton64(test) == htobe64(test));
+	g_assert(hton64(test) == cpu_to_be64(test));
 }
 
 static void test_sdp_get_access_protos_valid(void)