use zu/zd in printf to avoid warnings on 32bit
[sliver-openvswitch.git] / tests / library.at
index 70660a2..55adcfb 100644 (file)
@@ -103,12 +103,14 @@ AT_CLEANUP
 m4_foreach(
   [testname],
   [[ctz],
+   [popcount],
    [log_2_floor],
    [bitwise_copy],
    [bitwise_zero],
    [bitwise_one],
    [bitwise_is_all_zeros]],
   [AT_SETUP([testname[()] function])
+   AT_KEYWORDS([testname])
    AT_CHECK([test-util testname], [0], [], [])
    AT_CLEANUP])
 
@@ -138,3 +140,22 @@ mkdir 01234567890123456789012345678901234567890123456789012345678901234567890123
 cd 012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789
 AT_CHECK([test-unix-socket ../012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789/socket socket])
 AT_CLEANUP
+
+AT_SETUP([ovs_assert])
+OVS_LOGDIR=`pwd`; export OVS_LOGDIR
+AT_CHECK([test-util -voff -vfile:info '-vPATTERN:file:%c|%p|%m' --log-file assert || kill -l $?],
+  [0], [ABRT
+], [stderr])
+
+AT_CHECK([sed 's/\(opened log file\) .*/\1/
+s/|[[^|]]*: /|/' test-util.log], [0], [dnl
+vlog|INFO|opened log file
+util|EMER|assertion false failed in test_assert()
+])
+
+AT_CHECK([sed 's/.*: //
+1q' stderr], [0],
+  [assertion false failed in test_assert()
+])
+
+AT_CLEANUP