Tarantool development patches archive
 help / color / mirror / Atom feed
* [Tarantool-patches] [PATCH 0/2] Make unit tests TAP-compliant
@ 2020-05-21  9:59 sergeyb
  2020-05-21  9:59 ` [Tarantool-patches] [PATCH 1/2] test: update unit test lib to produce TAP-compliant output sergeyb
                   ` (3 more replies)
  0 siblings, 4 replies; 12+ messages in thread
From: sergeyb @ 2020-05-21  9:59 UTC (permalink / raw)
  To: tarantool-patches; +Cc: o.piskunov, alexander.turenko

From: Sergey Bronnikov <sergeyb@tarantool.org>

Tarantool unit tests uses TAP framework but some tests haven't produce
TAP-compliant output. This patch fixes such tests.

TAP framework contains primitives to check correctness of test functions
behaviour and produced test output contains information about passed and failed
testcases. This output processed by test-run.py on test execution. In this scheme
separate artifacts like reference output files are useless and patch removes them.

GH branch: https://github.com/tarantool/tarantool/tree/ligurio/gh-5000-using-tap-output-in-unit-tests
GH issue: https://github.com/tarantool/tarantool/issues/5000

Alexander Turenko (1):
  test: update unit test lib to produce TAP-compliant output

Sergey Bronnikov (1):
  test: update unit tests to make them TAP-compliant

 test/unit/CMakeLists.txt              |   49 +-
 test/unit/base64.result               |  178 --
 test/unit/bit.c                       |   75 +-
 test/unit/bit.result                  |  895 ----------
 test/unit/bitset_basic.c              |   38 +-
 test/unit/bitset_basic.result         |   12 -
 test/unit/bitset_index.c              |   42 +-
 test/unit/bitset_index.result         |   21 -
 test/unit/bitset_iterator.c           |   32 +
 test/unit/bitset_iterator.result      |   22 -
 test/unit/bloom.cc                    |   20 +-
 test/unit/bloom.result                |    6 -
 test/unit/bps_tree.cc                 |   80 +-
 test/unit/bps_tree.result             |  284 ---
 test/unit/bps_tree_iterator.cc        |   42 +-
 test/unit/bps_tree_iterator.result    |   21 -
 test/unit/cbus.c                      |   20 +-
 test/unit/cbus.result                 |   24 -
 test/unit/cbus_hang.c                 |    2 +-
 test/unit/cbus_hang.result            |    4 -
 test/unit/cbus_stress.c               |   53 +-
 test/unit/cbus_stress.result          |    2 -
 test/unit/checkpoint_schedule.result  |   41 -
 test/unit/coio.result                 |   12 -
 test/unit/coll.cpp                    |   51 +-
 test/unit/coll.result                 |   90 -
 test/unit/column_mask.result          |   36 -
 test/unit/crypto.result               |  132 --
 test/unit/csv.result                  |   80 +-
 test/unit/decimal.result              |  700 --------
 test/unit/fiber.cc                    |   21 +-
 test/unit/fiber.result                |   19 -
 test/unit/fiber_channel.cc            |    2 +
 test/unit/fiber_channel.result        |   23 -
 test/unit/fiber_channel_stress.cc     |    3 +
 test/unit/fiber_channel_stress.result |    2 -
 test/unit/fiber_cond.result           |    8 -
 test/unit/fiber_stack.c               |    3 +
 test/unit/fiber_stack.result          |   11 -
 test/unit/fiber_stress.cc             |    4 +
 test/unit/fiber_stress.result         |    0
 test/unit/find_path.c                 |    3 +
 test/unit/find_path.result            |    2 -
 test/unit/guard.cc                    |    3 +-
 test/unit/guard.result                |    1 -
 test/unit/guava.c                     |   11 +
 test/unit/guava.result                |    6 -
 test/unit/heap.c                      |   38 +
 test/unit/heap.result                 |   24 -
 test/unit/heap_iterator.c             |   14 +
 test/unit/heap_iterator.result        |    8 -
 test/unit/histogram.c                 |   11 +
 test/unit/histogram.result            |    6 -
 test/unit/int96.cc                    |   51 +-
 test/unit/int96.result                |    2 -
 test/unit/json.result                 |  208 ---
 test/unit/light.cc                    |   16 +-
 test/unit/light.result                |    8 -
 test/unit/luaL_iterator.result        |   89 -
 test/unit/luaT_tuple_new.result       |   22 -
 test/unit/merger.result               |   71 -
 test/unit/mhash.result                |   18 -
 test/unit/mhash_bytemap.result        |   18 -
 test/unit/mp_error.result             |   44 -
 test/unit/msgpack.result              | 2282 -------------------------
 test/unit/popen.result                |   30 -
 test/unit/queue.c                     |   65 +-
 test/unit/queue.result                |   34 -
 test/unit/ratelimit.result            |   13 -
 test/unit/reflection_c.result         |    5 -
 test/unit/reflection_cxx.result       |   31 -
 test/unit/rmean.cc                    |   19 +-
 test/unit/rmean.result                |   11 -
 test/unit/rope.c                      |   10 +-
 test/unit/rope.result                 |  299 ----
 test/unit/rope_avl.c                  |    5 +
 test/unit/rope_avl.result             |  123 --
 test/unit/rope_basic.c                |   19 +-
 test/unit/rope_basic.result           |  139 --
 test/unit/rope_common.h               |   11 +-
 test/unit/rope_stress.c               |    8 +
 test/unit/rope_stress.result          |    4 -
 test/unit/rtree.cc                    |   20 +-
 test/unit/rtree.result                |    8 -
 test/unit/rtree_iterator.cc           |   24 +-
 test/unit/rtree_iterator.result       |    7 -
 test/unit/rtree_multidim.cc           |   30 +-
 test/unit/rtree_multidim.result       |   15 -
 test/unit/say.result                  |   67 -
 test/unit/scramble.c                  |   21 +-
 test/unit/scramble.result             |    4 -
 test/unit/sio.result                  |   36 -
 test/unit/stailq.result               |   76 -
 test/unit/swim.result                 |  234 ---
 test/unit/swim_errinj.result          |   18 -
 test/unit/swim_proto.result           |   40 -
 test/unit/tuple_bigref.result         |   17 -
 test/unit/unit.c                      |    3 +
 test/unit/unit.h                      |   13 +-
 test/unit/uri.result                  | 1307 --------------
 test/unit/uuid.result                 |    9 -
 test/unit/vclock.result               |  149 --
 test/unit/vy_cache.result             |    9 -
 test/unit/vy_mem.c                    |    4 +-
 test/unit/vy_mem.result               |   17 -
 test/unit/vy_point_lookup.result      |   20 -
 test/unit/vy_write_iterator.result    |   61 -
 test/unit/xrow.result                 |   58 -
 108 files changed, 688 insertions(+), 8521 deletions(-)
 delete mode 100644 test/unit/base64.result
 delete mode 100644 test/unit/bit.result
 delete mode 100644 test/unit/bitset_basic.result
 delete mode 100644 test/unit/bitset_index.result
 delete mode 100644 test/unit/bitset_iterator.result
 delete mode 100644 test/unit/bloom.result
 delete mode 100644 test/unit/bps_tree.result
 delete mode 100644 test/unit/bps_tree_iterator.result
 delete mode 100644 test/unit/cbus.result
 delete mode 100644 test/unit/cbus_hang.result
 delete mode 100644 test/unit/cbus_stress.result
 delete mode 100644 test/unit/checkpoint_schedule.result
 delete mode 100644 test/unit/coio.result
 delete mode 100644 test/unit/coll.result
 delete mode 100644 test/unit/column_mask.result
 delete mode 100644 test/unit/crypto.result
 delete mode 100644 test/unit/decimal.result
 delete mode 100644 test/unit/fiber.result
 delete mode 100644 test/unit/fiber_channel.result
 delete mode 100644 test/unit/fiber_channel_stress.result
 delete mode 100644 test/unit/fiber_cond.result
 delete mode 100644 test/unit/fiber_stack.result
 delete mode 100644 test/unit/fiber_stress.result
 delete mode 100644 test/unit/find_path.result
 delete mode 100644 test/unit/guard.result
 delete mode 100644 test/unit/guava.result
 delete mode 100644 test/unit/heap.result
 delete mode 100644 test/unit/heap_iterator.result
 delete mode 100644 test/unit/histogram.result
 delete mode 100644 test/unit/int96.result
 delete mode 100644 test/unit/json.result
 delete mode 100644 test/unit/light.result
 delete mode 100644 test/unit/luaL_iterator.result
 delete mode 100644 test/unit/luaT_tuple_new.result
 delete mode 100644 test/unit/merger.result
 delete mode 100644 test/unit/mhash.result
 delete mode 100644 test/unit/mhash_bytemap.result
 delete mode 100644 test/unit/mp_error.result
 delete mode 100644 test/unit/msgpack.result
 delete mode 100644 test/unit/popen.result
 delete mode 100644 test/unit/queue.result
 delete mode 100644 test/unit/ratelimit.result
 delete mode 100644 test/unit/reflection_c.result
 delete mode 100644 test/unit/reflection_cxx.result
 delete mode 100644 test/unit/rmean.result
 delete mode 100644 test/unit/rope.result
 delete mode 100644 test/unit/rope_avl.result
 delete mode 100644 test/unit/rope_basic.result
 delete mode 100644 test/unit/rope_stress.result
 delete mode 100644 test/unit/rtree.result
 delete mode 100644 test/unit/rtree_iterator.result
 delete mode 100644 test/unit/rtree_multidim.result
 delete mode 100644 test/unit/say.result
 delete mode 100644 test/unit/scramble.result
 delete mode 100644 test/unit/sio.result
 delete mode 100644 test/unit/stailq.result
 delete mode 100644 test/unit/swim.result
 delete mode 100644 test/unit/swim_errinj.result
 delete mode 100644 test/unit/swim_proto.result
 delete mode 100644 test/unit/tuple_bigref.result
 delete mode 100644 test/unit/uri.result
 delete mode 100644 test/unit/uuid.result
 delete mode 100644 test/unit/vclock.result
 delete mode 100644 test/unit/vy_cache.result
 delete mode 100644 test/unit/vy_mem.result
 delete mode 100644 test/unit/vy_point_lookup.result
 delete mode 100644 test/unit/vy_write_iterator.result
 delete mode 100644 test/unit/xrow.result

-- 
2.23.0

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Tarantool-patches] [PATCH 1/2] test: update unit test lib to produce TAP-compliant output
  2020-05-21  9:59 [Tarantool-patches] [PATCH 0/2] Make unit tests TAP-compliant sergeyb
@ 2020-05-21  9:59 ` sergeyb
  2020-06-02  9:20   ` Sergey Bronnikov
  2020-06-03 22:52   ` Vladislav Shpilevoy
  2020-05-21  9:59 ` [Tarantool-patches] [PATCH 2/2] test: update unit tests to make them TAP-compliant sergeyb
                   ` (2 subsequent siblings)
  3 siblings, 2 replies; 12+ messages in thread
From: sergeyb @ 2020-05-21  9:59 UTC (permalink / raw)
  To: tarantool-patches; +Cc: o.piskunov, Alexander Turenko

From: Alexander Turenko <alexander.turenko@tarantool.org>

Closes #5000
---
 test/unit/CMakeLists.txt | 49 +++++++++++++++++++++-------------------
 test/unit/unit.c         |  3 +++
 test/unit/unit.h         | 13 ++++++++---
 3 files changed, 39 insertions(+), 26 deletions(-)

diff --git a/test/unit/CMakeLists.txt b/test/unit/CMakeLists.txt
index 84eb066bd..0704d10f0 100644
--- a/test/unit/CMakeLists.txt
+++ b/test/unit/CMakeLists.txt
@@ -23,46 +23,48 @@ target_link_libraries(stailq.test unit)
 add_executable(uri.test uri.c unit.c)
 target_link_libraries(uri.test uri unit)
 add_executable(queue.test queue.c)
+target_link_libraries(queue.test unit)
 add_executable(mhash.test mhash.c)
 target_link_libraries(mhash.test unit)
 add_executable(mhash_bytemap.test mhash_bytemap.c)
 target_link_libraries(mhash_bytemap.test unit)
 add_executable(rope_basic.test rope_basic.c)
-target_link_libraries(rope_basic.test salad)
+target_link_libraries(rope_basic.test salad unit)
 add_executable(rope_avl.test rope_avl.c)
-target_link_libraries(rope_avl.test salad)
+target_link_libraries(rope_avl.test salad unit)
 add_executable(rope_stress.test rope_stress.c)
-target_link_libraries(rope_stress.test salad)
+target_link_libraries(rope_stress.test salad unit)
 add_executable(rope.test rope.c)
-target_link_libraries(rope.test salad)
+target_link_libraries(rope.test salad unit)
 add_executable(int96.test int96.cc)
+target_link_libraries(int96.test unit)
 add_executable(bit.test bit.c bit.c)
-target_link_libraries(bit.test bit)
+target_link_libraries(bit.test bit unit)
 add_executable(bitset_basic.test bitset_basic.c)
-target_link_libraries(bitset_basic.test bitset)
+target_link_libraries(bitset_basic.test bitset unit)
 add_executable(bitset_iterator.test bitset_iterator.c)
-target_link_libraries(bitset_iterator.test bitset)
+target_link_libraries(bitset_iterator.test bitset unit)
 add_executable(bitset_index.test bitset_index.c)
-target_link_libraries(bitset_index.test bitset)
+target_link_libraries(bitset_index.test bitset unit)
 add_executable(base64.test base64.c)
 target_link_libraries(base64.test misc unit)
 add_executable(uuid.test uuid.c)
 target_link_libraries(uuid.test uuid unit)
 
 add_executable(bps_tree.test bps_tree.cc)
-target_link_libraries(bps_tree.test small misc)
+target_link_libraries(bps_tree.test small misc unit)
 add_executable(bps_tree_iterator.test bps_tree_iterator.cc)
-target_link_libraries(bps_tree_iterator.test small misc)
+target_link_libraries(bps_tree_iterator.test small misc unit)
 add_executable(rtree.test rtree.cc)
-target_link_libraries(rtree.test salad small)
+target_link_libraries(rtree.test salad small unit)
 add_executable(rtree_iterator.test rtree_iterator.cc)
-target_link_libraries(rtree_iterator.test salad small)
+target_link_libraries(rtree_iterator.test salad small unit)
 add_executable(rtree_multidim.test rtree_multidim.cc)
-target_link_libraries(rtree_multidim.test salad small)
+target_link_libraries(rtree_multidim.test salad small unit)
 add_executable(light.test light.cc)
-target_link_libraries(light.test small)
+target_link_libraries(light.test small unit)
 add_executable(bloom.test bloom.cc)
-target_link_libraries(bloom.test salad)
+target_link_libraries(bloom.test salad unit)
 add_executable(vclock.test vclock.cc)
 target_link_libraries(vclock.test vclock unit)
 add_executable(xrow.test xrow.cc)
@@ -87,19 +89,19 @@ if (NOT ENABLE_GCOV)
 endif ()
 
 add_executable(fiber_stress.test fiber_stress.cc)
-target_link_libraries(fiber_stress.test core)
+target_link_libraries(fiber_stress.test core unit)
 
 add_executable(fiber_cond.test fiber_cond.c unit.c)
-target_link_libraries(fiber_cond.test core)
+target_link_libraries(fiber_cond.test core unit)
 
 add_executable(fiber_channel.test fiber_channel.cc unit.c)
-target_link_libraries(fiber_channel.test core)
+target_link_libraries(fiber_channel.test core unit)
 
 add_executable(fiber_channel_stress.test fiber_channel_stress.cc)
-target_link_libraries(fiber_channel_stress.test core)
+target_link_libraries(fiber_channel_stress.test core unit)
 
 add_executable(cbus_stress.test cbus_stress.c)
-target_link_libraries(cbus_stress.test core stat)
+target_link_libraries(cbus_stress.test core stat unit)
 
 add_executable(cbus.test cbus.c)
 target_link_libraries(cbus.test core unit stat)
@@ -129,21 +131,22 @@ if (ENABLE_BUNDLED_MSGPUCK)
 endif ()
 
 add_executable(scramble.test scramble.c)
-target_link_libraries(scramble.test scramble)
+target_link_libraries(scramble.test scramble unit)
 
 add_executable(guava.test guava.c)
-target_link_libraries(guava.test salad small)
+target_link_libraries(guava.test salad small unit)
 
 add_executable(find_path.test find_path.c
     ${CMAKE_SOURCE_DIR}/src/find_path.c
 )
+target_link_libraries(find_path.test unit)
 
 add_executable(reflection_c.test reflection_c.c unit.c
     ${CMAKE_SOURCE_DIR}/src/lib/core/reflection.c)
 add_executable(reflection_cxx.test reflection_cxx.cc unit.c
     ${CMAKE_SOURCE_DIR}/src/lib/core/reflection.c)
 add_executable(csv.test csv.c)
-target_link_libraries(csv.test csv)
+target_link_libraries(csv.test csv unit)
 
 add_executable(json.test json.c)
 target_link_libraries(json.test json unit ${ICU_LIBRARIES})
diff --git a/test/unit/unit.c b/test/unit/unit.c
index d12b66f91..302dce2ef 100644
--- a/test/unit/unit.c
+++ b/test/unit/unit.c
@@ -26,6 +26,9 @@ plan(int count)
 	tests_done[level] = 0;
 	tests_failed[level] = 0;
 
+	if (level == 0)
+		printf("TAP version 13\n");
+
 	_space(stdout);
 	printf("%d..%d\n", 1, plan_test[level]);
 }
diff --git a/test/unit/unit.h b/test/unit/unit.h
index 43c301b28..27879ea98 100644
--- a/test/unit/unit.h
+++ b/test/unit/unit.h
@@ -33,9 +33,6 @@
 #include <stdio.h>
 #include <stdlib.h> /* exit() */
 
-#define header() printf("\t*** %s ***\n", __func__)
-#define footer() printf("\t*** %s: done ***\n", __func__)
-
 #define fail(expr, result) do {					\
 	fprintf(stderr, "Test failed: %s is %s at %s:%d, in function '%s'\n",\
 		expr, result, __FILE__, __LINE__, __func__);		\
@@ -129,6 +126,16 @@ int check_plan(void);
 	}						\
 }
 
+#define header() do {				\
+	_space(stdout);				\
+	printf("# *** %s ***\n", __func__);	\
+} while(0)
+
+#define footer() do {					\
+	_space(stdout);					\
+	printf("# *** %s: done ***\n", __func__);	\
+} while(0)
+
 #if defined(__cplusplus)
 }
 #endif /* defined(__cplusplus) */
-- 
2.23.0

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Tarantool-patches] [PATCH 2/2] test: update unit tests to make them TAP-compliant
  2020-05-21  9:59 [Tarantool-patches] [PATCH 0/2] Make unit tests TAP-compliant sergeyb
  2020-05-21  9:59 ` [Tarantool-patches] [PATCH 1/2] test: update unit test lib to produce TAP-compliant output sergeyb
@ 2020-05-21  9:59 ` sergeyb
  2020-06-02  9:20   ` Sergey Bronnikov
  2020-06-03 22:52   ` Vladislav Shpilevoy
  2020-06-02  9:21 ` [Tarantool-patches] [PATCH 0/2] Make unit tests TAP-compliant Sergey Bronnikov
  2020-06-03 22:52 ` Vladislav Shpilevoy
  3 siblings, 2 replies; 12+ messages in thread
From: sergeyb @ 2020-05-21  9:59 UTC (permalink / raw)
  To: tarantool-patches; +Cc: o.piskunov, alexander.turenko

From: Sergey Bronnikov <sergeyb@tarantool.org>

Closes #5000
---
 test/unit/base64.result               |  178 --
 test/unit/bit.c                       |   75 +-
 test/unit/bit.result                  |  895 ----------
 test/unit/bitset_basic.c              |   38 +-
 test/unit/bitset_basic.result         |   12 -
 test/unit/bitset_index.c              |   42 +-
 test/unit/bitset_index.result         |   21 -
 test/unit/bitset_iterator.c           |   32 +
 test/unit/bitset_iterator.result      |   22 -
 test/unit/bloom.cc                    |   20 +-
 test/unit/bloom.result                |    6 -
 test/unit/bps_tree.cc                 |   80 +-
 test/unit/bps_tree.result             |  284 ---
 test/unit/bps_tree_iterator.cc        |   42 +-
 test/unit/bps_tree_iterator.result    |   21 -
 test/unit/cbus.c                      |   20 +-
 test/unit/cbus.result                 |   24 -
 test/unit/cbus_hang.c                 |    2 +-
 test/unit/cbus_hang.result            |    4 -
 test/unit/cbus_stress.c               |   53 +-
 test/unit/cbus_stress.result          |    2 -
 test/unit/checkpoint_schedule.result  |   41 -
 test/unit/coio.result                 |   12 -
 test/unit/coll.cpp                    |   51 +-
 test/unit/coll.result                 |   90 -
 test/unit/column_mask.result          |   36 -
 test/unit/crypto.result               |  132 --
 test/unit/csv.result                  |   80 +-
 test/unit/decimal.result              |  700 --------
 test/unit/fiber.cc                    |   21 +-
 test/unit/fiber.result                |   19 -
 test/unit/fiber_channel.cc            |    2 +
 test/unit/fiber_channel.result        |   23 -
 test/unit/fiber_channel_stress.cc     |    3 +
 test/unit/fiber_channel_stress.result |    2 -
 test/unit/fiber_cond.result           |    8 -
 test/unit/fiber_stack.c               |    3 +
 test/unit/fiber_stack.result          |   11 -
 test/unit/fiber_stress.cc             |    4 +
 test/unit/fiber_stress.result         |    0
 test/unit/find_path.c                 |    3 +
 test/unit/find_path.result            |    2 -
 test/unit/guard.cc                    |    3 +-
 test/unit/guard.result                |    1 -
 test/unit/guava.c                     |   11 +
 test/unit/guava.result                |    6 -
 test/unit/heap.c                      |   38 +
 test/unit/heap.result                 |   24 -
 test/unit/heap_iterator.c             |   14 +
 test/unit/heap_iterator.result        |    8 -
 test/unit/histogram.c                 |   11 +
 test/unit/histogram.result            |    6 -
 test/unit/int96.cc                    |   51 +-
 test/unit/int96.result                |    2 -
 test/unit/json.result                 |  208 ---
 test/unit/light.cc                    |   16 +-
 test/unit/light.result                |    8 -
 test/unit/luaL_iterator.result        |   89 -
 test/unit/luaT_tuple_new.result       |   22 -
 test/unit/merger.result               |   71 -
 test/unit/mhash.result                |   18 -
 test/unit/mhash_bytemap.result        |   18 -
 test/unit/mp_error.result             |   44 -
 test/unit/msgpack.result              | 2282 -------------------------
 test/unit/popen.result                |   30 -
 test/unit/queue.c                     |   65 +-
 test/unit/queue.result                |   34 -
 test/unit/ratelimit.result            |   13 -
 test/unit/reflection_c.result         |    5 -
 test/unit/reflection_cxx.result       |   31 -
 test/unit/rmean.cc                    |   19 +-
 test/unit/rmean.result                |   11 -
 test/unit/rope.c                      |   10 +-
 test/unit/rope.result                 |  299 ----
 test/unit/rope_avl.c                  |    5 +
 test/unit/rope_avl.result             |  123 --
 test/unit/rope_basic.c                |   19 +-
 test/unit/rope_basic.result           |  139 --
 test/unit/rope_common.h               |   11 +-
 test/unit/rope_stress.c               |    8 +
 test/unit/rope_stress.result          |    4 -
 test/unit/rtree.cc                    |   20 +-
 test/unit/rtree.result                |    8 -
 test/unit/rtree_iterator.cc           |   24 +-
 test/unit/rtree_iterator.result       |    7 -
 test/unit/rtree_multidim.cc           |   30 +-
 test/unit/rtree_multidim.result       |   15 -
 test/unit/say.result                  |   67 -
 test/unit/scramble.c                  |   21 +-
 test/unit/scramble.result             |    4 -
 test/unit/sio.result                  |   36 -
 test/unit/stailq.result               |   76 -
 test/unit/swim.result                 |  234 ---
 test/unit/swim_errinj.result          |   18 -
 test/unit/swim_proto.result           |   40 -
 test/unit/tuple_bigref.result         |   17 -
 test/unit/uri.result                  | 1307 --------------
 test/unit/uuid.result                 |    9 -
 test/unit/vclock.result               |  149 --
 test/unit/vy_cache.result             |    9 -
 test/unit/vy_mem.c                    |    4 +-
 test/unit/vy_mem.result               |   17 -
 test/unit/vy_point_lookup.result      |   20 -
 test/unit/vy_write_iterator.result    |   61 -
 test/unit/xrow.result                 |   58 -
 105 files changed, 649 insertions(+), 8495 deletions(-)
 delete mode 100644 test/unit/base64.result
 delete mode 100644 test/unit/bit.result
 delete mode 100644 test/unit/bitset_basic.result
 delete mode 100644 test/unit/bitset_index.result
 delete mode 100644 test/unit/bitset_iterator.result
 delete mode 100644 test/unit/bloom.result
 delete mode 100644 test/unit/bps_tree.result
 delete mode 100644 test/unit/bps_tree_iterator.result
 delete mode 100644 test/unit/cbus.result
 delete mode 100644 test/unit/cbus_hang.result
 delete mode 100644 test/unit/cbus_stress.result
 delete mode 100644 test/unit/checkpoint_schedule.result
 delete mode 100644 test/unit/coio.result
 delete mode 100644 test/unit/coll.result
 delete mode 100644 test/unit/column_mask.result
 delete mode 100644 test/unit/crypto.result
 delete mode 100644 test/unit/decimal.result
 delete mode 100644 test/unit/fiber.result
 delete mode 100644 test/unit/fiber_channel.result
 delete mode 100644 test/unit/fiber_channel_stress.result
 delete mode 100644 test/unit/fiber_cond.result
 delete mode 100644 test/unit/fiber_stack.result
 delete mode 100644 test/unit/fiber_stress.result
 delete mode 100644 test/unit/find_path.result
 delete mode 100644 test/unit/guard.result
 delete mode 100644 test/unit/guava.result
 delete mode 100644 test/unit/heap.result
 delete mode 100644 test/unit/heap_iterator.result
 delete mode 100644 test/unit/histogram.result
 delete mode 100644 test/unit/int96.result
 delete mode 100644 test/unit/json.result
 delete mode 100644 test/unit/light.result
 delete mode 100644 test/unit/luaL_iterator.result
 delete mode 100644 test/unit/luaT_tuple_new.result
 delete mode 100644 test/unit/merger.result
 delete mode 100644 test/unit/mhash.result
 delete mode 100644 test/unit/mhash_bytemap.result
 delete mode 100644 test/unit/mp_error.result
 delete mode 100644 test/unit/msgpack.result
 delete mode 100644 test/unit/popen.result
 delete mode 100644 test/unit/queue.result
 delete mode 100644 test/unit/ratelimit.result
 delete mode 100644 test/unit/reflection_c.result
 delete mode 100644 test/unit/reflection_cxx.result
 delete mode 100644 test/unit/rmean.result
 delete mode 100644 test/unit/rope.result
 delete mode 100644 test/unit/rope_avl.result
 delete mode 100644 test/unit/rope_basic.result
 delete mode 100644 test/unit/rope_stress.result
 delete mode 100644 test/unit/rtree.result
 delete mode 100644 test/unit/rtree_iterator.result
 delete mode 100644 test/unit/rtree_multidim.result
 delete mode 100644 test/unit/say.result
 delete mode 100644 test/unit/scramble.result
 delete mode 100644 test/unit/sio.result
 delete mode 100644 test/unit/stailq.result
 delete mode 100644 test/unit/swim.result
 delete mode 100644 test/unit/swim_errinj.result
 delete mode 100644 test/unit/swim_proto.result
 delete mode 100644 test/unit/tuple_bigref.result
 delete mode 100644 test/unit/uri.result
 delete mode 100644 test/unit/uuid.result
 delete mode 100644 test/unit/vclock.result
 delete mode 100644 test/unit/vy_cache.result
 delete mode 100644 test/unit/vy_mem.result
 delete mode 100644 test/unit/vy_point_lookup.result
 delete mode 100644 test/unit/vy_write_iterator.result
 delete mode 100644 test/unit/xrow.result

diff --git a/test/unit/base64.result b/test/unit/base64.result
deleted file mode 100644
index cd1f2b3f6..000000000
--- a/test/unit/base64.result
+++ /dev/null
@@ -1,178 +0,0 @@
-1..28
-	*** main ***
-    1..3
-    ok 1 - length
-    ok 2 - decode length ok
-    ok 3 - encode/decode
-ok 1 - subtests
-    1..6
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - no + symbols
-    ok 4 - no = symbols
-    ok 5 - decode length ok
-    ok 6 - encode/decode
-ok 2 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no = symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 3 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 4 - subtests
-    1..3
-    ok 1 - length
-    ok 2 - decode length ok
-    ok 3 - encode/decode
-ok 5 - subtests
-    1..6
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - no + symbols
-    ok 4 - no = symbols
-    ok 5 - decode length ok
-    ok 6 - encode/decode
-ok 6 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no = symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 7 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 8 - subtests
-    1..3
-    ok 1 - length
-    ok 2 - decode length ok
-    ok 3 - encode/decode
-ok 9 - subtests
-    1..6
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - no + symbols
-    ok 4 - no = symbols
-    ok 5 - decode length ok
-    ok 6 - encode/decode
-ok 10 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no = symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 11 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 12 - subtests
-    1..3
-    ok 1 - length
-    ok 2 - decode length ok
-    ok 3 - encode/decode
-ok 13 - subtests
-    1..6
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - no + symbols
-    ok 4 - no = symbols
-    ok 5 - decode length ok
-    ok 6 - encode/decode
-ok 14 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no = symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 15 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 16 - subtests
-    1..3
-    ok 1 - length
-    ok 2 - decode length ok
-    ok 3 - encode/decode
-ok 17 - subtests
-    1..6
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - no + symbols
-    ok 4 - no = symbols
-    ok 5 - decode length ok
-    ok 6 - encode/decode
-ok 18 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no = symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 19 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 20 - subtests
-    1..3
-    ok 1 - length
-    ok 2 - decode length ok
-    ok 3 - encode/decode
-ok 21 - subtests
-    1..6
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - no + symbols
-    ok 4 - no = symbols
-    ok 5 - decode length ok
-    ok 6 - encode/decode
-ok 22 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no = symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 23 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 24 - subtests
-    1..3
-    ok 1 - length
-    ok 2 - decode length ok
-    ok 3 - encode/decode
-ok 25 - subtests
-    1..6
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - no + symbols
-    ok 4 - no = symbols
-    ok 5 - decode length ok
-    ok 6 - encode/decode
-ok 26 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no = symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 27 - subtests
-    1..4
-    ok 1 - length
-    ok 2 - no \n symbols
-    ok 3 - decode length ok
-    ok 4 - encode/decode
-ok 28 - subtests
-	*** main: done ***
diff --git a/test/unit/bit.c b/test/unit/bit.c
index da514484d..d18aa5579 100644
--- a/test/unit/bit.c
+++ b/test/unit/bit.c
@@ -2,7 +2,6 @@
 
 #include <stdio.h>
 #include <inttypes.h>
-#include <assert.h>
 #include <stdlib.h>
 
 #include "unit.h"
@@ -21,6 +20,7 @@ static void
 test_ctz_clz(void)
 {
 	header();
+	plan(1);
 
 	for (size_t i = 0; i < sizeof(vals) / sizeof(vals[0]); i++) {
 		if (vals[i] == 0)
@@ -29,20 +29,22 @@ test_ctz_clz(void)
 		uint64_t val64 = vals[i];
 		uint32_t val32 = (uint32_t) vals[i];
 
-		printf("bit_ctz_u64(%" PRIu64 ") => %d\n", val64,
+		note("bit_ctz_u64(%" PRIu64 ") => %d", val64,
 			bit_ctz_u64(val64));
-		printf("bit_clz_u64(%" PRIu64 ") => %d\n", val64,
+		note("bit_clz_u64(%" PRIu64 ") => %d", val64,
 			bit_clz_u64(val64));
 
 		if (vals[i] > UINT32_MAX)
 			continue;
 
-		printf("bit_ctz_u32(%" PRIu32 ") => %d\n", val32,
+		note("bit_ctz_u32(%" PRIu32 ") => %d", val32,
 			bit_ctz_u32(val32));
-		printf("bit_clz_u32(%" PRIu32 ") => %d\n", val32,
+		note("bit_clz_u32(%" PRIu32 ") => %d", val32,
 			bit_clz_u32(val32));
 	}
 
+	ok(1, "test ctz clz");
+	check_plan();
 	footer();
 }
 
@@ -50,21 +52,24 @@ static void
 test_count(void)
 {
 	header();
+	plan(1);
 
 	for (size_t i = 0; i < sizeof(vals) / sizeof(vals[0]); i++) {
 		uint64_t val64 = vals[i];
 		uint32_t val32 = (uint32_t) vals[i];
 
-		printf("bit_count_u64(%" PRIu64 ") => %d\n", val64,
+		note("bit_count_u64(%" PRIu64 ") => %d", val64,
 			bit_count_u64(val64));
 
 		if (vals[i] > UINT32_MAX)
 			continue;
 
-		printf("bit_count_u32(%" PRIu32 ") => %d\n", val32,
+		note("bit_count_u32(%" PRIu32 ") => %d", val32,
 			bit_count_u32(val32));
 	}
 
+	ok(1, "test count");
+	check_plan();
 	footer();
 }
 
@@ -75,17 +80,17 @@ test_rotl_rotr_one(int rot)
 		uint64_t val64 = vals[i];
 		uint32_t val32 = (uint32_t) vals[i];
 
-		printf("bit_rotl_u64(%" PRIu64 ", %d) => %" PRIu64 "\n",
+		note("bit_rotl_u64(%" PRIu64 ", %d) => %" PRIu64,
 		       val64, rot, bit_rotl_u64(val64, rot));
-		printf("bit_rotr_u64(%" PRIu64 ", %d) => %" PRIu64 "\n",
+		note("bit_rotr_u64(%" PRIu64 ", %d) => %" PRIu64,
 		       val64, rot, bit_rotr_u64(val64, rot));
 
 		if (vals[i] > UINT32_MAX || rot > 32)
 			continue;
 
-		printf("bit_rotl_u32(%" PRIu32 ", %d) => %" PRIu32 "\n",
+		note("bit_rotl_u32(%" PRIu32 ", %d) => %" PRIu32,
 		       val32, rot, bit_rotl_u32(val32, rot));
-		printf("bit_rotr_u32(%" PRIu32 ", %d) => %" PRIu32 "\n",
+		note("bit_rotr_u32(%" PRIu32 ", %d) => %" PRIu32,
 		       val32, rot, bit_rotr_u32(val32, rot));
 	}
 }
@@ -94,12 +99,15 @@ static void
 test_rotl_rotr(void)
 {
 	header();
+	plan(1);
 
 	int rots[] = { 0, 1, 15, 16, 31, 32, 63, 64 };
 	for (unsigned r = 0; r < sizeof(rots) / sizeof(rots[0]); r++) {
 		test_rotl_rotr_one(rots[r]);
 	}
 
+	ok(1, "test rotl rotr");
+	check_plan();
 	footer();
 }
 
@@ -107,36 +115,42 @@ static void
 test_bswap(void)
 {
 	header();
+	plan(1);
 
 	for (size_t i = 0; i < sizeof(vals) / sizeof(vals[0]); i++) {
 		uint64_t val64 = vals[i];
 		uint32_t val32 = (uint32_t) vals[i];
 
-		printf("bswap_u64(%" PRIu64 ") => %" PRIu64 "\n", val64,
+		note("bswap_u64(%" PRIu64 ") => %" PRIu64, val64,
 			bswap_u64(val64));
 
 		if (vals[i] > UINT32_MAX)
 			continue;
 
-		printf("bswap_u32(%" PRIu32 ") => %" PRIu32 "\n", val32,
+		note("bswap_u32(%" PRIu32 ") => %" PRIu32, val32,
 			bswap_u32(val32));
 	}
 
+	ok(1, "test bswap");
+	check_plan();
 	footer();
 }
 
 static inline void
 test_index_print(const int *start, const int *end)
 {
+	/*
 	for (const int *cur = start; cur < end; cur++) {
 		printf("%d ", *cur);
 	}
+	*/
 }
 
 static void
 test_index(void)
 {
 	header();
+	plan(1);
 
 	int indexes[sizeof(int64_t) * CHAR_BIT + 1];
 
@@ -144,18 +158,20 @@ test_index(void)
 		uint64_t val64 = vals[i];
 		uint32_t val32 = (uint32_t) vals[i];
 
-		printf("bit_index_u64(%" PRIu64 ", *, -1) => ", val64);
+		//printf("bit_index_u64(%" PRIu64 ", *, -1) => ", val64);
 		test_index_print(indexes, bit_index_u64(val64, indexes, -1));
-		printf("\n");
+		//printf("\n");
 
 		if (vals[i] > UINT32_MAX)
 			continue;
 
-		printf("bit_index_u32(%" PRIu32 ", *, -1) => ", val32);
+		//printf("bit_index_u32(%" PRIu32 ", *, -1) => ", val32);
 		test_index_print(indexes, bit_index_u32(val32, indexes, -1));
-		printf("\n");
+		//printf("\n");
 	}
 
+	ok(1, "test index");
+	check_plan();
 	footer();
 }
 
@@ -164,6 +180,7 @@ static void
 test_bit_iter(void)
 {
 	header();
+	plan(1);
 
 	struct bit_iterator it;
 	uint64_t *data = vals + 6;
@@ -171,22 +188,24 @@ test_bit_iter(void)
 
 	size_t pos = 0;
 
-	printf("Set: ");
+	note("Set: ");
 	bit_iterator_init(&it, data, size, true);
 	while ( (pos = bit_iterator_next(&it)) != SIZE_MAX) {
-		printf("%zu, ", pos);
+		//printf("%zu, ", pos);
 		fail_unless(bit_test(data, pos));
 	}
-	printf("\n");
+	//printf("\n");
 
-	printf("Clear: ");
+	note("Clear: ");
 	bit_iterator_init(&it, data, size, false);
 	while ( (pos = bit_iterator_next(&it)) != SIZE_MAX) {
-		printf("%zu, ", pos);
+		//printf("%zu, ", pos);
 		fail_if(bit_test(data, pos));
 	}
-	printf("\n");
+	//printf("\n");
 
+	ok(1, "test bit iter");
+	check_plan();
 	footer();
 }
 
@@ -194,6 +213,7 @@ static void
 test_bit_iter_empty(void)
 {
 	header();
+	plan(1);
 
 	struct bit_iterator it;
 
@@ -202,7 +222,9 @@ test_bit_iter_empty(void)
 
 	bit_iterator_init(&it, NULL, 0, false);
 	fail_unless(bit_iterator_next(&it) == SIZE_MAX);
-
+	
+	ok(1, "test bit iter empty");
+	check_plan();
 	footer();
 }
 
@@ -210,6 +232,7 @@ static void
 test_bitmap_size(void)
 {
 	header();
+	plan(1);
 	fail_unless(bitmap_size(1) == sizeof(long));
 	fail_unless(bitmap_size(10) == sizeof(long));
 	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT) == sizeof(long));
@@ -217,12 +240,15 @@ test_bitmap_size(void)
 	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT * 4) == sizeof(long) * 4);
 	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT * 4 - 1) == sizeof(long) * 4);
 	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT * 9 / 2) == sizeof(long) * 5);
+	ok(1, "test bitmap size");
+	check_plan();
 	footer();
 }
 
 int
 main(void)
 {
+	plan(8);
 	test_ctz_clz();
 	test_count();
 	test_rotl_rotr();
@@ -231,4 +257,5 @@ main(void)
 	test_bit_iter();
 	test_bit_iter_empty();
 	test_bitmap_size();
+	check_plan();
 }
diff --git a/test/unit/bit.result b/test/unit/bit.result
deleted file mode 100644
index 2d4ccc6f4..000000000
--- a/test/unit/bit.result
+++ /dev/null
@@ -1,895 +0,0 @@
-	*** test_ctz_clz ***
-bit_ctz_u64(1) => 0
-bit_clz_u64(1) => 63
-bit_ctz_u32(1) => 0
-bit_clz_u32(1) => 31
-bit_ctz_u64(2) => 1
-bit_clz_u64(2) => 62
-bit_ctz_u32(2) => 1
-bit_clz_u32(2) => 30
-bit_ctz_u64(32768) => 15
-bit_clz_u64(32768) => 48
-bit_ctz_u32(32768) => 15
-bit_clz_u32(32768) => 16
-bit_ctz_u64(65535) => 0
-bit_clz_u64(65535) => 48
-bit_ctz_u32(65535) => 0
-bit_clz_u32(65535) => 16
-bit_ctz_u64(65536) => 16
-bit_clz_u64(65536) => 47
-bit_ctz_u32(65536) => 16
-bit_clz_u32(65536) => 15
-bit_ctz_u64(726075912) => 3
-bit_clz_u64(726075912) => 34
-bit_ctz_u32(726075912) => 3
-bit_clz_u32(726075912) => 2
-bit_ctz_u64(858993459) => 0
-bit_clz_u64(858993459) => 34
-bit_ctz_u32(858993459) => 0
-bit_clz_u32(858993459) => 2
-bit_ctz_u64(1073741824) => 30
-bit_clz_u64(1073741824) => 33
-bit_ctz_u32(1073741824) => 30
-bit_clz_u32(1073741824) => 1
-bit_ctz_u64(1245250552) => 3
-bit_clz_u64(1245250552) => 33
-bit_ctz_u32(1245250552) => 3
-bit_clz_u32(1245250552) => 1
-bit_ctz_u64(1431655765) => 0
-bit_clz_u64(1431655765) => 33
-bit_ctz_u32(1431655765) => 0
-bit_clz_u32(1431655765) => 1
-bit_ctz_u64(1656977767) => 0
-bit_clz_u64(1656977767) => 33
-bit_ctz_u32(1656977767) => 0
-bit_clz_u32(1656977767) => 1
-bit_ctz_u64(2147483648) => 31
-bit_clz_u64(2147483648) => 32
-bit_ctz_u32(2147483648) => 31
-bit_clz_u32(2147483648) => 0
-bit_ctz_u64(2283114629) => 0
-bit_clz_u64(2283114629) => 32
-bit_ctz_u32(2283114629) => 0
-bit_clz_u32(2283114629) => 0
-bit_ctz_u64(2502548245) => 0
-bit_clz_u64(2502548245) => 32
-bit_ctz_u32(2502548245) => 0
-bit_clz_u32(2502548245) => 0
-bit_ctz_u64(4294967295) => 0
-bit_clz_u64(4294967295) => 32
-bit_ctz_u32(4294967295) => 0
-bit_clz_u32(4294967295) => 0
-bit_ctz_u64(708915120906848425) => 0
-bit_clz_u64(708915120906848425) => 4
-bit_ctz_u64(1960191741125985428) => 2
-bit_clz_u64(1960191741125985428) => 3
-bit_ctz_u64(3689348814741910323) => 0
-bit_clz_u64(3689348814741910323) => 2
-bit_ctz_u64(5578377670650038654) => 1
-bit_clz_u64(5578377670650038654) => 1
-bit_ctz_u64(9223372036854775808) => 63
-bit_clz_u64(9223372036854775808) => 0
-bit_ctz_u64(10755112315580060033) => 0
-bit_clz_u64(10755112315580060033) => 0
-bit_ctz_u64(11163782031541429823) => 0
-bit_clz_u64(11163782031541429823) => 0
-bit_ctz_u64(13903686156871869732) => 2
-bit_clz_u64(13903686156871869732) => 0
-bit_ctz_u64(14237897302422917095) => 0
-bit_clz_u64(14237897302422917095) => 0
-bit_ctz_u64(14302190498657618739) => 0
-bit_clz_u64(14302190498657618739) => 0
-bit_ctz_u64(15766411510232741269) => 0
-bit_clz_u64(15766411510232741269) => 0
-bit_ctz_u64(15984546468465238145) => 0
-bit_clz_u64(15984546468465238145) => 0
-bit_ctz_u64(18446744073709551615) => 0
-bit_clz_u64(18446744073709551615) => 0
-	*** test_ctz_clz: done ***
-	*** test_count ***
-bit_count_u64(0) => 0
-bit_count_u32(0) => 0
-bit_count_u64(1) => 1
-bit_count_u32(1) => 1
-bit_count_u64(2) => 1
-bit_count_u32(2) => 1
-bit_count_u64(32768) => 1
-bit_count_u32(32768) => 1
-bit_count_u64(65535) => 16
-bit_count_u32(65535) => 16
-bit_count_u64(65536) => 1
-bit_count_u32(65536) => 1
-bit_count_u64(726075912) => 11
-bit_count_u32(726075912) => 11
-bit_count_u64(858993459) => 16
-bit_count_u32(858993459) => 16
-bit_count_u64(1073741824) => 1
-bit_count_u32(1073741824) => 1
-bit_count_u64(1245250552) => 14
-bit_count_u32(1245250552) => 14
-bit_count_u64(1431655765) => 16
-bit_count_u32(1431655765) => 16
-bit_count_u64(1656977767) => 17
-bit_count_u32(1656977767) => 17
-bit_count_u64(2147483648) => 1
-bit_count_u32(2147483648) => 1
-bit_count_u64(2283114629) => 10
-bit_count_u32(2283114629) => 10
-bit_count_u64(2502548245) => 16
-bit_count_u32(2502548245) => 16
-bit_count_u64(4294967295) => 32
-bit_count_u32(4294967295) => 32
-bit_count_u64(708915120906848425) => 29
-bit_count_u64(1960191741125985428) => 19
-bit_count_u64(3689348814741910323) => 32
-bit_count_u64(5578377670650038654) => 31
-bit_count_u64(9223372036854775808) => 1
-bit_count_u64(10755112315580060033) => 24
-bit_count_u64(11163782031541429823) => 35
-bit_count_u64(13903686156871869732) => 28
-bit_count_u64(14237897302422917095) => 33
-bit_count_u64(14302190498657618739) => 37
-bit_count_u64(15766411510232741269) => 33
-bit_count_u64(15984546468465238145) => 25
-bit_count_u64(18446744073709551615) => 64
-	*** test_count: done ***
-	*** test_rotl_rotr ***
-bit_rotl_u64(0, 0) => 0
-bit_rotr_u64(0, 0) => 0
-bit_rotl_u32(0, 0) => 0
-bit_rotr_u32(0, 0) => 0
-bit_rotl_u64(1, 0) => 1
-bit_rotr_u64(1, 0) => 1
-bit_rotl_u32(1, 0) => 1
-bit_rotr_u32(1, 0) => 1
-bit_rotl_u64(2, 0) => 2
-bit_rotr_u64(2, 0) => 2
-bit_rotl_u32(2, 0) => 2
-bit_rotr_u32(2, 0) => 2
-bit_rotl_u64(32768, 0) => 32768
-bit_rotr_u64(32768, 0) => 32768
-bit_rotl_u32(32768, 0) => 32768
-bit_rotr_u32(32768, 0) => 32768
-bit_rotl_u64(65535, 0) => 65535
-bit_rotr_u64(65535, 0) => 65535
-bit_rotl_u32(65535, 0) => 65535
-bit_rotr_u32(65535, 0) => 65535
-bit_rotl_u64(65536, 0) => 65536
-bit_rotr_u64(65536, 0) => 65536
-bit_rotl_u32(65536, 0) => 65536
-bit_rotr_u32(65536, 0) => 65536
-bit_rotl_u64(726075912, 0) => 726075912
-bit_rotr_u64(726075912, 0) => 726075912
-bit_rotl_u32(726075912, 0) => 726075912
-bit_rotr_u32(726075912, 0) => 726075912
-bit_rotl_u64(858993459, 0) => 858993459
-bit_rotr_u64(858993459, 0) => 858993459
-bit_rotl_u32(858993459, 0) => 858993459
-bit_rotr_u32(858993459, 0) => 858993459
-bit_rotl_u64(1073741824, 0) => 1073741824
-bit_rotr_u64(1073741824, 0) => 1073741824
-bit_rotl_u32(1073741824, 0) => 1073741824
-bit_rotr_u32(1073741824, 0) => 1073741824
-bit_rotl_u64(1245250552, 0) => 1245250552
-bit_rotr_u64(1245250552, 0) => 1245250552
-bit_rotl_u32(1245250552, 0) => 1245250552
-bit_rotr_u32(1245250552, 0) => 1245250552
-bit_rotl_u64(1431655765, 0) => 1431655765
-bit_rotr_u64(1431655765, 0) => 1431655765
-bit_rotl_u32(1431655765, 0) => 1431655765
-bit_rotr_u32(1431655765, 0) => 1431655765
-bit_rotl_u64(1656977767, 0) => 1656977767
-bit_rotr_u64(1656977767, 0) => 1656977767
-bit_rotl_u32(1656977767, 0) => 1656977767
-bit_rotr_u32(1656977767, 0) => 1656977767
-bit_rotl_u64(2147483648, 0) => 2147483648
-bit_rotr_u64(2147483648, 0) => 2147483648
-bit_rotl_u32(2147483648, 0) => 2147483648
-bit_rotr_u32(2147483648, 0) => 2147483648
-bit_rotl_u64(2283114629, 0) => 2283114629
-bit_rotr_u64(2283114629, 0) => 2283114629
-bit_rotl_u32(2283114629, 0) => 2283114629
-bit_rotr_u32(2283114629, 0) => 2283114629
-bit_rotl_u64(2502548245, 0) => 2502548245
-bit_rotr_u64(2502548245, 0) => 2502548245
-bit_rotl_u32(2502548245, 0) => 2502548245
-bit_rotr_u32(2502548245, 0) => 2502548245
-bit_rotl_u64(4294967295, 0) => 4294967295
-bit_rotr_u64(4294967295, 0) => 4294967295
-bit_rotl_u32(4294967295, 0) => 4294967295
-bit_rotr_u32(4294967295, 0) => 4294967295
-bit_rotl_u64(708915120906848425, 0) => 708915120906848425
-bit_rotr_u64(708915120906848425, 0) => 708915120906848425
-bit_rotl_u64(1960191741125985428, 0) => 1960191741125985428
-bit_rotr_u64(1960191741125985428, 0) => 1960191741125985428
-bit_rotl_u64(3689348814741910323, 0) => 3689348814741910323
-bit_rotr_u64(3689348814741910323, 0) => 3689348814741910323
-bit_rotl_u64(5578377670650038654, 0) => 5578377670650038654
-bit_rotr_u64(5578377670650038654, 0) => 5578377670650038654
-bit_rotl_u64(9223372036854775808, 0) => 9223372036854775808
-bit_rotr_u64(9223372036854775808, 0) => 9223372036854775808
-bit_rotl_u64(10755112315580060033, 0) => 10755112315580060033
-bit_rotr_u64(10755112315580060033, 0) => 10755112315580060033
-bit_rotl_u64(11163782031541429823, 0) => 11163782031541429823
-bit_rotr_u64(11163782031541429823, 0) => 11163782031541429823
-bit_rotl_u64(13903686156871869732, 0) => 13903686156871869732
-bit_rotr_u64(13903686156871869732, 0) => 13903686156871869732
-bit_rotl_u64(14237897302422917095, 0) => 14237897302422917095
-bit_rotr_u64(14237897302422917095, 0) => 14237897302422917095
-bit_rotl_u64(14302190498657618739, 0) => 14302190498657618739
-bit_rotr_u64(14302190498657618739, 0) => 14302190498657618739
-bit_rotl_u64(15766411510232741269, 0) => 15766411510232741269
-bit_rotr_u64(15766411510232741269, 0) => 15766411510232741269
-bit_rotl_u64(15984546468465238145, 0) => 15984546468465238145
-bit_rotr_u64(15984546468465238145, 0) => 15984546468465238145
-bit_rotl_u64(18446744073709551615, 0) => 18446744073709551615
-bit_rotr_u64(18446744073709551615, 0) => 18446744073709551615
-bit_rotl_u64(0, 1) => 0
-bit_rotr_u64(0, 1) => 0
-bit_rotl_u32(0, 1) => 0
-bit_rotr_u32(0, 1) => 0
-bit_rotl_u64(1, 1) => 2
-bit_rotr_u64(1, 1) => 9223372036854775808
-bit_rotl_u32(1, 1) => 2
-bit_rotr_u32(1, 1) => 2147483648
-bit_rotl_u64(2, 1) => 4
-bit_rotr_u64(2, 1) => 1
-bit_rotl_u32(2, 1) => 4
-bit_rotr_u32(2, 1) => 1
-bit_rotl_u64(32768, 1) => 65536
-bit_rotr_u64(32768, 1) => 16384
-bit_rotl_u32(32768, 1) => 65536
-bit_rotr_u32(32768, 1) => 16384
-bit_rotl_u64(65535, 1) => 131070
-bit_rotr_u64(65535, 1) => 9223372036854808575
-bit_rotl_u32(65535, 1) => 131070
-bit_rotr_u32(65535, 1) => 2147516415
-bit_rotl_u64(65536, 1) => 131072
-bit_rotr_u64(65536, 1) => 32768
-bit_rotl_u32(65536, 1) => 131072
-bit_rotr_u32(65536, 1) => 32768
-bit_rotl_u64(726075912, 1) => 1452151824
-bit_rotr_u64(726075912, 1) => 363037956
-bit_rotl_u32(726075912, 1) => 1452151824
-bit_rotr_u32(726075912, 1) => 363037956
-bit_rotl_u64(858993459, 1) => 1717986918
-bit_rotr_u64(858993459, 1) => 9223372037284272537
-bit_rotl_u32(858993459, 1) => 1717986918
-bit_rotr_u32(858993459, 1) => 2576980377
-bit_rotl_u64(1073741824, 1) => 2147483648
-bit_rotr_u64(1073741824, 1) => 536870912
-bit_rotl_u32(1073741824, 1) => 2147483648
-bit_rotr_u32(1073741824, 1) => 536870912
-bit_rotl_u64(1245250552, 1) => 2490501104
-bit_rotr_u64(1245250552, 1) => 622625276
-bit_rotl_u32(1245250552, 1) => 2490501104
-bit_rotr_u32(1245250552, 1) => 622625276
-bit_rotl_u64(1431655765, 1) => 2863311530
-bit_rotr_u64(1431655765, 1) => 9223372037570603690
-bit_rotl_u32(1431655765, 1) => 2863311530
-bit_rotr_u32(1431655765, 1) => 2863311530
-bit_rotl_u64(1656977767, 1) => 3313955534
-bit_rotr_u64(1656977767, 1) => 9223372037683264691
-bit_rotl_u32(1656977767, 1) => 3313955534
-bit_rotr_u32(1656977767, 1) => 2975972531
-bit_rotl_u64(2147483648, 1) => 4294967296
-bit_rotr_u64(2147483648, 1) => 1073741824
-bit_rotl_u32(2147483648, 1) => 1
-bit_rotr_u32(2147483648, 1) => 1073741824
-bit_rotl_u64(2283114629, 1) => 4566229258
-bit_rotr_u64(2283114629, 1) => 9223372037996333122
-bit_rotl_u32(2283114629, 1) => 271261963
-bit_rotr_u32(2283114629, 1) => 3289040962
-bit_rotl_u64(2502548245, 1) => 5005096490
-bit_rotr_u64(2502548245, 1) => 9223372038106049930
-bit_rotl_u32(2502548245, 1) => 710129195
-bit_rotr_u32(2502548245, 1) => 3398757770
-bit_rotl_u64(4294967295, 1) => 8589934590
-bit_rotr_u64(4294967295, 1) => 9223372039002259455
-bit_rotl_u32(4294967295, 1) => 4294967295
-bit_rotr_u32(4294967295, 1) => 4294967295
-bit_rotl_u64(708915120906848425, 1) => 1417830241813696850
-bit_rotr_u64(708915120906848425, 1) => 9577829597308200020
-bit_rotl_u64(1960191741125985428, 1) => 3920383482251970856
-bit_rotr_u64(1960191741125985428, 1) => 980095870562992714
-bit_rotl_u64(3689348814741910323, 1) => 7378697629483820646
-bit_rotr_u64(3689348814741910323, 1) => 11068046444225730969
-bit_rotl_u64(5578377670650038654, 1) => 11156755341300077308
-bit_rotr_u64(5578377670650038654, 1) => 2789188835325019327
-bit_rotl_u64(9223372036854775808, 1) => 1
-bit_rotr_u64(9223372036854775808, 1) => 4611686018427387904
-bit_rotl_u64(10755112315580060033, 1) => 3063480557450568451
-bit_rotr_u64(10755112315580060033, 1) => 14600928194644805824
-bit_rotl_u64(11163782031541429823, 1) => 3880819989373308031
-bit_rotr_u64(11163782031541429823, 1) => 14805263052625490719
-bit_rotl_u64(13903686156871869732, 1) => 9360628240034187849
-bit_rotr_u64(13903686156871869732, 1) => 6951843078435934866
-bit_rotl_u64(14237897302422917095, 1) => 10029050531136282575
-bit_rotr_u64(14237897302422917095, 1) => 16342320688066234355
-bit_rotl_u64(14302190498657618739, 1) => 10157636923605685863
-bit_rotr_u64(14302190498657618739, 1) => 16374467286183585177
-bit_rotl_u64(15766411510232741269, 1) => 13086078946755930923
-bit_rotr_u64(15766411510232741269, 1) => 17106577791971146442
-bit_rotl_u64(15984546468465238145, 1) => 13522348863220924675
-bit_rotr_u64(15984546468465238145, 1) => 17215645271087394880
-bit_rotl_u64(18446744073709551615, 1) => 18446744073709551615
-bit_rotr_u64(18446744073709551615, 1) => 18446744073709551615
-bit_rotl_u64(0, 15) => 0
-bit_rotr_u64(0, 15) => 0
-bit_rotl_u32(0, 15) => 0
-bit_rotr_u32(0, 15) => 0
-bit_rotl_u64(1, 15) => 32768
-bit_rotr_u64(1, 15) => 562949953421312
-bit_rotl_u32(1, 15) => 32768
-bit_rotr_u32(1, 15) => 131072
-bit_rotl_u64(2, 15) => 65536
-bit_rotr_u64(2, 15) => 1125899906842624
-bit_rotl_u32(2, 15) => 65536
-bit_rotr_u32(2, 15) => 262144
-bit_rotl_u64(32768, 15) => 1073741824
-bit_rotr_u64(32768, 15) => 1
-bit_rotl_u32(32768, 15) => 1073741824
-bit_rotr_u32(32768, 15) => 1
-bit_rotl_u64(65535, 15) => 2147450880
-bit_rotr_u64(65535, 15) => 18446181123756130305
-bit_rotl_u32(65535, 15) => 2147450880
-bit_rotr_u32(65535, 15) => 4294836225
-bit_rotl_u64(65536, 15) => 2147483648
-bit_rotr_u64(65536, 15) => 2
-bit_rotl_u32(65536, 15) => 2147483648
-bit_rotr_u32(65536, 15) => 2
-bit_rotl_u64(726075912, 15) => 23792055484416
-bit_rotr_u64(726075912, 15) => 1445655480385951374
-bit_rotl_u32(726075912, 15) => 2231637411
-bit_rotr_u32(726075912, 15) => 336615054
-bit_rotl_u64(858993459, 15) => 28147497664512
-bit_rotr_u64(858993459, 15) => 7378585039493162598
-bit_rotl_u32(858993459, 15) => 2576980377
-bit_rotr_u32(858993459, 15) => 1717986918
-bit_rotl_u64(1073741824, 15) => 35184372088832
-bit_rotr_u64(1073741824, 15) => 32768
-bit_rotl_u32(1073741824, 15) => 8192
-bit_rotr_u32(1073741824, 15) => 32768
-bit_rotl_u64(1245250552, 15) => 40804370087936
-bit_rotr_u64(1245250552, 15) => 571957152676090994
-bit_rotl_u32(1245250552, 15) => 2180785436
-bit_rotr_u32(1245250552, 15) => 133207154
-bit_rotl_u64(1431655765, 15) => 46912496107520
-bit_rotr_u64(1431655765, 15) => 12297641732488604330
-bit_rotl_u32(1431655765, 15) => 2863311530
-bit_rotr_u32(1431655765, 15) => 2863311530
-bit_rotl_u64(1656977767, 15) => 54295847469056
-bit_rotr_u64(1656977767, 15) => 17495921602381006214
-bit_rotl_u32(1656977767, 15) => 3165892961
-bit_rotr_u32(1656977767, 15) => 4073637254
-bit_rotl_u64(2147483648, 15) => 70368744177664
-bit_rotr_u64(2147483648, 15) => 65536
-bit_rotl_u32(2147483648, 15) => 16384
-bit_rotr_u32(2147483648, 15) => 65536
-bit_rotl_u64(2283114629, 15) => 74813100163072
-bit_rotr_u64(2283114629, 15) => 2380715353018798123
-bit_rotl_u32(2283114629, 15) => 3359818762
-bit_rotr_u32(2283114629, 15) => 554373163
-bit_rotl_u64(2502548245, 15) => 82003500892160
-bit_rotr_u64(2502548245, 15) => 13126304063924808275
-bit_rotl_u32(2502548245, 15) => 3985296020
-bit_rotr_u32(2502548245, 15) => 3056282195
-bit_rotl_u64(4294967295, 15) => 140737488322560
-bit_rotr_u64(4294967295, 15) => 18446181123756261375
-bit_rotl_u32(4294967295, 15) => 4294967295
-bit_rotr_u32(4294967295, 15) => 4294967295
-bit_rotl_u64(708915120906848425, 15) => 5279893075283707115
-bit_rotr_u64(708915120906848425, 15) => 10471453717962410780
-bit_rotl_u64(1960191741125985428, 15) => 108559631781274
-bit_rotr_u64(1960191741125985428, 15) => 659837165714377456
-bit_rotl_u64(3689348814741910323, 15) => 11068046444225730969
-bit_rotr_u64(3689348814741910323, 15) => 7378697629483820646
-bit_rotl_u64(5578377670650038654, 15) => 3492485472519661237
-bit_rotr_u64(5578377670650038654, 15) => 1368138625390162978
-bit_rotl_u64(9223372036854775808, 15) => 16384
-bit_rotr_u64(9223372036854775808, 15) => 281474976710656
-bit_rotl_u64(10755112315580060033, 15) => 16921572780133108384
-bit_rotr_u64(10755112315580060033, 15) => 2522906961261232936
-bit_rotl_u64(11163782031541429823, 15) => 15874627889163914614
-bit_rotr_u64(11163782031541429823, 15) => 14735555722393159636
-bit_rotl_u64(13903686156871869732, 15) => 16749599972631142521
-bit_rotr_u64(13903686156871869732, 15) => 5352952463958352314
-bit_rotl_u64(14237897302422917095, 15) => 10814437605877473995
-bit_rotr_u64(14237897302422917095, 15) => 2292203766521423570
-bit_rotl_u64(14302190498657618739, 15) => 14645067421692060477
-bit_rotr_u64(14302190498657618739, 15) => 10837786021529578728
-bit_rotl_u64(15766411510232741269, 15) => 14257838996763372902
-bit_rotr_u64(15766411510232741269, 15) => 16945837700629926938
-bit_rotl_u64(15984546468465238145, 15) => 4767449759914979050
-bit_rotr_u64(15984546468465238145, 15) => 13908166408919157040
-bit_rotl_u64(18446744073709551615, 15) => 18446744073709551615
-bit_rotr_u64(18446744073709551615, 15) => 18446744073709551615
-bit_rotl_u64(0, 16) => 0
-bit_rotr_u64(0, 16) => 0
-bit_rotl_u32(0, 16) => 0
-bit_rotr_u32(0, 16) => 0
-bit_rotl_u64(1, 16) => 65536
-bit_rotr_u64(1, 16) => 281474976710656
-bit_rotl_u32(1, 16) => 65536
-bit_rotr_u32(1, 16) => 65536
-bit_rotl_u64(2, 16) => 131072
-bit_rotr_u64(2, 16) => 562949953421312
-bit_rotl_u32(2, 16) => 131072
-bit_rotr_u32(2, 16) => 131072
-bit_rotl_u64(32768, 16) => 2147483648
-bit_rotr_u64(32768, 16) => 9223372036854775808
-bit_rotl_u32(32768, 16) => 2147483648
-bit_rotr_u32(32768, 16) => 2147483648
-bit_rotl_u64(65535, 16) => 4294901760
-bit_rotr_u64(65535, 16) => 18446462598732840960
-bit_rotl_u32(65535, 16) => 4294901760
-bit_rotr_u32(65535, 16) => 4294901760
-bit_rotl_u64(65536, 16) => 4294967296
-bit_rotr_u64(65536, 16) => 1
-bit_rotl_u32(65536, 16) => 1
-bit_rotr_u32(65536, 16) => 1
-bit_rotl_u64(726075912, 16) => 47584110968832
-bit_rotr_u64(726075912, 16) => 722827740192975687
-bit_rotl_u32(726075912, 16) => 168307527
-bit_rotr_u32(726075912, 16) => 168307527
-bit_rotl_u64(858993459, 16) => 56294995329024
-bit_rotr_u64(858993459, 16) => 3689292519746581299
-bit_rotl_u32(858993459, 16) => 858993459
-bit_rotr_u32(858993459, 16) => 858993459
-bit_rotl_u64(1073741824, 16) => 70368744177664
-bit_rotr_u64(1073741824, 16) => 16384
-bit_rotl_u32(1073741824, 16) => 16384
-bit_rotr_u32(1073741824, 16) => 16384
-bit_rotl_u64(1245250552, 16) => 81608740175872
-bit_rotr_u64(1245250552, 16) => 285978576338045497
-bit_rotl_u32(1245250552, 16) => 66603577
-bit_rotr_u32(1245250552, 16) => 66603577
-bit_rotl_u64(1431655765, 16) => 93824992215040
-bit_rotr_u64(1431655765, 16) => 6148820866244302165
-bit_rotl_u32(1431655765, 16) => 1431655765
-bit_rotr_u32(1431655765, 16) => 1431655765
-bit_rotl_u64(1656977767, 16) => 108591694938112
-bit_rotr_u64(1656977767, 16) => 8747960801190503107
-bit_rotl_u32(1656977767, 16) => 2036818627
-bit_rotr_u32(1656977767, 16) => 2036818627
-bit_rotl_u64(2147483648, 16) => 140737488355328
-bit_rotr_u64(2147483648, 16) => 32768
-bit_rotl_u32(2147483648, 16) => 32768
-bit_rotr_u32(2147483648, 16) => 32768
-bit_rotl_u64(2283114629, 16) => 149626200326144
-bit_rotr_u64(2283114629, 16) => 10413729713364174869
-bit_rotl_u32(2283114629, 16) => 2424670229
-bit_rotr_u32(2283114629, 16) => 2424670229
-bit_rotl_u64(2502548245, 16) => 164007001784320
-bit_rotr_u64(2502548245, 16) => 15786524068817179945
-bit_rotl_u32(2502548245, 16) => 3675624745
-bit_rotr_u32(2502548245, 16) => 3675624745
-bit_rotl_u64(4294967295, 16) => 281474976645120
-bit_rotr_u64(4294967295, 16) => 18446462598732906495
-bit_rotl_u32(4294967295, 16) => 4294967295
-bit_rotr_u32(4294967295, 16) => 4294967295
-bit_rotl_u64(708915120906848425, 16) => 10559786150567414230
-bit_rotr_u64(708915120906848425, 16) => 5235726858981205390
-bit_rotl_u64(1960191741125985428, 16) => 217119263562548
-bit_rotr_u64(1960191741125985428, 16) => 329918582857188728
-bit_rotl_u64(3689348814741910323, 16) => 3689348814741910323
-bit_rotr_u64(3689348814741910323, 16) => 3689348814741910323
-bit_rotl_u64(5578377670650038654, 16) => 6984970945039322474
-bit_rotr_u64(5578377670650038654, 16) => 684069312695081489
-bit_rotl_u64(9223372036854775808, 16) => 32768
-bit_rotr_u64(9223372036854775808, 16) => 140737488355328
-bit_rotl_u64(10755112315580060033, 16) => 15396401486556665153
-bit_rotr_u64(10755112315580060033, 16) => 1261453480630616468
-bit_rotl_u64(11163782031541429823, 16) => 13302511704618277613
-bit_rotr_u64(11163782031541429823, 16) => 7367777861196579818
-bit_rotl_u64(13903686156871869732, 16) => 15052455871552733427
-bit_rotr_u64(13903686156871869732, 16) => 2676476231979176157
-bit_rotl_u64(14237897302422917095, 16) => 3182131138045396375
-bit_rotr_u64(14237897302422917095, 16) => 1146101883260711785
-bit_rotl_u64(14302190498657618739, 16) => 10843390769674569339
-bit_rotr_u64(14302190498657618739, 16) => 5418893010764789364
-bit_rotl_u64(15766411510232741269, 16) => 10068933919817194189
-bit_rotr_u64(15766411510232741269, 16) => 8472918850314963469
-bit_rotl_u64(15984546468465238145, 16) => 9534899519829958100
-bit_rotr_u64(15984546468465238145, 16) => 6954083204459578520
-bit_rotl_u64(18446744073709551615, 16) => 18446744073709551615
-bit_rotr_u64(18446744073709551615, 16) => 18446744073709551615
-bit_rotl_u64(0, 31) => 0
-bit_rotr_u64(0, 31) => 0
-bit_rotl_u32(0, 31) => 0
-bit_rotr_u32(0, 31) => 0
-bit_rotl_u64(1, 31) => 2147483648
-bit_rotr_u64(1, 31) => 8589934592
-bit_rotl_u32(1, 31) => 2147483648
-bit_rotr_u32(1, 31) => 2
-bit_rotl_u64(2, 31) => 4294967296
-bit_rotr_u64(2, 31) => 17179869184
-bit_rotl_u32(2, 31) => 1
-bit_rotr_u32(2, 31) => 4
-bit_rotl_u64(32768, 31) => 70368744177664
-bit_rotr_u64(32768, 31) => 281474976710656
-bit_rotl_u32(32768, 31) => 16384
-bit_rotr_u32(32768, 31) => 65536
-bit_rotl_u64(65535, 31) => 140735340871680
-bit_rotr_u64(65535, 31) => 562941363486720
-bit_rotl_u32(65535, 31) => 2147516415
-bit_rotr_u32(65535, 31) => 131070
-bit_rotl_u64(65536, 31) => 140737488355328
-bit_rotr_u64(65536, 31) => 562949953421312
-bit_rotl_u32(65536, 31) => 32768
-bit_rotr_u32(65536, 31) => 131072
-bit_rotl_u64(726075912, 31) => 1559236148226686976
-bit_rotr_u64(726075912, 31) => 6236944592906747904
-bit_rotl_u32(726075912, 31) => 363037956
-bit_rotr_u32(726075912, 31) => 1452151824
-bit_rotl_u64(858993459, 31) => 1844674406941458432
-bit_rotr_u64(858993459, 31) => 7378697627765833728
-bit_rotl_u32(858993459, 31) => 2576980377
-bit_rotr_u32(858993459, 31) => 1717986918
-bit_rotl_u64(1073741824, 31) => 2305843009213693952
-bit_rotr_u64(1073741824, 31) => 9223372036854775808
-bit_rotl_u32(1073741824, 31) => 536870912
-bit_rotr_u32(1073741824, 31) => 2147483648
-bit_rotl_u64(1245250552, 31) => 2674155198082973696
-bit_rotr_u64(1245250552, 31) => 10696620792331894784
-bit_rotl_u32(1245250552, 31) => 622625276
-bit_rotr_u32(1245250552, 31) => 2490501104
-bit_rotl_u64(1431655765, 31) => 3074457344902430720
-bit_rotr_u64(1431655765, 31) => 12297829379609722880
-bit_rotl_u32(1431655765, 31) => 2863311530
-bit_rotr_u32(1431655765, 31) => 2863311530
-bit_rotl_u64(1656977767, 31) => 3558332659732054016
-bit_rotr_u64(1656977767, 31) => 14233330638928216064
-bit_rotl_u32(1656977767, 31) => 2975972531
-bit_rotr_u32(1656977767, 31) => 3313955534
-bit_rotl_u64(2147483648, 31) => 4611686018427387904
-bit_rotr_u64(2147483648, 31) => 1
-bit_rotl_u32(2147483648, 31) => 1073741824
-bit_rotr_u32(2147483648, 31) => 1
-bit_rotl_u64(2283114629, 31) => 4902951332287086592
-bit_rotr_u64(2283114629, 31) => 1165061255438794753
-bit_rotl_u32(2283114629, 31) => 3289040962
-bit_rotr_u32(2283114629, 31) => 271261963
-bit_rotl_u64(2502548245, 31) => 5374181434468597760
-bit_rotr_u64(2502548245, 31) => 3049981664164839425
-bit_rotl_u32(2502548245, 31) => 3398757770
-bit_rotr_u32(2502548245, 31) => 710129195
-bit_rotl_u64(4294967295, 31) => 9223372034707292160
-bit_rotr_u64(4294967295, 31) => 18446744065119617025
-bit_rotl_u32(4294967295, 31) => 4294967295
-bit_rotr_u32(4294967295, 31) => 4294967295
-bit_rotl_u64(708915120906848425, 31) => 17493991222969846085
-bit_rotr_u64(708915120906848425, 31) => 14635732670750729495
-bit_rotl_u64(1960191741125985428, 31) => 7114564028417572864
-bit_rotr_u64(1960191741125985428, 31) => 10011512039960739841
-bit_rotl_u64(3689348814741910323, 31) => 11068046444225730969
-bit_rotr_u64(3689348814741910323, 31) => 7378697629483820646
-bit_rotl_u64(5578377670650038654, 31) => 14774204534111940727
-bit_rotr_u64(5578377670650038654, 31) => 3756585915319108063
-bit_rotl_u64(9223372036854775808, 31) => 1073741824
-bit_rotr_u64(9223372036854775808, 31) => 4294967296
-bit_rotl_u64(10755112315580060033, 31) => 9280239606276614869
-bit_rotr_u64(10755112315580060033, 31) => 227470277687356246
-bit_rotl_u64(11163782031541429823, 31) => 141075175016160334
-bit_rotr_u64(11163782031541429823, 31) => 564300700064641336
-bit_rotl_u64(13903686156871869732, 31) => 9830956193977854066
-bit_rotr_u64(13903686156871869732, 31) => 2430336628492313034
-bit_rotl_u64(14237897302422917095, 31) => 11075626865162688020
-bit_rotr_u64(14237897302422917095, 31) => 7409019313231648850
-bit_rotl_u64(14302190498657618739, 31) => 13491136976614443837
-bit_rotr_u64(14302190498657618739, 31) => 17071059759038672118
-bit_rotl_u64(15766411510232741269, 31) => 362182200778999262
-bit_rotr_u64(15766411510232741269, 31) => 1448728803115997048
-bit_rotl_u64(15984546468465238145, 31) => 7083089369391317545
-bit_rotr_u64(15984546468465238145, 31) => 9885613403855718565
-bit_rotl_u64(18446744073709551615, 31) => 18446744073709551615
-bit_rotr_u64(18446744073709551615, 31) => 18446744073709551615
-bit_rotl_u64(0, 32) => 0
-bit_rotr_u64(0, 32) => 0
-bit_rotl_u32(0, 32) => 0
-bit_rotr_u32(0, 32) => 0
-bit_rotl_u64(1, 32) => 4294967296
-bit_rotr_u64(1, 32) => 4294967296
-bit_rotl_u32(1, 32) => 1
-bit_rotr_u32(1, 32) => 1
-bit_rotl_u64(2, 32) => 8589934592
-bit_rotr_u64(2, 32) => 8589934592
-bit_rotl_u32(2, 32) => 2
-bit_rotr_u32(2, 32) => 2
-bit_rotl_u64(32768, 32) => 140737488355328
-bit_rotr_u64(32768, 32) => 140737488355328
-bit_rotl_u32(32768, 32) => 32768
-bit_rotr_u32(32768, 32) => 32768
-bit_rotl_u64(65535, 32) => 281470681743360
-bit_rotr_u64(65535, 32) => 281470681743360
-bit_rotl_u32(65535, 32) => 65535
-bit_rotr_u32(65535, 32) => 65535
-bit_rotl_u64(65536, 32) => 281474976710656
-bit_rotr_u64(65536, 32) => 281474976710656
-bit_rotl_u32(65536, 32) => 65536
-bit_rotr_u32(65536, 32) => 65536
-bit_rotl_u64(726075912, 32) => 3118472296453373952
-bit_rotr_u64(726075912, 32) => 3118472296453373952
-bit_rotl_u32(726075912, 32) => 726075912
-bit_rotr_u32(726075912, 32) => 726075912
-bit_rotl_u64(858993459, 32) => 3689348813882916864
-bit_rotr_u64(858993459, 32) => 3689348813882916864
-bit_rotl_u32(858993459, 32) => 858993459
-bit_rotr_u32(858993459, 32) => 858993459
-bit_rotl_u64(1073741824, 32) => 4611686018427387904
-bit_rotr_u64(1073741824, 32) => 4611686018427387904
-bit_rotl_u32(1073741824, 32) => 1073741824
-bit_rotr_u32(1073741824, 32) => 1073741824
-bit_rotl_u64(1245250552, 32) => 5348310396165947392
-bit_rotr_u64(1245250552, 32) => 5348310396165947392
-bit_rotl_u32(1245250552, 32) => 1245250552
-bit_rotr_u32(1245250552, 32) => 1245250552
-bit_rotl_u64(1431655765, 32) => 6148914689804861440
-bit_rotr_u64(1431655765, 32) => 6148914689804861440
-bit_rotl_u32(1431655765, 32) => 1431655765
-bit_rotr_u32(1431655765, 32) => 1431655765
-bit_rotl_u64(1656977767, 32) => 7116665319464108032
-bit_rotr_u64(1656977767, 32) => 7116665319464108032
-bit_rotl_u32(1656977767, 32) => 1656977767
-bit_rotr_u32(1656977767, 32) => 1656977767
-bit_rotl_u64(2147483648, 32) => 9223372036854775808
-bit_rotr_u64(2147483648, 32) => 9223372036854775808
-bit_rotl_u32(2147483648, 32) => 2147483648
-bit_rotr_u32(2147483648, 32) => 2147483648
-bit_rotl_u64(2283114629, 32) => 9805902664574173184
-bit_rotr_u64(2283114629, 32) => 9805902664574173184
-bit_rotl_u32(2283114629, 32) => 2283114629
-bit_rotr_u32(2283114629, 32) => 2283114629
-bit_rotl_u64(2502548245, 32) => 10748362868937195520
-bit_rotr_u64(2502548245, 32) => 10748362868937195520
-bit_rotl_u32(2502548245, 32) => 2502548245
-bit_rotr_u32(2502548245, 32) => 2502548245
-bit_rotl_u64(4294967295, 32) => 18446744069414584320
-bit_rotr_u64(4294967295, 32) => 18446744069414584320
-bit_rotl_u32(4294967295, 32) => 4294967295
-bit_rotr_u32(4294967295, 32) => 4294967295
-bit_rotl_u64(708915120906848425, 32) => 16541238372230140555
-bit_rotr_u64(708915120906848425, 32) => 16541238372230140555
-bit_rotl_u64(1960191741125985428, 32) => 14229128056835145728
-bit_rotr_u64(1960191741125985428, 32) => 14229128056835145728
-bit_rotl_u64(3689348814741910323, 32) => 3689348814741910323
-bit_rotr_u64(3689348814741910323, 32) => 3689348814741910323
-bit_rotl_u64(5578377670650038654, 32) => 11101664994514329839
-bit_rotr_u64(5578377670650038654, 32) => 11101664994514329839
-bit_rotl_u64(9223372036854775808, 32) => 2147483648
-bit_rotr_u64(9223372036854775808, 32) => 2147483648
-bit_rotl_u64(10755112315580060033, 32) => 113735138843678123
-bit_rotr_u64(10755112315580060033, 32) => 113735138843678123
-bit_rotl_u64(11163782031541429823, 32) => 282150350032320668
-bit_rotr_u64(11163782031541429823, 32) => 282150350032320668
-bit_rotl_u64(13903686156871869732, 32) => 1215168314246156517
-bit_rotr_u64(13903686156871869732, 32) => 1215168314246156517
-bit_rotl_u64(14237897302422917095, 32) => 3704509656615824425
-bit_rotr_u64(14237897302422917095, 32) => 3704509656615824425
-bit_rotl_u64(14302190498657618739, 32) => 8535529879519336059
-bit_rotr_u64(14302190498657618739, 32) => 8535529879519336059
-bit_rotl_u64(15766411510232741269, 32) => 724364401557998524
-bit_rotr_u64(15766411510232741269, 32) => 724364401557998524
-bit_rotl_u64(15984546468465238145, 32) => 14166178738782635090
-bit_rotr_u64(15984546468465238145, 32) => 14166178738782635090
-bit_rotl_u64(18446744073709551615, 32) => 18446744073709551615
-bit_rotr_u64(18446744073709551615, 32) => 18446744073709551615
-bit_rotl_u64(0, 63) => 0
-bit_rotr_u64(0, 63) => 0
-bit_rotl_u64(1, 63) => 9223372036854775808
-bit_rotr_u64(1, 63) => 2
-bit_rotl_u64(2, 63) => 1
-bit_rotr_u64(2, 63) => 4
-bit_rotl_u64(32768, 63) => 16384
-bit_rotr_u64(32768, 63) => 65536
-bit_rotl_u64(65535, 63) => 9223372036854808575
-bit_rotr_u64(65535, 63) => 131070
-bit_rotl_u64(65536, 63) => 32768
-bit_rotr_u64(65536, 63) => 131072
-bit_rotl_u64(726075912, 63) => 363037956
-bit_rotr_u64(726075912, 63) => 1452151824
-bit_rotl_u64(858993459, 63) => 9223372037284272537
-bit_rotr_u64(858993459, 63) => 1717986918
-bit_rotl_u64(1073741824, 63) => 536870912
-bit_rotr_u64(1073741824, 63) => 2147483648
-bit_rotl_u64(1245250552, 63) => 622625276
-bit_rotr_u64(1245250552, 63) => 2490501104
-bit_rotl_u64(1431655765, 63) => 9223372037570603690
-bit_rotr_u64(1431655765, 63) => 2863311530
-bit_rotl_u64(1656977767, 63) => 9223372037683264691
-bit_rotr_u64(1656977767, 63) => 3313955534
-bit_rotl_u64(2147483648, 63) => 1073741824
-bit_rotr_u64(2147483648, 63) => 4294967296
-bit_rotl_u64(2283114629, 63) => 9223372037996333122
-bit_rotr_u64(2283114629, 63) => 4566229258
-bit_rotl_u64(2502548245, 63) => 9223372038106049930
-bit_rotr_u64(2502548245, 63) => 5005096490
-bit_rotl_u64(4294967295, 63) => 9223372039002259455
-bit_rotr_u64(4294967295, 63) => 8589934590
-bit_rotl_u64(708915120906848425, 63) => 9577829597308200020
-bit_rotr_u64(708915120906848425, 63) => 1417830241813696850
-bit_rotl_u64(1960191741125985428, 63) => 980095870562992714
-bit_rotr_u64(1960191741125985428, 63) => 3920383482251970856
-bit_rotl_u64(3689348814741910323, 63) => 11068046444225730969
-bit_rotr_u64(3689348814741910323, 63) => 7378697629483820646
-bit_rotl_u64(5578377670650038654, 63) => 2789188835325019327
-bit_rotr_u64(5578377670650038654, 63) => 11156755341300077308
-bit_rotl_u64(9223372036854775808, 63) => 4611686018427387904
-bit_rotr_u64(9223372036854775808, 63) => 1
-bit_rotl_u64(10755112315580060033, 63) => 14600928194644805824
-bit_rotr_u64(10755112315580060033, 63) => 3063480557450568451
-bit_rotl_u64(11163782031541429823, 63) => 14805263052625490719
-bit_rotr_u64(11163782031541429823, 63) => 3880819989373308031
-bit_rotl_u64(13903686156871869732, 63) => 6951843078435934866
-bit_rotr_u64(13903686156871869732, 63) => 9360628240034187849
-bit_rotl_u64(14237897302422917095, 63) => 16342320688066234355
-bit_rotr_u64(14237897302422917095, 63) => 10029050531136282575
-bit_rotl_u64(14302190498657618739, 63) => 16374467286183585177
-bit_rotr_u64(14302190498657618739, 63) => 10157636923605685863
-bit_rotl_u64(15766411510232741269, 63) => 17106577791971146442
-bit_rotr_u64(15766411510232741269, 63) => 13086078946755930923
-bit_rotl_u64(15984546468465238145, 63) => 17215645271087394880
-bit_rotr_u64(15984546468465238145, 63) => 13522348863220924675
-bit_rotl_u64(18446744073709551615, 63) => 18446744073709551615
-bit_rotr_u64(18446744073709551615, 63) => 18446744073709551615
-bit_rotl_u64(0, 64) => 0
-bit_rotr_u64(0, 64) => 0
-bit_rotl_u64(1, 64) => 1
-bit_rotr_u64(1, 64) => 1
-bit_rotl_u64(2, 64) => 2
-bit_rotr_u64(2, 64) => 2
-bit_rotl_u64(32768, 64) => 32768
-bit_rotr_u64(32768, 64) => 32768
-bit_rotl_u64(65535, 64) => 65535
-bit_rotr_u64(65535, 64) => 65535
-bit_rotl_u64(65536, 64) => 65536
-bit_rotr_u64(65536, 64) => 65536
-bit_rotl_u64(726075912, 64) => 726075912
-bit_rotr_u64(726075912, 64) => 726075912
-bit_rotl_u64(858993459, 64) => 858993459
-bit_rotr_u64(858993459, 64) => 858993459
-bit_rotl_u64(1073741824, 64) => 1073741824
-bit_rotr_u64(1073741824, 64) => 1073741824
-bit_rotl_u64(1245250552, 64) => 1245250552
-bit_rotr_u64(1245250552, 64) => 1245250552
-bit_rotl_u64(1431655765, 64) => 1431655765
-bit_rotr_u64(1431655765, 64) => 1431655765
-bit_rotl_u64(1656977767, 64) => 1656977767
-bit_rotr_u64(1656977767, 64) => 1656977767
-bit_rotl_u64(2147483648, 64) => 2147483648
-bit_rotr_u64(2147483648, 64) => 2147483648
-bit_rotl_u64(2283114629, 64) => 2283114629
-bit_rotr_u64(2283114629, 64) => 2283114629
-bit_rotl_u64(2502548245, 64) => 2502548245
-bit_rotr_u64(2502548245, 64) => 2502548245
-bit_rotl_u64(4294967295, 64) => 4294967295
-bit_rotr_u64(4294967295, 64) => 4294967295
-bit_rotl_u64(708915120906848425, 64) => 708915120906848425
-bit_rotr_u64(708915120906848425, 64) => 708915120906848425
-bit_rotl_u64(1960191741125985428, 64) => 1960191741125985428
-bit_rotr_u64(1960191741125985428, 64) => 1960191741125985428
-bit_rotl_u64(3689348814741910323, 64) => 3689348814741910323
-bit_rotr_u64(3689348814741910323, 64) => 3689348814741910323
-bit_rotl_u64(5578377670650038654, 64) => 5578377670650038654
-bit_rotr_u64(5578377670650038654, 64) => 5578377670650038654
-bit_rotl_u64(9223372036854775808, 64) => 9223372036854775808
-bit_rotr_u64(9223372036854775808, 64) => 9223372036854775808
-bit_rotl_u64(10755112315580060033, 64) => 10755112315580060033
-bit_rotr_u64(10755112315580060033, 64) => 10755112315580060033
-bit_rotl_u64(11163782031541429823, 64) => 11163782031541429823
-bit_rotr_u64(11163782031541429823, 64) => 11163782031541429823
-bit_rotl_u64(13903686156871869732, 64) => 13903686156871869732
-bit_rotr_u64(13903686156871869732, 64) => 13903686156871869732
-bit_rotl_u64(14237897302422917095, 64) => 14237897302422917095
-bit_rotr_u64(14237897302422917095, 64) => 14237897302422917095
-bit_rotl_u64(14302190498657618739, 64) => 14302190498657618739
-bit_rotr_u64(14302190498657618739, 64) => 14302190498657618739
-bit_rotl_u64(15766411510232741269, 64) => 15766411510232741269
-bit_rotr_u64(15766411510232741269, 64) => 15766411510232741269
-bit_rotl_u64(15984546468465238145, 64) => 15984546468465238145
-bit_rotr_u64(15984546468465238145, 64) => 15984546468465238145
-bit_rotl_u64(18446744073709551615, 64) => 18446744073709551615
-bit_rotr_u64(18446744073709551615, 64) => 18446744073709551615
-	*** test_rotl_rotr: done ***
-	*** test_bswap ***
-bswap_u64(0) => 0
-bswap_u32(0) => 0
-bswap_u64(1) => 72057594037927936
-bswap_u32(1) => 16777216
-bswap_u64(2) => 144115188075855872
-bswap_u32(2) => 33554432
-bswap_u64(32768) => 36028797018963968
-bswap_u32(32768) => 8388608
-bswap_u64(65535) => 18446462598732840960
-bswap_u32(65535) => 4294901760
-bswap_u64(65536) => 1099511627776
-bswap_u32(65536) => 256
-bswap_u64(726075912) => 579353752079695872
-bswap_u32(726075912) => 134891307
-bswap_u64(858993459) => 3689348813882916864
-bswap_u32(858993459) => 858993459
-bswap_u64(1073741824) => 274877906944
-bswap_u32(1073741824) => 64
-bswap_u64(1245250552) => 17871190736326623232
-bswap_u32(1245250552) => 4160960842
-bswap_u64(1431655765) => 6148914689804861440
-bswap_u32(1431655765) => 1431655765
-bswap_u64(1656977767) => 7456205483762778112
-bswap_u32(1656977767) => 1736033122
-bswap_u64(2147483648) => 549755813888
-bswap_u32(2147483648) => 128
-bswap_u64(2283114629) => 9624216077550485504
-bswap_u32(2283114629) => 2240812424
-bswap_u64(2502548245) => 1574898214622986240
-bswap_u32(2502548245) => 366684565
-bswap_u64(4294967295) => 18446744069414584320
-bswap_u32(4294967295) => 4294967295
-bswap_u64(708915120906848425) => 12198156707273299465
-bswap_u64(1960191741125985428) => 10665782605024080923
-bswap_u64(3689348814741910323) => 3689348814741910323
-bswap_u64(5578377670650038654) => 9081809480708024909
-bswap_u64(9223372036854775808) => 128
-bswap_u64(10755112315580060033) => 9300377440395542933
-bswap_u64(11163782031541429823) => 4568596173249113498
-bswap_u64(13903686156871869732) => 2604731024148591552
-bswap_u64(14237897302422917095) => 16649642015867049925
-bswap_u64(14302190498657618739) => 3696175971416046534
-bswap_u64(15766411510232741269) => 10769528423690522074
-bswap_u64(15984546468465238145) => 9322619197622375645
-bswap_u64(18446744073709551615) => 18446744073709551615
-	*** test_bswap: done ***
-	*** test_index ***
-bit_index_u64(0, *, -1) => 
-bit_index_u32(0, *, -1) => 
-bit_index_u64(1, *, -1) => 0 
-bit_index_u32(1, *, -1) => 0 
-bit_index_u64(2, *, -1) => 1 
-bit_index_u32(2, *, -1) => 1 
-bit_index_u64(32768, *, -1) => 15 
-bit_index_u32(32768, *, -1) => 15 
-bit_index_u64(65535, *, -1) => 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 
-bit_index_u32(65535, *, -1) => 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 
-bit_index_u64(65536, *, -1) => 16 
-bit_index_u32(65536, *, -1) => 16 
-bit_index_u64(726075912, *, -1) => 3 9 11 16 17 18 22 24 25 27 29 
-bit_index_u32(726075912, *, -1) => 3 9 11 16 17 18 22 24 25 27 29 
-bit_index_u64(858993459, *, -1) => 0 1 4 5 8 9 12 13 16 17 20 21 24 25 28 29 
-bit_index_u32(858993459, *, -1) => 0 1 4 5 8 9 12 13 16 17 20 21 24 25 28 29 
-bit_index_u64(1073741824, *, -1) => 30 
-bit_index_u32(1073741824, *, -1) => 30 
-bit_index_u64(1245250552, *, -1) => 3 4 5 6 7 8 9 16 19 20 21 25 27 30 
-bit_index_u32(1245250552, *, -1) => 3 4 5 6 7 8 9 16 19 20 21 25 27 30 
-bit_index_u64(1431655765, *, -1) => 0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 
-bit_index_u32(1431655765, *, -1) => 0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 
-bit_index_u64(1656977767, *, -1) => 0 1 2 5 6 8 11 12 13 14 16 17 22 23 25 29 30 
-bit_index_u32(1656977767, *, -1) => 0 1 2 5 6 8 11 12 13 14 16 17 22 23 25 29 30 
-bit_index_u64(2147483648, *, -1) => 31 
-bit_index_u32(2147483648, *, -1) => 31 
-bit_index_u64(2283114629, *, -1) => 0 2 7 12 15 16 18 20 27 31 
-bit_index_u32(2283114629, *, -1) => 0 2 7 12 15 16 18 20 27 31 
-bit_index_u64(2502548245, *, -1) => 0 2 4 8 9 11 12 14 15 16 19 21 24 26 28 31 
-bit_index_u32(2502548245, *, -1) => 0 2 4 8 9 11 12 14 15 16 19 21 24 26 28 31 
-bit_index_u64(4294967295, *, -1) => 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 
-bit_index_u32(4294967295, *, -1) => 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 
-bit_index_u64(708915120906848425, *, -1) => 0 3 5 7 11 14 17 18 19 23 24 26 29 30 31 32 33 35 39 41 44 47 49 50 52 54 55 56 59 
-bit_index_u64(1960191741125985428, *, -1) => 2 4 7 10 19 20 21 22 24 26 30 31 50 52 53 56 57 59 60 
-bit_index_u64(3689348814741910323, *, -1) => 0 1 4 5 8 9 12 13 16 17 20 21 24 25 28 29 32 33 36 37 40 41 44 45 48 49 52 53 56 57 60 61 
-bit_index_u64(5578377670650038654, *, -1) => 1 2 3 4 5 6 8 11 16 20 25 27 28 31 32 33 34 35 37 38 39 45 46 49 51 53 54 56 58 59 62 
-bit_index_u64(9223372036854775808, *, -1) => 63 
-bit_index_u64(10755112315580060033, *, -1) => 0 7 8 12 18 20 23 24 32 33 35 37 39 40 42 44 46 47 48 54 56 58 60 63 
-bit_index_u64(11163782031541429823, *, -1) => 0 1 2 3 4 5 9 10 13 14 17 19 21 22 23 24 25 34 35 36 39 43 44 45 47 48 50 51 53 54 55 57 59 60 63 
-bit_index_u64(13903686156871869732, *, -1) => 2 5 8 10 13 16 18 19 20 22 23 28 32 34 37 38 39 44 46 47 48 49 52 53 54 55 62 63 
-bit_index_u64(14237897302422917095, *, -1) => 0 1 2 5 6 7 8 9 10 11 16 19 21 22 24 25 28 29 32 35 37 42 43 45 48 49 50 52 55 56 58 62 63 
-bit_index_u64(14302190498657618739, *, -1) => 0 1 4 5 8 9 11 14 18 20 21 22 25 26 28 29 30 32 33 35 36 37 38 41 42 44 47 48 49 51 52 53 54 57 58 62 63 
-bit_index_u64(15766411510232741269, *, -1) => 0 2 4 7 8 10 12 13 14 16 18 19 25 27 34 35 36 37 39 40 41 43 47 48 50 51 54 55 57 59 60 62 63 
-bit_index_u64(15984546468465238145, *, -1) => 0 7 13 14 19 20 23 26 30 31 33 36 38 42 47 50 52 54 55 56 58 59 60 62 63 
-bit_index_u64(18446744073709551615, *, -1) => 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 
-	*** test_index: done ***
-	*** test_bit_iter ***
-Set: 3, 9, 11, 16, 17, 18, 22, 24, 25, 27, 29, 64, 65, 68, 69, 72, 73, 76, 77, 
-Clear: 0, 1, 2, 4, 5, 6, 7, 8, 10, 12, 13, 14, 15, 19, 20, 21, 23, 26, 28, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 66, 67, 70, 71, 74, 75, 78, 79, 
-	*** test_bit_iter: done ***
-	*** test_bit_iter_empty ***
-	*** test_bit_iter_empty: done ***
-	*** test_bitmap_size ***
-	*** test_bitmap_size: done ***
diff --git a/test/unit/bitset_basic.c b/test/unit/bitset_basic.c
index fe4b6ab07..be17b0f6b 100644
--- a/test/unit/bitset_basic.c
+++ b/test/unit/bitset_basic.c
@@ -9,6 +9,7 @@ static
 void test_cardinality()
 {
 	header();
+	plan(1);
 
 	struct tt_bitset bm;
 	tt_bitset_create(&bm, realloc);
@@ -48,6 +49,8 @@ void test_cardinality()
 
 	tt_bitset_destroy(&bm);
 
+	ok(1, "test cardinality");
+	check_plan();
 	footer();
 }
 
@@ -85,6 +88,7 @@ static
 void test_get_set()
 {
 	header();
+	plan(1);
 
 	struct tt_bitset bm;
 	tt_bitset_create(&bm, realloc);
@@ -92,7 +96,7 @@ void test_get_set()
 	const size_t NUM_SIZE = (size_t) 1 << 14;
 	size_t *nums = malloc(NUM_SIZE * sizeof(size_t));
 
-	printf("Generating test set... ");
+	note("Generating test set... ");
 	for(size_t i = 0; i < NUM_SIZE; i++) {
 		nums[i] = rand();
 	}
@@ -107,26 +111,23 @@ void test_get_set()
 		}
 	}
 	shuffle(nums, NUM_SIZE);
-	printf("ok\n");
 
-	printf("Settings bits... ");
+	note("Settings bits... ");
 	for(size_t i = 0; i < NUM_SIZE; i++) {
 		if (nums[i] == SIZE_MAX)
 			continue;
 		fail_if(tt_bitset_set(&bm, nums[i]) < 0);
 	}
-	printf("ok\n");
 
-	printf("Checking bits... ");
+	note("Checking bits... ");
 	shuffle(nums, NUM_SIZE);
 	for(size_t i = 0; i < NUM_SIZE; i++) {
 		if (nums[i] == SIZE_MAX)
 			continue;
 		fail_unless(tt_bitset_test(&bm, nums[i]));
 	}
-	printf("ok\n");
 
-	printf("Unsetting random bits... ");
+	note("Unsetting random bits... ");
 	for(size_t k = 0; k < (NUM_SIZE >> 3); k++) {
 		size_t i = rand() % NUM_SIZE;
 		if (nums[i] == SIZE_MAX)
@@ -135,23 +136,19 @@ void test_get_set()
 		fail_if(tt_bitset_test(&bm, nums[i]));
 		nums[i] = SIZE_MAX;
 	}
-	printf("ok\n");
 
-	printf("Checking set bits... ");
+	note("Checking set bits... ");
 	shuffle(nums, NUM_SIZE);
 	for(size_t i = 0; i < NUM_SIZE; i++) {
 		if (nums[i] == SIZE_MAX) {
 			continue;
 		}
 
-		if (!tt_bitset_test(&bm, nums[i])) {
-			printf("Fail :%zu\n", nums[i]);
-		}
+		fail_if(!tt_bitset_test(&bm, nums[i]));
 		fail_unless(tt_bitset_test(&bm, nums[i]));
 	}
-	printf("ok\n");
 
-	printf("Checking all bits... ");
+	note("Checking all bits... ");
 	qsort(nums, NUM_SIZE, sizeof(size_t), size_compator);
 
 	size_t *pn = nums;
@@ -166,10 +163,8 @@ void test_get_set()
 			fail_if(tt_bitset_test(&bm, i));
 		}
 	}
-	printf("ok\n");
-
 
-	printf("Unsetting all bits... ");
+	note("Unsetting all bits... ");
 	shuffle(nums, NUM_SIZE);
 	for(size_t i = 0; i < NUM_SIZE; i++) {
 		if (nums[i] == SIZE_MAX) {
@@ -178,28 +173,29 @@ void test_get_set()
 
 		fail_if(tt_bitset_clear(&bm, nums[i]) < 0);
 	}
-	printf("ok\n");
-
 
-	printf("Checking all bits... ");
+	note("Checking all bits... ");
 	for(size_t i = 0; i < i_max; i++) {
 		fail_if(tt_bitset_test(&bm, i));
 	}
-	printf("ok\n");
 
 	free(nums);
 
 	tt_bitset_destroy(&bm);
 
+	ok(1, "test get set");
+	check_plan();
 	footer();
 }
 
 int main(int argc, char *argv[])
 {
+	plan(2);
 	setbuf(stdout, NULL);
 	srand(time(NULL));
 	test_cardinality();
 	test_get_set();
+	check_plan();
 
 	return 0;
 }
diff --git a/test/unit/bitset_basic.result b/test/unit/bitset_basic.result
deleted file mode 100644
index 54f0ae724..000000000
--- a/test/unit/bitset_basic.result
+++ /dev/null
@@ -1,12 +0,0 @@
-	*** test_cardinality ***
-	*** test_cardinality: done ***
-	*** test_get_set ***
-Generating test set... ok
-Settings bits... ok
-Checking bits... ok
-Unsetting random bits... ok
-Checking set bits... ok
-Checking all bits... ok
-Unsetting all bits... ok
-Checking all bits... ok
-	*** test_get_set: done ***
diff --git a/test/unit/bitset_index.c b/test/unit/bitset_index.c
index c077fae49..d8542e7d1 100644
--- a/test/unit/bitset_index.c
+++ b/test/unit/bitset_index.c
@@ -42,6 +42,7 @@ static
 void test_size_and_count(void)
 {
 	header();
+	plan(1);
 
 	struct tt_bitset_index index;
 	tt_bitset_index_create(&index, realloc);
@@ -60,8 +61,10 @@ void test_size_and_count(void)
 	fail_unless(tt_bitset_index_count(&index, 2147483648) == 0);
 
 	tt_bitset_index_destroy(&index);
+	ok(1, "test size and count");
 
 	footer();
+	check_plan();
 }
 
 static
@@ -73,7 +76,7 @@ void check_keys(struct tt_bitset_index *index,
 	struct tt_bitset_expr expr;
 	tt_bitset_expr_create(&expr, realloc);
 
-	printf("Checking keys... ");
+	note("Checking keys... ");
 	for (size_t i = 0; i < size; i++) {
 		/* ignore removed keys */
 		if (keys[i] == SIZE_MAX) {
@@ -97,7 +100,7 @@ void check_keys(struct tt_bitset_index *index,
 		}
 		fail_unless(pair_found);
 	}
-	printf("ok\n");
+	note("ok");
 
 	tt_bitset_iterator_destroy(&it);
 	tt_bitset_expr_destroy(&expr);
@@ -107,6 +110,7 @@ static
 void test_insert_remove(void)
 {
 	header();
+	plan(1);
 
 	struct tt_bitset_index index;
 	tt_bitset_index_create(&index, realloc);
@@ -117,36 +121,36 @@ void test_insert_remove(void)
 
 	size_t count0 = 0;
 	size_t count1 = 0;
-	printf("Generating test set... ");
+	note("Generating test set... ");
 	for(size_t i = 0; i < NUMS_SIZE; i++) {
 		keys[i] = rand();
 		values[i] = rand();
 		count0 += (keys[i] & 1) != 0 ? 1 : 0;
 		count1 += (keys[i] & 2) != 0 ? 1 : 0;
 	}
-	printf("ok\n");
+	note("ok");
 
-	printf("Inserting pairs... ");
+	note("Inserting pairs... ");
 	for(size_t i = 0; i < NUMS_SIZE; i++) {
 		tt_bitset_index_insert(&index, &keys[i], sizeof(keys[i]),
 				       values[i]);
 
 	}
-	printf("ok\n");
+	note("ok");
 
 	check_keys(&index, keys, values, NUMS_SIZE);
 
 	fail_unless(tt_bitset_index_count(&index, 0) == count0);
 	fail_unless(tt_bitset_index_count(&index, 1) == count1);
 
-	printf("Removing random pairs... ");
+	note("Removing random pairs... ");
 	for(size_t i = 0; i < NUMS_SIZE; i++) {
 		if (rand() % 5 == 0) {
 			tt_bitset_index_remove_value(&index, values[i]);
 			keys[i] = SIZE_MAX;
 		}
 	}
-	printf("ok\n");
+	note("ok");
 
 	check_keys(&index, keys, values, NUMS_SIZE);
 
@@ -154,8 +158,10 @@ void test_insert_remove(void)
 
 	free(keys);
 	free(values);
+	ok(1, "test_insert_remove");
 
 	footer();
+	check_plan();
 }
 
 
@@ -222,7 +228,10 @@ static void
 test_empty_simple(void)
 {
 	header();
+	plan(1);
 	test_simple(1, 0); /* empty result */
+	ok(1, "test empty simple");
+	check_plan();
 	footer();
 }
 
@@ -230,7 +239,10 @@ static void
 test_all_simple(void)
 {
 	header();
+	plan(1);
 	test_simple(0, 0);  /* all */
+	ok(1, "test all simple");
+	check_plan();
 	footer();
 }
 
@@ -238,8 +250,11 @@ static void
 test_all_set_simple(void)
 {
 	header();
+	plan(1);
 	size_t search_mask = 66; /* 0b1000010 */
 	test_simple(1, search_mask);  /* all bits set */
+	ok(1, "test all set simple");
+	check_plan();
 	footer();
 }
 
@@ -247,8 +262,11 @@ static void
 test_any_set_simple(void)
 {
 	header();
+	plan(1);
 	size_t search_mask = 66; /* 0b1000010 */
 	test_simple(2, search_mask);  /* any bits set */
+	ok(1, "test any set simple");
+	check_plan();
 	footer();
 }
 
@@ -256,6 +274,7 @@ static
 void test_equals_simple(void)
 {
 	header();
+	plan(1);
 
 	struct tt_bitset_index index;
 	tt_bitset_index_create(&index, realloc);
@@ -284,13 +303,17 @@ void test_equals_simple(void)
 	tt_bitset_expr_destroy(&expr);
 	tt_bitset_iterator_destroy(&it);
 	tt_bitset_index_destroy(&index);
+	ok(1, "test equals simple");
 
+	check_plan();
 	footer();
 }
 
 int main(void)
 {
 	setbuf(stdout, NULL);
+	header();
+	plan(7);
 
 	test_size_and_count();
 	test_resize();
@@ -301,5 +324,8 @@ int main(void)
 	test_any_set_simple();
 	test_equals_simple();
 
+	check_plan();
+	footer();
+
 	return 0;
 }
diff --git a/test/unit/bitset_index.result b/test/unit/bitset_index.result
deleted file mode 100644
index c358cfbc4..000000000
--- a/test/unit/bitset_index.result
+++ /dev/null
@@ -1,21 +0,0 @@
-	*** test_size_and_count ***
-	*** test_size_and_count: done ***
-	*** test_resize ***
-	*** test_resize: done ***
-	*** test_insert_remove ***
-Generating test set... ok
-Inserting pairs... ok
-Checking keys... ok
-Removing random pairs... ok
-Checking keys... ok
-	*** test_insert_remove: done ***
-	*** test_empty_simple ***
-	*** test_empty_simple: done ***
-	*** test_all_simple ***
-	*** test_all_simple: done ***
-	*** test_all_set_simple ***
-	*** test_all_set_simple: done ***
-	*** test_any_set_simple ***
-	*** test_any_set_simple: done ***
-	*** test_equals_simple ***
-	*** test_equals_simple: done ***
diff --git a/test/unit/bitset_iterator.c b/test/unit/bitset_iterator.c
index 04f2f9f72..445a43486 100644
--- a/test/unit/bitset_iterator.c
+++ b/test/unit/bitset_iterator.c
@@ -80,6 +80,7 @@ static
 void test_empty_expr(void)
 {
 	header();
+	plan(1);
 
 	struct tt_bitset_expr expr;
 	tt_bitset_expr_create(&expr, realloc);
@@ -94,6 +95,8 @@ void test_empty_expr(void)
 
 	tt_bitset_iterator_destroy(&it);
 
+	ok(1, "test empty expr")
+	check_plan();
 	footer();
 }
 
@@ -101,6 +104,7 @@ static
 void test_empty_expr_conj1(void)
 {
 	header();
+	plan(1);
 
 	struct tt_bitset_expr expr;
 	tt_bitset_expr_create(&expr, realloc);
@@ -117,6 +121,8 @@ void test_empty_expr_conj1(void)
 
 	tt_bitset_iterator_destroy(&it);
 
+	ok(1, "test empty expr conj1");
+	check_plan();
 	footer();
 }
 
@@ -124,6 +130,7 @@ static
 void test_empty_expr_conj2(void)
 {
 	header();
+	plan(1);
 
 	size_t big_i = (size_t) 1 << 15;
 	struct tt_bitset **bitsets = bitsets_create(2);
@@ -154,6 +161,8 @@ void test_empty_expr_conj2(void)
 	tt_bitset_iterator_destroy(&it);
 	bitsets_destroy(bitsets, 2);
 
+	ok(1, "test empty expr conj2");
+	check_plan();
 	footer();
 }
 
@@ -161,6 +170,7 @@ static
 void test_empty_result(void)
 {
 	header();
+	plan(1);
 
 	struct tt_bitset **bitsets = bitsets_create(2);
 
@@ -199,6 +209,8 @@ void test_empty_result(void)
 
 	bitsets_destroy(bitsets, 2);
 
+	ok(1, "test empty result");
+	check_plan();
 	footer();
 }
 
@@ -206,6 +218,7 @@ static
 void test_first_result(void)
 {
 	header();
+	plan(1);
 
 	struct tt_bitset **bitsets = bitsets_create(2);
 
@@ -237,6 +250,8 @@ void test_first_result(void)
 
 	bitsets_destroy(bitsets, 2);
 
+	ok(1, "test first result");
+	check_plan();
 	footer();
 }
 
@@ -244,6 +259,7 @@ static
 void test_simple()
 {
 	header();
+	plan(1);
 
 	enum { BITSETS_SIZE = 32 };
 
@@ -286,12 +302,15 @@ void test_simple()
 	tt_bitset_iterator_destroy(&it);
 	bitsets_destroy(bitsets, BITSETS_SIZE);
 
+	ok(1, "test simple");
+	check_plan();
 	footer();
 }
 
 static
 void test_big() {
 	header();
+	plan(1);
 
 	const size_t BITSETS_SIZE = 32;
 	struct tt_bitset **bitsets = bitsets_create(BITSETS_SIZE);
@@ -338,12 +357,15 @@ void test_big() {
 
 	bitsets_destroy(bitsets, BITSETS_SIZE);
 
+	ok(1, "test big");
+	check_plan();
 	footer();
 }
 
 static
 void test_not_last() {
 	header();
+	plan(1);
 
 	struct tt_bitset **bitsets = bitsets_create(2);
 
@@ -385,12 +407,15 @@ void test_not_last() {
 
 	bitsets_destroy(bitsets, 2);
 
+	ok(1, "test not last");
+	check_plan();
 	footer();
 }
 
 static
 void test_not_empty() {
 	header();
+	plan(1);
 
 	enum {
 		BITSETS_SIZE = 4,
@@ -428,6 +453,8 @@ void test_not_empty() {
 
 	bitsets_destroy(bitsets, BITSETS_SIZE);
 
+	ok(1, "test not empty");
+	check_plan();
 	footer();
 }
 
@@ -435,6 +462,7 @@ static
 void test_disjunction()
 {
 	header();
+	plan(1);
 
 	enum { BITSETS_SIZE = 32 };
 
@@ -474,6 +502,8 @@ void test_disjunction()
 
 	bitsets_destroy(bitsets, BITSETS_SIZE);
 
+	ok(1, "test disjunction")
+	check_plan();
 	footer();
 }
 
@@ -482,6 +512,7 @@ int main(void)
 	setbuf(stdout, NULL);
 	nums_fill(NUMS, NUMS_SIZE);
 
+	plan(10);
 	test_empty_expr();
 	test_empty_expr_conj1();
 	test_empty_expr_conj2();
@@ -493,5 +524,6 @@ int main(void)
 	test_not_last();
 	test_disjunction();
 
+	check_plan();
 	return 0;
 }
diff --git a/test/unit/bitset_iterator.result b/test/unit/bitset_iterator.result
deleted file mode 100644
index 1f8369d74..000000000
--- a/test/unit/bitset_iterator.result
+++ /dev/null
@@ -1,22 +0,0 @@
-	*** test_empty_expr ***
-	*** test_empty_expr: done ***
-	*** test_empty_expr_conj1 ***
-	*** test_empty_expr_conj1: done ***
-	*** test_empty_expr_conj2 ***
-	*** test_empty_expr_conj2: done ***
-	*** test_empty_result ***
-	*** test_empty_result: done ***
-	*** test_first_result ***
-	*** test_first_result: done ***
-	*** test_simple ***
-	*** test_simple: done ***
-	*** test_big ***
-Setting bits... ok
-Iterating... ok
-	*** test_big: done ***
-	*** test_not_empty ***
-	*** test_not_empty: done ***
-	*** test_not_last ***
-	*** test_not_last: done ***
-	*** test_disjunction ***
-	*** test_disjunction: done ***
diff --git a/test/unit/bloom.cc b/test/unit/bloom.cc
index 2e5b99412..23a36487c 100644
--- a/test/unit/bloom.cc
+++ b/test/unit/bloom.cc
@@ -2,6 +2,7 @@
 #include <unordered_set>
 #include <vector>
 #include <iostream>
+#include "unit.h"
 
 using namespace std;
 
@@ -13,7 +14,8 @@ uint32_t h(uint32_t i)
 void
 simple_test()
 {
-	cout << "*** " << __func__ << " ***" << endl;
+	header();
+	plan(1);
 	srand(time(0));
 	uint32_t error_count = 0;
 	uint32_t fp_rate_too_big = 0;
@@ -45,14 +47,16 @@ simple_test()
 		if (fp_rate > p + 0.001)
 			fp_rate_too_big++;
 	}
-	cout << "error_count = " << error_count << endl;
-	cout << "fp_rate_too_big = " << fp_rate_too_big << endl;
+	note("error_count = %d", error_count);
+	note("fp_rate_too_big = %d", fp_rate_too_big);
+	ok(1, "%s", __func__);
+	check_plan();
 }
 
 void
 store_load_test()
 {
-	cout << "*** " << __func__ << " ***" << endl;
+	plan(1);
 	srand(time(0));
 	uint32_t error_count = 0;
 	uint32_t fp_rate_too_big = 0;
@@ -92,13 +96,17 @@ store_load_test()
 		if (fp_rate > p + 0.001)
 			fp_rate_too_big++;
 	}
-	cout << "error_count = " << error_count << endl;
-	cout << "fp_rate_too_big = " << fp_rate_too_big << endl;
+	note("error_count = %d", error_count);
+	note("fp_rate_too_big = %d", fp_rate_too_big);
+	ok(1, "%s", __func__);
+	check_plan();
 }
 
 int
 main(void)
 {
+	plan(2);
 	simple_test();
 	store_load_test();
+	check_plan();
 }
diff --git a/test/unit/bloom.result b/test/unit/bloom.result
deleted file mode 100644
index 91193a618..000000000
--- a/test/unit/bloom.result
+++ /dev/null
@@ -1,6 +0,0 @@
-*** simple_test ***
-error_count = 0
-fp_rate_too_big = 0
-*** store_load_test ***
-error_count = 0
-fp_rate_too_big = 0
diff --git a/test/unit/bps_tree.cc b/test/unit/bps_tree.cc
index ef374deb1..d1a94ffb9 100644
--- a/test/unit/bps_tree.cc
+++ b/test/unit/bps_tree.cc
@@ -124,7 +124,7 @@ static int compare_key(const elem_t &a, long b)
 		type_t check_value =\
 			*tree_name##_iterator_get_elem((tree), &iter);\
 		if (check_value != (type_t)(elem)) {\
-			printf("iterator doesn't point to the inserted "\
+			diag("iterator doesn't point to the inserted "\
 			       "element: %lld != %lld", (long long) (elem),\
 			       (long long) check_value);\
 			fail("elem != check_value", "true");\
@@ -168,12 +168,13 @@ static void
 simple_check()
 {
 	header();
+	plan(1);
 
 	const unsigned int rounds = 2000;
 	test tree;
 	test_create(&tree, 0, extent_alloc, extent_free, &extents_count);
 
-	printf("Insert 1..X, remove 1..X\n");
+	note("Insert 1..X, remove 1..X");
 	for (unsigned int i = 0; i < rounds; i++) {
 		type_t v = i;
 		if (test_find(&tree, v) != NULL)
@@ -200,7 +201,7 @@ simple_check()
 	if (test_size(&tree) != 0)
 		fail("Tree count mismatch (2)", "true");
 
-	printf("Insert 1..X, remove X..1\n");
+	note("Insert 1..X, remove X..1");
 	for (unsigned int i = 0; i < rounds; i++) {
 		type_t v = i;
 		if (test_find(&tree, v) != NULL)
@@ -227,7 +228,7 @@ simple_check()
 	if (test_size(&tree) != 0)
 		fail("Tree count mismatch (4)", "true");
 
-	printf("Insert X..1, remove 1..X\n");
+	note("Insert X..1, remove 1..X");
 	for (unsigned int i = 0; i < rounds; i++) {
 		type_t v = rounds - 1 - i;
 		if (test_find(&tree, v) != NULL)
@@ -254,7 +255,7 @@ simple_check()
 	if (test_size(&tree) != 0)
 		fail("Tree count mismatch (6)", "true");
 
-	printf("Insert X..1, remove X..1\n");
+	note("Insert X..1, remove X..1");
 	for (unsigned int i = 0; i < rounds; i++) {
 		type_t v = rounds - 1 - i;
 		if (test_find(&tree, v) != NULL)
@@ -282,8 +283,10 @@ simple_check()
 		fail("Tree count mismatch (8)", "true");
 
 	test_destroy(&tree);
+	ok(1, "simple check");
 
 	footer();
+	check_plan();
 }
 
 static bool
@@ -311,6 +314,7 @@ static void
 compare_with_sptree_check()
 {
 	header();
+	plan(1);
 
 	sptree_test spt_test;
 	sptree_test_init(&spt_test, sizeof(type_t), 0, 0, 0, &node_comp, 0, 0);
@@ -345,14 +349,17 @@ compare_with_sptree_check()
 	sptree_test_destroy(&spt_test);
 
 	test_destroy(&tree);
+	ok(1, "compare with sptree check");
 
 	footer();
+	check_plan();
 }
 
 static void
 compare_with_sptree_check_branches()
 {
 	header();
+	plan(1);
 
 	sptree_test spt_test;
 	sptree_test_init(&spt_test, sizeof(type_t), 0, 0, 0, &node_comp, 0, 0);
@@ -570,28 +577,34 @@ compare_with_sptree_check_branches()
 	sptree_test_destroy(&spt_test);
 
 	test_destroy(&tree);
+	ok(1, "compare with sptree check branches");
 
 	footer();
+	check_plan();
 }
 
 static void
 bps_tree_debug_self_check()
 {
 	header();
+	plan(1);
 
 	int res = test_debug_check_internal_functions(false);
 	if (res)
-		printf("self test returned error %d\n", res);
+		note("self test returned error %d", res);
 
 	test_debug_check_internal_functions(true);
+	ok(1, "bps tree debug self check");
 
 	footer();
+	check_plan();
 }
 
 static void
-loading_test()
+load_test()
 {
 	header();
+	plan(1);
 
 	test tree;
 
@@ -623,14 +636,17 @@ loading_test()
 
 		test_destroy(&tree);
 	}
+	ok(1, "load test");
 
 	footer();
+	check_plan();
 }
 
 static void
 printing_test()
 {
 	header();
+	plan(1);
 
 	test tree;
 	test_create(&tree, 0, extent_alloc, extent_free, &extents_count);
@@ -639,24 +655,27 @@ printing_test()
 
 	for (type_t i = 0; i < rounds; i++) {
 		type_t v = rounds + i;
-		printf("Inserting " TYPE_F "\n", v);
+		note("Inserting " TYPE_F, v);
 		test_insert(&tree, v, 0);
 		test_print(&tree, TYPE_F);
 		v = rounds - i - 1;
-		printf("Inserting " TYPE_F "\n", v);
+		note("Inserting " TYPE_F, v);
 		test_insert(&tree, v, 0);
 		test_print(&tree, TYPE_F);
 	}
 
 	test_destroy(&tree);
+	ok(1, "printing test");
 
 	footer();
+	check_plan();
 }
 
 static void
 white_box_test()
 {
 	header();
+	plan(1);
 
 	test tree;
 	test_create(&tree, 0, extent_alloc, extent_free, &extents_count);
@@ -664,33 +683,33 @@ white_box_test()
 	assert(BPS_TREE_test_MAX_COUNT_IN_LEAF == 14);
 	assert(BPS_TREE_test_MAX_COUNT_IN_INNER == 10);
 
-	printf("full leaf:\n");
+	note("full leaf:");
 	for (type_t i = 0; i < 14; i++) {
 		test_insert(&tree, i, 0);
 	}
 	test_print(&tree, TYPE_F);
 
-	printf("split now:\n");
+	note("split now:");
 	test_insert(&tree, 14, 0);
 	test_print(&tree, TYPE_F);
 
-	printf("full 2 leafs:\n");
+	note("full 2 leafs:");
 	for (type_t i = 15; i < 28; i++) {
 		test_insert(&tree, i, 0);
 	}
 	test_print(&tree, TYPE_F);
 
-	printf("split now:\n");
+	note("split now:");
 	test_insert(&tree, 28, 0);
 	test_print(&tree, TYPE_F);
 
-	printf("full 3 leafs:\n");
+	note("full 3 leafs:");
 	for (type_t i = 29; i < 42; i++) {
 		test_insert(&tree, i, 0);
 	}
 	test_print(&tree, TYPE_F);
 
-	printf("split now:\n");
+	note("split now:");
 	test_insert(&tree, 42, 0);
 	test_print(&tree, TYPE_F);
 
@@ -700,22 +719,25 @@ white_box_test()
 	for (type_t i = 0; i < 140; i++)
 		arr[i] = i;
 	test_build(&tree, arr, 140);
-	printf("full 10 leafs:\n");
+	note("full 10 leafs:");
 	test_print(&tree, TYPE_F);
 
-	printf("2-level split now:\n");
+	note("2-level split now:");
 	test_insert(&tree, 140, 0);
 	test_print(&tree, TYPE_F);
 
 	test_destroy(&tree);
+	ok(1, "white box test");
 
 	footer();
+	check_plan();
 }
 
 static void
 approximate_count()
 {
 	header();
+	plan(1);
 	srand(0);
 
 	approx tree;
@@ -749,7 +771,7 @@ approximate_count()
 	for (uint64_t i = 1; i <= long_sequence_count; i++)
 		for (uint64_t j = 0; j < i * long_sequence_multiplier; j++)
 			arr[count++] = ((i * 100 + 50) << 32) | j;
-	printf("Count: %llu %u\n", (unsigned long long)count, arr_size);
+	note("Count: %llu %u", (unsigned long long)count, arr_size);
 	assert(count == arr_size);
 
 	for (uint64_t i = 0; i < count * 10; i++) {
@@ -763,7 +785,7 @@ approximate_count()
 	for (uint64_t i = 0; i < count; i++)
 		approx_insert(&tree, arr[i], NULL);
 
-	printf("Count: %zu\n", tree.size);
+	note("Count: %zu", tree.size);
 
 	count = 0;
 	int err_count = 0;
@@ -788,7 +810,7 @@ approximate_count()
 			if (approx_count != true_count) {
 				err_count++;
 				if (err_count <= 10)
-					printf("searching %u found %llu expected %llu\n",
+					diag("searching %u found %llu expected %llu\n",
 					       i, (unsigned long long)approx_count,
 					       (unsigned long long)true_count);
 			}
@@ -802,24 +824,27 @@ approximate_count()
 		if (true_count < low || true_count > up) {
 			err_count++;
 			if (err_count <= 10)
-				printf("searching %u found %llu expected %llu\n",
+				diag("searching %u found %llu expected %llu\n",
 				       i, (unsigned long long)approx_count,
 				       (unsigned long long)true_count);
 		}
 	};
 
-	printf("Error count: %d\n", err_count);
-	printf("Count: %llu\n", (unsigned long long)count);
+	note("Error count: %d", err_count);
+	note("Count: %llu", (unsigned long long)count);
 
 	approx_destroy(&tree);
+	ok(1, "approximate count");
 
 	footer();
+	check_plan();
 }
 
 static void
 insert_get_iterator()
 {
 	header();
+	plan(1);
 
 	test tree;
 	test_create(&tree, 0, extent_alloc, extent_free, &extents_count);
@@ -833,14 +858,17 @@ insert_get_iterator()
 		bps_insert_and_check(test, &tree, i, NULL);
 	for (i = -9999; i < 10000; i += 2)
 		bps_insert_and_check(test, &tree, i, NULL)
+	ok(1, "insert get iterator");
 
 	footer();
+	check_plan();
 }
 
 static void
 delete_value_check()
 {
 	header();
+	plan(1);
 	struct_tree tree;
 	struct_tree_create(&tree, 0, extent_alloc, extent_free, &extents_count);
 	struct elem_t e1 = {1, 1};
@@ -855,17 +883,20 @@ delete_value_check()
 	if (struct_tree_find(&tree, 1) != NULL)
 		fail("test identical element deletion completion", "false");
 	struct_tree_destroy(&tree);
+	ok(1, "delete value check");
 	footer();
+	check_plan();
 }
 
 int
 main(void)
 {
+	plan(10);
 	simple_check();
 	compare_with_sptree_check();
 	compare_with_sptree_check_branches();
 	bps_tree_debug_self_check();
-	loading_test();
+	load_test();
 	printing_test();
 	white_box_test();
 	approximate_count();
@@ -873,4 +904,5 @@ main(void)
 		fail("memory leak!", "true");
 	insert_get_iterator();
 	delete_value_check();
+	check_plan();
 }
diff --git a/test/unit/bps_tree.result b/test/unit/bps_tree.result
deleted file mode 100644
index 130ec555c..000000000
--- a/test/unit/bps_tree.result
+++ /dev/null
@@ -1,284 +0,0 @@
-	*** simple_check ***
-Insert 1..X, remove 1..X
-Insert 1..X, remove X..1
-Insert X..1, remove 1..X
-Insert X..1, remove X..1
-	*** simple_check: done ***
-	*** compare_with_sptree_check ***
-	*** compare_with_sptree_check: done ***
-	*** compare_with_sptree_check_branches ***
-	*** compare_with_sptree_check_branches: done ***
-	*** bps_tree_debug_self_check ***
-	*** bps_tree_debug_self_check: done ***
-	*** loading_test ***
-	*** loading_test: done ***
-	*** printing_test ***
-Inserting 22
-[(1) 22]
-Inserting 21
-[(2) 21 22]
-Inserting 23
-[(3) 21 22 23]
-Inserting 20
-[(4) 20 21 22 23]
-Inserting 24
-[(5) 20 21 22 23 24]
-Inserting 19
-[(6) 19 20 21 22 23 24]
-Inserting 25
-[(7) 19 20 21 22 23 24 25]
-Inserting 18
-[(8) 18 19 20 21 22 23 24 25]
-Inserting 26
-[(9) 18 19 20 21 22 23 24 25 26]
-Inserting 17
-[(10) 17 18 19 20 21 22 23 24 25 26]
-Inserting 27
-[(11) 17 18 19 20 21 22 23 24 25 26 27]
-Inserting 16
-[(12) 16 17 18 19 20 21 22 23 24 25 26 27]
-Inserting 28
-[(13) 16 17 18 19 20 21 22 23 24 25 26 27 28]
-Inserting 15
-[(14) 15 16 17 18 19 20 21 22 23 24 25 26 27 28]
-Inserting 29
-  [(8) 15 16 17 18 19 20 21 22]
-22
-  [(7) 23 24 25 26 27 28 29]
-Inserting 14
-  [(9) 14 15 16 17 18 19 20 21 22]
-22
-  [(7) 23 24 25 26 27 28 29]
-Inserting 30
-  [(9) 14 15 16 17 18 19 20 21 22]
-22
-  [(8) 23 24 25 26 27 28 29 30]
-Inserting 13
-  [(10) 13 14 15 16 17 18 19 20 21 22]
-22
-  [(8) 23 24 25 26 27 28 29 30]
-Inserting 31
-  [(10) 13 14 15 16 17 18 19 20 21 22]
-22
-  [(9) 23 24 25 26 27 28 29 30 31]
-Inserting 12
-  [(11) 12 13 14 15 16 17 18 19 20 21 22]
-22
-  [(9) 23 24 25 26 27 28 29 30 31]
-Inserting 32
-  [(11) 12 13 14 15 16 17 18 19 20 21 22]
-22
-  [(10) 23 24 25 26 27 28 29 30 31 32]
-Inserting 11
-  [(12) 11 12 13 14 15 16 17 18 19 20 21 22]
-22
-  [(10) 23 24 25 26 27 28 29 30 31 32]
-Inserting 33
-  [(12) 11 12 13 14 15 16 17 18 19 20 21 22]
-22
-  [(11) 23 24 25 26 27 28 29 30 31 32 33]
-Inserting 10
-  [(13) 10 11 12 13 14 15 16 17 18 19 20 21 22]
-22
-  [(11) 23 24 25 26 27 28 29 30 31 32 33]
-Inserting 34
-  [(13) 10 11 12 13 14 15 16 17 18 19 20 21 22]
-22
-  [(12) 23 24 25 26 27 28 29 30 31 32 33 34]
-Inserting 9
-  [(14) 9 10 11 12 13 14 15 16 17 18 19 20 21 22]
-22
-  [(12) 23 24 25 26 27 28 29 30 31 32 33 34]
-Inserting 35
-  [(14) 9 10 11 12 13 14 15 16 17 18 19 20 21 22]
-22
-  [(13) 23 24 25 26 27 28 29 30 31 32 33 34 35]
-Inserting 8
-  [(14) 8 9 10 11 12 13 14 15 16 17 18 19 20 21]
-21
-  [(14) 22 23 24 25 26 27 28 29 30 31 32 33 34 35]
-Inserting 36
-  [(10) 8 9 10 11 12 13 14 15 16 17]
-17
-  [(10) 18 19 20 21 22 23 24 25 26 27]
-27
-  [(9) 28 29 30 31 32 33 34 35 36]
-Inserting 7
-  [(11) 7 8 9 10 11 12 13 14 15 16 17]
-17
-  [(10) 18 19 20 21 22 23 24 25 26 27]
-27
-  [(9) 28 29 30 31 32 33 34 35 36]
-Inserting 37
-  [(11) 7 8 9 10 11 12 13 14 15 16 17]
-17
-  [(10) 18 19 20 21 22 23 24 25 26 27]
-27
-  [(10) 28 29 30 31 32 33 34 35 36 37]
-Inserting 6
-  [(12) 6 7 8 9 10 11 12 13 14 15 16 17]
-17
-  [(10) 18 19 20 21 22 23 24 25 26 27]
-27
-  [(10) 28 29 30 31 32 33 34 35 36 37]
-Inserting 38
-  [(12) 6 7 8 9 10 11 12 13 14 15 16 17]
-17
-  [(10) 18 19 20 21 22 23 24 25 26 27]
-27
-  [(11) 28 29 30 31 32 33 34 35 36 37 38]
-Inserting 5
-  [(13) 5 6 7 8 9 10 11 12 13 14 15 16 17]
-17
-  [(10) 18 19 20 21 22 23 24 25 26 27]
-27
-  [(11) 28 29 30 31 32 33 34 35 36 37 38]
-Inserting 39
-  [(13) 5 6 7 8 9 10 11 12 13 14 15 16 17]
-17
-  [(10) 18 19 20 21 22 23 24 25 26 27]
-27
-  [(12) 28 29 30 31 32 33 34 35 36 37 38 39]
-Inserting 4
-  [(14) 4 5 6 7 8 9 10 11 12 13 14 15 16 17]
-17
-  [(10) 18 19 20 21 22 23 24 25 26 27]
-27
-  [(12) 28 29 30 31 32 33 34 35 36 37 38 39]
-Inserting 40
-  [(14) 4 5 6 7 8 9 10 11 12 13 14 15 16 17]
-17
-  [(10) 18 19 20 21 22 23 24 25 26 27]
-27
-  [(13) 28 29 30 31 32 33 34 35 36 37 38 39 40]
-Inserting 3
-  [(12) 3 4 5 6 7 8 9 10 11 12 13 14]
-14
-  [(13) 15 16 17 18 19 20 21 22 23 24 25 26 27]
-27
-  [(13) 28 29 30 31 32 33 34 35 36 37 38 39 40]
-Inserting 41
-  [(12) 3 4 5 6 7 8 9 10 11 12 13 14]
-14
-  [(13) 15 16 17 18 19 20 21 22 23 24 25 26 27]
-27
-  [(14) 28 29 30 31 32 33 34 35 36 37 38 39 40 41]
-Inserting 2
-  [(13) 2 3 4 5 6 7 8 9 10 11 12 13 14]
-14
-  [(13) 15 16 17 18 19 20 21 22 23 24 25 26 27]
-27
-  [(14) 28 29 30 31 32 33 34 35 36 37 38 39 40 41]
-Inserting 42
-  [(13) 2 3 4 5 6 7 8 9 10 11 12 13 14]
-14
-  [(14) 15 16 17 18 19 20 21 22 23 24 25 26 27 28]
-28
-  [(14) 29 30 31 32 33 34 35 36 37 38 39 40 41 42]
-Inserting 1
-  [(14) 1 2 3 4 5 6 7 8 9 10 11 12 13 14]
-14
-  [(14) 15 16 17 18 19 20 21 22 23 24 25 26 27 28]
-28
-  [(14) 29 30 31 32 33 34 35 36 37 38 39 40 41 42]
-Inserting 43
-  [(11) 1 2 3 4 5 6 7 8 9 10 11]
-11
-  [(11) 12 13 14 15 16 17 18 19 20 21 22]
-22
-  [(11) 23 24 25 26 27 28 29 30 31 32 33]
-33
-  [(10) 34 35 36 37 38 39 40 41 42 43]
-Inserting 0
-  [(12) 0 1 2 3 4 5 6 7 8 9 10 11]
-11
-  [(11) 12 13 14 15 16 17 18 19 20 21 22]
-22
-  [(11) 23 24 25 26 27 28 29 30 31 32 33]
-33
-  [(10) 34 35 36 37 38 39 40 41 42 43]
-	*** printing_test: done ***
-	*** white_box_test ***
-full leaf:
-[(14) 0 1 2 3 4 5 6 7 8 9 10 11 12 13]
-split now:
-  [(8) 0 1 2 3 4 5 6 7]
-7
-  [(7) 8 9 10 11 12 13 14]
-full 2 leafs:
-  [(14) 0 1 2 3 4 5 6 7 8 9 10 11 12 13]
-13
-  [(14) 14 15 16 17 18 19 20 21 22 23 24 25 26 27]
-split now:
-  [(10) 0 1 2 3 4 5 6 7 8 9]
-9
-  [(10) 10 11 12 13 14 15 16 17 18 19]
-19
-  [(9) 20 21 22 23 24 25 26 27 28]
-full 3 leafs:
-  [(14) 0 1 2 3 4 5 6 7 8 9 10 11 12 13]
-13
-  [(14) 14 15 16 17 18 19 20 21 22 23 24 25 26 27]
-27
-  [(14) 28 29 30 31 32 33 34 35 36 37 38 39 40 41]
-split now:
-  [(11) 0 1 2 3 4 5 6 7 8 9 10]
-10
-  [(11) 11 12 13 14 15 16 17 18 19 20 21]
-21
-  [(11) 22 23 24 25 26 27 28 29 30 31 32]
-32
-  [(10) 33 34 35 36 37 38 39 40 41 42]
-full 10 leafs:
-  [(14) 0 1 2 3 4 5 6 7 8 9 10 11 12 13]
-13
-  [(14) 14 15 16 17 18 19 20 21 22 23 24 25 26 27]
-27
-  [(14) 28 29 30 31 32 33 34 35 36 37 38 39 40 41]
-41
-  [(14) 42 43 44 45 46 47 48 49 50 51 52 53 54 55]
-55
-  [(14) 56 57 58 59 60 61 62 63 64 65 66 67 68 69]
-69
-  [(14) 70 71 72 73 74 75 76 77 78 79 80 81 82 83]
-83
-  [(14) 84 85 86 87 88 89 90 91 92 93 94 95 96 97]
-97
-  [(14) 98 99 100 101 102 103 104 105 106 107 108 109 110 111]
-111
-  [(14) 112 113 114 115 116 117 118 119 120 121 122 123 124 125]
-125
-  [(14) 126 127 128 129 130 131 132 133 134 135 136 137 138 139]
-2-level split now:
-    [(14) 0 1 2 3 4 5 6 7 8 9 10 11 12 13]
-  13
-    [(14) 14 15 16 17 18 19 20 21 22 23 24 25 26 27]
-  27
-    [(14) 28 29 30 31 32 33 34 35 36 37 38 39 40 41]
-  41
-    [(14) 42 43 44 45 46 47 48 49 50 51 52 53 54 55]
-  55
-    [(14) 56 57 58 59 60 61 62 63 64 65 66 67 68 69]
-  69
-    [(14) 70 71 72 73 74 75 76 77 78 79 80 81 82 83]
-83
-    [(14) 84 85 86 87 88 89 90 91 92 93 94 95 96 97]
-  97
-    [(11) 98 99 100 101 102 103 104 105 106 107 108]
-  108
-    [(11) 109 110 111 112 113 114 115 116 117 118 119]
-  119
-    [(11) 120 121 122 123 124 125 126 127 128 129 130]
-  130
-    [(10) 131 132 133 134 135 136 137 138 139 140]
-	*** white_box_test: done ***
-	*** approximate_count ***
-Count: 10575 10575
-Count: 10575
-Error count: 0
-Count: 10575
-	*** approximate_count: done ***
-	*** insert_get_iterator ***
-	*** insert_get_iterator: done ***
-	*** delete_value_check ***
-	*** delete_value_check: done ***
diff --git a/test/unit/bps_tree_iterator.cc b/test/unit/bps_tree_iterator.cc
index 5c800bc69..bf1685a47 100644
--- a/test/unit/bps_tree_iterator.cc
+++ b/test/unit/bps_tree_iterator.cc
@@ -67,6 +67,7 @@ static void
 iterator_check()
 {
 	header();
+	plan(1);
 
 	test tree;
 	test_create(&tree, 0, extent_alloc, extent_free,
@@ -94,7 +95,7 @@ iterator_check()
 			test_insert(&tree, e, 0);
 		}
 	}
-	printf("Test tree size: %d\n", (int)test_size(&tree));
+	note("Test tree size: %d\n", (int)test_size(&tree));
 
 	/* Test that tree filled ok */
 	for (long i = 0; i < count1 * count2; i++) {
@@ -107,25 +108,24 @@ iterator_check()
 
 	/* Print first 7 elems */
 	{
-		printf("--> ");
+		note("--> ");
 		test_iterator iterator = test_iterator_first(&tree);
 		for (int i = 0; i < 7; i++) {
 			elem_t *elem = test_iterator_get_elem(&tree, &iterator);
-			printf("(%ld,%ld) ", elem->first, elem->second);
+			note("(%ld,%ld) ", elem->first, elem->second);
 			test_iterator_next(&tree, &iterator);
 		}
-		printf("\n");
 	}
 	/* Print last 7 elems */
 	{
-		printf("<-- ");
+		note("<-- ");
 		test_iterator iterator = test_iterator_last(&tree);
 		for (int i = 0; i < 7; i++) {
 			elem_t *elem = test_iterator_get_elem(&tree, &iterator);
-			printf("(%ld,%ld) ", elem->first, elem->second);
+			note("(%ld,%ld) ", elem->first, elem->second);
 			test_iterator_prev(&tree, &iterator);
 		}
-		printf("\n");
+		note("\n");
 	}
 
 	/* Iterate forward all elements 5 times */
@@ -180,24 +180,23 @@ iterator_check()
 		test_iterator end = test_upper_bound(&tree, key, &has_this_key2);
 		if (has_this_key1 != has_this_key2)
 			fail("Exact flag is broken", "true");
-		printf("Key %ld, %s range [%s, %s): ", key,
+		note("Key %ld, %s range [%s, %s): ", key,
 			has_this_key1 ? "not empty" : "empty",
 			test_iterator_is_invalid(&begin) ? "eof" : "ptr",
 			test_iterator_is_invalid(&end) ? "eof" : "ptr");
 		test_iterator runner = begin;
 		while (!test_iterator_are_equal(&tree, &runner, &end)) {
 			elem_t *elem = test_iterator_get_elem(&tree, &runner);
-			printf("(%ld,%ld) ", elem->first, elem->second);
+			note("(%ld,%ld) ", elem->first, elem->second);
 			test_iterator_next(&tree, &runner);
 		}
-		printf(" <-> ");
+		note(" <-> ");
 		runner = end;
 		while (!test_iterator_are_equal(&tree, &runner, &begin)) {
 			test_iterator_prev(&tree, &runner);
 			elem_t *elem = test_iterator_get_elem(&tree, &runner);
-			printf("(%ld,%ld) ", elem->first, elem->second);
+			note("(%ld,%ld) ", elem->first, elem->second);
 		}
-		printf("\n");
 	}
 
 	/* Check iterating in range from lower bound to upper bound */
@@ -230,23 +229,22 @@ iterator_check()
 		struct elem_t upper_elem_key = {key, LONG_MAX};
 		test_iterator begin = test_lower_bound_elem(&tree, lower_elem_key, NULL);
 		test_iterator end = test_upper_bound_elem(&tree, upper_elem_key, NULL);
-		printf("Key %ld, range [%s, %s): ", key,
+		note("Key %ld, range [%s, %s): ", key,
 		       test_iterator_is_invalid(&begin) ? "eof" : "ptr",
 		       test_iterator_is_invalid(&end) ? "eof" : "ptr");
 		test_iterator runner = begin;
 		while (!test_iterator_are_equal(&tree, &runner, &end)) {
 			elem_t *elem = test_iterator_get_elem(&tree, &runner);
-			printf("(%ld,%ld) ", elem->first, elem->second);
+			note("(%ld,%ld) ", elem->first, elem->second);
 			test_iterator_next(&tree, &runner);
 		}
-		printf(" <-> ");
+		note(" <-> ");
 		runner = end;
 		while (!test_iterator_are_equal(&tree, &runner, &begin)) {
 			test_iterator_prev(&tree, &runner);
 			elem_t *elem = test_iterator_get_elem(&tree, &runner);
-			printf("(%ld,%ld) ", elem->first, elem->second);
+			note("(%ld,%ld) ", elem->first, elem->second);
 		}
-		printf("\n");
 	}
 
 	/* Check iterating in range from lower bound to upper bound */
@@ -274,6 +272,8 @@ iterator_check()
 	}
 
 	test_destroy(&tree);
+	ok(1, "iterator check");
+	check_plan();
 
 	footer();
 }
@@ -282,6 +282,7 @@ static void
 iterator_invalidate_check()
 {
 	header();
+	plan(1);
 
 	const long test_size = 300;
 	const long max_delete_count = 100;
@@ -453,6 +454,8 @@ iterator_invalidate_check()
 		test_destroy(&tree);
 	}
 
+	ok(1, "iterator_invalidate_check");
+	check_plan();
 	footer();
 }
 
@@ -460,6 +463,7 @@ static void
 iterator_freeze_check()
 {
 	header();
+	plan(1);
 
 	const int test_rounds_size = 10;
 	const int test_data_size = 1000;
@@ -539,6 +543,8 @@ iterator_freeze_check()
 		test_destroy(&tree);
 	}
 
+	ok(1, "iterator_freeze_check");
+	check_plan();
 	footer();
 }
 
@@ -547,10 +553,12 @@ int
 main(void)
 {
 	srand(time(0));
+	plan(3);
 	iterator_check();
 	iterator_invalidate_check();
 	iterator_freeze_check();
 	if (total_extents_allocated) {
 		fail("memory leak", "true");
 	}
+	check_plan();
 }
diff --git a/test/unit/bps_tree_iterator.result b/test/unit/bps_tree_iterator.result
deleted file mode 100644
index 8a2e97eec..000000000
--- a/test/unit/bps_tree_iterator.result
+++ /dev/null
@@ -1,21 +0,0 @@
-	*** iterator_check ***
-Test tree size: 50000
---> (0,0) (0,1) (0,2) (0,3) (0,4) (2,0) (2,1) 
-<-- (19998,4) (19998,3) (19998,2) (19998,1) (19998,0) (19996,4) (19996,3) 
-Key -1, empty range [ptr, ptr):  <-> 
-Key 0, not empty range [ptr, ptr): (0,0) (0,1) (0,2) (0,3) (0,4)  <-> (0,4) (0,3) (0,2) (0,1) (0,0) 
-Key 10, not empty range [ptr, ptr): (10,0) (10,1) (10,2) (10,3) (10,4)  <-> (10,4) (10,3) (10,2) (10,1) (10,0) 
-Key 15, empty range [ptr, ptr):  <-> 
-Key 19998, not empty range [ptr, eof): (19998,0) (19998,1) (19998,2) (19998,3) (19998,4)  <-> (19998,4) (19998,3) (19998,2) (19998,1) (19998,0) 
-Key 20000, empty range [eof, eof):  <-> 
-Key -1, range [ptr, ptr):  <-> 
-Key 0, range [ptr, ptr): (0,0) (0,1) (0,2) (0,3) (0,4)  <-> (0,4) (0,3) (0,2) (0,1) (0,0) 
-Key 10, range [ptr, ptr): (10,0) (10,1) (10,2) (10,3) (10,4)  <-> (10,4) (10,3) (10,2) (10,1) (10,0) 
-Key 15, range [ptr, ptr):  <-> 
-Key 19998, range [ptr, eof): (19998,0) (19998,1) (19998,2) (19998,3) (19998,4)  <-> (19998,4) (19998,3) (19998,2) (19998,1) (19998,0) 
-Key 20000, range [eof, eof):  <-> 
-	*** iterator_check: done ***
-	*** iterator_invalidate_check ***
-	*** iterator_invalidate_check: done ***
-	*** iterator_freeze_check ***
-	*** iterator_freeze_check: done ***
diff --git a/test/unit/cbus.c b/test/unit/cbus.c
index ecf5fce72..09225c586 100644
--- a/test/unit/cbus.c
+++ b/test/unit/cbus.c
@@ -49,7 +49,7 @@ flush_cb(struct trigger *t, void *e)
 	(void) t;
 	(void) e;
 	++flushed_cnt;
-	printf("flush event, counter = %d\n", flushed_cnt);
+	note("flush event, counter = %d", flushed_cnt);
 	return 0;
 }
 
@@ -59,7 +59,7 @@ finish_execution(struct cmsg *m)
 {
 	(void) m;
 	fiber_cancel(fiber());
-	printf("break main fiber and finish test\n");
+	note("break main fiber and finish test");
 	is(flushed_cnt, expected_flushed_cnt,
 	   "flushed_cnt at the end of the test");
 }
@@ -84,7 +84,7 @@ worker_f(va_list ap)
 static void
 worker_start()
 {
-	printf("start worker\n");
+	note("start worker");
 	fail_if(cord_costart(&worker, "worker", worker_f, NULL) != 0);
 	cpipe_create(&pipe_to_worker, "worker");
 }
@@ -92,7 +92,7 @@ worker_start()
 static void
 worker_stop()
 {
-	printf("finish worker\n");
+	note("finish worker");
 	cbus_stop_loop(&pipe_to_worker);
 	cpipe_destroy(&pipe_to_worker);
 	fail_if(cord_join(&worker) != 0);
@@ -126,7 +126,7 @@ test_forced_flush(struct cmsg *m)
 {
 	(void) m;
 	is(flushed_cnt, 1, "1 flush after test_several_messages");
-	printf("\n*** Test forced flush ***\n");
+	note("*** Test forced flush ***");
 	flushed_cnt = 0;
 	static struct cmsg_hop test_forced_flush_route =
 		{ do_forced_flush, NULL };
@@ -160,7 +160,7 @@ test_several_messages(struct cmsg *m)
 {
 	(void) m;
 	is(flushed_cnt, 1, "1 flush after test_single_msg");
-	printf("\n*** Test several messages ***\n");
+	note("*** Test several messages ***");
 	flushed_cnt = 0;
 	static struct cmsg_hop test_event_route[] = {
 		{ do_some_event, &pipe_to_main },
@@ -190,7 +190,7 @@ test_several_messages(struct cmsg *m)
 static void
 test_single_msg()
 {
-	printf("\n*** Test single message ***\n");
+	note("*** Test single message ***");
 	static struct cmsg_hop test_single_flush_route[] = {
 		{ do_nothing, &pipe_to_main },
 		/* Schedule the next test. */
@@ -231,13 +231,13 @@ main()
 	memory_init();
 	fiber_init(fiber_c_invoke);
 	cbus_init();
-	printf("start main fiber\n");
+	note("start main fiber");
 	struct fiber *main_fiber = fiber_new("main", main_f);
 	assert(main_fiber != NULL);
 	fiber_wakeup(main_fiber);
-	printf("start main loop\n");
+	note("start main loop");
 	ev_run(loop(), 0);
-	printf("finish main loop\n");
+	note("finish main loop");
 	cbus_free();
 	fiber_free();
 	memory_free();
diff --git a/test/unit/cbus.result b/test/unit/cbus.result
deleted file mode 100644
index e87f861f3..000000000
--- a/test/unit/cbus.result
+++ /dev/null
@@ -1,24 +0,0 @@
-	*** main ***
-1..6
-start main fiber
-start main loop
-start worker
-
-*** Test single message ***
-flush event, counter = 1
-ok 1 - 1 flush after test_single_msg
-
-*** Test several messages ***
-ok 2 - no flush during loop
-ok 3 - no flush during loop
-ok 4 - no flush during loop
-flush event, counter = 1
-ok 5 - 1 flush after test_several_messages
-
-*** Test forced flush ***
-flush event, counter = 1
-break main fiber and finish test
-ok 6 - flushed_cnt at the end of the test
-finish worker
-finish main loop
-	*** main: done ***
diff --git a/test/unit/cbus_hang.c b/test/unit/cbus_hang.c
index 8b3671001..eac283890 100644
--- a/test/unit/cbus_hang.c
+++ b/test/unit/cbus_hang.c
@@ -33,7 +33,7 @@ pthread_cond_t endpoint_hack_cond_2;
 static
 void join_fail(int signum) {
 	(void)signum;
-	printf("Can't join the hang worker\n");
+	diag("Can't join the hang worker\n");
 	exit(EXIT_FAILURE);
 }
 
diff --git a/test/unit/cbus_hang.result b/test/unit/cbus_hang.result
deleted file mode 100644
index d5810e8cf..000000000
--- a/test/unit/cbus_hang.result
+++ /dev/null
@@ -1,4 +0,0 @@
-	*** main ***
-1..1
-ok 1 - The hang worker has been joined
-	*** main: done ***
diff --git a/test/unit/cbus_stress.c b/test/unit/cbus_stress.c
index 37e8e0f77..4d0b58a35 100644
--- a/test/unit/cbus_stress.c
+++ b/test/unit/cbus_stress.c
@@ -1,4 +1,3 @@
-#include <assert.h>
 #include <stdarg.h>
 #include <stddef.h>
 #include <stdlib.h>
@@ -94,25 +93,25 @@ thread_func(va_list ap);
 static void
 thread_create(struct thread *t, int id)
 {
-	assert(thread_count > 1);
-	assert(id >= 0 && id < thread_count);
+	fail_if(thread_count <= 1);
+	fail_if(!(id >= 0 && id < thread_count));
 
 	const int neighbor_count = thread_count - 1;
 
 	t->id = id;
 	snprintf(t->name, sizeof(t->name), "thread_%d", id);
-	assert(t->name != NULL);
+	fail_if(t->name == NULL);
 
 	t->connections = calloc(thread_count, sizeof(*t->connections));
-	assert(t->connections != NULL);
+	fail_if(t->connections == NULL);
 
 	t->connected_count = 0;
 	t->connected = calloc(neighbor_count, sizeof(*t->connected));
-	assert(t->connected != NULL);
+	fail_if(t->connected == NULL);
 
 	t->disconnected_count = 0;
 	t->disconnected = calloc(neighbor_count, sizeof(*t->disconnected));
-	assert(t->disconnected != NULL);
+	fail_if(t->disconnected == NULL);
 
 	/* Initially, we are not connected to anyone. */
 	for (int i = 0; i < thread_count; i++) {
@@ -120,7 +119,7 @@ thread_create(struct thread *t, int id)
 			continue; /* can't connect to self */
 		t->disconnected[t->disconnected_count++] = i;
 	}
-	assert(t->disconnected_count == neighbor_count);
+	fail_if(t->disconnected_count != neighbor_count);
 
 	t->sent = t->received = 0;
 	active_thread_count++;
@@ -139,7 +138,7 @@ thread_start_test_cb(struct cmsg *cmsg)
 {
 	struct thread *t = container_of(cmsg, struct thread, cmsg);
 	struct fiber *test_fiber = fiber_new("test", test_func);
-	assert(test_fiber != NULL);
+	fail_if(test_fiber == NULL);
 	fiber_start(test_fiber, t);
 }
 
@@ -173,10 +172,10 @@ thread_destroy(struct thread *t)
 static void
 thread_connect(struct thread *t, int dest_id)
 {
-	assert(dest_id != t->id);
-	assert(dest_id < thread_count);
+	fail_if(dest_id == t->id);
+	fail_if(dest_id >= thread_count);
 	struct conn *conn = &t->connections[dest_id];
-	assert(!conn->active);
+	fail_if(conn->active);
 	cbus_pair(thread_name(dest_id), t->name,
 		  &conn->to, &conn->from, NULL, NULL, NULL);
 	conn->active = true;
@@ -186,10 +185,10 @@ thread_connect(struct thread *t, int dest_id)
 static void
 thread_disconnect(struct thread *t, int dest_id)
 {
-	assert(dest_id != t->id);
-	assert(dest_id < thread_count);
+	fail_if(dest_id == t->id);
+	fail_if(dest_id >= thread_count);
 	struct conn *conn = &t->connections[dest_id];
-	assert(conn->active);
+	fail_if(!(conn->active));
 	cbus_unpair(&conn->to, &conn->from, NULL, NULL, NULL);
 	conn->active = false;
 }
@@ -198,8 +197,8 @@ thread_disconnect(struct thread *t, int dest_id)
 static void
 thread_connect_random(struct thread *t)
 {
-	assert(t->disconnected_count > 0);
-	assert(t->connected_count + t->disconnected_count == thread_count - 1);
+	fail_if(t->disconnected_count <= 0);
+	fail_if(t->connected_count + t->disconnected_count != thread_count - 1);
 	int idx = rand() % t->disconnected_count;
 	int dest_id = t->disconnected[idx];
 	t->disconnected[idx] = t->disconnected[--t->disconnected_count];
@@ -211,8 +210,8 @@ thread_connect_random(struct thread *t)
 static void
 thread_disconnect_random(struct thread *t)
 {
-	assert(t->connected_count > 0);
-	assert(t->connected_count + t->disconnected_count == thread_count - 1);
+	fail_if(t->connected_count <= 0);
+	fail_if(t->connected_count + t->disconnected_count != thread_count - 1);
 	int idx = rand() % t->connected_count;
 	int dest_id = t->connected[idx];
 	t->connected[idx] = t->connected[--t->connected_count];
@@ -242,9 +241,9 @@ thread_send(struct thread *t, int dest_id)
 		{ thread_msg_received_cb, NULL }
 	};
 	struct conn *c = &t->connections[dest_id];
-	assert(c->active);
+	fail_if(!(c->active));
 	struct thread_msg *msg = malloc(sizeof(*msg));
-	assert(msg != NULL);
+	fail_if(msg == NULL);
 	cmsg_init(&msg->cmsg, route);
 	msg->dest_id = dest_id;
 	cpipe_push(&c->to, &msg->cmsg);
@@ -255,7 +254,7 @@ thread_send(struct thread *t, int dest_id)
 static void
 thread_send_random(struct thread *t)
 {
-	assert(t->connected_count > 0);
+	fail_if(t->connected_count <= 0);
 	int idx = rand() % t->connected_count;
 	int dest_id = t->connected[idx];
 	thread_send(t, dest_id);
@@ -276,7 +275,7 @@ static void
 test_complete_cb(struct cmsg *cmsg)
 {
 	(void)cmsg;
-	assert(active_thread_count > 0);
+	fail_if(active_thread_count <= 0);
 	if (--active_thread_count == 0) {
 		/* Stop the main fiber when all workers are done. */
 		fiber_cancel(fiber());
@@ -334,7 +333,7 @@ main_func(va_list ap)
 	cbus_endpoint_create(&endpoint, "main", fiber_schedule_cb, fiber());
 
 	threads = calloc(thread_count, sizeof(*threads));
-	assert(threads != NULL);
+	fail_if(threads == NULL);
 
 	for (int i = 0; i < thread_count; i++)
 		thread_create(&threads[i], i);
@@ -351,7 +350,7 @@ main_func(va_list ap)
 		received += t->received;
 		thread_destroy(t);
 	}
-	assert(sent == received);
+	fail_if(sent != received);
 
 	cbus_endpoint_destroy(&endpoint, cbus_process);
 
@@ -373,12 +372,14 @@ main()
 	cbus_init();
 
 	header();
+	plan(1);
 
 	struct fiber *main_fiber = fiber_new("main", main_func);
-	assert(main_fiber != NULL);
+	isnt(main_fiber, NULL, "fiber started");
 	fiber_wakeup(main_fiber);
 	ev_run(loop(), 0);
 
+	check_plan();
 	footer();
 
 	cbus_free();
diff --git a/test/unit/cbus_stress.result b/test/unit/cbus_stress.result
deleted file mode 100644
index 8300f0550..000000000
--- a/test/unit/cbus_stress.result
+++ /dev/null
@@ -1,2 +0,0 @@
-	*** main ***
-	*** main: done ***
diff --git a/test/unit/checkpoint_schedule.result b/test/unit/checkpoint_schedule.result
deleted file mode 100644
index e34c762a1..000000000
--- a/test/unit/checkpoint_schedule.result
+++ /dev/null
@@ -1,41 +0,0 @@
-	*** main ***
-1..38
-ok 1 - checkpointing disabled - timeout after configuration
-ok 2 - checkpointing disabled - timeout after sleep
-ok 3 - checkpointing disabled - timeout after reset
-ok 4 - checkpoint interval 100 - timeout after configuration
-ok 5 - checkpoint interval 100 - initial timeout randomization
-ok 6 - checkpoint interval 100 - timeout after sleep 1
-ok 7 - checkpoint interval 100 - timeout after sleep 2
-ok 8 - checkpoint interval 100 - timeout after sleep 3
-ok 9 - checkpoint interval 100 - timeout after sleep 4
-ok 10 - checkpoint interval 100 - timeout after reset
-ok 11 - checkpoint interval 600 - timeout after configuration
-ok 12 - checkpoint interval 600 - initial timeout randomization
-ok 13 - checkpoint interval 600 - timeout after sleep 1
-ok 14 - checkpoint interval 600 - timeout after sleep 2
-ok 15 - checkpoint interval 600 - timeout after sleep 3
-ok 16 - checkpoint interval 600 - timeout after sleep 4
-ok 17 - checkpoint interval 600 - timeout after reset
-ok 18 - checkpoint interval 1200 - timeout after configuration
-ok 19 - checkpoint interval 1200 - initial timeout randomization
-ok 20 - checkpoint interval 1200 - timeout after sleep 1
-ok 21 - checkpoint interval 1200 - timeout after sleep 2
-ok 22 - checkpoint interval 1200 - timeout after sleep 3
-ok 23 - checkpoint interval 1200 - timeout after sleep 4
-ok 24 - checkpoint interval 1200 - timeout after reset
-ok 25 - checkpoint interval 1800 - timeout after configuration
-ok 26 - checkpoint interval 1800 - initial timeout randomization
-ok 27 - checkpoint interval 1800 - timeout after sleep 1
-ok 28 - checkpoint interval 1800 - timeout after sleep 2
-ok 29 - checkpoint interval 1800 - timeout after sleep 3
-ok 30 - checkpoint interval 1800 - timeout after sleep 4
-ok 31 - checkpoint interval 1800 - timeout after reset
-ok 32 - checkpoint interval 3600 - timeout after configuration
-ok 33 - checkpoint interval 3600 - initial timeout randomization
-ok 34 - checkpoint interval 3600 - timeout after sleep 1
-ok 35 - checkpoint interval 3600 - timeout after sleep 2
-ok 36 - checkpoint interval 3600 - timeout after sleep 3
-ok 37 - checkpoint interval 3600 - timeout after sleep 4
-ok 38 - checkpoint interval 3600 - timeout after reset
-	*** main: done ***
diff --git a/test/unit/coio.result b/test/unit/coio.result
deleted file mode 100644
index 5019fa48a..000000000
--- a/test/unit/coio.result
+++ /dev/null
@@ -1,12 +0,0 @@
-	*** stat_timeout_test ***
-	*** stat_timeout_test: done ***
-	*** stat_notify_test ***
-# filename: 1.out
-	*** stat_notify_test: done ***
-	*** test_call_f ***
-# call done with res 0
-	*** test_call_f: done ***
-	*** test_getaddrinfo ***
-1..1
-ok 1 - getaddrinfo
-	*** test_getaddrinfo: done ***
diff --git a/test/unit/coll.cpp b/test/unit/coll.cpp
index 8d7a3ff1e..16d2e28b4 100644
--- a/test/unit/coll.cpp
+++ b/test/unit/coll.cpp
@@ -2,7 +2,6 @@
 #include <vector>
 #include <algorithm>
 #include <string.h>
-#include <assert.h>
 #include <msgpuck.h>
 #include <diag.h>
 #include <fiber.h>
@@ -30,12 +29,13 @@ void
 test_sort_strings(vector<const char *> &strings, struct coll *coll)
 {
 	sort(strings.begin(), strings.end(), comp(coll));
-	cout << strings[0] << endl;
+	cout << "# " << strings[0] << endl;
 	for (size_t i = 1; i < strings.size(); i++) {
 		int cmp = coll->cmp(strings[i], strlen(strings[i]),
 				    strings[i - 1], strlen(strings[i - 1]),
 				    coll);
-		cout << strings[i]
+		cout << "# "
+		     << strings[i]
 		     << (cmp < 0 ? " LESS" : cmp > 0 ? " GREATER " : " EQUAL")
 		     << endl;
 	}
@@ -45,6 +45,7 @@ void
 manual_test()
 {
 	header();
+	plan(7);
 
 	vector<const char *> strings;
 	struct coll_def def;
@@ -54,62 +55,56 @@ manual_test()
 	def.icu.strength = COLL_ICU_STRENGTH_IDENTICAL;
 	struct coll *coll;
 
-	cout << " -- default ru_RU -- " << endl;
 	coll = coll_new(&def);
-	assert(coll != NULL);
+	isnt(coll, NULL, "-- default ru_RU --")
 	strings = {"Б", "бб", "е", "ЕЕЕЕ", "ё", "Ё", "и", "И", "123", "45" };
 	test_sort_strings(strings, coll);
 	coll_unref(coll);
 
-	cout << " -- --||-- + upper first -- " << endl;
 	def.icu.case_first = COLL_ICU_CF_UPPER_FIRST;
 	coll = coll_new(&def);
-	assert(coll != NULL);
+	isnt(coll, NULL, "-- --||-- + upper first --")
 	strings = {"Б", "бб", "е", "ЕЕЕЕ", "ё", "Ё", "и", "И", "123", "45" };
 	test_sort_strings(strings, coll);
 	coll_unref(coll);
 
-	cout << " -- --||-- + lower first -- " << endl;
 	def.icu.case_first = COLL_ICU_CF_LOWER_FIRST;
 	coll = coll_new(&def);
-	assert(coll != NULL);
+	isnt(coll, NULL, "-- --||-- + lower first --")
 	strings = {"Б", "бб", "е", "ЕЕЕЕ", "ё", "Ё", "и", "И", "123", "45" };
 	test_sort_strings(strings, coll);
 	coll_unref(coll);
 
-	cout << " -- --||-- + secondary strength + numeric -- " << endl;
 	def.icu.strength = COLL_ICU_STRENGTH_SECONDARY;
 	def.icu.numeric_collation = COLL_ICU_ON;
 	coll = coll_new(&def);
-	assert(coll != NULL);
+	isnt(coll, NULL, "-- --||-- + secondary strength + numeric --")
 	strings = {"Б", "бб", "е", "ЕЕЕЕ", "ё", "Ё", "и", "И", "123", "45" };
 	test_sort_strings(strings, coll);
 	coll_unref(coll);
 
-	cout << " -- --||-- + case level -- " << endl;
 	def.icu.case_level = COLL_ICU_ON;
 	coll = coll_new(&def);
-	assert(coll != NULL);
+	isnt(coll, NULL, "-- --||-- + case level --")
 	strings = {"Б", "бб", "е", "ЕЕЕЕ", "ё", "Ё", "и", "И", "123", "45" };
 	test_sort_strings(strings, coll);
 	coll_unref(coll);
 
-	cout << " -- en_EN -- " << endl;
 	snprintf(def.locale, sizeof(def.locale), "%s", "en_EN-EN");
 	coll = coll_new(&def);
-	assert(coll != NULL);
+	isnt(coll, NULL, "-- en_EN --")
 	strings = {"aa", "bb", "cc", "ch", "dd", "gg", "hh", "ii" };
 	test_sort_strings(strings, coll);
 	coll_unref(coll);
 
-	cout << " -- cs_CZ -- " << endl;
 	snprintf(def.locale, sizeof(def.locale), "%s", "cs_CZ");
 	coll = coll_new(&def);
-	assert(coll != NULL);
+	isnt(coll, NULL, "-- cs_CZ --")
 	strings = {"aa", "bb", "cc", "ch", "dd", "gg", "hh", "ii" };
 	test_sort_strings(strings, coll);
 	coll_unref(coll);
 
+	check_plan();
 	footer();
 }
 
@@ -127,6 +122,7 @@ void
 hash_test()
 {
 	header();
+	plan(8);
 
 	struct coll_def def;
 	memset(&def, 0, sizeof(def));
@@ -137,23 +133,22 @@ hash_test()
 
 	/* Case sensitive */
 	coll = coll_new(&def);
-	assert(coll != NULL);
-	cout << "Case sensitive" << endl;
-	cout << (calc_hash("ае", coll) != calc_hash("аё", coll) ? "OK" : "Fail") << endl;
-	cout << (calc_hash("ае", coll) != calc_hash("аЕ", coll) ? "OK" : "Fail") << endl;
-	cout << (calc_hash("аЕ", coll) != calc_hash("аё", coll) ? "OK" : "Fail") << endl;
+	isnt(coll, NULL, "Case sensitive");
+	isnt(calc_hash("ае", coll), calc_hash("аё", coll), "ае != аё");
+	isnt(calc_hash("ае", coll), calc_hash("аЕ", coll), "ае != аЕ");
+	isnt(calc_hash("аЕ", coll), calc_hash("аё", coll), "аЕ != аё");
 	coll_unref(coll);
 
 	/* Case insensitive */
 	def.icu.strength = COLL_ICU_STRENGTH_SECONDARY;
 	coll = coll_new(&def);
-	assert(coll != NULL);
-	cout << "Case insensitive" << endl;
-	cout << (calc_hash("ае", coll) != calc_hash("аё", coll) ? "OK" : "Fail") << endl;
-	cout << (calc_hash("ае", coll) == calc_hash("аЕ", coll) ? "OK" : "Fail") << endl;
-	cout << (calc_hash("аЕ", coll) != calc_hash("аё", coll) ? "OK" : "Fail") << endl;
+	isnt(coll, NULL, "Case insensitive");
+	isnt(calc_hash("ае", coll), calc_hash("аё", coll), "ае != аё");
+	is(calc_hash("ае", coll), calc_hash("аЕ", coll), "ае == аЕ");
+	isnt(calc_hash("аЕ", coll), calc_hash("аё", coll), "аЕ != аё");
 	coll_unref(coll);
 
+	check_plan();
 	footer();
 }
 
@@ -187,6 +182,7 @@ cache_test()
 int
 main(int, const char**)
 {
+	plan(3);
 	coll_init();
 	memory_init();
 	fiber_init(fiber_c_invoke);
@@ -196,4 +192,5 @@ main(int, const char**)
 	fiber_free();
 	memory_free();
 	coll_free();
+	check_plan();
 }
diff --git a/test/unit/coll.result b/test/unit/coll.result
deleted file mode 100644
index 269764246..000000000
--- a/test/unit/coll.result
+++ /dev/null
@@ -1,90 +0,0 @@
-	*** manual_test ***
- -- default ru_RU -- 
-123
-45 GREATER 
-Б GREATER 
-бб GREATER 
-е GREATER 
-ё GREATER 
-Ё GREATER 
-ЕЕЕЕ GREATER 
-и GREATER 
-И GREATER 
- -- --||-- + upper first -- 
-123
-45 GREATER 
-Б GREATER 
-бб GREATER 
-е GREATER 
-Ё GREATER 
-ё GREATER 
-ЕЕЕЕ GREATER 
-И GREATER 
-и GREATER 
- -- --||-- + lower first -- 
-123
-45 GREATER 
-Б GREATER 
-бб GREATER 
-е GREATER 
-ё GREATER 
-Ё GREATER 
-ЕЕЕЕ GREATER 
-и GREATER 
-И GREATER 
- -- --||-- + secondary strength + numeric -- 
-45
-123 GREATER 
-Б GREATER 
-бб GREATER 
-е GREATER 
-ё GREATER 
-Ё EQUAL
-ЕЕЕЕ GREATER 
-и GREATER 
-И EQUAL
- -- --||-- + case level -- 
-45
-123 GREATER 
-Б GREATER 
-бб GREATER 
-е GREATER 
-ё GREATER 
-Ё GREATER 
-ЕЕЕЕ GREATER 
-и GREATER 
-И GREATER 
- -- en_EN -- 
-aa
-bb GREATER 
-cc GREATER 
-ch GREATER 
-dd GREATER 
-gg GREATER 
-hh GREATER 
-ii GREATER 
- -- cs_CZ -- 
-aa
-bb GREATER 
-cc GREATER 
-dd GREATER 
-gg GREATER 
-hh GREATER 
-ch GREATER 
-ii GREATER 
-	*** manual_test: done ***
-	*** hash_test ***
-Case sensitive
-OK
-OK
-OK
-Case insensitive
-OK
-OK
-OK
-	*** hash_test: done ***
-	*** cache_test ***
-1..2
-ok 1 - collations with the same definition are not duplicated
-ok 2 - collations with different definitions are different objects
-	*** cache_test: done ***
diff --git a/test/unit/column_mask.result b/test/unit/column_mask.result
deleted file mode 100644
index 1d87a2f24..000000000
--- a/test/unit/column_mask.result
+++ /dev/null
@@ -1,36 +0,0 @@
-	*** main ***
-1..28
-ok 1 - check result length
-ok 2 - tuple update is correct
-ok 3 - column_mask is correct
-ok 4 - check result length
-ok 5 - tuple update is correct
-ok 6 - column_mask is correct
-ok 7 - check result length
-ok 8 - tuple update is correct
-ok 9 - column_mask is correct
-ok 10 - check result length
-ok 11 - tuple update is correct
-ok 12 - column_mask is correct
-ok 13 - check result length
-ok 14 - tuple update is correct
-ok 15 - column_mask is correct
-ok 16 - check result length
-ok 17 - tuple update is correct
-ok 18 - column_mask is correct
-ok 19 - check result length
-ok 20 - tuple update is correct
-ok 21 - column_mask is correct
-ok 22 - check result length
-ok 23 - tuple update is correct
-ok 24 - column_mask is correct
-ok 25 - check result length
-ok 26 - tuple update is correct
-ok 27 - column_mask is correct
-	*** test_paths ***
-    1..2
-    ok 1 - JSON update works
-    ok 2 - column mask match
-ok 28 - subtests
-	*** test_paths: done ***
-	*** main: done ***
diff --git a/test/unit/crypto.result b/test/unit/crypto.result
deleted file mode 100644
index 6e01896b1..000000000
--- a/test/unit/crypto.result
+++ /dev/null
@@ -1,132 +0,0 @@
-	*** main ***
-1..5
-ok 1 - crypto checks that algo argument is correct
-	*** test_aes128_codec ***
-    1..20
-    ok 1 - encrypt returns needed number of bytes
-    ok 2 - encrypt does not write anything when too small buffer
-    ok 3 - encrypt does not allow 0 sized buffer
-    ok 4 - encrypt requires additional block when buffer size is multiple of block size
-    ok 5 - AES 126 IV size is 16
-    ok 6 - encrypt works when buffer is big enough
-    ok 7 - encrypt returns the same on second call
-    ok 8 - encrypted data is the same
-    ok 9 - and it is not just copied from the plain text
-    ok 10 - decrypt also checks length and returns needed number of bytes
-    ok 11 - decrypt returns correct number of bytes
-    ok 12 - and correctly decrypts data
-    ok 13 - decrypt can't correctly decode anything with a wrong IV
-    ok 14 - in case decrypt has totally failed, diag is set
-    ok 15 - encrypt with different IV and the same number of written bytes returned
-    ok 16 - the encrypted data looks different
-    ok 17 - decrypt works with correct but another IV
-    ok 18 - data is the same
-    ok 19 - encrypt with one codec, but decrypt with another codec and the same key
-    ok 20 - data is the same
-ok 2 - subtests
-	*** test_aes128_codec: done ***
-	*** test_aes128_stress ***
-    1..1
-    ok 1 - try encrypt/decrypt on a variety of sizes, keys, and ivs
-ok 3 - subtests
-	*** test_aes128_stress: done ***
-	*** test_each ***
-    1..80
-    ok 1 - none 0 ECB, create iv of size 0
-    ok 2 - encode
-    ok 3 - decode
-    ok 4 - data is correct
-    ok 5 - none 0 CBC, create iv of size 0
-    ok 6 - encode
-    ok 7 - decode
-    ok 8 - data is correct
-    ok 9 - none 0 CFB, create iv of size 0
-    ok 10 - encode
-    ok 11 - decode
-    ok 12 - data is correct
-    ok 13 - none 0 OFB, create iv of size 0
-    ok 14 - encode
-    ok 15 - decode
-    ok 16 - data is correct
-    ok 17 - AES128 16 ECB, create iv of size 0
-    ok 18 - encode
-    ok 19 - decode
-    ok 20 - data is correct
-    ok 21 - AES128 16 CBC, create iv of size 16
-    ok 22 - encode
-    ok 23 - decode
-    ok 24 - data is correct
-    ok 25 - AES128 16 CFB, create iv of size 16
-    ok 26 - encode
-    ok 27 - decode
-    ok 28 - data is correct
-    ok 29 - AES128 16 OFB, create iv of size 16
-    ok 30 - encode
-    ok 31 - decode
-    ok 32 - data is correct
-    ok 33 - AES192 24 ECB, create iv of size 0
-    ok 34 - encode
-    ok 35 - decode
-    ok 36 - data is correct
-    ok 37 - AES192 24 CBC, create iv of size 16
-    ok 38 - encode
-    ok 39 - decode
-    ok 40 - data is correct
-    ok 41 - AES192 24 CFB, create iv of size 16
-    ok 42 - encode
-    ok 43 - decode
-    ok 44 - data is correct
-    ok 45 - AES192 24 OFB, create iv of size 16
-    ok 46 - encode
-    ok 47 - decode
-    ok 48 - data is correct
-    ok 49 - AES256 32 ECB, create iv of size 0
-    ok 50 - encode
-    ok 51 - decode
-    ok 52 - data is correct
-    ok 53 - AES256 32 CBC, create iv of size 16
-    ok 54 - encode
-    ok 55 - decode
-    ok 56 - data is correct
-    ok 57 - AES256 32 CFB, create iv of size 16
-    ok 58 - encode
-    ok 59 - decode
-    ok 60 - data is correct
-    ok 61 - AES256 32 OFB, create iv of size 16
-    ok 62 - encode
-    ok 63 - decode
-    ok 64 - data is correct
-    ok 65 - DES 8 ECB, create iv of size 0
-    ok 66 - encode
-    ok 67 - decode
-    ok 68 - data is correct
-    ok 69 - DES 8 CBC, create iv of size 8
-    ok 70 - encode
-    ok 71 - decode
-    ok 72 - data is correct
-    ok 73 - DES 8 CFB, create iv of size 8
-    ok 74 - encode
-    ok 75 - decode
-    ok 76 - data is correct
-    ok 77 - DES 8 OFB, create iv of size 8
-    ok 78 - encode
-    ok 79 - decode
-    ok 80 - data is correct
-ok 4 - subtests
-	*** test_each: done ***
-	*** test_stream ***
-    1..11
-    ok 1 - stream begin checks key size
-    ok 2 - stream begin checks iv size
-    ok 3 - begin encryption
-    ok 4 - append checks size
-    ok 5 - append 5
-    ok 6 - append 10
-    ok 7 - last append 30
-    ok 8 - commit checks size
-    ok 9 - commit 16
-    ok 10 - decoder returned correct size
-    ok 11 - data is decoded correctly
-ok 5 - subtests
-	*** test_stream: done ***
-	*** main: done ***
diff --git a/test/unit/csv.result b/test/unit/csv.result
index 8f9dab5b2..783388aca 100644
--- a/test/unit/csv.result
+++ b/test/unit/csv.result
@@ -1,30 +1,30 @@
-	*** test1 ***
+# *** test1 ***
 |1|
 ||
 |1|	|2|	|3|
 |123|
-	*** test1: done ***
-	*** test2 ***
+# *** test1: done ***
+# *** test2 ***
 |123|	|456|	|abcac|	|'multiword field 4'|
 |none|	|none|	|0|
 ||	||	||
 ||	||	||
-	*** test2: done ***
-	*** test3 ***
+# *** test2: done ***
+# *** test3 ***
 |1|	||	|2|
-	*** test3: done ***
-	*** test4 ***
+# *** test3: done ***
+# *** test4 ***
 |123|	|5|	|92|	|0|	|0|
 |1|	|12  34|	|56|	|quote , |	|66|
 |ok|
-	*** test4: done ***
-	*** test5 ***
+# *** test4: done ***
+# *** test5 ***
 |abc|	|longlonglonglonglonglonglonglonglonglonglonglonglonglonglonglonglonglong|	|0|
 |123|	|456|	||
 |0|	||	||
 valid: yes
-	*** test5: done ***
-	*** test6 ***
+# *** test5: done ***
+# *** test6 ***
 ||
 ||
 |abc|
@@ -36,67 +36,67 @@ valid: yes
 ||
 | |
 valid: NO
-	*** test6: done ***
-	*** big_chunk_separated_test ***
+# *** test6: done ***
+# *** big_chunk_separated_test ***
 line_cnt=10000, fieldsizes_cnt=1920000, 1920000
-	*** big_chunk_separated_test: done ***
-	*** random_generated_test ***
+# *** big_chunk_separated_test: done ***
+# *** random_generated_test ***
 line_cnt=40, fieldsizes_cnt=183
 valid: yes
-	*** random_generated_test: done ***
-	*** common_test ***
+# *** random_generated_test: done ***
+# *** common_test ***
 |first|	|last|	|address|	|city|	|zip|
 |John|	|Doe|	|120 any st.|	|Anytown, WW|	|08123|
-	*** common_test: done ***
-	*** common_test ***
+# *** common_test: done ***
+# *** common_test ***
 |a|	|b|	|c|
 |1|	|"|	|"|
 |2|	|3|	|4|
-	*** common_test: done ***
-	*** common_test ***
+# *** common_test: done ***
+# *** common_test ***
 |a|	|b|
 |1|	|ha "ha" ha|
 |3|	|4|
-	*** common_test: done ***
-	*** common_test ***
+# *** common_test: done ***
+# *** common_test ***
 |key|	|val|
 |1|	|{"type": "Point", "coordinates": [102.0, 0.5]}|
-	*** common_test: done ***
-	*** common_test ***
+# *** common_test: done ***
+# *** common_test ***
 |a|	|b|	|c|
 |1|	|2|	|3|
 |Once upon 
 a time|	|5|	|6|
 |7|	|8|	|9|
-	*** common_test: done ***
-	*** common_test ***
+# *** common_test: done ***
+# *** common_test ***
 |a|	|b|
 |1|	|ha
 "ha"
 ha|
 |3|	|4|
-	*** common_test: done ***
-	*** common_test ***
+# *** common_test: done ***
+# *** common_test ***
 |a|	|b|	|c|
 |1|	|2|	|3|
 |4|	|5|	|а нет ли ошибок?|
-	*** common_test: done ***
-	*** common_test ***
+# *** common_test: done ***
+# *** common_test ***
 |www|	|aaa|	|tt  |
-	*** common_test: done ***
-	*** iter_test1 ***
+# *** common_test: done ***
+# *** iter_test1 ***
 ||	|d|	|e|
 |12|	|42|	|3|
 |o|
-	*** iter_test1: done ***
-	*** iter_test2 ***
+# *** iter_test1: done ***
+# *** iter_test2 ***
 |1|
 |23|
-	*** iter_test2: done ***
-	*** iter_test3 ***
+# *** iter_test2: done ***
+# *** iter_test3 ***
 |1|	|2|	|3|
 |4|	|5|	|6|
-	*** iter_test3: done ***
-	*** csv_out ***
+# *** iter_test3: done ***
+# *** csv_out ***
 abc<len=3>,"with,comma"<len=12>,""in quotes""<len=13>,1 "" quote<len=10>
-	*** csv_out: done ***
+# *** csv_out: done ***
diff --git a/test/unit/decimal.result b/test/unit/decimal.result
deleted file mode 100644
index e8432fb36..000000000
--- a/test/unit/decimal.result
+++ /dev/null
@@ -1,700 +0,0 @@
-1..281
-ok 1 - decimal(314)
-ok 2 - decimal(271)
-ok 3 - decimal(314) + decimal(271)
-ok 4 - decimal((314) + (271))
-ok 5 - decimal(314) + decimal(271) == (314) + (271)
-ok 6 - decimal(314) - decimal(271)
-ok 7 - decimal((314) - (271))
-ok 8 - decimal(314) - decimal(271) == (314) - (271)
-ok 9 - decimal(314) * decimal(271)
-ok 10 - decimal((314) * (271))
-ok 11 - decimal_round((314) * (271), 15)
-ok 12 - decimal(314) * decimal(271) == (314) * (271)
-ok 13 - decimal(314) / decimal(271)
-ok 14 - decimal((314) / (271))
-ok 15 - decimal_round((314)/(271), 15)
-ok 16 - decimal(314) / decimal(271) == (314) / (271)
-ok 17 - decimal(65535)
-ok 18 - decimal(23456)
-ok 19 - decimal(65535) + decimal(23456)
-ok 20 - decimal((65535) + (23456))
-ok 21 - decimal(65535) + decimal(23456) == (65535) + (23456)
-ok 22 - decimal(65535) - decimal(23456)
-ok 23 - decimal((65535) - (23456))
-ok 24 - decimal(65535) - decimal(23456) == (65535) - (23456)
-ok 25 - decimal(65535) * decimal(23456)
-ok 26 - decimal((65535) * (23456))
-ok 27 - decimal_round((65535) * (23456), 15)
-ok 28 - decimal(65535) * decimal(23456) == (65535) * (23456)
-ok 29 - decimal(65535) / decimal(23456)
-ok 30 - decimal((65535) / (23456))
-ok 31 - decimal_round((65535)/(23456), 15)
-ok 32 - decimal(65535) / decimal(23456) == (65535) / (23456)
-ok 33 - decimal(0)
-ok 34 - decimal(1)
-ok 35 - decimal(0) + decimal(1)
-ok 36 - decimal((0) + (1))
-ok 37 - decimal(0) + decimal(1) == (0) + (1)
-ok 38 - decimal(0) - decimal(1)
-ok 39 - decimal((0) - (1))
-ok 40 - decimal(0) - decimal(1) == (0) - (1)
-ok 41 - decimal(0) * decimal(1)
-ok 42 - decimal((0) * (1))
-ok 43 - decimal_round((0) * (1), 15)
-ok 44 - decimal(0) * decimal(1) == (0) * (1)
-ok 45 - decimal(0) / decimal(1)
-ok 46 - decimal((0) / (1))
-ok 47 - decimal_round((0)/(1), 15)
-ok 48 - decimal(0) / decimal(1) == (0) / (1)
-ok 49 - decimal(0)
-ok 50 - decimal(-1)
-ok 51 - decimal(0) + decimal(-1)
-ok 52 - decimal((0) + (-1))
-ok 53 - decimal(0) + decimal(-1) == (0) + (-1)
-ok 54 - decimal(0) - decimal(-1)
-ok 55 - decimal((0) - (-1))
-ok 56 - decimal(0) - decimal(-1) == (0) - (-1)
-ok 57 - decimal(0) * decimal(-1)
-ok 58 - decimal((0) * (-1))
-ok 59 - decimal_round((0) * (-1), 15)
-ok 60 - decimal(0) * decimal(-1) == (0) * (-1)
-ok 61 - decimal(0) / decimal(-1)
-ok 62 - decimal((0) / (-1))
-ok 63 - decimal_round((0)/(-1), 15)
-ok 64 - decimal(0) / decimal(-1) == (0) / (-1)
-ok 65 - decimal(-1)
-ok 66 - decimal(1)
-ok 67 - decimal(-1) + decimal(1)
-ok 68 - decimal((-1) + (1))
-ok 69 - decimal(-1) + decimal(1) == (-1) + (1)
-ok 70 - decimal(-1) - decimal(1)
-ok 71 - decimal((-1) - (1))
-ok 72 - decimal(-1) - decimal(1) == (-1) - (1)
-ok 73 - decimal(-1) * decimal(1)
-ok 74 - decimal((-1) * (1))
-ok 75 - decimal_round((-1) * (1), 15)
-ok 76 - decimal(-1) * decimal(1) == (-1) * (1)
-ok 77 - decimal(-1) / decimal(1)
-ok 78 - decimal((-1) / (1))
-ok 79 - decimal_round((-1)/(1), 15)
-ok 80 - decimal(-1) / decimal(1) == (-1) / (1)
-ok 81 - decimal(INT_MIN)
-ok 82 - decimal(INT_MAX)
-ok 83 - decimal(INT_MIN) + decimal(INT_MAX)
-ok 84 - decimal((INT_MIN) + (INT_MAX))
-ok 85 - decimal(INT_MIN) + decimal(INT_MAX) == (INT_MIN) + (INT_MAX)
-ok 86 - decimal(INT_MIN) - decimal(INT_MAX)
-ok 87 - decimal((INT_MIN) - (INT_MAX))
-ok 88 - decimal(INT_MIN) - decimal(INT_MAX) == (INT_MIN) - (INT_MAX)
-ok 89 - decimal(INT_MIN) * decimal(INT_MAX)
-ok 90 - decimal((INT_MIN) * (INT_MAX))
-ok 91 - decimal_round((INT_MIN) * (INT_MAX), 15)
-ok 92 - decimal(INT_MIN) * decimal(INT_MAX) == (INT_MIN) * (INT_MAX)
-ok 93 - decimal(INT_MIN) / decimal(INT_MAX)
-ok 94 - decimal((INT_MIN) / (INT_MAX))
-ok 95 - decimal_round((INT_MIN)/(INT_MAX), 15)
-ok 96 - decimal(INT_MIN) / decimal(INT_MAX) == (INT_MIN) / (INT_MAX)
-ok 97 - decimal(-314)
-ok 98 - decimal(-271)
-ok 99 - decimal(-314) + decimal(-271)
-ok 100 - decimal((-314) + (-271))
-ok 101 - decimal(-314) + decimal(-271) == (-314) + (-271)
-ok 102 - decimal(-314) - decimal(-271)
-ok 103 - decimal((-314) - (-271))
-ok 104 - decimal(-314) - decimal(-271) == (-314) - (-271)
-ok 105 - decimal(-314) * decimal(-271)
-ok 106 - decimal((-314) * (-271))
-ok 107 - decimal_round((-314) * (-271), 15)
-ok 108 - decimal(-314) * decimal(-271) == (-314) * (-271)
-ok 109 - decimal(-314) / decimal(-271)
-ok 110 - decimal((-314) / (-271))
-ok 111 - decimal_round((-314)/(-271), 15)
-ok 112 - decimal(-314) / decimal(-271) == (-314) / (-271)
-ok 113 - decimal(-159615516)
-ok 114 - decimal(172916921)
-ok 115 - decimal(-159615516) + decimal(172916921)
-ok 116 - decimal((-159615516) + (172916921))
-ok 117 - decimal(-159615516) + decimal(172916921) == (-159615516) + (172916921)
-ok 118 - decimal(-159615516) - decimal(172916921)
-ok 119 - decimal((-159615516) - (172916921))
-ok 120 - decimal(-159615516) - decimal(172916921) == (-159615516) - (172916921)
-ok 121 - decimal(-159615516) * decimal(172916921)
-ok 122 - decimal((-159615516) * (172916921))
-ok 123 - decimal_round((-159615516) * (172916921), 15)
-ok 124 - decimal(-159615516) * decimal(172916921) == (-159615516) * (172916921)
-ok 125 - decimal(-159615516) / decimal(172916921)
-ok 126 - decimal((-159615516) / (172916921))
-ok 127 - decimal_round((-159615516)/(172916921), 15)
-ok 128 - decimal(-159615516) / decimal(172916921) == (-159615516) / (172916921)
-ok 129 - decimal(1.1)
-ok 130 - decimal(2.3)
-ok 131 - decimal(1.1) + decimal(2.3)
-ok 132 - decimal((1.1) + (2.3))
-ok 133 - decimal(1.1) + decimal(2.3) == (1.1) + (2.3)
-ok 134 - decimal(1.1) - decimal(2.3)
-ok 135 - decimal((1.1) - (2.3))
-ok 136 - decimal(1.1) - decimal(2.3) == (1.1) - (2.3)
-ok 137 - decimal(1.1) * decimal(2.3)
-ok 138 - decimal((1.1) * (2.3))
-ok 139 - decimal_round((1.1) * (2.3), 15)
-ok 140 - decimal(1.1) * decimal(2.3) == (1.1) * (2.3)
-ok 141 - decimal(1.1) / decimal(2.3)
-ok 142 - decimal((1.1) / (2.3))
-ok 143 - decimal_round((1.1)/(2.3), 15)
-ok 144 - decimal(1.1) / decimal(2.3) == (1.1) / (2.3)
-ok 145 - decimal(1e10)
-ok 146 - decimal(1e10)
-ok 147 - decimal(1e10) + decimal(1e10)
-ok 148 - decimal((1e10) + (1e10))
-ok 149 - decimal(1e10) + decimal(1e10) == (1e10) + (1e10)
-ok 150 - decimal(1e10) - decimal(1e10)
-ok 151 - decimal((1e10) - (1e10))
-ok 152 - decimal(1e10) - decimal(1e10) == (1e10) - (1e10)
-ok 153 - decimal(1e10) * decimal(1e10)
-ok 154 - decimal((1e10) * (1e10))
-ok 155 - decimal_round((1e10) * (1e10), 15)
-ok 156 - decimal(1e10) * decimal(1e10) == (1e10) * (1e10)
-ok 157 - decimal(1e10) / decimal(1e10)
-ok 158 - decimal((1e10) / (1e10))
-ok 159 - decimal_round((1e10)/(1e10), 15)
-ok 160 - decimal(1e10) / decimal(1e10) == (1e10) / (1e10)
-ok 161 - decimal(1.23456789)
-ok 162 - decimal(4.567890123)
-ok 163 - decimal(1.23456789) + decimal(4.567890123)
-ok 164 - decimal((1.23456789) + (4.567890123))
-ok 165 - decimal(1.23456789) + decimal(4.567890123) == (1.23456789) + (4.567890123)
-ok 166 - decimal(1.23456789) - decimal(4.567890123)
-ok 167 - decimal((1.23456789) - (4.567890123))
-ok 168 - decimal(1.23456789) - decimal(4.567890123) == (1.23456789) - (4.567890123)
-ok 169 - decimal(1.23456789) * decimal(4.567890123)
-ok 170 - decimal((1.23456789) * (4.567890123))
-ok 171 - decimal_round((1.23456789) * (4.567890123), 15)
-ok 172 - decimal(1.23456789) * decimal(4.567890123) == (1.23456789) * (4.567890123)
-ok 173 - decimal(1.23456789) / decimal(4.567890123)
-ok 174 - decimal((1.23456789) / (4.567890123))
-ok 175 - decimal_round((1.23456789)/(4.567890123), 15)
-ok 176 - decimal(1.23456789) / decimal(4.567890123) == (1.23456789) / (4.567890123)
-ok 177 - decimal_from_string(1e-38)
-ok 178 - decimal_from_string(1e-38)
-ok 179 - decimal_from_string(2e-38)
-ok 180 - decimal_add(1e-38, 1e-38)
-ok 181 - decimal_compare(2e-38)
-ok 182 - decimal_from_string(-1e-38)
-ok 183 - decimal_from_string(1e-38)
-ok 184 - decimal_from_string(0)
-ok 185 - decimal_add(-1e-38, 1e-38)
-ok 186 - decimal_compare(0)
-ok 187 - decimal_from_string(1e-39)
-ok 188 - decimal_from_string(0)
-ok 189 - decimal_from_string(0)
-ok 190 - decimal_add(1e-39, 0)
-ok 191 - decimal_compare(0)
-ok 192 - decimal_from_string(1e-39)
-ok 193 - decimal_from_string(1e-38)
-ok 194 - decimal_from_string(1e-38)
-ok 195 - decimal_add(1e-39, 1e-38)
-ok 196 - decimal_compare(1e-38)
-ok 197 - decimal_from_string(1e-19)
-ok 198 - decimal_from_string(1e-19)
-ok 199 - decimal_from_string(1e-38)
-ok 200 - decimal_mul(1e-19, 1e-19)
-ok 201 - decimal_compare(1e-38)
-ok 202 - decimal_from_string(1e37)
-ok 203 - decimal_from_string(0)
-ok 204 - decimal_from_string(1e37)
-ok 205 - decimal_add(1e37, 0)
-ok 206 - decimal_compare(1e37)
-ok 207 - decimal_from_string(1e18)
-ok 208 - decimal_from_string(1e18)
-ok 209 - decimal_from_string(1e36)
-ok 210 - decimal_mul(1e18, 1e18)
-ok 211 - decimal_compare(1e36)
-ok 212 - decimal_from_string(10)
-ok 213 - decimal_from_string(2)
-ok 214 - decimal_from_string(100)
-ok 215 - decimal_pow(10, 2)
-ok 216 - decimal_compare(100)
-ok 217 - decimal_from_string(2)
-ok 218 - decimal_from_string(10)
-ok 219 - decimal_from_string(1024)
-ok 220 - decimal_pow(2, 10)
-ok 221 - decimal_compare(1024)
-ok 222 - decimal_from_string(100)
-ok 223 - decimal_from_string(0.5)
-ok 224 - decimal_from_string(10)
-ok 225 - decimal_pow(100, 0.5)
-ok 226 - decimal_compare(10)
-ok 227 - decimal_from_string(100)
-ok 228 - decimal_from_string(2)
-ok 229 - decimal_log10(100)
-ok 230 - decimal_compare(2)
-ok 231 - decimal_from_string(10)
-ok 232 - decimal_from_string(2.3)
-ok 233 - decimal_ln(10)
-ok 234 - decimal_compare(2.3)
-ok 235 - decimal_from_string(1.1)
-ok 236 - decimal_from_string(0.1)
-ok 237 - decimal_ln(1.1)
-ok 238 - decimal_compare(0.1)
-ok 239 - decimal_from_string(1.0000000000000000000000000000000000001)
-ok 240 - decimal_from_string(0.0000000000000000000000000000000000001)
-ok 241 - decimal_ln(1.0000000000000000000000000000000000001)
-ok 242 - decimal_compare(0.0000000000000000000000000000000000001)
-ok 243 - decimal_from_string(2)
-ok 244 - decimal_from_string(7.39)
-ok 245 - decimal_exp(2)
-ok 246 - decimal_compare(7.39)
-ok 247 - decimal_from_string(100)
-ok 248 - decimal_from_string(10)
-ok 249 - decimal_sqrt(100)
-ok 250 - decimal_compare(10)
-ok 251 - decimal construction from 2e38 failure
-ok 252 - decimal construction from "1e38" failure
-ok 253 - decimal construction from "100000000000000000000000000000000000000" failure
-ok 254 - decimal construction from "inf" failure
-ok 255 - decimal construction from "NaN" failure
-ok 256 - decimal construction from "a random string" failure
-ok 257 - decimal construction from LONG_MIN success
-ok 258 - decimal construction from LONG_MAX success
-ok 259 - decimal construction from ULONG_MAX success
-ok 260 - decimal_from_string(9e37)
-ok 261 - decimal_from_string(1e37)
-ok 262 - decimal_add(9e37, 1e37) - overflow
-ok 263 - decimal_from_string(1e19)
-ok 264 - decimal_from_string(1e19)
-ok 265 - decimal_mul(1e19, 1e19) - overflow
-ok 266 - decimal_from_string(1e19)
-ok 267 - decimal_from_string(1e-19)
-ok 268 - decimal_div(1e19, 1e-19) - overflow
-ok 269 - decimal_from_string(0)
-ok 270 - decimal_ln(0) - error on wrong operands.
-ok 271 - decimal_from_string(-1)
-ok 272 - decimal_ln(-1) - error on wrong operands.
-ok 273 - decimal_from_string(0)
-ok 274 - decimal_log10(0) - error on wrong operands.
-ok 275 - decimal_from_string(-1)
-ok 276 - decimal_log10(-1) - error on wrong operands.
-ok 277 - decimal_from_string(-10)
-ok 278 - decimal_sqrt(-10) - error on wrong operands.
-    1..66
-    ok 1 - Conversion of 18446744073709551615 to decimal and back to uint64 successful
-    ok 2 - Conversion back to uint64 correct
-    ok 3 - Conversion of 9223372036854775807 to decimal and back to int64 successful
-    ok 4 - Conversion back to int64 correct
-    ok 5 - Conversion of -9223372036854775808 to decimal and back to int64 successful
-    ok 6 - Conversion back to int64 correct
-    ok 7 - Conversion of 0 to decimal and back to uint64 successful
-    ok 8 - Conversion back to uint64 correct
-    ok 9 - Conversion of 0 to decimal and back to int64 successful
-    ok 10 - Conversion back to int64 correct
-    ok 11 - Conversion of -1 to decimal and back to int64 successful
-    ok 12 - Conversion back to int64 correct
-    ok 13 - Conversion of 117495185182863386 to decimal and back to uint64 successful
-    ok 14 - Conversion back to uint64 correct
-    ok 15 - Conversion of 58747592591431693 to decimal and back to int64 successful
-    ok 16 - Conversion back to int64 correct
-    ok 17 - Conversion of -58747592591431693 to decimal and back to int64 successful
-    ok 18 - Conversion back to int64 correct
-    ok 19 - Conversion of 778113809158035 to decimal and back to uint64 successful
-    ok 20 - Conversion back to uint64 correct
-    ok 21 - Conversion of 389056904579017 to decimal and back to int64 successful
-    ok 22 - Conversion back to int64 correct
-    ok 23 - Conversion of -389056904579017 to decimal and back to int64 successful
-    ok 24 - Conversion back to int64 correct
-    ok 25 - Conversion of 5222240329919 to decimal and back to uint64 successful
-    ok 26 - Conversion back to uint64 correct
-    ok 27 - Conversion of 2611120164959 to decimal and back to int64 successful
-    ok 28 - Conversion back to int64 correct
-    ok 29 - Conversion of -2611120164959 to decimal and back to int64 successful
-    ok 30 - Conversion back to int64 correct
-    ok 31 - Conversion of 37570074315 to decimal and back to uint64 successful
-    ok 32 - Conversion back to uint64 correct
-    ok 33 - Conversion of 18785037157 to decimal and back to int64 successful
-    ok 34 - Conversion back to int64 correct
-    ok 35 - Conversion of -18785037157 to decimal and back to int64 successful
-    ok 36 - Conversion back to int64 correct
-    ok 37 - Conversion of 274234119 to decimal and back to uint64 successful
-    ok 38 - Conversion back to uint64 correct
-    ok 39 - Conversion of 137996015 to decimal and back to int64 successful
-    ok 40 - Conversion back to int64 correct
-    ok 41 - Conversion of -137996015 to decimal and back to int64 successful
-    ok 42 - Conversion back to int64 correct
-    ok 43 - Conversion of 4294967295 to decimal and back to uint64 successful
-    ok 44 - Conversion back to uint64 correct
-    ok 45 - Conversion of 2147483647 to decimal and back to int64 successful
-    ok 46 - Conversion back to int64 correct
-    ok 47 - Conversion of -2147483648 to decimal and back to int64 successful
-    ok 48 - Conversion back to int64 correct
-    ok 49 - Conversion of 27356479 to decimal and back to uint64 successful
-    ok 50 - Conversion back to uint64 correct
-    ok 51 - Conversion of 13678239 to decimal and back to int64 successful
-    ok 52 - Conversion back to int64 correct
-    ok 53 - Conversion of -13678239 to decimal and back to int64 successful
-    ok 54 - Conversion back to int64 correct
-    ok 55 - Conversion of 181168 to decimal and back to uint64 successful
-    ok 56 - Conversion back to uint64 correct
-    ok 57 - Conversion of 90584 to decimal and back to int64 successful
-    ok 58 - Conversion back to int64 correct
-    ok 59 - Conversion of -90584 to decimal and back to int64 successful
-    ok 60 - Conversion back to int64 correct
-    ok 61 - Conversion of 1215 to decimal and back to uint64 successful
-    ok 62 - Conversion back to uint64 correct
-    ok 63 - Conversion of 607 to decimal and back to int64 successful
-    ok 64 - Conversion back to int64 correct
-    ok 65 - Conversion of -607 to decimal and back to int64 successful
-    ok 66 - Conversion back to int64 correct
-ok 279 - subtests
-    1..151
-    ok 1 - decimal_len(0)
-    ok 2 - decimal_len(0) == len(decimal_pack(0)
-    ok 3 - decimal_unpack(decimal_pack(0))
-    ok 4 - decimal_unpack(decimal_pack(0)) len
-    ok 5 - decimal_unpack(decimal_pack(0)) value
-    ok 6 - decimal_unpack(decimal_pack(0)) scale
-    ok 7 - decimal_unpack(decimal_pack(0)) precision
-    ok 8 - str(decimal_unpack(decimal_pack(0)) == 0
-    ok 9 - decimal_len(-0)
-    ok 10 - decimal_len(-0) == len(decimal_pack(-0)
-    ok 11 - decimal_unpack(decimal_pack(-0))
-    ok 12 - decimal_unpack(decimal_pack(-0)) len
-    ok 13 - decimal_unpack(decimal_pack(-0)) value
-    ok 14 - decimal_unpack(decimal_pack(-0)) scale
-    ok 15 - decimal_unpack(decimal_pack(-0)) precision
-    ok 16 - str(decimal_unpack(decimal_pack(-0)) == -0
-    ok 17 - decimal_len(1)
-    ok 18 - decimal_len(1) == len(decimal_pack(1)
-    ok 19 - decimal_unpack(decimal_pack(1))
-    ok 20 - decimal_unpack(decimal_pack(1)) len
-    ok 21 - decimal_unpack(decimal_pack(1)) value
-    ok 22 - decimal_unpack(decimal_pack(1)) scale
-    ok 23 - decimal_unpack(decimal_pack(1)) precision
-    ok 24 - str(decimal_unpack(decimal_pack(1)) == 1
-    ok 25 - decimal_len(-1)
-    ok 26 - decimal_len(-1) == len(decimal_pack(-1)
-    ok 27 - decimal_unpack(decimal_pack(-1))
-    ok 28 - decimal_unpack(decimal_pack(-1)) len
-    ok 29 - decimal_unpack(decimal_pack(-1)) value
-    ok 30 - decimal_unpack(decimal_pack(-1)) scale
-    ok 31 - decimal_unpack(decimal_pack(-1)) precision
-    ok 32 - str(decimal_unpack(decimal_pack(-1)) == -1
-    ok 33 - decimal_len(0.1)
-    ok 34 - decimal_len(0.1) == len(decimal_pack(0.1)
-    ok 35 - decimal_unpack(decimal_pack(0.1))
-    ok 36 - decimal_unpack(decimal_pack(0.1)) len
-    ok 37 - decimal_unpack(decimal_pack(0.1)) value
-    ok 38 - decimal_unpack(decimal_pack(0.1)) scale
-    ok 39 - decimal_unpack(decimal_pack(0.1)) precision
-    ok 40 - str(decimal_unpack(decimal_pack(0.1)) == 0.1
-    ok 41 - decimal_len(-0.1)
-    ok 42 - decimal_len(-0.1) == len(decimal_pack(-0.1)
-    ok 43 - decimal_unpack(decimal_pack(-0.1))
-    ok 44 - decimal_unpack(decimal_pack(-0.1)) len
-    ok 45 - decimal_unpack(decimal_pack(-0.1)) value
-    ok 46 - decimal_unpack(decimal_pack(-0.1)) scale
-    ok 47 - decimal_unpack(decimal_pack(-0.1)) precision
-    ok 48 - str(decimal_unpack(decimal_pack(-0.1)) == -0.1
-    ok 49 - decimal_len(2.718281828459045)
-    ok 50 - decimal_len(2.718281828459045) == len(decimal_pack(2.718281828459045)
-    ok 51 - decimal_unpack(decimal_pack(2.718281828459045))
-    ok 52 - decimal_unpack(decimal_pack(2.718281828459045)) len
-    ok 53 - decimal_unpack(decimal_pack(2.718281828459045)) value
-    ok 54 - decimal_unpack(decimal_pack(2.718281828459045)) scale
-    ok 55 - decimal_unpack(decimal_pack(2.718281828459045)) precision
-    ok 56 - str(decimal_unpack(decimal_pack(2.718281828459045)) == 2.718281828459045
-    ok 57 - decimal_len(-2.718281828459045)
-    ok 58 - decimal_len(-2.718281828459045) == len(decimal_pack(-2.718281828459045)
-    ok 59 - decimal_unpack(decimal_pack(-2.718281828459045))
-    ok 60 - decimal_unpack(decimal_pack(-2.718281828459045)) len
-    ok 61 - decimal_unpack(decimal_pack(-2.718281828459045)) value
-    ok 62 - decimal_unpack(decimal_pack(-2.718281828459045)) scale
-    ok 63 - decimal_unpack(decimal_pack(-2.718281828459045)) precision
-    ok 64 - str(decimal_unpack(decimal_pack(-2.718281828459045)) == -2.718281828459045
-    ok 65 - decimal_len(3.141592653589793)
-    ok 66 - decimal_len(3.141592653589793) == len(decimal_pack(3.141592653589793)
-    ok 67 - decimal_unpack(decimal_pack(3.141592653589793))
-    ok 68 - decimal_unpack(decimal_pack(3.141592653589793)) len
-    ok 69 - decimal_unpack(decimal_pack(3.141592653589793)) value
-    ok 70 - decimal_unpack(decimal_pack(3.141592653589793)) scale
-    ok 71 - decimal_unpack(decimal_pack(3.141592653589793)) precision
-    ok 72 - str(decimal_unpack(decimal_pack(3.141592653589793)) == 3.141592653589793
-    ok 73 - decimal_len(-3.141592653589793)
-    ok 74 - decimal_len(-3.141592653589793) == len(decimal_pack(-3.141592653589793)
-    ok 75 - decimal_unpack(decimal_pack(-3.141592653589793))
-    ok 76 - decimal_unpack(decimal_pack(-3.141592653589793)) len
-    ok 77 - decimal_unpack(decimal_pack(-3.141592653589793)) value
-    ok 78 - decimal_unpack(decimal_pack(-3.141592653589793)) scale
-    ok 79 - decimal_unpack(decimal_pack(-3.141592653589793)) precision
-    ok 80 - str(decimal_unpack(decimal_pack(-3.141592653589793)) == -3.141592653589793
-    ok 81 - decimal_len(1234567891234567890.0987654321987654321)
-    ok 82 - decimal_len(1234567891234567890.0987654321987654321) == len(decimal_pack(1234567891234567890.0987654321987654321)
-    ok 83 - decimal_unpack(decimal_pack(1234567891234567890.0987654321987654321))
-    ok 84 - decimal_unpack(decimal_pack(1234567891234567890.0987654321987654321)) len
-    ok 85 - decimal_unpack(decimal_pack(1234567891234567890.0987654321987654321)) value
-    ok 86 - decimal_unpack(decimal_pack(1234567891234567890.0987654321987654321)) scale
-    ok 87 - decimal_unpack(decimal_pack(1234567891234567890.0987654321987654321)) precision
-    ok 88 - str(decimal_unpack(decimal_pack(1234567891234567890.0987654321987654321)) == 1234567891234567890.0987654321987654321
-    ok 89 - decimal_len(-1234567891234567890.0987654321987654321)
-    ok 90 - decimal_len(-1234567891234567890.0987654321987654321) == len(decimal_pack(-1234567891234567890.0987654321987654321)
-    ok 91 - decimal_unpack(decimal_pack(-1234567891234567890.0987654321987654321))
-    ok 92 - decimal_unpack(decimal_pack(-1234567891234567890.0987654321987654321)) len
-    ok 93 - decimal_unpack(decimal_pack(-1234567891234567890.0987654321987654321)) value
-    ok 94 - decimal_unpack(decimal_pack(-1234567891234567890.0987654321987654321)) scale
-    ok 95 - decimal_unpack(decimal_pack(-1234567891234567890.0987654321987654321)) precision
-    ok 96 - str(decimal_unpack(decimal_pack(-1234567891234567890.0987654321987654321)) == -1234567891234567890.0987654321987654321
-    ok 97 - decimal_len(0.0000000000000000000000000000000000001)
-    ok 98 - decimal_len(0.0000000000000000000000000000000000001) == len(decimal_pack(0.0000000000000000000000000000000000001)
-    ok 99 - decimal_unpack(decimal_pack(0.0000000000000000000000000000000000001))
-    ok 100 - decimal_unpack(decimal_pack(0.0000000000000000000000000000000000001)) len
-    ok 101 - decimal_unpack(decimal_pack(0.0000000000000000000000000000000000001)) value
-    ok 102 - decimal_unpack(decimal_pack(0.0000000000000000000000000000000000001)) scale
-    ok 103 - decimal_unpack(decimal_pack(0.0000000000000000000000000000000000001)) precision
-    ok 104 - str(decimal_unpack(decimal_pack(0.0000000000000000000000000000000000001)) == 0.0000000000000000000000000000000000001
-    ok 105 - decimal_len(-0.0000000000000000000000000000000000001)
-    ok 106 - decimal_len(-0.0000000000000000000000000000000000001) == len(decimal_pack(-0.0000000000000000000000000000000000001)
-    ok 107 - decimal_unpack(decimal_pack(-0.0000000000000000000000000000000000001))
-    ok 108 - decimal_unpack(decimal_pack(-0.0000000000000000000000000000000000001)) len
-    ok 109 - decimal_unpack(decimal_pack(-0.0000000000000000000000000000000000001)) value
-    ok 110 - decimal_unpack(decimal_pack(-0.0000000000000000000000000000000000001)) scale
-    ok 111 - decimal_unpack(decimal_pack(-0.0000000000000000000000000000000000001)) precision
-    ok 112 - str(decimal_unpack(decimal_pack(-0.0000000000000000000000000000000000001)) == -0.0000000000000000000000000000000000001
-    ok 113 - decimal_len(0.00000000000000000000000000000000000001)
-    ok 114 - decimal_len(0.00000000000000000000000000000000000001) == len(decimal_pack(0.00000000000000000000000000000000000001)
-    ok 115 - decimal_unpack(decimal_pack(0.00000000000000000000000000000000000001))
-    ok 116 - decimal_unpack(decimal_pack(0.00000000000000000000000000000000000001)) len
-    ok 117 - decimal_unpack(decimal_pack(0.00000000000000000000000000000000000001)) value
-    ok 118 - decimal_unpack(decimal_pack(0.00000000000000000000000000000000000001)) scale
-    ok 119 - decimal_unpack(decimal_pack(0.00000000000000000000000000000000000001)) precision
-    ok 120 - str(decimal_unpack(decimal_pack(0.00000000000000000000000000000000000001)) == 0.00000000000000000000000000000000000001
-    ok 121 - decimal_len(-0.00000000000000000000000000000000000001)
-    ok 122 - decimal_len(-0.00000000000000000000000000000000000001) == len(decimal_pack(-0.00000000000000000000000000000000000001)
-    ok 123 - decimal_unpack(decimal_pack(-0.00000000000000000000000000000000000001))
-    ok 124 - decimal_unpack(decimal_pack(-0.00000000000000000000000000000000000001)) len
-    ok 125 - decimal_unpack(decimal_pack(-0.00000000000000000000000000000000000001)) value
-    ok 126 - decimal_unpack(decimal_pack(-0.00000000000000000000000000000000000001)) scale
-    ok 127 - decimal_unpack(decimal_pack(-0.00000000000000000000000000000000000001)) precision
-    ok 128 - str(decimal_unpack(decimal_pack(-0.00000000000000000000000000000000000001)) == -0.00000000000000000000000000000000000001
-    ok 129 - decimal_len(99999999999999999999999999999999999999)
-    ok 130 - decimal_len(99999999999999999999999999999999999999) == len(decimal_pack(99999999999999999999999999999999999999)
-    ok 131 - decimal_unpack(decimal_pack(99999999999999999999999999999999999999))
-    ok 132 - decimal_unpack(decimal_pack(99999999999999999999999999999999999999)) len
-    ok 133 - decimal_unpack(decimal_pack(99999999999999999999999999999999999999)) value
-    ok 134 - decimal_unpack(decimal_pack(99999999999999999999999999999999999999)) scale
-    ok 135 - decimal_unpack(decimal_pack(99999999999999999999999999999999999999)) precision
-    ok 136 - str(decimal_unpack(decimal_pack(99999999999999999999999999999999999999)) == 99999999999999999999999999999999999999
-    ok 137 - decimal_len(-99999999999999999999999999999999999999)
-    ok 138 - decimal_len(-99999999999999999999999999999999999999) == len(decimal_pack(-99999999999999999999999999999999999999)
-    ok 139 - decimal_unpack(decimal_pack(-99999999999999999999999999999999999999))
-    ok 140 - decimal_unpack(decimal_pack(-99999999999999999999999999999999999999)) len
-    ok 141 - decimal_unpack(decimal_pack(-99999999999999999999999999999999999999)) value
-    ok 142 - decimal_unpack(decimal_pack(-99999999999999999999999999999999999999)) scale
-    ok 143 - decimal_unpack(decimal_pack(-99999999999999999999999999999999999999)) precision
-    ok 144 - str(decimal_unpack(decimal_pack(-99999999999999999999999999999999999999)) == -99999999999999999999999999999999999999
-    ok 145 - decimal_len() is small for positive exponent decimal
-    ok 146 - positive exponent decimal length
-    ok 147 - decimal_unpack() of a positive exponent decimal
-    ok 148 - decimal_unpack uses every byte packed by decimal_pack
-    ok 149 - positive exponent number is packed/unpacked correctly
-    ok 150 - unpack malformed decimal fails
-    ok 151 - decode malformed decimal preserves buffer position
-ok 280 - subtests
-    1..198
-    ok 1 - mp_sizeof_decimal(0)
-    ok 2 - mp_sizeof_decimal(0) == len(mp_encode_decimal(0))
-    ok 3 - mp_next(mp_encode(0))
-    ok 4 - mp_decode(mp_encode(0) len
-    ok 5 - mp_decode(mp_encode(0)) value
-    ok 6 - mp_decode(mp_encode(0)) scale
-    ok 7 - str(mp_decode(mp_encode(0))) == 0
-    ok 8 - mp_ext_type is MP_DECIMAL
-    ok 9 - decimal_unpack() after mp_decode_extl()
-    ok 10 - decimal_unpack() after mp_decode_extl() value
-    ok 11 - decimal_unpack() after mp_decode_extl() len
-    ok 12 - mp_sizeof_decimal(-0)
-    ok 13 - mp_sizeof_decimal(-0) == len(mp_encode_decimal(-0))
-    ok 14 - mp_next(mp_encode(-0))
-    ok 15 - mp_decode(mp_encode(-0) len
-    ok 16 - mp_decode(mp_encode(-0)) value
-    ok 17 - mp_decode(mp_encode(-0)) scale
-    ok 18 - str(mp_decode(mp_encode(-0))) == -0
-    ok 19 - mp_ext_type is MP_DECIMAL
-    ok 20 - decimal_unpack() after mp_decode_extl()
-    ok 21 - decimal_unpack() after mp_decode_extl() value
-    ok 22 - decimal_unpack() after mp_decode_extl() len
-    ok 23 - mp_sizeof_decimal(1)
-    ok 24 - mp_sizeof_decimal(1) == len(mp_encode_decimal(1))
-    ok 25 - mp_next(mp_encode(1))
-    ok 26 - mp_decode(mp_encode(1) len
-    ok 27 - mp_decode(mp_encode(1)) value
-    ok 28 - mp_decode(mp_encode(1)) scale
-    ok 29 - str(mp_decode(mp_encode(1))) == 1
-    ok 30 - mp_ext_type is MP_DECIMAL
-    ok 31 - decimal_unpack() after mp_decode_extl()
-    ok 32 - decimal_unpack() after mp_decode_extl() value
-    ok 33 - decimal_unpack() after mp_decode_extl() len
-    ok 34 - mp_sizeof_decimal(-1)
-    ok 35 - mp_sizeof_decimal(-1) == len(mp_encode_decimal(-1))
-    ok 36 - mp_next(mp_encode(-1))
-    ok 37 - mp_decode(mp_encode(-1) len
-    ok 38 - mp_decode(mp_encode(-1)) value
-    ok 39 - mp_decode(mp_encode(-1)) scale
-    ok 40 - str(mp_decode(mp_encode(-1))) == -1
-    ok 41 - mp_ext_type is MP_DECIMAL
-    ok 42 - decimal_unpack() after mp_decode_extl()
-    ok 43 - decimal_unpack() after mp_decode_extl() value
-    ok 44 - decimal_unpack() after mp_decode_extl() len
-    ok 45 - mp_sizeof_decimal(0.1)
-    ok 46 - mp_sizeof_decimal(0.1) == len(mp_encode_decimal(0.1))
-    ok 47 - mp_next(mp_encode(0.1))
-    ok 48 - mp_decode(mp_encode(0.1) len
-    ok 49 - mp_decode(mp_encode(0.1)) value
-    ok 50 - mp_decode(mp_encode(0.1)) scale
-    ok 51 - str(mp_decode(mp_encode(0.1))) == 0.1
-    ok 52 - mp_ext_type is MP_DECIMAL
-    ok 53 - decimal_unpack() after mp_decode_extl()
-    ok 54 - decimal_unpack() after mp_decode_extl() value
-    ok 55 - decimal_unpack() after mp_decode_extl() len
-    ok 56 - mp_sizeof_decimal(-0.1)
-    ok 57 - mp_sizeof_decimal(-0.1) == len(mp_encode_decimal(-0.1))
-    ok 58 - mp_next(mp_encode(-0.1))
-    ok 59 - mp_decode(mp_encode(-0.1) len
-    ok 60 - mp_decode(mp_encode(-0.1)) value
-    ok 61 - mp_decode(mp_encode(-0.1)) scale
-    ok 62 - str(mp_decode(mp_encode(-0.1))) == -0.1
-    ok 63 - mp_ext_type is MP_DECIMAL
-    ok 64 - decimal_unpack() after mp_decode_extl()
-    ok 65 - decimal_unpack() after mp_decode_extl() value
-    ok 66 - decimal_unpack() after mp_decode_extl() len
-    ok 67 - mp_sizeof_decimal(2.718281828459045)
-    ok 68 - mp_sizeof_decimal(2.718281828459045) == len(mp_encode_decimal(2.718281828459045))
-    ok 69 - mp_next(mp_encode(2.718281828459045))
-    ok 70 - mp_decode(mp_encode(2.718281828459045) len
-    ok 71 - mp_decode(mp_encode(2.718281828459045)) value
-    ok 72 - mp_decode(mp_encode(2.718281828459045)) scale
-    ok 73 - str(mp_decode(mp_encode(2.718281828459045))) == 2.718281828459045
-    ok 74 - mp_ext_type is MP_DECIMAL
-    ok 75 - decimal_unpack() after mp_decode_extl()
-    ok 76 - decimal_unpack() after mp_decode_extl() value
-    ok 77 - decimal_unpack() after mp_decode_extl() len
-    ok 78 - mp_sizeof_decimal(-2.718281828459045)
-    ok 79 - mp_sizeof_decimal(-2.718281828459045) == len(mp_encode_decimal(-2.718281828459045))
-    ok 80 - mp_next(mp_encode(-2.718281828459045))
-    ok 81 - mp_decode(mp_encode(-2.718281828459045) len
-    ok 82 - mp_decode(mp_encode(-2.718281828459045)) value
-    ok 83 - mp_decode(mp_encode(-2.718281828459045)) scale
-    ok 84 - str(mp_decode(mp_encode(-2.718281828459045))) == -2.718281828459045
-    ok 85 - mp_ext_type is MP_DECIMAL
-    ok 86 - decimal_unpack() after mp_decode_extl()
-    ok 87 - decimal_unpack() after mp_decode_extl() value
-    ok 88 - decimal_unpack() after mp_decode_extl() len
-    ok 89 - mp_sizeof_decimal(3.141592653589793)
-    ok 90 - mp_sizeof_decimal(3.141592653589793) == len(mp_encode_decimal(3.141592653589793))
-    ok 91 - mp_next(mp_encode(3.141592653589793))
-    ok 92 - mp_decode(mp_encode(3.141592653589793) len
-    ok 93 - mp_decode(mp_encode(3.141592653589793)) value
-    ok 94 - mp_decode(mp_encode(3.141592653589793)) scale
-    ok 95 - str(mp_decode(mp_encode(3.141592653589793))) == 3.141592653589793
-    ok 96 - mp_ext_type is MP_DECIMAL
-    ok 97 - decimal_unpack() after mp_decode_extl()
-    ok 98 - decimal_unpack() after mp_decode_extl() value
-    ok 99 - decimal_unpack() after mp_decode_extl() len
-    ok 100 - mp_sizeof_decimal(-3.141592653589793)
-    ok 101 - mp_sizeof_decimal(-3.141592653589793) == len(mp_encode_decimal(-3.141592653589793))
-    ok 102 - mp_next(mp_encode(-3.141592653589793))
-    ok 103 - mp_decode(mp_encode(-3.141592653589793) len
-    ok 104 - mp_decode(mp_encode(-3.141592653589793)) value
-    ok 105 - mp_decode(mp_encode(-3.141592653589793)) scale
-    ok 106 - str(mp_decode(mp_encode(-3.141592653589793))) == -3.141592653589793
-    ok 107 - mp_ext_type is MP_DECIMAL
-    ok 108 - decimal_unpack() after mp_decode_extl()
-    ok 109 - decimal_unpack() after mp_decode_extl() value
-    ok 110 - decimal_unpack() after mp_decode_extl() len
-    ok 111 - mp_sizeof_decimal(1234567891234567890.0987654321987654321)
-    ok 112 - mp_sizeof_decimal(1234567891234567890.0987654321987654321) == len(mp_encode_decimal(1234567891234567890.0987654321987654321))
-    ok 113 - mp_next(mp_encode(1234567891234567890.0987654321987654321))
-    ok 114 - mp_decode(mp_encode(1234567891234567890.0987654321987654321) len
-    ok 115 - mp_decode(mp_encode(1234567891234567890.0987654321987654321)) value
-    ok 116 - mp_decode(mp_encode(1234567891234567890.0987654321987654321)) scale
-    ok 117 - str(mp_decode(mp_encode(1234567891234567890.0987654321987654321))) == 1234567891234567890.0987654321987654321
-    ok 118 - mp_ext_type is MP_DECIMAL
-    ok 119 - decimal_unpack() after mp_decode_extl()
-    ok 120 - decimal_unpack() after mp_decode_extl() value
-    ok 121 - decimal_unpack() after mp_decode_extl() len
-    ok 122 - mp_sizeof_decimal(-1234567891234567890.0987654321987654321)
-    ok 123 - mp_sizeof_decimal(-1234567891234567890.0987654321987654321) == len(mp_encode_decimal(-1234567891234567890.0987654321987654321))
-    ok 124 - mp_next(mp_encode(-1234567891234567890.0987654321987654321))
-    ok 125 - mp_decode(mp_encode(-1234567891234567890.0987654321987654321) len
-    ok 126 - mp_decode(mp_encode(-1234567891234567890.0987654321987654321)) value
-    ok 127 - mp_decode(mp_encode(-1234567891234567890.0987654321987654321)) scale
-    ok 128 - str(mp_decode(mp_encode(-1234567891234567890.0987654321987654321))) == -1234567891234567890.0987654321987654321
-    ok 129 - mp_ext_type is MP_DECIMAL
-    ok 130 - decimal_unpack() after mp_decode_extl()
-    ok 131 - decimal_unpack() after mp_decode_extl() value
-    ok 132 - decimal_unpack() after mp_decode_extl() len
-    ok 133 - mp_sizeof_decimal(0.0000000000000000000000000000000000001)
-    ok 134 - mp_sizeof_decimal(0.0000000000000000000000000000000000001) == len(mp_encode_decimal(0.0000000000000000000000000000000000001))
-    ok 135 - mp_next(mp_encode(0.0000000000000000000000000000000000001))
-    ok 136 - mp_decode(mp_encode(0.0000000000000000000000000000000000001) len
-    ok 137 - mp_decode(mp_encode(0.0000000000000000000000000000000000001)) value
-    ok 138 - mp_decode(mp_encode(0.0000000000000000000000000000000000001)) scale
-    ok 139 - str(mp_decode(mp_encode(0.0000000000000000000000000000000000001))) == 0.0000000000000000000000000000000000001
-    ok 140 - mp_ext_type is MP_DECIMAL
-    ok 141 - decimal_unpack() after mp_decode_extl()
-    ok 142 - decimal_unpack() after mp_decode_extl() value
-    ok 143 - decimal_unpack() after mp_decode_extl() len
-    ok 144 - mp_sizeof_decimal(-0.0000000000000000000000000000000000001)
-    ok 145 - mp_sizeof_decimal(-0.0000000000000000000000000000000000001) == len(mp_encode_decimal(-0.0000000000000000000000000000000000001))
-    ok 146 - mp_next(mp_encode(-0.0000000000000000000000000000000000001))
-    ok 147 - mp_decode(mp_encode(-0.0000000000000000000000000000000000001) len
-    ok 148 - mp_decode(mp_encode(-0.0000000000000000000000000000000000001)) value
-    ok 149 - mp_decode(mp_encode(-0.0000000000000000000000000000000000001)) scale
-    ok 150 - str(mp_decode(mp_encode(-0.0000000000000000000000000000000000001))) == -0.0000000000000000000000000000000000001
-    ok 151 - mp_ext_type is MP_DECIMAL
-    ok 152 - decimal_unpack() after mp_decode_extl()
-    ok 153 - decimal_unpack() after mp_decode_extl() value
-    ok 154 - decimal_unpack() after mp_decode_extl() len
-    ok 155 - mp_sizeof_decimal(0.00000000000000000000000000000000000001)
-    ok 156 - mp_sizeof_decimal(0.00000000000000000000000000000000000001) == len(mp_encode_decimal(0.00000000000000000000000000000000000001))
-    ok 157 - mp_next(mp_encode(0.00000000000000000000000000000000000001))
-    ok 158 - mp_decode(mp_encode(0.00000000000000000000000000000000000001) len
-    ok 159 - mp_decode(mp_encode(0.00000000000000000000000000000000000001)) value
-    ok 160 - mp_decode(mp_encode(0.00000000000000000000000000000000000001)) scale
-    ok 161 - str(mp_decode(mp_encode(0.00000000000000000000000000000000000001))) == 0.00000000000000000000000000000000000001
-    ok 162 - mp_ext_type is MP_DECIMAL
-    ok 163 - decimal_unpack() after mp_decode_extl()
-    ok 164 - decimal_unpack() after mp_decode_extl() value
-    ok 165 - decimal_unpack() after mp_decode_extl() len
-    ok 166 - mp_sizeof_decimal(-0.00000000000000000000000000000000000001)
-    ok 167 - mp_sizeof_decimal(-0.00000000000000000000000000000000000001) == len(mp_encode_decimal(-0.00000000000000000000000000000000000001))
-    ok 168 - mp_next(mp_encode(-0.00000000000000000000000000000000000001))
-    ok 169 - mp_decode(mp_encode(-0.00000000000000000000000000000000000001) len
-    ok 170 - mp_decode(mp_encode(-0.00000000000000000000000000000000000001)) value
-    ok 171 - mp_decode(mp_encode(-0.00000000000000000000000000000000000001)) scale
-    ok 172 - str(mp_decode(mp_encode(-0.00000000000000000000000000000000000001))) == -0.00000000000000000000000000000000000001
-    ok 173 - mp_ext_type is MP_DECIMAL
-    ok 174 - decimal_unpack() after mp_decode_extl()
-    ok 175 - decimal_unpack() after mp_decode_extl() value
-    ok 176 - decimal_unpack() after mp_decode_extl() len
-    ok 177 - mp_sizeof_decimal(99999999999999999999999999999999999999)
-    ok 178 - mp_sizeof_decimal(99999999999999999999999999999999999999) == len(mp_encode_decimal(99999999999999999999999999999999999999))
-    ok 179 - mp_next(mp_encode(99999999999999999999999999999999999999))
-    ok 180 - mp_decode(mp_encode(99999999999999999999999999999999999999) len
-    ok 181 - mp_decode(mp_encode(99999999999999999999999999999999999999)) value
-    ok 182 - mp_decode(mp_encode(99999999999999999999999999999999999999)) scale
-    ok 183 - str(mp_decode(mp_encode(99999999999999999999999999999999999999))) == 99999999999999999999999999999999999999
-    ok 184 - mp_ext_type is MP_DECIMAL
-    ok 185 - decimal_unpack() after mp_decode_extl()
-    ok 186 - decimal_unpack() after mp_decode_extl() value
-    ok 187 - decimal_unpack() after mp_decode_extl() len
-    ok 188 - mp_sizeof_decimal(-99999999999999999999999999999999999999)
-    ok 189 - mp_sizeof_decimal(-99999999999999999999999999999999999999) == len(mp_encode_decimal(-99999999999999999999999999999999999999))
-    ok 190 - mp_next(mp_encode(-99999999999999999999999999999999999999))
-    ok 191 - mp_decode(mp_encode(-99999999999999999999999999999999999999) len
-    ok 192 - mp_decode(mp_encode(-99999999999999999999999999999999999999)) value
-    ok 193 - mp_decode(mp_encode(-99999999999999999999999999999999999999)) scale
-    ok 194 - str(mp_decode(mp_encode(-99999999999999999999999999999999999999))) == -99999999999999999999999999999999999999
-    ok 195 - mp_ext_type is MP_DECIMAL
-    ok 196 - decimal_unpack() after mp_decode_extl()
-    ok 197 - decimal_unpack() after mp_decode_extl() value
-    ok 198 - decimal_unpack() after mp_decode_extl() len
-ok 281 - subtests
diff --git a/test/unit/fiber.cc b/test/unit/fiber.cc
index b0dfc9b14..e2c885009 100644
--- a/test/unit/fiber.cc
+++ b/test/unit/fiber.cc
@@ -74,6 +74,7 @@ static void
 fiber_join_test()
 {
 	header();
+	plan(1);
 
 	struct fiber *fiber = fiber_new_xc("join", noop_f);
 	fiber_set_joinable(fiber, true);
@@ -98,7 +99,7 @@ fiber_join_test()
 		note("exception propagated");
 	}
 
-	fputs("#gh-1238: log uncaught errors\n", stderr);
+	note("log uncaught errors (gh-1238)");
 	fiber = fiber_new_xc("exception", exception_f);
 	fiber_wakeup(fiber);
 
@@ -123,7 +124,9 @@ fiber_join_test()
 	note("by this time the fiber should be dead already");
 	fiber_cancel(fiber);
 	fiber_join(fiber);
-
+	
+	ok(1, "fiber join test");
+	check_plan();
 	footer();
 }
 
@@ -131,6 +134,7 @@ void
 fiber_stack_test()
 {
 	header();
+	plan(1);
 
 	struct fiber *fiber;
 	struct fiber_attr *fiber_attr;
@@ -158,6 +162,8 @@ fiber_stack_test()
 	fiber_sleep(0);
 	note("big-stack fiber not crashed");
 
+	ok(1, "fiber stack test");
+	check_plan();
 	footer();
 }
 
@@ -165,11 +171,12 @@ void
 fiber_name_test()
 {
 	header();
-	note("name of a new fiber: %s.\n", fiber_name(fiber()));
+	plan(1);
+	note("name of a new fiber: %s", fiber_name(fiber()));
 
 	fiber_set_name(fiber(), "Horace");
 
-	note("set new fiber name: %s.\n", fiber_name(fiber()));
+	note("set new fiber name: %s", fiber_name(fiber()));
 
 	char long_name[FIBER_NAME_MAX + 30];
 	memset(long_name, 'a', sizeof(long_name));
@@ -177,17 +184,21 @@ fiber_name_test()
 
 	fiber_set_name(fiber(), long_name);
 
-	note("fiber name is truncated: %s.\n", fiber_name(fiber()));
+	note("fiber name is truncated: %s", fiber_name(fiber()));
+	ok(1, "fiber name test");
+	check_plan();
 	footer();
 }
 
 static int
 main_f(va_list ap)
 {
+	plan(3);
 	fiber_name_test();
 	fiber_join_test();
 	fiber_stack_test();
 	ev_break(loop(), EVBREAK_ALL);
+	check_plan();
 	return 0;
 }
 
diff --git a/test/unit/fiber.result b/test/unit/fiber.result
deleted file mode 100644
index a61e0a2b8..000000000
--- a/test/unit/fiber.result
+++ /dev/null
@@ -1,19 +0,0 @@
-#gh-1238: log uncaught errors
-SystemError Failed to allocate 42 bytes in allocator for exception: Cannot allocate memory
-	*** fiber_name_test ***
-# name of a new fiber: main.
-
-# set new fiber name: Horace.
-
-# fiber name is truncated: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.
-
-	*** fiber_name_test: done ***
-	*** fiber_join_test ***
-# exception propagated
-# cancel dead has started
-# by this time the fiber should be dead already
-	*** fiber_join_test: done ***
-	*** fiber_stack_test ***
-# normal-stack fiber not crashed
-# big-stack fiber not crashed
-	*** fiber_stack_test: done ***
diff --git a/test/unit/fiber_channel.cc b/test/unit/fiber_channel.cc
index 90c73a581..3b403768a 100644
--- a/test/unit/fiber_channel.cc
+++ b/test/unit/fiber_channel.cc
@@ -90,6 +90,7 @@ main_f(va_list ap)
 
 int main()
 {
+	plan(2);
 	memory_init();
 	fiber_init(fiber_c_invoke);
 	struct fiber *main= fiber_new_xc("main", main_f);
@@ -97,5 +98,6 @@ int main()
 	ev_run(loop(), 0);
 	fiber_free();
 	memory_free();
+	check_plan();
 	return status;
 }
diff --git a/test/unit/fiber_channel.result b/test/unit/fiber_channel.result
deleted file mode 100644
index b03949d8c..000000000
--- a/test/unit/fiber_channel.result
+++ /dev/null
@@ -1,23 +0,0 @@
-	*** fiber_channel_basic ***
-1..10
-ok 1 - fiber_channel_new()
-ok 2 - fiber_channel_size()
-ok 3 - fiber_channel_count()
-ok 4 - fiber_channel_is_full()
-ok 5 - fiber_channel_is_empty()
-ok 6 - fiber_channel_size(1)
-ok 7 - fiber_channel_count(1)
-ok 8 - fiber_channel_is_full(1)
-ok 9 - fiber_channel_is_empty(1)
-ok 10 - fiber_channel_get()
-	*** fiber_channel_basic: done ***
-	*** fiber_channel_get ***
-1..7
-ok 1 - fiber_channel_put(0)
-ok 2 - fiber_channel_put_timeout(0)
-ok 3 - fiber_channel_get(0)
-ok 4 - fiber_channel_put_timeout(1)
-ok 5 - fiber_channel_get(1)
-ok 6 - fiber_channel_put(closed)
-ok 7 - fiber_channel_get(closed)
-	*** fiber_channel_get: done ***
diff --git a/test/unit/fiber_channel_stress.cc b/test/unit/fiber_channel_stress.cc
index 98aec697b..1ac1d8ae5 100644
--- a/test/unit/fiber_channel_stress.cc
+++ b/test/unit/fiber_channel_stress.cc
@@ -50,6 +50,7 @@ main_f(va_list ap)
 
 int main()
 {
+	plan(1);
 	memory_init();
 	fiber_init(fiber_c_invoke);
 	struct fiber *main= fiber_new_xc("main", main_f);
@@ -57,5 +58,7 @@ int main()
 	ev_run(loop(), 0);
 	fiber_free();
 	memory_free();
+	ok(1, "fiber channel stress");
+	check_plan();
 	return 0;
 }
diff --git a/test/unit/fiber_channel_stress.result b/test/unit/fiber_channel_stress.result
deleted file mode 100644
index 7abdb54e0..000000000
--- a/test/unit/fiber_channel_stress.result
+++ /dev/null
@@ -1,2 +0,0 @@
-	*** main_f ***
-	*** main_f: done ***
diff --git a/test/unit/fiber_cond.result b/test/unit/fiber_cond.result
deleted file mode 100644
index 20539e2be..000000000
--- a/test/unit/fiber_cond.result
+++ /dev/null
@@ -1,8 +0,0 @@
-1..7
-ok 1 - timeout
-ok 2 - timeout
-ok 3 - signal
-ok 4 - signal
-ok 5 - order
-ok 6 - broadcast
-ok 7 - broadcast
diff --git a/test/unit/fiber_stack.c b/test/unit/fiber_stack.c
index 41abe3764..3d1fce7ba 100644
--- a/test/unit/fiber_stack.c
+++ b/test/unit/fiber_stack.c
@@ -97,6 +97,8 @@ main_f(va_list ap)
 
 int main()
 {
+	header();
+	plan(1);
 	memory_init();
 	fiber_init(fiber_c_invoke);
 	fiber_attr_create(&default_attr);
@@ -105,5 +107,6 @@ int main()
 	ev_run(loop(), 0);
 	fiber_free();
 	memory_free();
+	check_plan();
 	return 0;
 }
diff --git a/test/unit/fiber_stack.result b/test/unit/fiber_stack.result
deleted file mode 100644
index 7cae4e96c..000000000
--- a/test/unit/fiber_stack.result
+++ /dev/null
@@ -1,11 +0,0 @@
-SystemError fiber mprotect failed: Cannot allocate memory
-fiber: Can't put guard page to slab. Leak 57344 bytes: Cannot allocate memory
-	*** main_f ***
-1..6
-ok 1 - mprotect: failed to setup fiber guard page
-ok 2 - mprotect: diag is armed after error
-ok 3 - madvise: non critical error on madvise hint
-ok 4 - madvise: diag is armed after error
-ok 5 - fiber with custom stack
-ok 6 - expected leak detected
-	*** main_f: done ***
diff --git a/test/unit/fiber_stress.cc b/test/unit/fiber_stress.cc
index 44ab12487..a0baf5fbd 100644
--- a/test/unit/fiber_stress.cc
+++ b/test/unit/fiber_stress.cc
@@ -1,5 +1,6 @@
 #include "memory.h"
 #include "fiber.h"
+#include "unit.h"
 
 enum {
 	ITERATIONS = 50000,
@@ -35,6 +36,7 @@ benchmark_f(va_list ap)
 
 int main()
 {
+	plan(1);
 	memory_init();
 	fiber_init(fiber_cxx_invoke);
 	struct fiber *benchmark = fiber_new_xc("benchmark", benchmark_f);
@@ -42,5 +44,7 @@ int main()
 	ev_run(loop(), 0);
 	fiber_free();
 	memory_free();
+	ok(1, "fiber stress");
+	check_plan();
 	return 0;
 }
diff --git a/test/unit/fiber_stress.result b/test/unit/fiber_stress.result
deleted file mode 100644
index e69de29bb..000000000
diff --git a/test/unit/find_path.c b/test/unit/find_path.c
index 5c6c0a8b6..2d4eb29d7 100644
--- a/test/unit/find_path.c
+++ b/test/unit/find_path.c
@@ -11,6 +11,9 @@ int
 main(int argc, char *argv[])
 {
 	header();
+	plan(1);
 	fail_unless(open(find_path(argv[0]), O_RDONLY) >= 0);
+	ok(1, "find_path");
+	check_plan();
 	footer();
 }
diff --git a/test/unit/find_path.result b/test/unit/find_path.result
deleted file mode 100644
index 8300f0550..000000000
--- a/test/unit/find_path.result
+++ /dev/null
@@ -1,2 +0,0 @@
-	*** main ***
-	*** main: done ***
diff --git a/test/unit/guard.cc b/test/unit/guard.cc
index a2953b829..ddf2e0d87 100644
--- a/test/unit/guard.cc
+++ b/test/unit/guard.cc
@@ -7,7 +7,7 @@ static struct fiber_attr default_attr;
 static void
 sigsegf_handler(int signo)
 {
-	note("signal handler called");
+	ok(1, "signal handler called");
 	exit(0);
 }
 
@@ -53,6 +53,7 @@ main_f(va_list ap)
 
 int main()
 {
+	plan(1);
 	memory_init();
 	fiber_init(fiber_cxx_invoke);
 	fiber_attr_create(&default_attr);
diff --git a/test/unit/guard.result b/test/unit/guard.result
deleted file mode 100644
index bc9889d42..000000000
--- a/test/unit/guard.result
+++ /dev/null
@@ -1 +0,0 @@
-# signal handler called
diff --git a/test/unit/guava.c b/test/unit/guava.c
index 4e3ced76a..4100c6b61 100644
--- a/test/unit/guava.c
+++ b/test/unit/guava.c
@@ -21,12 +21,15 @@ static void
 correctness_check()
 {
 	header();
+	plan(1);
 	int64_t i_vals[] = {0, 1, 2};
 	for (size_t i = 0; i < sizeof(i_vals) / sizeof(int64_t); ++i)
 		check_guava_correctness(i_vals[i]);
 	srand(time(NULL));
 	for (size_t i = 0; i < 20; ++i)
 		check_guava_correctness(rand() % 7);
+	ok(1, "correctness check");
+	check_plan();
 	footer();
 }
 
@@ -34,7 +37,10 @@ static void
 sameresult_check()
 {
 	header();
+	plan(1);
 	fail_if(guava(100, 20) != guava(100, 20));
+	ok(1, "sameresult check");
+	check_plan();
 	footer();
 }
 
@@ -42,6 +48,7 @@ static void
 lcg_compat_check()
 {
 	header();
+	plan(1);
 	int32_t golden100[] = {
 		0, 55, 62, 8, 45, 59, 86, 97, 82, 59,
 		73, 37, 17, 56, 86, 21, 90, 37, 38, 83
@@ -55,13 +62,17 @@ lcg_compat_check()
 	fail_if(80343 != guava(2, 100001));
 	fail_if(22152 != guava(2201, 100001));
 	fail_if(15018 != guava(2202, 100001));
+	ok(1, "lcg compat check");
+	check_plan();
 	footer();
 }
 
 int
 main(void)
 {
+	plan(3);
 	correctness_check();
 	lcg_compat_check();
 	sameresult_check();
+	check_plan();
 }
diff --git a/test/unit/guava.result b/test/unit/guava.result
deleted file mode 100644
index afc3e890f..000000000
--- a/test/unit/guava.result
+++ /dev/null
@@ -1,6 +0,0 @@
-	*** correctness_check ***
-	*** correctness_check: done ***
-	*** lcg_compat_check ***
-	*** lcg_compat_check: done ***
-	*** sameresult_check ***
-	*** sameresult_check: done ***
diff --git a/test/unit/heap.c b/test/unit/heap.c
index 89806c633..a2480b5d4 100644
--- a/test/unit/heap.c
+++ b/test/unit/heap.c
@@ -51,6 +51,7 @@ static void
 test_insert_1_to_3()
 {
 	header();
+	plan(1);
 	struct test_type *value, *root_value;
 	heap_t heap;
 	test_heap_create(&heap);
@@ -73,7 +74,9 @@ test_insert_1_to_3()
 
 	free_all_nodes(&heap);
 	test_heap_destroy(&heap);
+	ok(1, "test insert 1 to 3");
 
+	check_plan();
 	footer();
 }
 
@@ -81,6 +84,7 @@ static void
 test_insert_3_to_1()
 {
 	header();
+	plan(1);
 	struct test_type *value, *root_value;
 	heap_t heap;
 	test_heap_create(&heap);
@@ -103,7 +107,9 @@ test_insert_3_to_1()
 
 	free_all_nodes(&heap);
 	test_heap_destroy(&heap);
+	ok(1, "test insert 3 to 1");
 
+	check_plan();
 	footer();
 }
 
@@ -111,6 +117,7 @@ static void
 test_insert_50_to_150_mod_100()
 {
 	header();
+	plan(1);
 	struct test_type *value, *root_value;
 	heap_t heap;
 	test_heap_create(&heap);
@@ -143,7 +150,9 @@ test_insert_50_to_150_mod_100()
 		free(root_value);
 	}
 	test_heap_destroy(&heap);
+	ok(1, "test insert 50 to 150 mod 100");
 
+	check_plan();
 	footer();
 }
 
@@ -151,6 +160,7 @@ static void
 test_insert_many_random()
 {
 	header();
+	plan(1);
 	uint32_t ans = UINT_MAX;
 	struct test_type *value, *root_value;
 	heap_t heap;
@@ -179,6 +189,8 @@ test_insert_many_random()
 
 	free_all_nodes(&heap);
 	test_heap_destroy(&heap);
+	ok(1, "test insert many random");
+	check_plan();
 	footer();
 }
 
@@ -186,6 +198,7 @@ static void
 test_insert_10_to_1_pop()
 {
 	header();
+	plan(1);
 	struct test_type *value, *root_value;
 	heap_t heap;
 	test_heap_create(&heap);
@@ -221,7 +234,9 @@ test_insert_10_to_1_pop()
 		free(root_value);
 	}
 	test_heap_destroy(&heap);
+	ok(1, "test insert 10 to 1 pop");
 
+	check_plan();
 	footer();
 }
 
@@ -243,6 +258,7 @@ static void
 test_insert_many_pop_many_random()
 {
 	header();
+	plan(1);
 	uint32_t ans = UINT_MAX;
 
 	struct test_type *value, *root_value;
@@ -309,8 +325,10 @@ test_insert_many_pop_many_random()
 		free(root_value);
 	}
 	test_heap_destroy(&heap);
+	ok(1, "test insert many pop many random");
 
 	free(keys);
+	check_plan();
 	footer();
 }
 
@@ -318,6 +336,7 @@ static void
 test_insert_pop_workload()
 {
 	header();
+	plan(1);
 	uint32_t ans = UINT_MAX;
 
 	struct test_type *value, *root_value;
@@ -354,6 +373,8 @@ test_insert_pop_workload()
 
 	free_all_nodes(&heap);
 	test_heap_destroy(&heap);
+	ok(1, "test insert pop workload");
+	check_plan();
 	footer();
 }
 
@@ -361,6 +382,7 @@ static void
 test_pop_last()
 {
 	header();
+	plan(1);
 	uint32_t ans = UINT_MAX;
 
 	struct test_type *value, *root_value;
@@ -377,6 +399,8 @@ test_pop_last()
 
 	test_heap_destroy(&heap);
 	free(value);
+	ok(1, "test pop last");
+	check_plan();
 	footer();
 }
 
@@ -384,6 +408,7 @@ static void
 test_insert_update_workload()
 {
 	header();
+	plan(1);
 	uint32_t nodes_it = 0;
 	uint64_t current_size = 0;
 	uint32_t ans = UINT_MAX;
@@ -427,6 +452,8 @@ test_insert_update_workload()
 	free_all_nodes(&heap);
 	test_heap_destroy(&heap);
 	free(nodes);
+	ok(1, "test insert update workload");
+	check_plan();
 	footer();
 }
 
@@ -434,6 +461,7 @@ static void
 test_random_delete_workload()
 {
 	header();
+	plan(1);
 	uint32_t nodes_it = 0;
 	uint64_t current_size = 0;
 	uint32_t ans = UINT_MAX;
@@ -477,6 +505,8 @@ test_random_delete_workload()
 	free_all_nodes(&heap);
 	test_heap_destroy(&heap);
 	free(nodes);
+	ok(1, "test random delete workload")
+	check_plan();
 	footer();
 }
 
@@ -484,6 +514,7 @@ static void
 test_delete_last_node()
 {
 	header();
+	plan(1);
 	struct test_type *value, *root_value;
 	heap_t heap;
 	test_heap_create(&heap);
@@ -500,6 +531,8 @@ test_delete_last_node()
 		fail("check heap invariants failed", "test_heap_check(&heap)");
 	}
 	test_heap_destroy(&heap);
+	ok(1, "test delete last node");
+	check_plan();
 	footer();
 }
 
@@ -507,6 +540,7 @@ static void
 test_heapify()
 {
 	header();
+	plan(1);
 	heap_t heap;
 	test_heap_create(&heap);
 
@@ -524,15 +558,18 @@ test_heapify()
 		     "test_heap_check(&heap)");
 	}
 	order_by_val2 = false;
+	ok(1, "test heapify");
 
 	free_all_nodes(&heap);
 	test_heap_destroy(&heap);
+	check_plan();
 	footer();
 }
 
 int
 main(int argc, const char** argv)
 {
+	plan(12);
 	srand(179);
 	test_insert_1_to_3();
 	test_insert_3_to_1();
@@ -546,4 +583,5 @@ main(int argc, const char** argv)
 	test_random_delete_workload();
 	test_delete_last_node();
 	test_heapify();
+	check_plan();
 }
diff --git a/test/unit/heap.result b/test/unit/heap.result
deleted file mode 100644
index 7928983c1..000000000
--- a/test/unit/heap.result
+++ /dev/null
@@ -1,24 +0,0 @@
-	*** test_insert_1_to_3 ***
-	*** test_insert_1_to_3: done ***
-	*** test_insert_3_to_1 ***
-	*** test_insert_3_to_1: done ***
-	*** test_insert_50_to_150_mod_100 ***
-	*** test_insert_50_to_150_mod_100: done ***
-	*** test_insert_many_random ***
-	*** test_insert_many_random: done ***
-	*** test_insert_10_to_1_pop ***
-	*** test_insert_10_to_1_pop: done ***
-	*** test_insert_many_pop_many_random ***
-	*** test_insert_many_pop_many_random: done ***
-	*** test_insert_pop_workload ***
-	*** test_insert_pop_workload: done ***
-	*** test_pop_last ***
-	*** test_pop_last: done ***
-	*** test_insert_update_workload ***
-	*** test_insert_update_workload: done ***
-	*** test_random_delete_workload ***
-	*** test_random_delete_workload: done ***
-	*** test_delete_last_node ***
-	*** test_delete_last_node: done ***
-	*** test_heapify ***
-	*** test_heapify: done ***
diff --git a/test/unit/heap_iterator.c b/test/unit/heap_iterator.c
index 4fde39dfe..6981bbc92 100644
--- a/test/unit/heap_iterator.c
+++ b/test/unit/heap_iterator.c
@@ -43,6 +43,7 @@ static void
 test_iterator_create()
 {
 	header();
+	plan(1);
 	struct test_type *value, *root_value;
 	heap_t heap;
 	test_heap_create(&heap);
@@ -59,6 +60,8 @@ test_iterator_create()
 
 	free_all_nodes(&heap);
 
+	ok(1, "test iterator create");
+	check_plan();
 	footer();
 }
 
@@ -66,6 +69,7 @@ static void
 test_iterator_empty()
 {
 	header();
+	plan(1);
 	heap_t heap;
 	test_heap_create(&heap);
 
@@ -79,6 +83,8 @@ test_iterator_empty()
 
 	free_all_nodes(&heap);
 
+	ok(1, "test iterator empty");
+	check_plan();
 	footer();
 }
 
@@ -87,6 +93,7 @@ static void
 test_iterator_small()
 {
 	header();
+	plan(1);
 	struct test_type *value;
 	heap_t heap;
 	test_heap_create(&heap);
@@ -128,6 +135,8 @@ test_iterator_small()
 		fail("after all iterator returns not NULL", "value != NULL");
 
 	free_all_nodes(&heap);
+	ok(1, "test iterator small");
+	check_plan();
 	footer();
 }
 
@@ -135,6 +144,7 @@ static void
 test_iterator_large()
 {
 	header();
+	plan(1);
 	uint32_t const TEST_CASE_SIZE = 1000;
 	struct test_type *value;
 	heap_t heap;
@@ -180,6 +190,8 @@ test_iterator_large()
 		     "value != NULL");
 
 	free_all_nodes(&heap);
+	ok(1, "test iterator large");
+	check_plan();
 	footer();
 }
 
@@ -188,8 +200,10 @@ int
 main(int argc, const char** argv)
 {
 	srand(179);
+	plan(4);
 	test_iterator_create();
 	test_iterator_empty();
 	test_iterator_small();
 	test_iterator_large();
+	check_plan();
 }
diff --git a/test/unit/heap_iterator.result b/test/unit/heap_iterator.result
deleted file mode 100644
index 66b99dcc6..000000000
--- a/test/unit/heap_iterator.result
+++ /dev/null
@@ -1,8 +0,0 @@
-	*** test_iterator_create ***
-	*** test_iterator_create: done ***
-	*** test_iterator_empty ***
-	*** test_iterator_empty: done ***
-	*** test_iterator_small ***
-	*** test_iterator_small: done ***
-	*** test_iterator_large ***
-	*** test_iterator_large: done ***
diff --git a/test/unit/histogram.c b/test/unit/histogram.c
index 3056d20fe..462f93511 100644
--- a/test/unit/histogram.c
+++ b/test/unit/histogram.c
@@ -57,6 +57,7 @@ static void
 test_counts(void)
 {
 	header();
+	plan(1);
 
 	size_t n_buckets;
 	int64_t *buckets = gen_buckets(&n_buckets);
@@ -83,14 +84,17 @@ test_counts(void)
 	histogram_delete(hist);
 	free(data);
 	free(buckets);
+	ok(1, "test counts");
 
 	footer();
+	check_plan();
 }
 
 static void
 test_discard(void)
 {
 	header();
+	plan(1);
 
 	size_t n_buckets;
 	int64_t *buckets = gen_buckets(&n_buckets);
@@ -124,14 +128,17 @@ test_discard(void)
 	histogram_delete(hist);
 	free(data);
 	free(buckets);
+	ok(1, "test discard");
 
 	footer();
+	check_plan();
 }
 
 static void
 test_percentile(void)
 {
 	header();
+	plan(1);
 
 	size_t n_buckets;
 	int64_t *buckets = gen_buckets(&n_buckets);
@@ -170,15 +177,19 @@ test_percentile(void)
 	histogram_delete(hist);
 	free(data);
 	free(buckets);
+	ok(1, "test percentile");
 
 	footer();
+	check_plan();
 }
 
 int
 main()
 {
+	plan(3);
 	srand(time(NULL));
 	test_counts();
 	test_discard();
 	test_percentile();
+	check_plan();
 }
diff --git a/test/unit/histogram.result b/test/unit/histogram.result
deleted file mode 100644
index e393c194d..000000000
--- a/test/unit/histogram.result
+++ /dev/null
@@ -1,6 +0,0 @@
-	*** test_counts ***
-	*** test_counts: done ***
-	*** test_discard ***
-	*** test_discard: done ***
-	*** test_percentile ***
-	*** test_percentile: done ***
diff --git a/test/unit/int96.cc b/test/unit/int96.cc
index 29dbbcbf5..c033b0aed 100644
--- a/test/unit/int96.cc
+++ b/test/unit/int96.cc
@@ -2,12 +2,11 @@
 
 #include "unit.h"
 
-#define check(expr) if (!(expr)) printf("failed at %s:%d\n", __FILE__, __LINE__)
-
 static void
 test()
 {
 	header();
+	plan(15);
 
 	const uint64_t a = 0xFFFFFFFFFFFFFFFFull / 2;
 	int96_num num, num1, num2;
@@ -15,57 +14,61 @@ test()
 	int96_set_unsigned(&num1, a);
 	int96_set_unsigned(&num2, a);
 	int96_invert(&num2);
-	check(int96_is_neg_int64(&num2));
-	check(int96_extract_neg_int64(&num2) == int64_t(-a));
-	check(int96_is_uint64(&num));
-	check(int96_extract_uint64(&num) == 0);
+	is(int96_is_neg_int64(&num2), true, "int96_is_neg_int64()");
+	is(int96_extract_neg_int64(&num2), int64_t(-a), "int96_extract_neg_int64()");
+	is(int96_is_uint64(&num), true, "int96_is_uint64()");
+	is(int96_extract_uint64(&num), 0, "int96_extract_uint64()");
 	int96_add(&num, &num1);
-	check(int96_is_uint64(&num));
-	check(int96_extract_uint64(&num) == a);
+	is(int96_is_uint64(&num), true, "int96_is_uint64()");
+	is(int96_extract_uint64(&num), a, "int96_extract_uint64()");
 	int96_add(&num, &num1);
-	check(int96_is_uint64(&num));
-	check(int96_extract_uint64(&num) == a * 2);
+	is(int96_is_uint64(&num), true, "int96_is_uint64()");
+	is(int96_extract_uint64(&num), a * 2, "int96_extract_uint64()");
 	for (int i = 1; i < 1000; i++) {
 		for(int j = 0; j < i; j++) {
 			int96_add(&num, &num1);
-			check(!int96_is_uint64(&num) && !int96_is_neg_int64(&num));
+			fail_if(!(!int96_is_uint64(&num) && !int96_is_neg_int64(&num)));
 		}
 		for(int j = 0; j < i - 1; j++) {
 			int96_add(&num, &num2);
-			check(!int96_is_uint64(&num) && !int96_is_neg_int64(&num));
+			fail_if(!(!int96_is_uint64(&num) && !int96_is_neg_int64(&num)));
 		}
 		int96_add(&num, &num2);
-		check(int96_is_uint64(&num));
-		check(int96_extract_uint64(&num) == a * 2);
+		fail_if(!int96_is_uint64(&num));
+		fail_if(int96_extract_uint64(&num) != a * 2);
 	}
+	ok(1, "int96_add() in loop");
 	int96_add(&num, &num2);
-	check(int96_is_uint64(&num));
-	check(int96_extract_uint64(&num) == a);
+	is(int96_is_uint64(&num), true, "int96_is_uint64()");
+	is(int96_extract_uint64(&num), a, "int96_extract_uint64()");
 	int96_add(&num, &num2);
-	check(int96_is_uint64(&num));
-	check(int96_extract_uint64(&num) == 0);
+	is(int96_is_uint64(&num), true, "int96_is_uint64()");
+	is(int96_extract_uint64(&num), 0, "int96_extract_uint64()");
 	int96_add(&num, &num2);
-	check(int96_is_neg_int64(&num));
-	check(int96_extract_neg_int64(&num) == int64_t(-a));
+	is(int96_is_neg_int64(&num), true, "int96_is_neg_int64()");
+	is(int96_extract_neg_int64(&num), int64_t(-a), "int96_extract_neg_int64()");
 	for (int i = 1; i < 1000; i++) {
 		for(int j = 0; j < i; j++) {
 			int96_add(&num, &num2);
-			check(!int96_is_uint64(&num) && !int96_is_neg_int64(&num));
+			fail_if(!(!int96_is_uint64(&num) && !int96_is_neg_int64(&num)));
 		}
 		for(int j = 0; j < i - 1; j++) {
 			int96_add(&num, &num1);
-			check(!int96_is_uint64(&num) && !int96_is_neg_int64(&num));
+			fail_if(!(!int96_is_uint64(&num) && !int96_is_neg_int64(&num)));
 		}
 		int96_add(&num, &num1);
-		check(int96_is_neg_int64(&num));
-		check(int96_extract_neg_int64(&num) == int64_t(-a));
+		fail_if(!(int96_is_neg_int64(&num)));
+		fail_if(int96_extract_neg_int64(&num) != int64_t(-a));
 	}
 
+	check_plan();
 	footer();
 }
 
 int
 main(int, const char **)
 {
+	plan(1);
 	test();
+	check_plan();
 }
diff --git a/test/unit/int96.result b/test/unit/int96.result
deleted file mode 100644
index 4a0b26f56..000000000
--- a/test/unit/int96.result
+++ /dev/null
@@ -1,2 +0,0 @@
-	*** test ***
-	*** test: done ***
diff --git a/test/unit/json.result b/test/unit/json.result
deleted file mode 100644
index fb9d1490f..000000000
--- a/test/unit/json.result
+++ /dev/null
@@ -1,208 +0,0 @@
-	*** main ***
-1..6
-	*** test_basic ***
-    1..71
-    ok 1 - parse <[1]>
-    ok 2 - <[1]> is num
-    ok 3 - <[1]> is 0
-    ok 4 - parse <field1>
-    ok 5 - <field1> is str
-    ok 6 - len is 6
-    ok 7 - str is field1
-    ok 8 - parse <field2>
-    ok 9 - <field2> is str
-    ok 10 - len is 6
-    ok 11 - str is field2
-    ok 12 - parse <field3>
-    ok 13 - <field3> is str
-    ok 14 - len is 6
-    ok 15 - str is field3
-    ok 16 - parse <[5]>
-    ok 17 - <[5]> is num
-    ok 18 - <[5]> is 4
-    ok 19 - parse <[3]>
-    ok 20 - <[3]> is num
-    ok 21 - <[3]> is 2
-    ok 22 - parse <field>
-    ok 23 - <field> is str
-    ok 24 - len is 5
-    ok 25 - str is field
-    ok 26 - parse <[2]>
-    ok 27 - <[2]> is num
-    ok 28 - <[2]> is 1
-    ok 29 - parse <field>
-    ok 30 - <field> is str
-    ok 31 - len is 5
-    ok 32 - str is field
-    ok 33 - parse <f1>
-    ok 34 - <f1> is str
-    ok 35 - len is 2
-    ok 36 - str is f1
-    ok 37 - parse <f2'3'>
-    ok 38 - <f2'3'> is str
-    ok 39 - len is 5
-    ok 40 - str is f2'3'
-    ok 41 - parse <field1>
-    ok 42 - <field1> is str
-    ok 43 - len is 6
-    ok 44 - str is field1
-    ok 45 - parse <field1>
-    ok 46 - <field1> is str
-    ok 47 - len is 6
-    ok 48 - str is field1
-    ok 49 - parse <[1234]>
-    ok 50 - <[1234]> is num
-    ok 51 - <[1234]> is 1233
-    ok 52 - parse empty path
-    ok 53 - is str
-    ok 54 - parse <field1>
-    ok 55 - <field1> is str
-    ok 56 - len is 6
-    ok 57 - str is field1
-    ok 58 - parse <[2]>
-    ok 59 - <[2]> is num
-    ok 60 - <[2]> is 1
-    ok 61 - parse <[6]>
-    ok 62 - <[6]> is num
-    ok 63 - <[6]> is 5
-    ok 64 - parse <привет中国world>
-    ok 65 - <привет中国world> is str
-    ok 66 - len is 23
-    ok 67 - str is привет中国world
-    ok 68 - parse <中国a>
-    ok 69 - <中国a> is str
-    ok 70 - len is 7
-    ok 71 - str is 中国a
-ok 1 - subtests
-	*** test_basic: done ***
-	*** test_errors ***
-    1..22
-    ok 1 - error on position 2 for <[[>
-    ok 2 - error on position 2 for <[field]>
-    ok 3 - error on position 1 for <'field1'.field2>
-    ok 4 - error on position 2 for <[]>
-    ok 5 - error on position 1 for <''>
-    ok 6 - error on position 1 for < field1>
-    ok 7 - error on position 1 for <1field>
-    ok 8 - error on position 2 for <.1field>
-    ok 9 - error on position 8 for <['field>
-    ok 10 - error on position 9 for <['field'>
-    ok 11 - error on position 5 for <[123>
-    ok 12 - error on position 3 for <['']>
-    ok 13 - error on position 2 for <.[123]>
-    ok 14 - error on position 2 for <[.]>
-    ok 15 - error on position 6 for <['aaa��']>
-    ok 16 - error on position 2 for <.��>
-    ok 17 - can not write <field.[index]>
-    ok 18 - can not omit '.' before not a first key out of []
-    ok 19 - error in leading <.>
-    ok 20 - space inside identifier
-    ok 21 - tab inside identifier
-    ok 22 - invalid token for index_base 1
-ok 2 - subtests
-	*** test_errors: done ***
-	*** test_tree ***
-    1..65
-    ok 1 - add path '[1][10]'
-    ok 2 - add path '[1][20].file'
-    ok 3 - add path '[1][20].file[2]'
-    ok 4 - add path '[1][20].file[8]'
-    ok 5 - add path '[1][20]["file"][8]'
-    ok 6 - lookup path '[1][10]'
-    ok 7 - lookup path '[1][20].file'
-    ok 8 - lookup unregistered path '[1][3]'
-    ok 9 - test foreach pre order 0: have 0 expected of 0
-    ok 10 - test foreach pre order 1: have 1 expected of 1
-    ok 11 - test foreach pre order 2: have 2 expected of 2
-    ok 12 - test foreach pre order 3: have 3 expected of 3
-    ok 13 - test foreach pre order 4: have 4 expected of 4
-    ok 14 - test foreach pre order 5: have 5 expected of 5
-    ok 15 - records iterated count 6 of 6
-    ok 16 - test foreach post order 0: have 1 expected of 1
-    ok 17 - test foreach post order 1: have 4 expected of 4
-    ok 18 - test foreach post order 2: have 5 expected of 5
-    ok 19 - test foreach post order 3: have 3 expected of 3
-    ok 20 - test foreach post order 4: have 2 expected of 2
-    ok 21 - test foreach post order 5: have 0 expected of 0
-    ok 22 - records iterated count 6 of 6
-    ok 23 - test foreach safe order 0: have 1 expected of 1
-    ok 24 - test foreach safe order 1: have 4 expected of 4
-    ok 25 - test foreach safe order 2: have 5 expected of 5
-    ok 26 - test foreach safe order 3: have 3 expected of 3
-    ok 27 - test foreach safe order 4: have 2 expected of 2
-    ok 28 - test foreach safe order 5: have 0 expected of 0
-    ok 29 - records iterated count 6 of 6
-    ok 30 - test foreach entry pre order 0: have 0 expected of 0
-    ok 31 - test foreach entry pre order 1: have 1 expected of 1
-    ok 32 - test foreach entry pre order 2: have 2 expected of 2
-    ok 33 - test foreach entry pre order 3: have 3 expected of 3
-    ok 34 - test foreach entry pre order 4: have 4 expected of 4
-    ok 35 - test foreach entry pre order 5: have 5 expected of 5
-    ok 36 - records iterated count 6 of 6
-    ok 37 - test foreach entry post order 0: have 1 expected of 1
-    ok 38 - test foreach entry post order 1: have 4 expected of 4
-    ok 39 - test foreach entry post order 2: have 5 expected of 5
-    ok 40 - test foreach entry post order 3: have 3 expected of 3
-    ok 41 - test foreach entry post order 4: have 2 expected of 2
-    ok 42 - test foreach entry post order 5: have 0 expected of 0
-    ok 43 - records iterated count 6 of 6
-    ok 44 - max_child_index 7 expected of 7
-    ok 45 - max_child_index 1 expected of 1
-    ok 46 - max_child_index -1 expected of -1
-    ok 47 - lookup removed path '[1][20].file[2]'
-    ok 48 - lookup removed path '[1][20].file[8]'
-    ok 49 - lookup path was not corrupted '[1][20].file'
-    ok 50 - test foreach entry safe order 0: have 1 expected of 1
-    ok 51 - test foreach entry safe order 1: have 3 expected of 3
-    ok 52 - test foreach entry safe order 2: have 2 expected of 2
-    ok 53 - test foreach entry safe order 3: have 0 expected of 0
-    ok 54 - records iterated count 4 of 4
-    ok 55 - interm node is not leaf
-    ok 56 - last node is leaf
-    ok 57 - last node became interm - it can't be leaf anymore
-    ok 58 - last node is leaf
-    ok 59 - add path '[1][10]'
-    ok 60 - lookup any token in non-multikey node
-    ok 61 - add path '[1][*]["data"]'
-    ok 62 - lookup path '[1][*]["data"]'
-    ok 63 - lookup numeric token in multikey node
-    ok 64 - lookup any token in multikey node
-    ok 65 - lookup string token in multikey node
-ok 3 - subtests
-	*** test_tree: done ***
-	*** test_path_cmp ***
-    1..8
-    ok 1 - path cmp result "Data[1]["FIO"].fname" with "Data[1]["FIO"].fname": have 0, expected 0
-    ok 2 - path cmp result "Data[1]["FIO"].fname" with "["Data"][1].FIO["fname"]": have 0, expected 0
-    ok 3 - path cmp result "Data[1]["FIO"].fname" with "Data[1]": have 1, expected 1
-    ok 4 - path cmp result "Data[1]["FIO"].fname" with "Data[1]["FIO"].fname[1]": have -1, expected -1
-    ok 5 - path cmp result "Data[1]["FIO"].fname" with "Data[1]["Info"].fname[1]": have -1, expected -1
-    ok 6 - path cmp result "Data[*]["FIO"].fname[*]" with "["Data"][*].FIO["fname"][*]": have 0, expected 0
-    ok 7 - path Data[1]["FIO"].fname is valid
-    ok 8 - path Data[[1]["FIO"].fname error pos 6 expected 6
-ok 4 - subtests
-	*** test_path_cmp: done ***
-	*** test_path_snprint ***
-    1..9
-    ok 1 - full path - retval
-    ok 2 - full path - terminating nul
-    ok 3 - full path - output
-    ok 4 - truncated path - retval
-    ok 5 - truncated path - terminating nul
-    ok 6 - truncated path - output
-    ok 7 - 1-byte buffer - retval
-    ok 8 - 1-byte buffer - terminating nul
-    ok 9 - 0-byte buffer - retval
-ok 5 - subtests
-	*** test_path_snprint: done ***
-	*** test_path_multikey ***
-    1..6
-    ok 1 - Test json_path_multikey_offset with : have 0 expected 0
-    ok 2 - Test json_path_multikey_offset with [1].Data[1].extra[1]: have 20 expected 20
-    ok 3 - Test json_path_multikey_offset with [*].Data[1].extra[1]: have 0 expected 0
-    ok 4 - Test json_path_multikey_offset with [*].Data[*].extra[1]: have 0 expected 0
-    ok 5 - Test json_path_multikey_offset with [1].Data[*].extra[1]: have 8 expected 8
-    ok 6 - Test json_path_multikey_offset with [1].Data[1].extra[*]: have 17 expected 17
-ok 6 - subtests
-	*** test_path_multikey: done ***
-	*** main: done ***
diff --git a/test/unit/light.cc b/test/unit/light.cc
index 6d89938b4..c1832654b 100644
--- a/test/unit/light.cc
+++ b/test/unit/light.cc
@@ -62,6 +62,7 @@ static void
 simple_test()
 {
 	header();
+	plan(1);
 
 	struct light_core ht;
 	light_create(&ht, light_extent_size,
@@ -80,7 +81,6 @@ simple_test()
 			hash_t fnd = light_find(&ht, h, val);
 			bool has1 = fnd != light_end;
 			bool has2 = vect[val];
-			assert(has1 == has2);
 			if (has1 != has2) {
 				fail("find key failed!", "true");
 				return;
@@ -118,7 +118,9 @@ simple_test()
 		}
 	}
 	light_destroy(&ht);
+	ok(1, "Simple test")
 
+	check_plan();
 	footer();
 }
 
@@ -126,6 +128,7 @@ static void
 collision_test()
 {
 	header();
+	plan(1);
 
 	struct light_core ht;
 	light_create(&ht, light_extent_size,
@@ -144,7 +147,6 @@ collision_test()
 			hash_t fnd = light_find(&ht, h * 1024, val);
 			bool has1 = fnd != light_end;
 			bool has2 = vect[val];
-			assert(has1 == has2);
 			if (has1 != has2) {
 				fail("find key failed!", "true");
 				return;
@@ -182,7 +184,9 @@ collision_test()
 		}
 	}
 	light_destroy(&ht);
+	ok(1, "Collision test")
 
+	check_plan();
 	footer();
 }
 
@@ -190,6 +194,7 @@ static void
 iterator_test()
 {
 	header();
+	plan(1);
 
 	struct light_core ht;
 	light_create(&ht, light_extent_size,
@@ -239,14 +244,17 @@ iterator_test()
 	if (strage_thing >> 20) {
 		printf("impossible!\n"); // prevent strage_thing to be optimized out
 	}
+	ok(1, "Iterator test")
 
 	footer();
+	check_plan();
 }
 
 static void
 iterator_freeze_check()
 {
 	header();
+	plan(1);
 
 	const int test_data_size = 1000;
 	hash_value_t comp_buf[test_data_size];
@@ -313,13 +321,16 @@ iterator_freeze_check()
 
 		light_destroy(&ht);
 	}
+	ok(1, "Iterator freeze test");
 
 	footer();
+	check_plan();
 }
 
 int
 main(int, const char**)
 {
+	plan(4);
 	srand(time(0));
 	simple_test();
 	collision_test();
@@ -327,4 +338,5 @@ main(int, const char**)
 	iterator_freeze_check();
 	if (extents_count != 0)
 		fail("memory leak!", "true");
+	check_plan();
 }
diff --git a/test/unit/light.result b/test/unit/light.result
deleted file mode 100644
index 39c4d7c53..000000000
--- a/test/unit/light.result
+++ /dev/null
@@ -1,8 +0,0 @@
-	*** simple_test ***
-	*** simple_test: done ***
-	*** collision_test ***
-	*** collision_test: done ***
-	*** iterator_test ***
-	*** iterator_test: done ***
-	*** iterator_freeze_check ***
-	*** iterator_freeze_check: done ***
diff --git a/test/unit/luaL_iterator.result b/test/unit/luaL_iterator.result
deleted file mode 100644
index 2472eedcf..000000000
--- a/test/unit/luaL_iterator.result
+++ /dev/null
@@ -1,89 +0,0 @@
-1..86
-	*** main ***
-ok 1 - pairs, zero idx: stack size
-ok 2 - pairs, zero idx: iter 0: gen() retval count
-ok 3 - pairs, zero idx: iter 0: gen() 1st retval
-ok 4 - pairs, zero idx: iter 0: gen() 2nd retval
-ok 5 - pairs, zero idx: iter: 0: stack size
-ok 6 - pairs, zero idx: iterator ends
-ok 7 - pairs, zero idx: stack size
-ok 8 - pairs, zero idx: stack size
-ok 9 - ipairs, zero idx: stack size
-ok 10 - ipairs, zero idx: iter 0: gen() retval count
-ok 11 - ipairs, zero idx: iter 0: gen() 1st retval
-ok 12 - ipairs, zero idx: iter 0: gen() 2nd retval
-ok 13 - ipairs, zero idx: iter: 0: stack size
-ok 14 - ipairs, zero idx: iter 1: gen() retval count
-ok 15 - ipairs, zero idx: iter 1: gen() 1st retval
-ok 16 - ipairs, zero idx: iter 1: gen() 2nd retval
-ok 17 - ipairs, zero idx: iter: 1: stack size
-ok 18 - ipairs, zero idx: iter 2: gen() retval count
-ok 19 - ipairs, zero idx: iter 2: gen() 1st retval
-ok 20 - ipairs, zero idx: iter 2: gen() 2nd retval
-ok 21 - ipairs, zero idx: iter: 2: stack size
-ok 22 - ipairs, zero idx: iterator ends
-ok 23 - ipairs, zero idx: stack size
-ok 24 - ipairs, zero idx: stack size
-ok 25 - luafun iterator, zero idx: stack size
-ok 26 - luafun iterator, zero idx: iter 0: gen() retval count
-ok 27 - luafun iterator, zero idx: iter 0: gen() 1st retval
-ok 28 - luafun iterator, zero idx: iter 0: gen() 2nd retval
-ok 29 - luafun iterator, zero idx: iter: 0: stack size
-ok 30 - luafun iterator, zero idx: iter 1: gen() retval count
-ok 31 - luafun iterator, zero idx: iter 1: gen() 1st retval
-ok 32 - luafun iterator, zero idx: iter 1: gen() 2nd retval
-ok 33 - luafun iterator, zero idx: iter: 1: stack size
-ok 34 - luafun iterator, zero idx: iter 2: gen() retval count
-ok 35 - luafun iterator, zero idx: iter 2: gen() 1st retval
-ok 36 - luafun iterator, zero idx: iter 2: gen() 2nd retval
-ok 37 - luafun iterator, zero idx: iter: 2: stack size
-ok 38 - luafun iterator, zero idx: iterator ends
-ok 39 - luafun iterator, zero idx: stack size
-ok 40 - luafun iterator, zero idx: stack size
-ok 41 - pairs, from table: stack size
-ok 42 - pairs, from table: iter 0: gen() retval count
-ok 43 - pairs, from table: iter 0: gen() 1st retval
-ok 44 - pairs, from table: iter 0: gen() 2nd retval
-ok 45 - pairs, from table: iter: 0: stack size
-ok 46 - pairs, from table: iterator ends
-ok 47 - pairs, from table: stack size
-ok 48 - pairs, from table: stack size
-ok 49 - ipairs, from table: stack size
-ok 50 - ipairs, from table: iter 0: gen() retval count
-ok 51 - ipairs, from table: iter 0: gen() 1st retval
-ok 52 - ipairs, from table: iter 0: gen() 2nd retval
-ok 53 - ipairs, from table: iter: 0: stack size
-ok 54 - ipairs, from table: iter 1: gen() retval count
-ok 55 - ipairs, from table: iter 1: gen() 1st retval
-ok 56 - ipairs, from table: iter 1: gen() 2nd retval
-ok 57 - ipairs, from table: iter: 1: stack size
-ok 58 - ipairs, from table: iter 2: gen() retval count
-ok 59 - ipairs, from table: iter 2: gen() 1st retval
-ok 60 - ipairs, from table: iter 2: gen() 2nd retval
-ok 61 - ipairs, from table: iter: 2: stack size
-ok 62 - ipairs, from table: iterator ends
-ok 63 - ipairs, from table: stack size
-ok 64 - ipairs, from table: stack size
-ok 65 - luafun iterator, from table: stack size
-ok 66 - luafun iterator, from table: iter 0: gen() retval count
-ok 67 - luafun iterator, from table: iter 0: gen() 1st retval
-ok 68 - luafun iterator, from table: iter 0: gen() 2nd retval
-ok 69 - luafun iterator, from table: iter: 0: stack size
-ok 70 - luafun iterator, from table: iter 1: gen() retval count
-ok 71 - luafun iterator, from table: iter 1: gen() 1st retval
-ok 72 - luafun iterator, from table: iter 1: gen() 2nd retval
-ok 73 - luafun iterator, from table: iter: 1: stack size
-ok 74 - luafun iterator, from table: iter 2: gen() retval count
-ok 75 - luafun iterator, from table: iter 2: gen() 1st retval
-ok 76 - luafun iterator, from table: iter 2: gen() 2nd retval
-ok 77 - luafun iterator, from table: iter: 2: stack size
-ok 78 - luafun iterator, from table: iterator ends
-ok 79 - luafun iterator, from table: stack size
-ok 80 - luafun iterator, from table: stack size
-ok 81 - lua error: stack size
-ok 82 - lua error: iterator error
-ok 83 - lua error: check error type
-ok 84 - lua error: check error message
-ok 85 - lua error: stack size
-ok 86 - lua error: stack size
-	*** main: done ***
diff --git a/test/unit/luaT_tuple_new.result b/test/unit/luaT_tuple_new.result
deleted file mode 100644
index 110aa68c2..000000000
--- a/test/unit/luaT_tuple_new.result
+++ /dev/null
@@ -1,22 +0,0 @@
-1..19
-	*** test_basic ***
-ok 1 - table: tuple != NULL
-ok 2 - table: check tuple format id
-ok 3 - table: check tuple size
-ok 4 - table: check tuple data
-ok 5 - table: check retvals count
-ok 6 - tuple: tuple != NULL
-ok 7 - tuple: check tuple format id
-ok 8 - tuple: check tuple size
-ok 9 - tuple: check tuple data
-ok 10 - tuple: check retvals count
-ok 11 - objects: tuple != NULL
-ok 12 - objects: check tuple format id
-ok 13 - objects: check tuple size
-ok 14 - objects: check tuple data
-ok 15 - objects: check retvals count
-ok 16 - unexpected type: tuple == NULL
-ok 17 - unexpected type: check retvals count
-ok 18 - unexpected type: check error type
-ok 19 - unexpected type: check error message
-	*** test_basic: done ***
diff --git a/test/unit/merger.result b/test/unit/merger.result
deleted file mode 100644
index 766ebce63..000000000
--- a/test/unit/merger.result
+++ /dev/null
@@ -1,71 +0,0 @@
-1..4
-	*** test_basic ***
-    1..9
-	*** test_array_source ***
-    ok 1 - array source next() (any format): tuple != NULL
-    ok 2 - array source next() (any format): skip tuple validation
-    ok 3 - array source next() (any format): check tuple size
-    ok 4 - array source next() (any format): check tuple data
-    ok 5 - array source next() (any format): tuple != NULL
-    ok 6 - array source next() (any format): skip tuple validation
-    ok 7 - array source next() (any format): check tuple size
-    ok 8 - array source next() (any format): check tuple data
-    ok 9 - array source is empty (any format)
-	*** test_array_source: done ***
-ok 1 - subtests
-    1..9
-	*** test_array_source ***
-    ok 1 - array source next() (user's format): tuple != NULL
-    ok 2 - array source next() (user's format): validate tuple
-    ok 3 - array source next() (user's format): check tuple size
-    ok 4 - array source next() (user's format): check tuple data
-    ok 5 - array source next() (user's format): tuple != NULL
-    ok 6 - array source next() (user's format): validate tuple
-    ok 7 - array source next() (user's format): check tuple size
-    ok 8 - array source next() (user's format): check tuple data
-    ok 9 - array source is empty (user's format)
-	*** test_array_source: done ***
-ok 2 - subtests
-    1..17
-	*** test_merger ***
-    ok 1 - merger next() (any format): tuple != NULL
-    ok 2 - merger next() (any format): skip tuple validation
-    ok 3 - merger next() (any format): check tuple size
-    ok 4 - merger next() (any format): check tuple data
-    ok 5 - merger next() (any format): tuple != NULL
-    ok 6 - merger next() (any format): skip tuple validation
-    ok 7 - merger next() (any format): check tuple size
-    ok 8 - merger next() (any format): check tuple data
-    ok 9 - merger next() (any format): tuple != NULL
-    ok 10 - merger next() (any format): skip tuple validation
-    ok 11 - merger next() (any format): check tuple size
-    ok 12 - merger next() (any format): check tuple data
-    ok 13 - merger next() (any format): tuple != NULL
-    ok 14 - merger next() (any format): skip tuple validation
-    ok 15 - merger next() (any format): check tuple size
-    ok 16 - merger next() (any format): check tuple data
-    ok 17 - merger is empty (any format)
-	*** test_merger: done ***
-ok 3 - subtests
-    1..17
-	*** test_merger ***
-    ok 1 - merger next() (user's format): tuple != NULL
-    ok 2 - merger next() (user's format): validate tuple
-    ok 3 - merger next() (user's format): check tuple size
-    ok 4 - merger next() (user's format): check tuple data
-    ok 5 - merger next() (user's format): tuple != NULL
-    ok 6 - merger next() (user's format): validate tuple
-    ok 7 - merger next() (user's format): check tuple size
-    ok 8 - merger next() (user's format): check tuple data
-    ok 9 - merger next() (user's format): tuple != NULL
-    ok 10 - merger next() (user's format): validate tuple
-    ok 11 - merger next() (user's format): check tuple size
-    ok 12 - merger next() (user's format): check tuple data
-    ok 13 - merger next() (user's format): tuple != NULL
-    ok 14 - merger next() (user's format): validate tuple
-    ok 15 - merger next() (user's format): check tuple size
-    ok 16 - merger next() (user's format): check tuple data
-    ok 17 - merger is empty (user's format)
-	*** test_merger: done ***
-ok 4 - subtests
-	*** test_basic: done ***
diff --git a/test/unit/mhash.result b/test/unit/mhash.result
deleted file mode 100644
index fc757fa35..000000000
--- a/test/unit/mhash.result
+++ /dev/null
@@ -1,18 +0,0 @@
-	*** main ***
-1..3
-	*** mhash_int32_id_test ***
-    1..0
-	*** mhash_int32_id_test: done ***
-ok 1 - subtests
-	*** mhash_int32_collision_test ***
-    1..0
-	*** mhash_int32_collision_test: done ***
-ok 2 - subtests
-	*** mhash_random_test ***
-    1..3
-    ok 1 - empty random is always 'end'
-    ok 2 - one element is always found
-    ok 3 - incremental random from mutable hash
-ok 3 - subtests
-	*** mhash_random_test: done ***
-	*** main: done ***
diff --git a/test/unit/mhash_bytemap.result b/test/unit/mhash_bytemap.result
deleted file mode 100644
index fc757fa35..000000000
--- a/test/unit/mhash_bytemap.result
+++ /dev/null
@@ -1,18 +0,0 @@
-	*** main ***
-1..3
-	*** mhash_int32_id_test ***
-    1..0
-	*** mhash_int32_id_test: done ***
-ok 1 - subtests
-	*** mhash_int32_collision_test ***
-    1..0
-	*** mhash_int32_collision_test: done ***
-ok 2 - subtests
-	*** mhash_random_test ***
-    1..3
-    ok 1 - empty random is always 'end'
-    ok 2 - one element is always found
-    ok 3 - incremental random from mutable hash
-ok 3 - subtests
-	*** mhash_random_test: done ***
-	*** main: done ***
diff --git a/test/unit/mp_error.result b/test/unit/mp_error.result
deleted file mode 100644
index 6ef37b4d5..000000000
--- a/test/unit/mp_error.result
+++ /dev/null
@@ -1,44 +0,0 @@
-	*** main ***
-1..5
-	*** test_stack_error_decode ***
-    1..17
-    ok 1 - check CustomError
-    ok 2 - check AccessDeniedError
-    ok 3 - check ClientError
-    ok 4 - check XlogError
-    ok 5 - check XlogGapError
-    ok 6 - check SystemError
-    ok 7 - check SocketError
-    ok 8 - check OutOfMemory
-    ok 9 - check TimedOut
-    ok 10 - check ChannelIsClosed
-    ok 11 - check FiberIsCancelled
-    ok 12 - check LuajitError
-    ok 13 - check IllegalParams
-    ok 14 - check CollationError
-    ok 15 - check SwimError
-    ok 16 - check CryptoError
-    ok 17 - stack size
-ok 1 - subtests
-	*** test_stack_error_decode: done ***
-	*** test_decode_unknown_type ***
-    1..1
-    ok 1 - check SomeNewError
-ok 2 - subtests
-	*** test_decode_unknown_type: done ***
-	*** test_fail_not_enough_fields ***
-    1..2
-    ok 1 - check not enough additional fields
-    ok 2 - error about parsing problem is set
-ok 3 - subtests
-	*** test_fail_not_enough_fields: done ***
-	*** test_unknown_fields ***
-    1..1
-    ok 1 - check unknown fields
-ok 4 - subtests
-	*** test_unknown_additional_fields ***
-    1..1
-    ok 1 - check unknown additional field
-ok 5 - subtests
-	*** test_unknown_additional_fields: done ***
-	*** main: done ***
diff --git a/test/unit/msgpack.result b/test/unit/msgpack.result
deleted file mode 100644
index 02c0b05fd..000000000
--- a/test/unit/msgpack.result
+++ /dev/null
@@ -1,2282 +0,0 @@
-1..22
-    1..135
-    # *** test_uints ***
-    # uint 0U
-    ok 1 - mp_check_uint(0U) == 0
-    ok 2 - mp_decode(mp_encode(0U)) == 0U
-    ok 3 - mp_check(0U)
-    ok 4 - len(mp_encode_uint(0U)
-    ok 5 - len(mp_decode_uint(0U))
-    ok 6 - len(mp_next_uint(0U))
-    ok 7 - len(mp_check_uint(0U))
-    ok 8 - mp_sizeof_uint(0U)
-    ok 9 - mp_encode(0U) == "\x00"
-    # uint 1U
-    ok 10 - mp_check_uint(1U) == 0
-    ok 11 - mp_decode(mp_encode(1U)) == 1U
-    ok 12 - mp_check(1U)
-    ok 13 - len(mp_encode_uint(1U)
-    ok 14 - len(mp_decode_uint(1U))
-    ok 15 - len(mp_next_uint(1U))
-    ok 16 - len(mp_check_uint(1U))
-    ok 17 - mp_sizeof_uint(1U)
-    ok 18 - mp_encode(1U) == "\x01"
-    # uint 0x7eU
-    ok 19 - mp_check_uint(0x7eU) == 0
-    ok 20 - mp_decode(mp_encode(0x7eU)) == 0x7eU
-    ok 21 - mp_check(0x7eU)
-    ok 22 - len(mp_encode_uint(0x7eU)
-    ok 23 - len(mp_decode_uint(0x7eU))
-    ok 24 - len(mp_next_uint(0x7eU))
-    ok 25 - len(mp_check_uint(0x7eU))
-    ok 26 - mp_sizeof_uint(0x7eU)
-    ok 27 - mp_encode(0x7eU) == "\x7e"
-    # uint 0x7fU
-    ok 28 - mp_check_uint(0x7fU) == 0
-    ok 29 - mp_decode(mp_encode(0x7fU)) == 0x7fU
-    ok 30 - mp_check(0x7fU)
-    ok 31 - len(mp_encode_uint(0x7fU)
-    ok 32 - len(mp_decode_uint(0x7fU))
-    ok 33 - len(mp_next_uint(0x7fU))
-    ok 34 - len(mp_check_uint(0x7fU))
-    ok 35 - mp_sizeof_uint(0x7fU)
-    ok 36 - mp_encode(0x7fU) == "\x7f"
-    # uint 0x80U
-    ok 37 - mp_check_uint(0x80U) == 0
-    ok 38 - mp_decode(mp_encode(0x80U)) == 0x80U
-    ok 39 - mp_check(0x80U)
-    ok 40 - len(mp_encode_uint(0x80U)
-    ok 41 - len(mp_decode_uint(0x80U))
-    ok 42 - len(mp_next_uint(0x80U))
-    ok 43 - len(mp_check_uint(0x80U))
-    ok 44 - mp_sizeof_uint(0x80U)
-    ok 45 - mp_encode(0x80U) == "\xcc\x80"
-    # uint 0xfeU
-    ok 46 - mp_check_uint(0xfeU) == 0
-    ok 47 - mp_decode(mp_encode(0xfeU)) == 0xfeU
-    ok 48 - mp_check(0xfeU)
-    ok 49 - len(mp_encode_uint(0xfeU)
-    ok 50 - len(mp_decode_uint(0xfeU))
-    ok 51 - len(mp_next_uint(0xfeU))
-    ok 52 - len(mp_check_uint(0xfeU))
-    ok 53 - mp_sizeof_uint(0xfeU)
-    ok 54 - mp_encode(0xfeU) == "\xcc\xfe"
-    # uint 0xffU
-    ok 55 - mp_check_uint(0xffU) == 0
-    ok 56 - mp_decode(mp_encode(0xffU)) == 0xffU
-    ok 57 - mp_check(0xffU)
-    ok 58 - len(mp_encode_uint(0xffU)
-    ok 59 - len(mp_decode_uint(0xffU))
-    ok 60 - len(mp_next_uint(0xffU))
-    ok 61 - len(mp_check_uint(0xffU))
-    ok 62 - mp_sizeof_uint(0xffU)
-    ok 63 - mp_encode(0xffU) == "\xcc\xff"
-    # uint 0xfffeU
-    ok 64 - mp_check_uint(0xfffeU) == 0
-    ok 65 - mp_decode(mp_encode(0xfffeU)) == 0xfffeU
-    ok 66 - mp_check(0xfffeU)
-    ok 67 - len(mp_encode_uint(0xfffeU)
-    ok 68 - len(mp_decode_uint(0xfffeU))
-    ok 69 - len(mp_next_uint(0xfffeU))
-    ok 70 - len(mp_check_uint(0xfffeU))
-    ok 71 - mp_sizeof_uint(0xfffeU)
-    ok 72 - mp_encode(0xfffeU) == "\xcd\xff\xfe"
-    # uint 0xffffU
-    ok 73 - mp_check_uint(0xffffU) == 0
-    ok 74 - mp_decode(mp_encode(0xffffU)) == 0xffffU
-    ok 75 - mp_check(0xffffU)
-    ok 76 - len(mp_encode_uint(0xffffU)
-    ok 77 - len(mp_decode_uint(0xffffU))
-    ok 78 - len(mp_next_uint(0xffffU))
-    ok 79 - len(mp_check_uint(0xffffU))
-    ok 80 - mp_sizeof_uint(0xffffU)
-    ok 81 - mp_encode(0xffffU) == "\xcd\xff\xff"
-    # uint 0x10000U
-    ok 82 - mp_check_uint(0x10000U) == 0
-    ok 83 - mp_decode(mp_encode(0x10000U)) == 0x10000U
-    ok 84 - mp_check(0x10000U)
-    ok 85 - len(mp_encode_uint(0x10000U)
-    ok 86 - len(mp_decode_uint(0x10000U))
-    ok 87 - len(mp_next_uint(0x10000U))
-    ok 88 - len(mp_check_uint(0x10000U))
-    ok 89 - mp_sizeof_uint(0x10000U)
-    ok 90 - mp_encode(0x10000U) == "\xce\x00\x01\x00\x00"
-    # uint 0xfffffffeU
-    ok 91 - mp_check_uint(0xfffffffeU) == 0
-    ok 92 - mp_decode(mp_encode(0xfffffffeU)) == 0xfffffffeU
-    ok 93 - mp_check(0xfffffffeU)
-    ok 94 - len(mp_encode_uint(0xfffffffeU)
-    ok 95 - len(mp_decode_uint(0xfffffffeU))
-    ok 96 - len(mp_next_uint(0xfffffffeU))
-    ok 97 - len(mp_check_uint(0xfffffffeU))
-    ok 98 - mp_sizeof_uint(0xfffffffeU)
-    ok 99 - mp_encode(0xfffffffeU) == "\xce\xff\xff\xff\xfe"
-    # uint 0xffffffffU
-    ok 100 - mp_check_uint(0xffffffffU) == 0
-    ok 101 - mp_decode(mp_encode(0xffffffffU)) == 0xffffffffU
-    ok 102 - mp_check(0xffffffffU)
-    ok 103 - len(mp_encode_uint(0xffffffffU)
-    ok 104 - len(mp_decode_uint(0xffffffffU))
-    ok 105 - len(mp_next_uint(0xffffffffU))
-    ok 106 - len(mp_check_uint(0xffffffffU))
-    ok 107 - mp_sizeof_uint(0xffffffffU)
-    ok 108 - mp_encode(0xffffffffU) == "\xce\xff\xff\xff\xff"
-    # uint 0x100000000ULL
-    ok 109 - mp_check_uint(0x100000000ULL) == 0
-    ok 110 - mp_decode(mp_encode(0x100000000ULL)) == 0x100000000ULL
-    ok 111 - mp_check(0x100000000ULL)
-    ok 112 - len(mp_encode_uint(0x100000000ULL)
-    ok 113 - len(mp_decode_uint(0x100000000ULL))
-    ok 114 - len(mp_next_uint(0x100000000ULL))
-    ok 115 - len(mp_check_uint(0x100000000ULL))
-    ok 116 - mp_sizeof_uint(0x100000000ULL)
-    ok 117 - mp_encode(0x100000000ULL) == "\xcf\x00\x00\x00\x01\x00\x00\x00\x00"
-    # uint 0xfffffffffffffffeULL
-    ok 118 - mp_check_uint(0xfffffffffffffffeULL) == 0
-    ok 119 - mp_decode(mp_encode(0xfffffffffffffffeULL)) == 0xfffffffffffffffeULL
-    ok 120 - mp_check(0xfffffffffffffffeULL)
-    ok 121 - len(mp_encode_uint(0xfffffffffffffffeULL)
-    ok 122 - len(mp_decode_uint(0xfffffffffffffffeULL))
-    ok 123 - len(mp_next_uint(0xfffffffffffffffeULL))
-    ok 124 - len(mp_check_uint(0xfffffffffffffffeULL))
-    ok 125 - mp_sizeof_uint(0xfffffffffffffffeULL)
-    ok 126 - mp_encode(0xfffffffffffffffeULL) == "\xcf\xff\xff\xff\xff\xff\xff\xff\xfe"
-    # uint 0xffffffffffffffffULL
-    ok 127 - mp_check_uint(0xffffffffffffffffULL) == 0
-    ok 128 - mp_decode(mp_encode(0xffffffffffffffffULL)) == 0xffffffffffffffffULL
-    ok 129 - mp_check(0xffffffffffffffffULL)
-    ok 130 - len(mp_encode_uint(0xffffffffffffffffULL)
-    ok 131 - len(mp_decode_uint(0xffffffffffffffffULL))
-    ok 132 - len(mp_next_uint(0xffffffffffffffffULL))
-    ok 133 - len(mp_check_uint(0xffffffffffffffffULL))
-    ok 134 - mp_sizeof_uint(0xffffffffffffffffULL)
-    ok 135 - mp_encode(0xffffffffffffffffULL) == "\xcf\xff\xff\xff\xff\xff\xff\xff\xff"
-    # *** test_uints: done ***
-ok 1 - subtests
-    1..153
-    # *** test_ints ***
-    # int -0x01
-    ok 1 - mp_check_int(-0x01) == 0
-    ok 2 - mp_decode(mp_encode(-0x01)) == -0x01
-    ok 3 - mp_check(-0x01)
-    ok 4 - len(mp_encode_int(-0x01)
-    ok 5 - len(mp_decode_int(-0x01))
-    ok 6 - len(mp_next_int(-0x01))
-    ok 7 - len(mp_check_int(-0x01))
-    ok 8 - mp_sizeof_int(-0x01)
-    ok 9 - mp_encode(-0x01) == "\xff"
-    # int -0x1e
-    ok 10 - mp_check_int(-0x1e) == 0
-    ok 11 - mp_decode(mp_encode(-0x1e)) == -0x1e
-    ok 12 - mp_check(-0x1e)
-    ok 13 - len(mp_encode_int(-0x1e)
-    ok 14 - len(mp_decode_int(-0x1e))
-    ok 15 - len(mp_next_int(-0x1e))
-    ok 16 - len(mp_check_int(-0x1e))
-    ok 17 - mp_sizeof_int(-0x1e)
-    ok 18 - mp_encode(-0x1e) == "\xe2"
-    # int -0x1f
-    ok 19 - mp_check_int(-0x1f) == 0
-    ok 20 - mp_decode(mp_encode(-0x1f)) == -0x1f
-    ok 21 - mp_check(-0x1f)
-    ok 22 - len(mp_encode_int(-0x1f)
-    ok 23 - len(mp_decode_int(-0x1f))
-    ok 24 - len(mp_next_int(-0x1f))
-    ok 25 - len(mp_check_int(-0x1f))
-    ok 26 - mp_sizeof_int(-0x1f)
-    ok 27 - mp_encode(-0x1f) == "\xe1"
-    # int -0x20
-    ok 28 - mp_check_int(-0x20) == 0
-    ok 29 - mp_decode(mp_encode(-0x20)) == -0x20
-    ok 30 - mp_check(-0x20)
-    ok 31 - len(mp_encode_int(-0x20)
-    ok 32 - len(mp_decode_int(-0x20))
-    ok 33 - len(mp_next_int(-0x20))
-    ok 34 - len(mp_check_int(-0x20))
-    ok 35 - mp_sizeof_int(-0x20)
-    ok 36 - mp_encode(-0x20) == "\xe0"
-    # int -0x21
-    ok 37 - mp_check_int(-0x21) == 0
-    ok 38 - mp_decode(mp_encode(-0x21)) == -0x21
-    ok 39 - mp_check(-0x21)
-    ok 40 - len(mp_encode_int(-0x21)
-    ok 41 - len(mp_decode_int(-0x21))
-    ok 42 - len(mp_next_int(-0x21))
-    ok 43 - len(mp_check_int(-0x21))
-    ok 44 - mp_sizeof_int(-0x21)
-    ok 45 - mp_encode(-0x21) == "\xd0\xdf"
-    # int -0x7f
-    ok 46 - mp_check_int(-0x7f) == 0
-    ok 47 - mp_decode(mp_encode(-0x7f)) == -0x7f
-    ok 48 - mp_check(-0x7f)
-    ok 49 - len(mp_encode_int(-0x7f)
-    ok 50 - len(mp_decode_int(-0x7f))
-    ok 51 - len(mp_next_int(-0x7f))
-    ok 52 - len(mp_check_int(-0x7f))
-    ok 53 - mp_sizeof_int(-0x7f)
-    ok 54 - mp_encode(-0x7f) == "\xd0\x81"
-    # int -0x80
-    ok 55 - mp_check_int(-0x80) == 0
-    ok 56 - mp_decode(mp_encode(-0x80)) == -0x80
-    ok 57 - mp_check(-0x80)
-    ok 58 - len(mp_encode_int(-0x80)
-    ok 59 - len(mp_decode_int(-0x80))
-    ok 60 - len(mp_next_int(-0x80))
-    ok 61 - len(mp_check_int(-0x80))
-    ok 62 - mp_sizeof_int(-0x80)
-    ok 63 - mp_encode(-0x80) == "\xd0\x80"
-    # int -0x81
-    ok 64 - mp_check_int(-0x81) == 0
-    ok 65 - mp_decode(mp_encode(-0x81)) == -0x81
-    ok 66 - mp_check(-0x81)
-    ok 67 - len(mp_encode_int(-0x81)
-    ok 68 - len(mp_decode_int(-0x81))
-    ok 69 - len(mp_next_int(-0x81))
-    ok 70 - len(mp_check_int(-0x81))
-    ok 71 - mp_sizeof_int(-0x81)
-    ok 72 - mp_encode(-0x81) == "\xd1\xff\x7f"
-    # int -0x7fff
-    ok 73 - mp_check_int(-0x7fff) == 0
-    ok 74 - mp_decode(mp_encode(-0x7fff)) == -0x7fff
-    ok 75 - mp_check(-0x7fff)
-    ok 76 - len(mp_encode_int(-0x7fff)
-    ok 77 - len(mp_decode_int(-0x7fff))
-    ok 78 - len(mp_next_int(-0x7fff))
-    ok 79 - len(mp_check_int(-0x7fff))
-    ok 80 - mp_sizeof_int(-0x7fff)
-    ok 81 - mp_encode(-0x7fff) == "\xd1\x80\x01"
-    # int -0x8000
-    ok 82 - mp_check_int(-0x8000) == 0
-    ok 83 - mp_decode(mp_encode(-0x8000)) == -0x8000
-    ok 84 - mp_check(-0x8000)
-    ok 85 - len(mp_encode_int(-0x8000)
-    ok 86 - len(mp_decode_int(-0x8000))
-    ok 87 - len(mp_next_int(-0x8000))
-    ok 88 - len(mp_check_int(-0x8000))
-    ok 89 - mp_sizeof_int(-0x8000)
-    ok 90 - mp_encode(-0x8000) == "\xd1\x80\x00"
-    # int -0x8001
-    ok 91 - mp_check_int(-0x8001) == 0
-    ok 92 - mp_decode(mp_encode(-0x8001)) == -0x8001
-    ok 93 - mp_check(-0x8001)
-    ok 94 - len(mp_encode_int(-0x8001)
-    ok 95 - len(mp_decode_int(-0x8001))
-    ok 96 - len(mp_next_int(-0x8001))
-    ok 97 - len(mp_check_int(-0x8001))
-    ok 98 - mp_sizeof_int(-0x8001)
-    ok 99 - mp_encode(-0x8001) == "\xd2\xff\xff\x7f\xff"
-    # int -0x7fffffff
-    ok 100 - mp_check_int(-0x7fffffff) == 0
-    ok 101 - mp_decode(mp_encode(-0x7fffffff)) == -0x7fffffff
-    ok 102 - mp_check(-0x7fffffff)
-    ok 103 - len(mp_encode_int(-0x7fffffff)
-    ok 104 - len(mp_decode_int(-0x7fffffff))
-    ok 105 - len(mp_next_int(-0x7fffffff))
-    ok 106 - len(mp_check_int(-0x7fffffff))
-    ok 107 - mp_sizeof_int(-0x7fffffff)
-    ok 108 - mp_encode(-0x7fffffff) == "\xd2\x80\x00\x00\x01"
-    # int -0x80000000LL
-    ok 109 - mp_check_int(-0x80000000LL) == 0
-    ok 110 - mp_decode(mp_encode(-0x80000000LL)) == -0x80000000LL
-    ok 111 - mp_check(-0x80000000LL)
-    ok 112 - len(mp_encode_int(-0x80000000LL)
-    ok 113 - len(mp_decode_int(-0x80000000LL))
-    ok 114 - len(mp_next_int(-0x80000000LL))
-    ok 115 - len(mp_check_int(-0x80000000LL))
-    ok 116 - mp_sizeof_int(-0x80000000LL)
-    ok 117 - mp_encode(-0x80000000LL) == "\xd2\x80\x00\x00\x00"
-    # int -0x80000001LL
-    ok 118 - mp_check_int(-0x80000001LL) == 0
-    ok 119 - mp_decode(mp_encode(-0x80000001LL)) == -0x80000001LL
-    ok 120 - mp_check(-0x80000001LL)
-    ok 121 - len(mp_encode_int(-0x80000001LL)
-    ok 122 - len(mp_decode_int(-0x80000001LL))
-    ok 123 - len(mp_next_int(-0x80000001LL))
-    ok 124 - len(mp_check_int(-0x80000001LL))
-    ok 125 - mp_sizeof_int(-0x80000001LL)
-    ok 126 - mp_encode(-0x80000001LL) == "\xd3\xff\xff\xff\xff\x7f\xff\xff\xff"
-    # int -0x80000001LL
-    ok 127 - mp_check_int(-0x80000001LL) == 0
-    ok 128 - mp_decode(mp_encode(-0x80000001LL)) == -0x80000001LL
-    ok 129 - mp_check(-0x80000001LL)
-    ok 130 - len(mp_encode_int(-0x80000001LL)
-    ok 131 - len(mp_decode_int(-0x80000001LL))
-    ok 132 - len(mp_next_int(-0x80000001LL))
-    ok 133 - len(mp_check_int(-0x80000001LL))
-    ok 134 - mp_sizeof_int(-0x80000001LL)
-    ok 135 - mp_encode(-0x80000001LL) == "\xd3\xff\xff\xff\xff\x7f\xff\xff\xff"
-    # int -0x7fffffffffffffffLL
-    ok 136 - mp_check_int(-0x7fffffffffffffffLL) == 0
-    ok 137 - mp_decode(mp_encode(-0x7fffffffffffffffLL)) == -0x7fffffffffffffffLL
-    ok 138 - mp_check(-0x7fffffffffffffffLL)
-    ok 139 - len(mp_encode_int(-0x7fffffffffffffffLL)
-    ok 140 - len(mp_decode_int(-0x7fffffffffffffffLL))
-    ok 141 - len(mp_next_int(-0x7fffffffffffffffLL))
-    ok 142 - len(mp_check_int(-0x7fffffffffffffffLL))
-    ok 143 - mp_sizeof_int(-0x7fffffffffffffffLL)
-    ok 144 - mp_encode(-0x7fffffffffffffffLL) == "\xd3\x80\x00\x00\x00\x00\x00\x00\x01"
-    # int (int64_t)-0x8000000000000000LL
-    ok 145 - mp_check_int((int64_t)-0x8000000000000000LL) == 0
-    ok 146 - mp_decode(mp_encode((int64_t)-0x8000000000000000LL)) == (int64_t)-0x8000000000000000LL
-    ok 147 - mp_check((int64_t)-0x8000000000000000LL)
-    ok 148 - len(mp_encode_int((int64_t)-0x8000000000000000LL)
-    ok 149 - len(mp_decode_int((int64_t)-0x8000000000000000LL))
-    ok 150 - len(mp_next_int((int64_t)-0x8000000000000000LL))
-    ok 151 - len(mp_check_int((int64_t)-0x8000000000000000LL))
-    ok 152 - mp_sizeof_int((int64_t)-0x8000000000000000LL)
-    ok 153 - mp_encode((int64_t)-0x8000000000000000LL) == "\xd3\x80\x00\x00\x00\x00\x00\x00\x00"
-    # *** test_ints: done ***
-ok 2 - subtests
-    1..18
-    # *** test_bools ***
-    # bool 1
-    ok 1 - mp_check_bool(1) == 0
-    ok 2 - mp_decode(mp_encode(1)) == 1
-    ok 3 - mp_check(1)
-    ok 4 - len(mp_encode_bool(1)
-    ok 5 - len(mp_decode_bool(1))
-    ok 6 - len(mp_next_bool(1))
-    ok 7 - len(mp_check_bool(1))
-    ok 8 - mp_sizeof_bool(1)
-    ok 9 - mp_encode(1) == "\xc3"
-    # bool 0
-    ok 10 - mp_check_bool(0) == 0
-    ok 11 - mp_decode(mp_encode(0)) == 0
-    ok 12 - mp_check(0)
-    ok 13 - len(mp_encode_bool(0)
-    ok 14 - len(mp_decode_bool(0))
-    ok 15 - len(mp_next_bool(0))
-    ok 16 - len(mp_check_bool(0))
-    ok 17 - mp_sizeof_bool(0)
-    ok 18 - mp_encode(0) == "\xc2"
-    # *** test_bools: done ***
-ok 3 - subtests
-    1..27
-    # *** test_floats ***
-    # float (float) 1.0
-    ok 1 - mp_check_float((float) 1.0) == 0
-    ok 2 - mp_decode(mp_encode((float) 1.0)) == (float) 1.0
-    ok 3 - mp_check((float) 1.0)
-    ok 4 - len(mp_encode_float((float) 1.0)
-    ok 5 - len(mp_decode_float((float) 1.0))
-    ok 6 - len(mp_next_float((float) 1.0))
-    ok 7 - len(mp_check_float((float) 1.0))
-    ok 8 - mp_sizeof_float((float) 1.0)
-    ok 9 - mp_encode((float) 1.0) == "\xca\x3f\x80\x00\x00"
-    # float (float) 3.141593
-    ok 10 - mp_check_float((float) 3.141593) == 0
-    ok 11 - mp_decode(mp_encode((float) 3.141593)) == (float) 3.141593
-    ok 12 - mp_check((float) 3.141593)
-    ok 13 - len(mp_encode_float((float) 3.141593)
-    ok 14 - len(mp_decode_float((float) 3.141593))
-    ok 15 - len(mp_next_float((float) 3.141593))
-    ok 16 - len(mp_check_float((float) 3.141593))
-    ok 17 - mp_sizeof_float((float) 3.141593)
-    ok 18 - mp_encode((float) 3.141593) == "\xca\x40\x49\x0f\xdc"
-    # float (float) -1e38f
-    ok 19 - mp_check_float((float) -1e38f) == 0
-    ok 20 - mp_decode(mp_encode((float) -1e38f)) == (float) -1e38f
-    ok 21 - mp_check((float) -1e38f)
-    ok 22 - len(mp_encode_float((float) -1e38f)
-    ok 23 - len(mp_decode_float((float) -1e38f))
-    ok 24 - len(mp_next_float((float) -1e38f))
-    ok 25 - len(mp_check_float((float) -1e38f))
-    ok 26 - mp_sizeof_float((float) -1e38f)
-    ok 27 - mp_encode((float) -1e38f) == "\xca\xfe\x96\x76\x99"
-    # *** test_floats: done ***
-ok 4 - subtests
-    1..27
-    # *** test_doubles ***
-    # double (double) 1.0
-    ok 1 - mp_check_double((double) 1.0) == 0
-    ok 2 - mp_decode(mp_encode((double) 1.0)) == (double) 1.0
-    ok 3 - mp_check((double) 1.0)
-    ok 4 - len(mp_encode_double((double) 1.0)
-    ok 5 - len(mp_decode_double((double) 1.0))
-    ok 6 - len(mp_next_double((double) 1.0))
-    ok 7 - len(mp_check_double((double) 1.0))
-    ok 8 - mp_sizeof_double((double) 1.0)
-    ok 9 - mp_encode((double) 1.0) == "\xcb\x3f\xf0\x00\x00\x00\x00\x00\x00"
-    # double (double) 3.141592653589793
-    ok 10 - mp_check_double((double) 3.141592653589793) == 0
-    ok 11 - mp_decode(mp_encode((double) 3.141592653589793)) == (double) 3.141592653589793
-    ok 12 - mp_check((double) 3.141592653589793)
-    ok 13 - len(mp_encode_double((double) 3.141592653589793)
-    ok 14 - len(mp_decode_double((double) 3.141592653589793))
-    ok 15 - len(mp_next_double((double) 3.141592653589793))
-    ok 16 - len(mp_check_double((double) 3.141592653589793))
-    ok 17 - mp_sizeof_double((double) 3.141592653589793)
-    ok 18 - mp_encode((double) 3.141592653589793) == "\xcb\x40\x09\x21\xfb\x54\x44\x2d\x18"
-    # double (double) -1e99
-    ok 19 - mp_check_double((double) -1e99) == 0
-    ok 20 - mp_decode(mp_encode((double) -1e99)) == (double) -1e99
-    ok 21 - mp_check((double) -1e99)
-    ok 22 - len(mp_encode_double((double) -1e99)
-    ok 23 - len(mp_decode_double((double) -1e99))
-    ok 24 - len(mp_next_double((double) -1e99))
-    ok 25 - len(mp_check_double((double) -1e99))
-    ok 26 - mp_sizeof_double((double) -1e99)
-    ok 27 - mp_encode((double) -1e99) == "\xcb\xd4\x7d\x42\xae\xa2\x87\x9f\x2e"
-    # *** test_doubles: done ***
-ok 5 - subtests
-    1..6
-    # *** test_nils ***
-    # nil
-    ok 1 - mp_check_nil()
-    ok 2 - len(mp_encode_nil() == 1
-    ok 3 - len(mp_decode_nil()) == 1
-    ok 4 - len(mp_next_nil()) == 1
-    ok 5 - len(mp_check_nil()) == 1
-    ok 6 - mp_sizeof_nil() == 1
-    # *** test_nils: done ***
-ok 6 - subtests
-    1..78
-    # *** test_strls ***
-    # strl 0x00U
-    ok 1 - mp_check_strl(0x00U) == 0
-    ok 2 - mp_decode(mp_encode(0x00U)) == 0x00U
-    ok 3 - len(mp_encode_strl(0x00U)
-    ok 4 - len(mp_decode_strl(0x00U))
-    ok 5 - mp_sizeof_strl(0x00U)
-    ok 6 - mp_encode(0x00U) == "\xa0"
-    # strl 0x01U
-    ok 7 - mp_check_strl(0x01U) == 0
-    ok 8 - mp_decode(mp_encode(0x01U)) == 0x01U
-    ok 9 - len(mp_encode_strl(0x01U)
-    ok 10 - len(mp_decode_strl(0x01U))
-    ok 11 - mp_sizeof_strl(0x01U)
-    ok 12 - mp_encode(0x01U) == "\xa1"
-    # strl 0x1eU
-    ok 13 - mp_check_strl(0x1eU) == 0
-    ok 14 - mp_decode(mp_encode(0x1eU)) == 0x1eU
-    ok 15 - len(mp_encode_strl(0x1eU)
-    ok 16 - len(mp_decode_strl(0x1eU))
-    ok 17 - mp_sizeof_strl(0x1eU)
-    ok 18 - mp_encode(0x1eU) == "\xbe"
-    # strl 0x1fU
-    ok 19 - mp_check_strl(0x1fU) == 0
-    ok 20 - mp_decode(mp_encode(0x1fU)) == 0x1fU
-    ok 21 - len(mp_encode_strl(0x1fU)
-    ok 22 - len(mp_decode_strl(0x1fU))
-    ok 23 - mp_sizeof_strl(0x1fU)
-    ok 24 - mp_encode(0x1fU) == "\xbf"
-    # strl 0x20U
-    ok 25 - mp_check_strl(0x20U) == 0
-    ok 26 - mp_decode(mp_encode(0x20U)) == 0x20U
-    ok 27 - len(mp_encode_strl(0x20U)
-    ok 28 - len(mp_decode_strl(0x20U))
-    ok 29 - mp_sizeof_strl(0x20U)
-    ok 30 - mp_encode(0x20U) == "\xd9\x20"
-    # strl 0xfeU
-    ok 31 - mp_check_strl(0xfeU) == 0
-    ok 32 - mp_decode(mp_encode(0xfeU)) == 0xfeU
-    ok 33 - len(mp_encode_strl(0xfeU)
-    ok 34 - len(mp_decode_strl(0xfeU))
-    ok 35 - mp_sizeof_strl(0xfeU)
-    ok 36 - mp_encode(0xfeU) == "\xd9\xfe"
-    # strl 0xffU
-    ok 37 - mp_check_strl(0xffU) == 0
-    ok 38 - mp_decode(mp_encode(0xffU)) == 0xffU
-    ok 39 - len(mp_encode_strl(0xffU)
-    ok 40 - len(mp_decode_strl(0xffU))
-    ok 41 - mp_sizeof_strl(0xffU)
-    ok 42 - mp_encode(0xffU) == "\xd9\xff"
-    # strl 0x0100U
-    ok 43 - mp_check_strl(0x0100U) == 0
-    ok 44 - mp_decode(mp_encode(0x0100U)) == 0x0100U
-    ok 45 - len(mp_encode_strl(0x0100U)
-    ok 46 - len(mp_decode_strl(0x0100U))
-    ok 47 - mp_sizeof_strl(0x0100U)
-    ok 48 - mp_encode(0x0100U) == "\xda\x01\x00"
-    # strl 0xfffeU
-    ok 49 - mp_check_strl(0xfffeU) == 0
-    ok 50 - mp_decode(mp_encode(0xfffeU)) == 0xfffeU
-    ok 51 - len(mp_encode_strl(0xfffeU)
-    ok 52 - len(mp_decode_strl(0xfffeU))
-    ok 53 - mp_sizeof_strl(0xfffeU)
-    ok 54 - mp_encode(0xfffeU) == "\xda\xff\xfe"
-    # strl 0xffffU
-    ok 55 - mp_check_strl(0xffffU) == 0
-    ok 56 - mp_decode(mp_encode(0xffffU)) == 0xffffU
-    ok 57 - len(mp_encode_strl(0xffffU)
-    ok 58 - len(mp_decode_strl(0xffffU))
-    ok 59 - mp_sizeof_strl(0xffffU)
-    ok 60 - mp_encode(0xffffU) == "\xda\xff\xff"
-    # strl 0x00010000U
-    ok 61 - mp_check_strl(0x00010000U) == 0
-    ok 62 - mp_decode(mp_encode(0x00010000U)) == 0x00010000U
-    ok 63 - len(mp_encode_strl(0x00010000U)
-    ok 64 - len(mp_decode_strl(0x00010000U))
-    ok 65 - mp_sizeof_strl(0x00010000U)
-    ok 66 - mp_encode(0x00010000U) == "\xdb\x00\x01\x00\x00"
-    # strl 0xfffffffeU
-    ok 67 - mp_check_strl(0xfffffffeU) == 0
-    ok 68 - mp_decode(mp_encode(0xfffffffeU)) == 0xfffffffeU
-    ok 69 - len(mp_encode_strl(0xfffffffeU)
-    ok 70 - len(mp_decode_strl(0xfffffffeU))
-    ok 71 - mp_sizeof_strl(0xfffffffeU)
-    ok 72 - mp_encode(0xfffffffeU) == "\xdb\xff\xff\xff\xfe"
-    # strl 0xffffffffU
-    ok 73 - mp_check_strl(0xffffffffU) == 0
-    ok 74 - mp_decode(mp_encode(0xffffffffU)) == 0xffffffffU
-    ok 75 - len(mp_encode_strl(0xffffffffU)
-    ok 76 - len(mp_decode_strl(0xffffffffU))
-    ok 77 - mp_sizeof_strl(0xffffffffU)
-    ok 78 - mp_encode(0xffffffffU) == "\xdb\xff\xff\xff\xff"
-    # *** test_strls: done ***
-ok 7 - subtests
-    1..78
-    # *** test_binls ***
-    # binl 0x00U
-    ok 1 - mp_check_binl(0x00U) == 0
-    ok 2 - mp_decode(mp_encode(0x00U)) == 0x00U
-    ok 3 - len(mp_encode_binl(0x00U)
-    ok 4 - len(mp_decode_binl(0x00U))
-    ok 5 - mp_sizeof_binl(0x00U)
-    ok 6 - mp_encode(0x00U) == "\xc4\x00"
-    # binl 0x01U
-    ok 7 - mp_check_binl(0x01U) == 0
-    ok 8 - mp_decode(mp_encode(0x01U)) == 0x01U
-    ok 9 - len(mp_encode_binl(0x01U)
-    ok 10 - len(mp_decode_binl(0x01U))
-    ok 11 - mp_sizeof_binl(0x01U)
-    ok 12 - mp_encode(0x01U) == "\xc4\x01"
-    # binl 0x1eU
-    ok 13 - mp_check_binl(0x1eU) == 0
-    ok 14 - mp_decode(mp_encode(0x1eU)) == 0x1eU
-    ok 15 - len(mp_encode_binl(0x1eU)
-    ok 16 - len(mp_decode_binl(0x1eU))
-    ok 17 - mp_sizeof_binl(0x1eU)
-    ok 18 - mp_encode(0x1eU) == "\xc4\x1e"
-    # binl 0x1fU
-    ok 19 - mp_check_binl(0x1fU) == 0
-    ok 20 - mp_decode(mp_encode(0x1fU)) == 0x1fU
-    ok 21 - len(mp_encode_binl(0x1fU)
-    ok 22 - len(mp_decode_binl(0x1fU))
-    ok 23 - mp_sizeof_binl(0x1fU)
-    ok 24 - mp_encode(0x1fU) == "\xc4\x1f"
-    # binl 0x20U
-    ok 25 - mp_check_binl(0x20U) == 0
-    ok 26 - mp_decode(mp_encode(0x20U)) == 0x20U
-    ok 27 - len(mp_encode_binl(0x20U)
-    ok 28 - len(mp_decode_binl(0x20U))
-    ok 29 - mp_sizeof_binl(0x20U)
-    ok 30 - mp_encode(0x20U) == "\xc4\x20"
-    # binl 0xfeU
-    ok 31 - mp_check_binl(0xfeU) == 0
-    ok 32 - mp_decode(mp_encode(0xfeU)) == 0xfeU
-    ok 33 - len(mp_encode_binl(0xfeU)
-    ok 34 - len(mp_decode_binl(0xfeU))
-    ok 35 - mp_sizeof_binl(0xfeU)
-    ok 36 - mp_encode(0xfeU) == "\xc4\xfe"
-    # binl 0xffU
-    ok 37 - mp_check_binl(0xffU) == 0
-    ok 38 - mp_decode(mp_encode(0xffU)) == 0xffU
-    ok 39 - len(mp_encode_binl(0xffU)
-    ok 40 - len(mp_decode_binl(0xffU))
-    ok 41 - mp_sizeof_binl(0xffU)
-    ok 42 - mp_encode(0xffU) == "\xc4\xff"
-    # binl 0x0100U
-    ok 43 - mp_check_binl(0x0100U) == 0
-    ok 44 - mp_decode(mp_encode(0x0100U)) == 0x0100U
-    ok 45 - len(mp_encode_binl(0x0100U)
-    ok 46 - len(mp_decode_binl(0x0100U))
-    ok 47 - mp_sizeof_binl(0x0100U)
-    ok 48 - mp_encode(0x0100U) == "\xc5\x01\x00"
-    # binl 0xfffeU
-    ok 49 - mp_check_binl(0xfffeU) == 0
-    ok 50 - mp_decode(mp_encode(0xfffeU)) == 0xfffeU
-    ok 51 - len(mp_encode_binl(0xfffeU)
-    ok 52 - len(mp_decode_binl(0xfffeU))
-    ok 53 - mp_sizeof_binl(0xfffeU)
-    ok 54 - mp_encode(0xfffeU) == "\xc5\xff\xfe"
-    # binl 0xffffU
-    ok 55 - mp_check_binl(0xffffU) == 0
-    ok 56 - mp_decode(mp_encode(0xffffU)) == 0xffffU
-    ok 57 - len(mp_encode_binl(0xffffU)
-    ok 58 - len(mp_decode_binl(0xffffU))
-    ok 59 - mp_sizeof_binl(0xffffU)
-    ok 60 - mp_encode(0xffffU) == "\xc5\xff\xff"
-    # binl 0x00010000U
-    ok 61 - mp_check_binl(0x00010000U) == 0
-    ok 62 - mp_decode(mp_encode(0x00010000U)) == 0x00010000U
-    ok 63 - len(mp_encode_binl(0x00010000U)
-    ok 64 - len(mp_decode_binl(0x00010000U))
-    ok 65 - mp_sizeof_binl(0x00010000U)
-    ok 66 - mp_encode(0x00010000U) == "\xc6\x00\x01\x00\x00"
-    # binl 0xfffffffeU
-    ok 67 - mp_check_binl(0xfffffffeU) == 0
-    ok 68 - mp_decode(mp_encode(0xfffffffeU)) == 0xfffffffeU
-    ok 69 - len(mp_encode_binl(0xfffffffeU)
-    ok 70 - len(mp_decode_binl(0xfffffffeU))
-    ok 71 - mp_sizeof_binl(0xfffffffeU)
-    ok 72 - mp_encode(0xfffffffeU) == "\xc6\xff\xff\xff\xfe"
-    # binl 0xffffffffU
-    ok 73 - mp_check_binl(0xffffffffU) == 0
-    ok 74 - mp_decode(mp_encode(0xffffffffU)) == 0xffffffffU
-    ok 75 - len(mp_encode_binl(0xffffffffU)
-    ok 76 - len(mp_decode_binl(0xffffffffU))
-    ok 77 - mp_sizeof_binl(0xffffffffU)
-    ok 78 - mp_encode(0xffffffffU) == "\xc6\xff\xff\xff\xff"
-    # *** test_binls: done ***
-ok 8 - subtests
-    1..168
-    # *** test_extls ***
-    # extl 0x01U
-    ok 1 - mp_check_extl(0x01U) == 0
-    ok 2 - mp_decode(mp_encode(0x01U)) == 0x01U
-    ok 3 - len(mp_encode_extl(0x01U)
-    ok 4 - len(mp_decode_extl(0x01U))
-    ok 5 - mp_sizeof_extl(0x01U)
-    ok 6 - mp_encode(0x01U) == "\xd4\x00"
-    # extl 0x02U
-    ok 7 - mp_check_extl(0x02U) == 0
-    ok 8 - mp_decode(mp_encode(0x02U)) == 0x02U
-    ok 9 - len(mp_encode_extl(0x02U)
-    ok 10 - len(mp_decode_extl(0x02U))
-    ok 11 - mp_sizeof_extl(0x02U)
-    ok 12 - mp_encode(0x02U) == "\xd5\x00"
-    # extl 0x04U
-    ok 13 - mp_check_extl(0x04U) == 0
-    ok 14 - mp_decode(mp_encode(0x04U)) == 0x04U
-    ok 15 - len(mp_encode_extl(0x04U)
-    ok 16 - len(mp_decode_extl(0x04U))
-    ok 17 - mp_sizeof_extl(0x04U)
-    ok 18 - mp_encode(0x04U) == "\xd6\x00"
-    # extl 0x08U
-    ok 19 - mp_check_extl(0x08U) == 0
-    ok 20 - mp_decode(mp_encode(0x08U)) == 0x08U
-    ok 21 - len(mp_encode_extl(0x08U)
-    ok 22 - len(mp_decode_extl(0x08U))
-    ok 23 - mp_sizeof_extl(0x08U)
-    ok 24 - mp_encode(0x08U) == "\xd7\x00"
-    # extl 0x10U
-    ok 25 - mp_check_extl(0x10U) == 0
-    ok 26 - mp_decode(mp_encode(0x10U)) == 0x10U
-    ok 27 - len(mp_encode_extl(0x10U)
-    ok 28 - len(mp_decode_extl(0x10U))
-    ok 29 - mp_sizeof_extl(0x10U)
-    ok 30 - mp_encode(0x10U) == "\xd8\x00"
-    # extl 0x11U
-    ok 31 - mp_check_extl(0x11U) == 0
-    ok 32 - mp_decode(mp_encode(0x11U)) == 0x11U
-    ok 33 - len(mp_encode_extl(0x11U)
-    ok 34 - len(mp_decode_extl(0x11U))
-    ok 35 - mp_sizeof_extl(0x11U)
-    ok 36 - mp_encode(0x11U) == "\xc7\x11\x00"
-    # extl 0xfeU
-    ok 37 - mp_check_extl(0xfeU) == 0
-    ok 38 - mp_decode(mp_encode(0xfeU)) == 0xfeU
-    ok 39 - len(mp_encode_extl(0xfeU)
-    ok 40 - len(mp_decode_extl(0xfeU))
-    ok 41 - mp_sizeof_extl(0xfeU)
-    ok 42 - mp_encode(0xfeU) == "\xc7\xfe\x00"
-    # extl 0xffU
-    ok 43 - mp_check_extl(0xffU) == 0
-    ok 44 - mp_decode(mp_encode(0xffU)) == 0xffU
-    ok 45 - len(mp_encode_extl(0xffU)
-    ok 46 - len(mp_decode_extl(0xffU))
-    ok 47 - mp_sizeof_extl(0xffU)
-    ok 48 - mp_encode(0xffU) == "\xc7\xff\x00"
-    # extl 0x00U
-    ok 49 - mp_check_extl(0x00U) == 0
-    ok 50 - mp_decode(mp_encode(0x00U)) == 0x00U
-    ok 51 - len(mp_encode_extl(0x00U)
-    ok 52 - len(mp_decode_extl(0x00U))
-    ok 53 - mp_sizeof_extl(0x00U)
-    ok 54 - mp_encode(0x00U) == "\xc7\x00\x00"
-    # extl 0x03U
-    ok 55 - mp_check_extl(0x03U) == 0
-    ok 56 - mp_decode(mp_encode(0x03U)) == 0x03U
-    ok 57 - len(mp_encode_extl(0x03U)
-    ok 58 - len(mp_decode_extl(0x03U))
-    ok 59 - mp_sizeof_extl(0x03U)
-    ok 60 - mp_encode(0x03U) == "\xc7\x03\x00"
-    # extl 0x05U
-    ok 61 - mp_check_extl(0x05U) == 0
-    ok 62 - mp_decode(mp_encode(0x05U)) == 0x05U
-    ok 63 - len(mp_encode_extl(0x05U)
-    ok 64 - len(mp_decode_extl(0x05U))
-    ok 65 - mp_sizeof_extl(0x05U)
-    ok 66 - mp_encode(0x05U) == "\xc7\x05\x00"
-    # extl 0x06U
-    ok 67 - mp_check_extl(0x06U) == 0
-    ok 68 - mp_decode(mp_encode(0x06U)) == 0x06U
-    ok 69 - len(mp_encode_extl(0x06U)
-    ok 70 - len(mp_decode_extl(0x06U))
-    ok 71 - mp_sizeof_extl(0x06U)
-    ok 72 - mp_encode(0x06U) == "\xc7\x06\x00"
-    # extl 0x07U
-    ok 73 - mp_check_extl(0x07U) == 0
-    ok 74 - mp_decode(mp_encode(0x07U)) == 0x07U
-    ok 75 - len(mp_encode_extl(0x07U)
-    ok 76 - len(mp_decode_extl(0x07U))
-    ok 77 - mp_sizeof_extl(0x07U)
-    ok 78 - mp_encode(0x07U) == "\xc7\x07\x00"
-    # extl 0x09U
-    ok 79 - mp_check_extl(0x09U) == 0
-    ok 80 - mp_decode(mp_encode(0x09U)) == 0x09U
-    ok 81 - len(mp_encode_extl(0x09U)
-    ok 82 - len(mp_decode_extl(0x09U))
-    ok 83 - mp_sizeof_extl(0x09U)
-    ok 84 - mp_encode(0x09U) == "\xc7\x09\x00"
-    # extl 0x0aU
-    ok 85 - mp_check_extl(0x0aU) == 0
-    ok 86 - mp_decode(mp_encode(0x0aU)) == 0x0aU
-    ok 87 - len(mp_encode_extl(0x0aU)
-    ok 88 - len(mp_decode_extl(0x0aU))
-    ok 89 - mp_sizeof_extl(0x0aU)
-    ok 90 - mp_encode(0x0aU) == "\xc7\x0a\x00"
-    # extl 0x0bU
-    ok 91 - mp_check_extl(0x0bU) == 0
-    ok 92 - mp_decode(mp_encode(0x0bU)) == 0x0bU
-    ok 93 - len(mp_encode_extl(0x0bU)
-    ok 94 - len(mp_decode_extl(0x0bU))
-    ok 95 - mp_sizeof_extl(0x0bU)
-    ok 96 - mp_encode(0x0bU) == "\xc7\x0b\x00"
-    # extl 0x0cU
-    ok 97 - mp_check_extl(0x0cU) == 0
-    ok 98 - mp_decode(mp_encode(0x0cU)) == 0x0cU
-    ok 99 - len(mp_encode_extl(0x0cU)
-    ok 100 - len(mp_decode_extl(0x0cU))
-    ok 101 - mp_sizeof_extl(0x0cU)
-    ok 102 - mp_encode(0x0cU) == "\xc7\x0c\x00"
-    # extl 0x0dU
-    ok 103 - mp_check_extl(0x0dU) == 0
-    ok 104 - mp_decode(mp_encode(0x0dU)) == 0x0dU
-    ok 105 - len(mp_encode_extl(0x0dU)
-    ok 106 - len(mp_decode_extl(0x0dU))
-    ok 107 - mp_sizeof_extl(0x0dU)
-    ok 108 - mp_encode(0x0dU) == "\xc7\x0d\x00"
-    # extl 0x0eU
-    ok 109 - mp_check_extl(0x0eU) == 0
-    ok 110 - mp_decode(mp_encode(0x0eU)) == 0x0eU
-    ok 111 - len(mp_encode_extl(0x0eU)
-    ok 112 - len(mp_decode_extl(0x0eU))
-    ok 113 - mp_sizeof_extl(0x0eU)
-    ok 114 - mp_encode(0x0eU) == "\xc7\x0e\x00"
-    # extl 0x0fU
-    ok 115 - mp_check_extl(0x0fU) == 0
-    ok 116 - mp_decode(mp_encode(0x0fU)) == 0x0fU
-    ok 117 - len(mp_encode_extl(0x0fU)
-    ok 118 - len(mp_decode_extl(0x0fU))
-    ok 119 - mp_sizeof_extl(0x0fU)
-    ok 120 - mp_encode(0x0fU) == "\xc7\x0f\x00"
-    # extl 0x0100U
-    ok 121 - mp_check_extl(0x0100U) == 0
-    ok 122 - mp_decode(mp_encode(0x0100U)) == 0x0100U
-    ok 123 - len(mp_encode_extl(0x0100U)
-    ok 124 - len(mp_decode_extl(0x0100U))
-    ok 125 - mp_sizeof_extl(0x0100U)
-    ok 126 - mp_encode(0x0100U) == "\xc8\x01\x00\x00"
-    # extl 0x0101U
-    ok 127 - mp_check_extl(0x0101U) == 0
-    ok 128 - mp_decode(mp_encode(0x0101U)) == 0x0101U
-    ok 129 - len(mp_encode_extl(0x0101U)
-    ok 130 - len(mp_decode_extl(0x0101U))
-    ok 131 - mp_sizeof_extl(0x0101U)
-    ok 132 - mp_encode(0x0101U) == "\xc8\x01\x01\x00"
-    # extl 0xfffeU
-    ok 133 - mp_check_extl(0xfffeU) == 0
-    ok 134 - mp_decode(mp_encode(0xfffeU)) == 0xfffeU
-    ok 135 - len(mp_encode_extl(0xfffeU)
-    ok 136 - len(mp_decode_extl(0xfffeU))
-    ok 137 - mp_sizeof_extl(0xfffeU)
-    ok 138 - mp_encode(0xfffeU) == "\xc8\xff\xfe\x00"
-    # extl 0xffffU
-    ok 139 - mp_check_extl(0xffffU) == 0
-    ok 140 - mp_decode(mp_encode(0xffffU)) == 0xffffU
-    ok 141 - len(mp_encode_extl(0xffffU)
-    ok 142 - len(mp_decode_extl(0xffffU))
-    ok 143 - mp_sizeof_extl(0xffffU)
-    ok 144 - mp_encode(0xffffU) == "\xc8\xff\xff\x00"
-    # extl 0x00010000U
-    ok 145 - mp_check_extl(0x00010000U) == 0
-    ok 146 - mp_decode(mp_encode(0x00010000U)) == 0x00010000U
-    ok 147 - len(mp_encode_extl(0x00010000U)
-    ok 148 - len(mp_decode_extl(0x00010000U))
-    ok 149 - mp_sizeof_extl(0x00010000U)
-    ok 150 - mp_encode(0x00010000U) == "\xc9\x00\x01\x00\x00\x00"
-    # extl 0x00010001U
-    ok 151 - mp_check_extl(0x00010001U) == 0
-    ok 152 - mp_decode(mp_encode(0x00010001U)) == 0x00010001U
-    ok 153 - len(mp_encode_extl(0x00010001U)
-    ok 154 - len(mp_decode_extl(0x00010001U))
-    ok 155 - mp_sizeof_extl(0x00010001U)
-    ok 156 - mp_encode(0x00010001U) == "\xc9\x00\x01\x00\x01\x00"
-    # extl 0xfffffffeU
-    ok 157 - mp_check_extl(0xfffffffeU) == 0
-    ok 158 - mp_decode(mp_encode(0xfffffffeU)) == 0xfffffffeU
-    ok 159 - len(mp_encode_extl(0xfffffffeU)
-    ok 160 - len(mp_decode_extl(0xfffffffeU))
-    ok 161 - mp_sizeof_extl(0xfffffffeU)
-    ok 162 - mp_encode(0xfffffffeU) == "\xc9\xff\xff\xff\xfe\x00"
-    # extl 0xffffffffU
-    ok 163 - mp_check_extl(0xffffffffU) == 0
-    ok 164 - mp_decode(mp_encode(0xffffffffU)) == 0xffffffffU
-    ok 165 - len(mp_encode_extl(0xffffffffU)
-    ok 166 - len(mp_decode_extl(0xffffffffU))
-    ok 167 - mp_sizeof_extl(0xffffffffU)
-    ok 168 - mp_encode(0xffffffffU) == "\xc9\xff\xff\xff\xff\x00"
-    # *** test_extls: done ***
-ok 9 - subtests
-    1..96
-    # *** test_strs ***
-    # str len=0x01
-    ok 1 - len(mp_decode_str(x, 1))
-    ok 2 - len(mp_decode_strbin(x, 1))
-    ok 3 - mp_check_str(mp_encode_str(x, 0x01))
-    ok 4 - len(mp_decode_str(x, 0x01)
-    ok 5 - len(mp_next_str(x, 0x01)
-    ok 6 - len(mp_check_str(x, 0x01)
-    ok 7 - mp_sizeof_str(0x01)
-    ok 8 - mp_encode_str(x, 0x01) == x
-    # str len=0x1e
-    ok 9 - len(mp_decode_str(x, 30))
-    ok 10 - len(mp_decode_strbin(x, 30))
-    ok 11 - mp_check_str(mp_encode_str(x, 0x1e))
-    ok 12 - len(mp_decode_str(x, 0x1e)
-    ok 13 - len(mp_next_str(x, 0x1e)
-    ok 14 - len(mp_check_str(x, 0x1e)
-    ok 15 - mp_sizeof_str(0x1e)
-    ok 16 - mp_encode_str(x, 0x1e) == x
-    # str len=0x1f
-    ok 17 - len(mp_decode_str(x, 31))
-    ok 18 - len(mp_decode_strbin(x, 31))
-    ok 19 - mp_check_str(mp_encode_str(x, 0x1f))
-    ok 20 - len(mp_decode_str(x, 0x1f)
-    ok 21 - len(mp_next_str(x, 0x1f)
-    ok 22 - len(mp_check_str(x, 0x1f)
-    ok 23 - mp_sizeof_str(0x1f)
-    ok 24 - mp_encode_str(x, 0x1f) == x
-    # str len=0x20
-    ok 25 - len(mp_decode_str(x, 32))
-    ok 26 - len(mp_decode_strbin(x, 32))
-    ok 27 - mp_check_str(mp_encode_str(x, 0x20))
-    ok 28 - len(mp_decode_str(x, 0x20)
-    ok 29 - len(mp_next_str(x, 0x20)
-    ok 30 - len(mp_check_str(x, 0x20)
-    ok 31 - mp_sizeof_str(0x20)
-    ok 32 - mp_encode_str(x, 0x20) == x
-    # str len=0xfe
-    ok 33 - len(mp_decode_str(x, 254))
-    ok 34 - len(mp_decode_strbin(x, 254))
-    ok 35 - mp_check_str(mp_encode_str(x, 0xfe))
-    ok 36 - len(mp_decode_str(x, 0xfe)
-    ok 37 - len(mp_next_str(x, 0xfe)
-    ok 38 - len(mp_check_str(x, 0xfe)
-    ok 39 - mp_sizeof_str(0xfe)
-    ok 40 - mp_encode_str(x, 0xfe) == x
-    # str len=0xff
-    ok 41 - len(mp_decode_str(x, 255))
-    ok 42 - len(mp_decode_strbin(x, 255))
-    ok 43 - mp_check_str(mp_encode_str(x, 0xff))
-    ok 44 - len(mp_decode_str(x, 0xff)
-    ok 45 - len(mp_next_str(x, 0xff)
-    ok 46 - len(mp_check_str(x, 0xff)
-    ok 47 - mp_sizeof_str(0xff)
-    ok 48 - mp_encode_str(x, 0xff) == x
-    # str len=0x100
-    ok 49 - len(mp_decode_str(x, 256))
-    ok 50 - len(mp_decode_strbin(x, 256))
-    ok 51 - mp_check_str(mp_encode_str(x, 0x100))
-    ok 52 - len(mp_decode_str(x, 0x100)
-    ok 53 - len(mp_next_str(x, 0x100)
-    ok 54 - len(mp_check_str(x, 0x100)
-    ok 55 - mp_sizeof_str(0x100)
-    ok 56 - mp_encode_str(x, 0x100) == x
-    # str len=0x101
-    ok 57 - len(mp_decode_str(x, 257))
-    ok 58 - len(mp_decode_strbin(x, 257))
-    ok 59 - mp_check_str(mp_encode_str(x, 0x101))
-    ok 60 - len(mp_decode_str(x, 0x101)
-    ok 61 - len(mp_next_str(x, 0x101)
-    ok 62 - len(mp_check_str(x, 0x101)
-    ok 63 - mp_sizeof_str(0x101)
-    ok 64 - mp_encode_str(x, 0x101) == x
-    # str len=0xfffe
-    ok 65 - len(mp_decode_str(x, 65534))
-    ok 66 - len(mp_decode_strbin(x, 65534))
-    ok 67 - mp_check_str(mp_encode_str(x, 0xfffe))
-    ok 68 - len(mp_decode_str(x, 0xfffe)
-    ok 69 - len(mp_next_str(x, 0xfffe)
-    ok 70 - len(mp_check_str(x, 0xfffe)
-    ok 71 - mp_sizeof_str(0xfffe)
-    ok 72 - mp_encode_str(x, 0xfffe) == x
-    # str len=0xffff
-    ok 73 - len(mp_decode_str(x, 65535))
-    ok 74 - len(mp_decode_strbin(x, 65535))
-    ok 75 - mp_check_str(mp_encode_str(x, 0xffff))
-    ok 76 - len(mp_decode_str(x, 0xffff)
-    ok 77 - len(mp_next_str(x, 0xffff)
-    ok 78 - len(mp_check_str(x, 0xffff)
-    ok 79 - mp_sizeof_str(0xffff)
-    ok 80 - mp_encode_str(x, 0xffff) == x
-    # str len=0x10000
-    ok 81 - len(mp_decode_str(x, 65536))
-    ok 82 - len(mp_decode_strbin(x, 65536))
-    ok 83 - mp_check_str(mp_encode_str(x, 0x10000))
-    ok 84 - len(mp_decode_str(x, 0x10000)
-    ok 85 - len(mp_next_str(x, 0x10000)
-    ok 86 - len(mp_check_str(x, 0x10000)
-    ok 87 - mp_sizeof_str(0x10000)
-    ok 88 - mp_encode_str(x, 0x10000) == x
-    # str len=0x10001
-    ok 89 - len(mp_decode_str(x, 65537))
-    ok 90 - len(mp_decode_strbin(x, 65537))
-    ok 91 - mp_check_str(mp_encode_str(x, 0x10001))
-    ok 92 - len(mp_decode_str(x, 0x10001)
-    ok 93 - len(mp_next_str(x, 0x10001)
-    ok 94 - len(mp_check_str(x, 0x10001)
-    ok 95 - mp_sizeof_str(0x10001)
-    ok 96 - mp_encode_str(x, 0x10001) == x
-    # *** test_strs: done ***
-ok 10 - subtests
-    1..96
-    # *** test_bins ***
-    # bin len=0x01
-    ok 1 - len(mp_decode_bin(x, 1))
-    ok 2 - len(mp_decode_strbin(x, 1))
-    ok 3 - mp_check_bin(mp_encode_bin(x, 0x01))
-    ok 4 - len(mp_decode_bin(x, 0x01)
-    ok 5 - len(mp_next_bin(x, 0x01)
-    ok 6 - len(mp_check_bin(x, 0x01)
-    ok 7 - mp_sizeof_bin(0x01)
-    ok 8 - mp_encode_bin(x, 0x01) == x
-    # bin len=0x1e
-    ok 9 - len(mp_decode_bin(x, 30))
-    ok 10 - len(mp_decode_strbin(x, 30))
-    ok 11 - mp_check_bin(mp_encode_bin(x, 0x1e))
-    ok 12 - len(mp_decode_bin(x, 0x1e)
-    ok 13 - len(mp_next_bin(x, 0x1e)
-    ok 14 - len(mp_check_bin(x, 0x1e)
-    ok 15 - mp_sizeof_bin(0x1e)
-    ok 16 - mp_encode_bin(x, 0x1e) == x
-    # bin len=0x1f
-    ok 17 - len(mp_decode_bin(x, 31))
-    ok 18 - len(mp_decode_strbin(x, 31))
-    ok 19 - mp_check_bin(mp_encode_bin(x, 0x1f))
-    ok 20 - len(mp_decode_bin(x, 0x1f)
-    ok 21 - len(mp_next_bin(x, 0x1f)
-    ok 22 - len(mp_check_bin(x, 0x1f)
-    ok 23 - mp_sizeof_bin(0x1f)
-    ok 24 - mp_encode_bin(x, 0x1f) == x
-    # bin len=0x20
-    ok 25 - len(mp_decode_bin(x, 32))
-    ok 26 - len(mp_decode_strbin(x, 32))
-    ok 27 - mp_check_bin(mp_encode_bin(x, 0x20))
-    ok 28 - len(mp_decode_bin(x, 0x20)
-    ok 29 - len(mp_next_bin(x, 0x20)
-    ok 30 - len(mp_check_bin(x, 0x20)
-    ok 31 - mp_sizeof_bin(0x20)
-    ok 32 - mp_encode_bin(x, 0x20) == x
-    # bin len=0xfe
-    ok 33 - len(mp_decode_bin(x, 254))
-    ok 34 - len(mp_decode_strbin(x, 254))
-    ok 35 - mp_check_bin(mp_encode_bin(x, 0xfe))
-    ok 36 - len(mp_decode_bin(x, 0xfe)
-    ok 37 - len(mp_next_bin(x, 0xfe)
-    ok 38 - len(mp_check_bin(x, 0xfe)
-    ok 39 - mp_sizeof_bin(0xfe)
-    ok 40 - mp_encode_bin(x, 0xfe) == x
-    # bin len=0xff
-    ok 41 - len(mp_decode_bin(x, 255))
-    ok 42 - len(mp_decode_strbin(x, 255))
-    ok 43 - mp_check_bin(mp_encode_bin(x, 0xff))
-    ok 44 - len(mp_decode_bin(x, 0xff)
-    ok 45 - len(mp_next_bin(x, 0xff)
-    ok 46 - len(mp_check_bin(x, 0xff)
-    ok 47 - mp_sizeof_bin(0xff)
-    ok 48 - mp_encode_bin(x, 0xff) == x
-    # bin len=0x100
-    ok 49 - len(mp_decode_bin(x, 256))
-    ok 50 - len(mp_decode_strbin(x, 256))
-    ok 51 - mp_check_bin(mp_encode_bin(x, 0x100))
-    ok 52 - len(mp_decode_bin(x, 0x100)
-    ok 53 - len(mp_next_bin(x, 0x100)
-    ok 54 - len(mp_check_bin(x, 0x100)
-    ok 55 - mp_sizeof_bin(0x100)
-    ok 56 - mp_encode_bin(x, 0x100) == x
-    # bin len=0x101
-    ok 57 - len(mp_decode_bin(x, 257))
-    ok 58 - len(mp_decode_strbin(x, 257))
-    ok 59 - mp_check_bin(mp_encode_bin(x, 0x101))
-    ok 60 - len(mp_decode_bin(x, 0x101)
-    ok 61 - len(mp_next_bin(x, 0x101)
-    ok 62 - len(mp_check_bin(x, 0x101)
-    ok 63 - mp_sizeof_bin(0x101)
-    ok 64 - mp_encode_bin(x, 0x101) == x
-    # bin len=0xfffe
-    ok 65 - len(mp_decode_bin(x, 65534))
-    ok 66 - len(mp_decode_strbin(x, 65534))
-    ok 67 - mp_check_bin(mp_encode_bin(x, 0xfffe))
-    ok 68 - len(mp_decode_bin(x, 0xfffe)
-    ok 69 - len(mp_next_bin(x, 0xfffe)
-    ok 70 - len(mp_check_bin(x, 0xfffe)
-    ok 71 - mp_sizeof_bin(0xfffe)
-    ok 72 - mp_encode_bin(x, 0xfffe) == x
-    # bin len=0xffff
-    ok 73 - len(mp_decode_bin(x, 65535))
-    ok 74 - len(mp_decode_strbin(x, 65535))
-    ok 75 - mp_check_bin(mp_encode_bin(x, 0xffff))
-    ok 76 - len(mp_decode_bin(x, 0xffff)
-    ok 77 - len(mp_next_bin(x, 0xffff)
-    ok 78 - len(mp_check_bin(x, 0xffff)
-    ok 79 - mp_sizeof_bin(0xffff)
-    ok 80 - mp_encode_bin(x, 0xffff) == x
-    # bin len=0x10000
-    ok 81 - len(mp_decode_bin(x, 65536))
-    ok 82 - len(mp_decode_strbin(x, 65536))
-    ok 83 - mp_check_bin(mp_encode_bin(x, 0x10000))
-    ok 84 - len(mp_decode_bin(x, 0x10000)
-    ok 85 - len(mp_next_bin(x, 0x10000)
-    ok 86 - len(mp_check_bin(x, 0x10000)
-    ok 87 - mp_sizeof_bin(0x10000)
-    ok 88 - mp_encode_bin(x, 0x10000) == x
-    # bin len=0x10001
-    ok 89 - len(mp_decode_bin(x, 65537))
-    ok 90 - len(mp_decode_strbin(x, 65537))
-    ok 91 - mp_check_bin(mp_encode_bin(x, 0x10001))
-    ok 92 - len(mp_decode_bin(x, 0x10001)
-    ok 93 - len(mp_next_bin(x, 0x10001)
-    ok 94 - len(mp_check_bin(x, 0x10001)
-    ok 95 - mp_sizeof_bin(0x10001)
-    ok 96 - mp_encode_bin(x, 0x10001) == x
-    # *** test_bins: done ***
-ok 11 - subtests
-    1..225
-    # *** test_exts ***
-    # ext len=0x01
-    ok 1 - len(mp_decode_ext(x, 1))
-    ok 2 - type(mp_decode_ext(x))
-    ok 3 - len(mp_decode_strbin(x, 1))
-    ok 4 - mp_check_ext(mp_encode_ext(x, 0x01))
-    ok 5 - len(mp_decode_ext(x, 0x01)
-    ok 6 - len(mp_next_ext(x, 0x01)
-    ok 7 - len(mp_check_ext(x, 0x01)
-    ok 8 - mp_sizeof_ext(0x01)
-    ok 9 - mp_encode_ext(x, 0x01) == x
-    # ext len=0x02
-    ok 10 - len(mp_decode_ext(x, 2))
-    ok 11 - type(mp_decode_ext(x))
-    ok 12 - len(mp_decode_strbin(x, 2))
-    ok 13 - mp_check_ext(mp_encode_ext(x, 0x02))
-    ok 14 - len(mp_decode_ext(x, 0x02)
-    ok 15 - len(mp_next_ext(x, 0x02)
-    ok 16 - len(mp_check_ext(x, 0x02)
-    ok 17 - mp_sizeof_ext(0x02)
-    ok 18 - mp_encode_ext(x, 0x02) == x
-    # ext len=0x03
-    ok 19 - len(mp_decode_ext(x, 3))
-    ok 20 - type(mp_decode_ext(x))
-    ok 21 - len(mp_decode_strbin(x, 3))
-    ok 22 - mp_check_ext(mp_encode_ext(x, 0x03))
-    ok 23 - len(mp_decode_ext(x, 0x03)
-    ok 24 - len(mp_next_ext(x, 0x03)
-    ok 25 - len(mp_check_ext(x, 0x03)
-    ok 26 - mp_sizeof_ext(0x03)
-    ok 27 - mp_encode_ext(x, 0x03) == x
-    # ext len=0x04
-    ok 28 - len(mp_decode_ext(x, 4))
-    ok 29 - type(mp_decode_ext(x))
-    ok 30 - len(mp_decode_strbin(x, 4))
-    ok 31 - mp_check_ext(mp_encode_ext(x, 0x04))
-    ok 32 - len(mp_decode_ext(x, 0x04)
-    ok 33 - len(mp_next_ext(x, 0x04)
-    ok 34 - len(mp_check_ext(x, 0x04)
-    ok 35 - mp_sizeof_ext(0x04)
-    ok 36 - mp_encode_ext(x, 0x04) == x
-    # ext len=0x05
-    ok 37 - len(mp_decode_ext(x, 5))
-    ok 38 - type(mp_decode_ext(x))
-    ok 39 - len(mp_decode_strbin(x, 5))
-    ok 40 - mp_check_ext(mp_encode_ext(x, 0x05))
-    ok 41 - len(mp_decode_ext(x, 0x05)
-    ok 42 - len(mp_next_ext(x, 0x05)
-    ok 43 - len(mp_check_ext(x, 0x05)
-    ok 44 - mp_sizeof_ext(0x05)
-    ok 45 - mp_encode_ext(x, 0x05) == x
-    # ext len=0x06
-    ok 46 - len(mp_decode_ext(x, 6))
-    ok 47 - type(mp_decode_ext(x))
-    ok 48 - len(mp_decode_strbin(x, 6))
-    ok 49 - mp_check_ext(mp_encode_ext(x, 0x06))
-    ok 50 - len(mp_decode_ext(x, 0x06)
-    ok 51 - len(mp_next_ext(x, 0x06)
-    ok 52 - len(mp_check_ext(x, 0x06)
-    ok 53 - mp_sizeof_ext(0x06)
-    ok 54 - mp_encode_ext(x, 0x06) == x
-    # ext len=0x07
-    ok 55 - len(mp_decode_ext(x, 7))
-    ok 56 - type(mp_decode_ext(x))
-    ok 57 - len(mp_decode_strbin(x, 7))
-    ok 58 - mp_check_ext(mp_encode_ext(x, 0x07))
-    ok 59 - len(mp_decode_ext(x, 0x07)
-    ok 60 - len(mp_next_ext(x, 0x07)
-    ok 61 - len(mp_check_ext(x, 0x07)
-    ok 62 - mp_sizeof_ext(0x07)
-    ok 63 - mp_encode_ext(x, 0x07) == x
-    # ext len=0x08
-    ok 64 - len(mp_decode_ext(x, 8))
-    ok 65 - type(mp_decode_ext(x))
-    ok 66 - len(mp_decode_strbin(x, 8))
-    ok 67 - mp_check_ext(mp_encode_ext(x, 0x08))
-    ok 68 - len(mp_decode_ext(x, 0x08)
-    ok 69 - len(mp_next_ext(x, 0x08)
-    ok 70 - len(mp_check_ext(x, 0x08)
-    ok 71 - mp_sizeof_ext(0x08)
-    ok 72 - mp_encode_ext(x, 0x08) == x
-    # ext len=0x09
-    ok 73 - len(mp_decode_ext(x, 9))
-    ok 74 - type(mp_decode_ext(x))
-    ok 75 - len(mp_decode_strbin(x, 9))
-    ok 76 - mp_check_ext(mp_encode_ext(x, 0x09))
-    ok 77 - len(mp_decode_ext(x, 0x09)
-    ok 78 - len(mp_next_ext(x, 0x09)
-    ok 79 - len(mp_check_ext(x, 0x09)
-    ok 80 - mp_sizeof_ext(0x09)
-    ok 81 - mp_encode_ext(x, 0x09) == x
-    # ext len=0x0a
-    ok 82 - len(mp_decode_ext(x, 10))
-    ok 83 - type(mp_decode_ext(x))
-    ok 84 - len(mp_decode_strbin(x, 10))
-    ok 85 - mp_check_ext(mp_encode_ext(x, 0x0a))
-    ok 86 - len(mp_decode_ext(x, 0x0a)
-    ok 87 - len(mp_next_ext(x, 0x0a)
-    ok 88 - len(mp_check_ext(x, 0x0a)
-    ok 89 - mp_sizeof_ext(0x0a)
-    ok 90 - mp_encode_ext(x, 0x0a) == x
-    # ext len=0x0b
-    ok 91 - len(mp_decode_ext(x, 11))
-    ok 92 - type(mp_decode_ext(x))
-    ok 93 - len(mp_decode_strbin(x, 11))
-    ok 94 - mp_check_ext(mp_encode_ext(x, 0x0b))
-    ok 95 - len(mp_decode_ext(x, 0x0b)
-    ok 96 - len(mp_next_ext(x, 0x0b)
-    ok 97 - len(mp_check_ext(x, 0x0b)
-    ok 98 - mp_sizeof_ext(0x0b)
-    ok 99 - mp_encode_ext(x, 0x0b) == x
-    # ext len=0x0c
-    ok 100 - len(mp_decode_ext(x, 12))
-    ok 101 - type(mp_decode_ext(x))
-    ok 102 - len(mp_decode_strbin(x, 12))
-    ok 103 - mp_check_ext(mp_encode_ext(x, 0x0c))
-    ok 104 - len(mp_decode_ext(x, 0x0c)
-    ok 105 - len(mp_next_ext(x, 0x0c)
-    ok 106 - len(mp_check_ext(x, 0x0c)
-    ok 107 - mp_sizeof_ext(0x0c)
-    ok 108 - mp_encode_ext(x, 0x0c) == x
-    # ext len=0x0d
-    ok 109 - len(mp_decode_ext(x, 13))
-    ok 110 - type(mp_decode_ext(x))
-    ok 111 - len(mp_decode_strbin(x, 13))
-    ok 112 - mp_check_ext(mp_encode_ext(x, 0x0d))
-    ok 113 - len(mp_decode_ext(x, 0x0d)
-    ok 114 - len(mp_next_ext(x, 0x0d)
-    ok 115 - len(mp_check_ext(x, 0x0d)
-    ok 116 - mp_sizeof_ext(0x0d)
-    ok 117 - mp_encode_ext(x, 0x0d) == x
-    # ext len=0x0e
-    ok 118 - len(mp_decode_ext(x, 14))
-    ok 119 - type(mp_decode_ext(x))
-    ok 120 - len(mp_decode_strbin(x, 14))
-    ok 121 - mp_check_ext(mp_encode_ext(x, 0x0e))
-    ok 122 - len(mp_decode_ext(x, 0x0e)
-    ok 123 - len(mp_next_ext(x, 0x0e)
-    ok 124 - len(mp_check_ext(x, 0x0e)
-    ok 125 - mp_sizeof_ext(0x0e)
-    ok 126 - mp_encode_ext(x, 0x0e) == x
-    # ext len=0x0f
-    ok 127 - len(mp_decode_ext(x, 15))
-    ok 128 - type(mp_decode_ext(x))
-    ok 129 - len(mp_decode_strbin(x, 15))
-    ok 130 - mp_check_ext(mp_encode_ext(x, 0x0f))
-    ok 131 - len(mp_decode_ext(x, 0x0f)
-    ok 132 - len(mp_next_ext(x, 0x0f)
-    ok 133 - len(mp_check_ext(x, 0x0f)
-    ok 134 - mp_sizeof_ext(0x0f)
-    ok 135 - mp_encode_ext(x, 0x0f) == x
-    # ext len=0x10
-    ok 136 - len(mp_decode_ext(x, 16))
-    ok 137 - type(mp_decode_ext(x))
-    ok 138 - len(mp_decode_strbin(x, 16))
-    ok 139 - mp_check_ext(mp_encode_ext(x, 0x10))
-    ok 140 - len(mp_decode_ext(x, 0x10)
-    ok 141 - len(mp_next_ext(x, 0x10)
-    ok 142 - len(mp_check_ext(x, 0x10)
-    ok 143 - mp_sizeof_ext(0x10)
-    ok 144 - mp_encode_ext(x, 0x10) == x
-    # ext len=0x11
-    ok 145 - len(mp_decode_ext(x, 17))
-    ok 146 - type(mp_decode_ext(x))
-    ok 147 - len(mp_decode_strbin(x, 17))
-    ok 148 - mp_check_ext(mp_encode_ext(x, 0x11))
-    ok 149 - len(mp_decode_ext(x, 0x11)
-    ok 150 - len(mp_next_ext(x, 0x11)
-    ok 151 - len(mp_check_ext(x, 0x11)
-    ok 152 - mp_sizeof_ext(0x11)
-    ok 153 - mp_encode_ext(x, 0x11) == x
-    # ext len=0xfe
-    ok 154 - len(mp_decode_ext(x, 254))
-    ok 155 - type(mp_decode_ext(x))
-    ok 156 - len(mp_decode_strbin(x, 254))
-    ok 157 - mp_check_ext(mp_encode_ext(x, 0xfe))
-    ok 158 - len(mp_decode_ext(x, 0xfe)
-    ok 159 - len(mp_next_ext(x, 0xfe)
-    ok 160 - len(mp_check_ext(x, 0xfe)
-    ok 161 - mp_sizeof_ext(0xfe)
-    ok 162 - mp_encode_ext(x, 0xfe) == x
-    # ext len=0xff
-    ok 163 - len(mp_decode_ext(x, 255))
-    ok 164 - type(mp_decode_ext(x))
-    ok 165 - len(mp_decode_strbin(x, 255))
-    ok 166 - mp_check_ext(mp_encode_ext(x, 0xff))
-    ok 167 - len(mp_decode_ext(x, 0xff)
-    ok 168 - len(mp_next_ext(x, 0xff)
-    ok 169 - len(mp_check_ext(x, 0xff)
-    ok 170 - mp_sizeof_ext(0xff)
-    ok 171 - mp_encode_ext(x, 0xff) == x
-    # ext len=0x0100
-    ok 172 - len(mp_decode_ext(x, 256))
-    ok 173 - type(mp_decode_ext(x))
-    ok 174 - len(mp_decode_strbin(x, 256))
-    ok 175 - mp_check_ext(mp_encode_ext(x, 0x0100))
-    ok 176 - len(mp_decode_ext(x, 0x0100)
-    ok 177 - len(mp_next_ext(x, 0x0100)
-    ok 178 - len(mp_check_ext(x, 0x0100)
-    ok 179 - mp_sizeof_ext(0x0100)
-    ok 180 - mp_encode_ext(x, 0x0100) == x
-    # ext len=0x0101
-    ok 181 - len(mp_decode_ext(x, 257))
-    ok 182 - type(mp_decode_ext(x))
-    ok 183 - len(mp_decode_strbin(x, 257))
-    ok 184 - mp_check_ext(mp_encode_ext(x, 0x0101))
-    ok 185 - len(mp_decode_ext(x, 0x0101)
-    ok 186 - len(mp_next_ext(x, 0x0101)
-    ok 187 - len(mp_check_ext(x, 0x0101)
-    ok 188 - mp_sizeof_ext(0x0101)
-    ok 189 - mp_encode_ext(x, 0x0101) == x
-    # ext len=0xfffe
-    ok 190 - len(mp_decode_ext(x, 65534))
-    ok 191 - type(mp_decode_ext(x))
-    ok 192 - len(mp_decode_strbin(x, 65534))
-    ok 193 - mp_check_ext(mp_encode_ext(x, 0xfffe))
-    ok 194 - len(mp_decode_ext(x, 0xfffe)
-    ok 195 - len(mp_next_ext(x, 0xfffe)
-    ok 196 - len(mp_check_ext(x, 0xfffe)
-    ok 197 - mp_sizeof_ext(0xfffe)
-    ok 198 - mp_encode_ext(x, 0xfffe) == x
-    # ext len=0xffff
-    ok 199 - len(mp_decode_ext(x, 65535))
-    ok 200 - type(mp_decode_ext(x))
-    ok 201 - len(mp_decode_strbin(x, 65535))
-    ok 202 - mp_check_ext(mp_encode_ext(x, 0xffff))
-    ok 203 - len(mp_decode_ext(x, 0xffff)
-    ok 204 - len(mp_next_ext(x, 0xffff)
-    ok 205 - len(mp_check_ext(x, 0xffff)
-    ok 206 - mp_sizeof_ext(0xffff)
-    ok 207 - mp_encode_ext(x, 0xffff) == x
-    # ext len=0x00010000
-    ok 208 - len(mp_decode_ext(x, 65536))
-    ok 209 - type(mp_decode_ext(x))
-    ok 210 - len(mp_decode_strbin(x, 65536))
-    ok 211 - mp_check_ext(mp_encode_ext(x, 0x00010000))
-    ok 212 - len(mp_decode_ext(x, 0x00010000)
-    ok 213 - len(mp_next_ext(x, 0x00010000)
-    ok 214 - len(mp_check_ext(x, 0x00010000)
-    ok 215 - mp_sizeof_ext(0x00010000)
-    ok 216 - mp_encode_ext(x, 0x00010000) == x
-    # ext len=0x00010001
-    ok 217 - len(mp_decode_ext(x, 65537))
-    ok 218 - type(mp_decode_ext(x))
-    ok 219 - len(mp_decode_strbin(x, 65537))
-    ok 220 - mp_check_ext(mp_encode_ext(x, 0x00010001))
-    ok 221 - len(mp_decode_ext(x, 0x00010001)
-    ok 222 - len(mp_next_ext(x, 0x00010001)
-    ok 223 - len(mp_check_ext(x, 0x00010001)
-    ok 224 - mp_sizeof_ext(0x00010001)
-    ok 225 - mp_encode_ext(x, 0x00010001) == x
-    # *** test_exts: done ***
-ok 12 - subtests
-    1..54
-    # *** test_arrays ***
-    # array 0
-    ok 1 - mp_check_array(0) == 0
-    ok 2 - mp_decode(mp_encode(0)) == 0
-    ok 3 - len(mp_encode_array(0)
-    ok 4 - len(mp_decode_array(0))
-    ok 5 - mp_sizeof_array(0)
-    ok 6 - mp_encode(0) == "\x90"
-    # array 1
-    ok 7 - mp_check_array(1) == 0
-    ok 8 - mp_decode(mp_encode(1)) == 1
-    ok 9 - len(mp_encode_array(1)
-    ok 10 - len(mp_decode_array(1))
-    ok 11 - mp_sizeof_array(1)
-    ok 12 - mp_encode(1) == "\x91"
-    # array 15
-    ok 13 - mp_check_array(15) == 0
-    ok 14 - mp_decode(mp_encode(15)) == 15
-    ok 15 - len(mp_encode_array(15)
-    ok 16 - len(mp_decode_array(15))
-    ok 17 - mp_sizeof_array(15)
-    ok 18 - mp_encode(15) == "\x9f"
-    # array 16
-    ok 19 - mp_check_array(16) == 0
-    ok 20 - mp_decode(mp_encode(16)) == 16
-    ok 21 - len(mp_encode_array(16)
-    ok 22 - len(mp_decode_array(16))
-    ok 23 - mp_sizeof_array(16)
-    ok 24 - mp_encode(16) == "\xdc\x00\x10"
-    # array 0xfffe
-    ok 25 - mp_check_array(0xfffe) == 0
-    ok 26 - mp_decode(mp_encode(0xfffe)) == 0xfffe
-    ok 27 - len(mp_encode_array(0xfffe)
-    ok 28 - len(mp_decode_array(0xfffe))
-    ok 29 - mp_sizeof_array(0xfffe)
-    ok 30 - mp_encode(0xfffe) == "\xdc\xff\xfe"
-    # array 0xffff
-    ok 31 - mp_check_array(0xffff) == 0
-    ok 32 - mp_decode(mp_encode(0xffff)) == 0xffff
-    ok 33 - len(mp_encode_array(0xffff)
-    ok 34 - len(mp_decode_array(0xffff))
-    ok 35 - mp_sizeof_array(0xffff)
-    ok 36 - mp_encode(0xffff) == "\xdc\xff\xff"
-    # array 0x10000
-    ok 37 - mp_check_array(0x10000) == 0
-    ok 38 - mp_decode(mp_encode(0x10000)) == 0x10000
-    ok 39 - len(mp_encode_array(0x10000)
-    ok 40 - len(mp_decode_array(0x10000))
-    ok 41 - mp_sizeof_array(0x10000)
-    ok 42 - mp_encode(0x10000) == "\xdd\x00\x01\x00\x00"
-    # array 0xfffffffeU
-    ok 43 - mp_check_array(0xfffffffeU) == 0
-    ok 44 - mp_decode(mp_encode(0xfffffffeU)) == 0xfffffffeU
-    ok 45 - len(mp_encode_array(0xfffffffeU)
-    ok 46 - len(mp_decode_array(0xfffffffeU))
-    ok 47 - mp_sizeof_array(0xfffffffeU)
-    ok 48 - mp_encode(0xfffffffeU) == "\xdd\xff\xff\xff\xfe"
-    # array 0xffffffffU
-    ok 49 - mp_check_array(0xffffffffU) == 0
-    ok 50 - mp_decode(mp_encode(0xffffffffU)) == 0xffffffffU
-    ok 51 - len(mp_encode_array(0xffffffffU)
-    ok 52 - len(mp_decode_array(0xffffffffU))
-    ok 53 - mp_sizeof_array(0xffffffffU)
-    ok 54 - mp_encode(0xffffffffU) == "\xdd\xff\xff\xff\xff"
-    # *** test_arrays: done ***
-ok 13 - subtests
-    1..54
-    # *** test_maps ***
-    # map 0
-    ok 1 - mp_check_map(0) == 0
-    ok 2 - mp_decode(mp_encode(0)) == 0
-    ok 3 - len(mp_encode_map(0)
-    ok 4 - len(mp_decode_map(0))
-    ok 5 - mp_sizeof_map(0)
-    ok 6 - mp_encode(0) == "\x80"
-    # map 1
-    ok 7 - mp_check_map(1) == 0
-    ok 8 - mp_decode(mp_encode(1)) == 1
-    ok 9 - len(mp_encode_map(1)
-    ok 10 - len(mp_decode_map(1))
-    ok 11 - mp_sizeof_map(1)
-    ok 12 - mp_encode(1) == "\x81"
-    # map 15
-    ok 13 - mp_check_map(15) == 0
-    ok 14 - mp_decode(mp_encode(15)) == 15
-    ok 15 - len(mp_encode_map(15)
-    ok 16 - len(mp_decode_map(15))
-    ok 17 - mp_sizeof_map(15)
-    ok 18 - mp_encode(15) == "\x8f"
-    # map 16
-    ok 19 - mp_check_map(16) == 0
-    ok 20 - mp_decode(mp_encode(16)) == 16
-    ok 21 - len(mp_encode_map(16)
-    ok 22 - len(mp_decode_map(16))
-    ok 23 - mp_sizeof_map(16)
-    ok 24 - mp_encode(16) == "\xde\x00\x10"
-    # map 0xfffe
-    ok 25 - mp_check_map(0xfffe) == 0
-    ok 26 - mp_decode(mp_encode(0xfffe)) == 0xfffe
-    ok 27 - len(mp_encode_map(0xfffe)
-    ok 28 - len(mp_decode_map(0xfffe))
-    ok 29 - mp_sizeof_map(0xfffe)
-    ok 30 - mp_encode(0xfffe) == "\xde\xff\xfe"
-    # map 0xffff
-    ok 31 - mp_check_map(0xffff) == 0
-    ok 32 - mp_decode(mp_encode(0xffff)) == 0xffff
-    ok 33 - len(mp_encode_map(0xffff)
-    ok 34 - len(mp_decode_map(0xffff))
-    ok 35 - mp_sizeof_map(0xffff)
-    ok 36 - mp_encode(0xffff) == "\xde\xff\xff"
-    # map 0x10000
-    ok 37 - mp_check_map(0x10000) == 0
-    ok 38 - mp_decode(mp_encode(0x10000)) == 0x10000
-    ok 39 - len(mp_encode_map(0x10000)
-    ok 40 - len(mp_decode_map(0x10000))
-    ok 41 - mp_sizeof_map(0x10000)
-    ok 42 - mp_encode(0x10000) == "\xdf\x00\x01\x00\x00"
-    # map 0xfffffffeU
-    ok 43 - mp_check_map(0xfffffffeU) == 0
-    ok 44 - mp_decode(mp_encode(0xfffffffeU)) == 0xfffffffeU
-    ok 45 - len(mp_encode_map(0xfffffffeU)
-    ok 46 - len(mp_decode_map(0xfffffffeU))
-    ok 47 - mp_sizeof_map(0xfffffffeU)
-    ok 48 - mp_encode(0xfffffffeU) == "\xdf\xff\xff\xff\xfe"
-    # map 0xffffffffU
-    ok 49 - mp_check_map(0xffffffffU) == 0
-    ok 50 - mp_decode(mp_encode(0xffffffffU)) == 0xffffffffU
-    ok 51 - len(mp_encode_map(0xffffffffU)
-    ok 52 - len(mp_decode_map(0xffffffffU))
-    ok 53 - mp_sizeof_map(0xffffffffU)
-    ok 54 - mp_encode(0xffffffffU) == "\xdf\xff\xff\xff\xff"
-    # *** test_maps: done ***
-ok 14 - subtests
-    1..52
-    # *** test_next_on_arrays ***
-    # next/check on array(0)
-    ok 1 - mp_check(array 0))
-    ok 2 - len(array 0) == 1
-    ok 3 - len(mp_check(array 0)) == 1
-    ok 4 - len(mp_next(array 0)) == 1
-    # next/check on array(1)
-    ok 5 - mp_check(array 1))
-    ok 6 - len(array 1) == 2
-    ok 7 - len(mp_check(array 1)) == 2
-    ok 8 - len(mp_next(array 1)) == 2
-    # next/check on array(15)
-    ok 9 - mp_check(array 15))
-    ok 10 - len(array 15) == 16
-    ok 11 - len(mp_check(array 15)) == 16
-    ok 12 - len(mp_next(array 15)) == 16
-    # next/check on array(16)
-    ok 13 - mp_check(array 16))
-    ok 14 - len(array 16) == 19
-    ok 15 - len(mp_check(array 16)) == 19
-    ok 16 - len(mp_next(array 16)) == 19
-    # next/check on array(17)
-    ok 17 - mp_check(array 17))
-    ok 18 - len(array 17) == 20
-    ok 19 - len(mp_check(array 17)) == 20
-    ok 20 - len(mp_next(array 17)) == 20
-    # next/check on array(254)
-    ok 21 - mp_check(array 254))
-    ok 22 - len(array 254) == 257
-    ok 23 - len(mp_check(array 254)) == 257
-    ok 24 - len(mp_next(array 254)) == 257
-    # next/check on array(255)
-    ok 25 - mp_check(array 255))
-    ok 26 - len(array 255) == 258
-    ok 27 - len(mp_check(array 255)) == 258
-    ok 28 - len(mp_next(array 255)) == 258
-    # next/check on array(256)
-    ok 29 - mp_check(array 256))
-    ok 30 - len(array 256) == 259
-    ok 31 - len(mp_check(array 256)) == 259
-    ok 32 - len(mp_next(array 256)) == 259
-    # next/check on array(257)
-    ok 33 - mp_check(array 257))
-    ok 34 - len(array 257) == 260
-    ok 35 - len(mp_check(array 257)) == 260
-    ok 36 - len(mp_next(array 257)) == 260
-    # next/check on array(65534)
-    ok 37 - mp_check(array 65534))
-    ok 38 - len(array 65534) == 65537
-    ok 39 - len(mp_check(array 65534)) == 65537
-    ok 40 - len(mp_next(array 65534)) == 65537
-    # next/check on array(65535)
-    ok 41 - mp_check(array 65535))
-    ok 42 - len(array 65535) == 65538
-    ok 43 - len(mp_check(array 65535)) == 65538
-    ok 44 - len(mp_next(array 65535)) == 65538
-    # next/check on array(65536)
-    ok 45 - mp_check(array 65536))
-    ok 46 - len(array 65536) == 65541
-    ok 47 - len(mp_check(array 65536)) == 65541
-    ok 48 - len(mp_next(array 65536)) == 65541
-    # next/check on array(65537)
-    ok 49 - mp_check(array 65537))
-    ok 50 - len(array 65537) == 65542
-    ok 51 - len(mp_check(array 65537)) == 65542
-    ok 52 - len(mp_next(array 65537)) == 65542
-    # *** test_next_on_arrays: done ***
-ok 15 - subtests
-    1..52
-    # *** test_next_on_maps ***
-    # next/check on map(0)
-    ok 1 - mp_check(map 0))
-    ok 2 - len(map 0) == 1
-    ok 3 - len(mp_check(map 0)) == 1
-    ok 4 - len(mp_next(map 0)) == 1
-    # next/check on map(1)
-    ok 5 - mp_check(map 1))
-    ok 6 - len(map 1) == 3
-    ok 7 - len(mp_check(map 1)) == 3
-    ok 8 - len(mp_next(map 1)) == 3
-    # next/check on map(15)
-    ok 9 - mp_check(map 15))
-    ok 10 - len(map 15) == 31
-    ok 11 - len(mp_check(map 15)) == 31
-    ok 12 - len(mp_next(map 15)) == 31
-    # next/check on map(16)
-    ok 13 - mp_check(map 16))
-    ok 14 - len(map 16) == 35
-    ok 15 - len(mp_check(map 16)) == 35
-    ok 16 - len(mp_next(map 16)) == 35
-    # next/check on map(17)
-    ok 17 - mp_check(map 17))
-    ok 18 - len(map 17) == 37
-    ok 19 - len(mp_check(map 17)) == 37
-    ok 20 - len(mp_next(map 17)) == 37
-    # next/check on map(254)
-    ok 21 - mp_check(map 254))
-    ok 22 - len(map 254) == 511
-    ok 23 - len(mp_check(map 254)) == 511
-    ok 24 - len(mp_next(map 254)) == 511
-    # next/check on map(255)
-    ok 25 - mp_check(map 255))
-    ok 26 - len(map 255) == 513
-    ok 27 - len(mp_check(map 255)) == 513
-    ok 28 - len(mp_next(map 255)) == 513
-    # next/check on map(256)
-    ok 29 - mp_check(map 256))
-    ok 30 - len(map 256) == 515
-    ok 31 - len(mp_check(map 256)) == 515
-    ok 32 - len(mp_next(map 256)) == 515
-    # next/check on map(257)
-    ok 33 - mp_check(map 257))
-    ok 34 - len(map 257) == 517
-    ok 35 - len(mp_check(map 257)) == 517
-    ok 36 - len(mp_next(map 257)) == 517
-    # next/check on map(65534)
-    ok 37 - mp_check(map 65534))
-    ok 38 - len(map 65534) == 131071
-    ok 39 - len(mp_check(map 65534)) == 131071
-    ok 40 - len(mp_next(map 65534)) == 131071
-    # next/check on map(65535)
-    ok 41 - mp_check(map 65535))
-    ok 42 - len(map 65535) == 131073
-    ok 43 - len(mp_check(map 65535)) == 131073
-    ok 44 - len(mp_next(map 65535)) == 131073
-    # next/check on map(65536)
-    ok 45 - mp_check(map 65536))
-    ok 46 - len(map 65536) == 131077
-    ok 47 - len(mp_check(map 65536)) == 131077
-    ok 48 - len(mp_next(map 65536)) == 131077
-    # next/check on map(65537)
-    ok 49 - mp_check(map 65537))
-    ok 50 - len(map 65537) == 131079
-    ok 51 - len(mp_check(map 65537)) == 131079
-    ok 52 - len(mp_next(map 65537)) == 131079
-    # *** test_next_on_maps: done ***
-ok 16 - subtests
-    1..227
-    # *** test_compare_uints ***
-    ok 1 - mp_compare_uint(0, 0) == 0
-    ok 2 - mp_compare_uint(0, 0) == 0
-    ok 3 - mp_compare_uint(0, 0) == 0
-    ok 4 - mp_compare_uint(0, 1) < 0
-    ok 5 - mp_compare_uint(0, 126) < 0
-    ok 6 - mp_compare_uint(0, 127) < 0
-    ok 7 - mp_compare_uint(0, 128) < 0
-    ok 8 - mp_compare_uint(0, 254) < 0
-    ok 9 - mp_compare_uint(0, 255) < 0
-    ok 10 - mp_compare_uint(0, 65534) < 0
-    ok 11 - mp_compare_uint(0, 65535) < 0
-    ok 12 - mp_compare_uint(0, 65536) < 0
-    ok 13 - mp_compare_uint(0, 4294967294) < 0
-    ok 14 - mp_compare_uint(0, 4294967295) < 0
-    ok 15 - mp_compare_uint(0, 4294967296) < 0
-    ok 16 - mp_compare_uint(0, 18446744073709551614) < 0
-    ok 17 - mp_compare_uint(0, 18446744073709551615) < 0
-    ok 18 - mp_compare_uint(1, 0) > 0
-    ok 19 - mp_compare_uint(1, 1) == 0
-    ok 20 - mp_compare_uint(1, 126) < 0
-    ok 21 - mp_compare_uint(1, 127) < 0
-    ok 22 - mp_compare_uint(1, 128) < 0
-    ok 23 - mp_compare_uint(1, 254) < 0
-    ok 24 - mp_compare_uint(1, 255) < 0
-    ok 25 - mp_compare_uint(1, 65534) < 0
-    ok 26 - mp_compare_uint(1, 65535) < 0
-    ok 27 - mp_compare_uint(1, 65536) < 0
-    ok 28 - mp_compare_uint(1, 4294967294) < 0
-    ok 29 - mp_compare_uint(1, 4294967295) < 0
-    ok 30 - mp_compare_uint(1, 4294967296) < 0
-    ok 31 - mp_compare_uint(1, 18446744073709551614) < 0
-    ok 32 - mp_compare_uint(1, 18446744073709551615) < 0
-    ok 33 - mp_compare_uint(126, 0) > 0
-    ok 34 - mp_compare_uint(126, 1) > 0
-    ok 35 - mp_compare_uint(126, 126) == 0
-    ok 36 - mp_compare_uint(126, 127) < 0
-    ok 37 - mp_compare_uint(126, 128) < 0
-    ok 38 - mp_compare_uint(126, 254) < 0
-    ok 39 - mp_compare_uint(126, 255) < 0
-    ok 40 - mp_compare_uint(126, 65534) < 0
-    ok 41 - mp_compare_uint(126, 65535) < 0
-    ok 42 - mp_compare_uint(126, 65536) < 0
-    ok 43 - mp_compare_uint(126, 4294967294) < 0
-    ok 44 - mp_compare_uint(126, 4294967295) < 0
-    ok 45 - mp_compare_uint(126, 4294967296) < 0
-    ok 46 - mp_compare_uint(126, 18446744073709551614) < 0
-    ok 47 - mp_compare_uint(126, 18446744073709551615) < 0
-    ok 48 - mp_compare_uint(127, 0) > 0
-    ok 49 - mp_compare_uint(127, 1) > 0
-    ok 50 - mp_compare_uint(127, 126) > 0
-    ok 51 - mp_compare_uint(127, 127) == 0
-    ok 52 - mp_compare_uint(127, 128) < 0
-    ok 53 - mp_compare_uint(127, 254) < 0
-    ok 54 - mp_compare_uint(127, 255) < 0
-    ok 55 - mp_compare_uint(127, 65534) < 0
-    ok 56 - mp_compare_uint(127, 65535) < 0
-    ok 57 - mp_compare_uint(127, 65536) < 0
-    ok 58 - mp_compare_uint(127, 4294967294) < 0
-    ok 59 - mp_compare_uint(127, 4294967295) < 0
-    ok 60 - mp_compare_uint(127, 4294967296) < 0
-    ok 61 - mp_compare_uint(127, 18446744073709551614) < 0
-    ok 62 - mp_compare_uint(127, 18446744073709551615) < 0
-    ok 63 - mp_compare_uint(128, 0) > 0
-    ok 64 - mp_compare_uint(128, 1) > 0
-    ok 65 - mp_compare_uint(128, 126) > 0
-    ok 66 - mp_compare_uint(128, 127) > 0
-    ok 67 - mp_compare_uint(128, 128) == 0
-    ok 68 - mp_compare_uint(128, 254) < 0
-    ok 69 - mp_compare_uint(128, 255) < 0
-    ok 70 - mp_compare_uint(128, 65534) < 0
-    ok 71 - mp_compare_uint(128, 65535) < 0
-    ok 72 - mp_compare_uint(128, 65536) < 0
-    ok 73 - mp_compare_uint(128, 4294967294) < 0
-    ok 74 - mp_compare_uint(128, 4294967295) < 0
-    ok 75 - mp_compare_uint(128, 4294967296) < 0
-    ok 76 - mp_compare_uint(128, 18446744073709551614) < 0
-    ok 77 - mp_compare_uint(128, 18446744073709551615) < 0
-    ok 78 - mp_compare_uint(254, 0) > 0
-    ok 79 - mp_compare_uint(254, 1) > 0
-    ok 80 - mp_compare_uint(254, 126) > 0
-    ok 81 - mp_compare_uint(254, 127) > 0
-    ok 82 - mp_compare_uint(254, 128) > 0
-    ok 83 - mp_compare_uint(254, 254) == 0
-    ok 84 - mp_compare_uint(254, 255) < 0
-    ok 85 - mp_compare_uint(254, 65534) < 0
-    ok 86 - mp_compare_uint(254, 65535) < 0
-    ok 87 - mp_compare_uint(254, 65536) < 0
-    ok 88 - mp_compare_uint(254, 4294967294) < 0
-    ok 89 - mp_compare_uint(254, 4294967295) < 0
-    ok 90 - mp_compare_uint(254, 4294967296) < 0
-    ok 91 - mp_compare_uint(254, 18446744073709551614) < 0
-    ok 92 - mp_compare_uint(254, 18446744073709551615) < 0
-    ok 93 - mp_compare_uint(255, 0) > 0
-    ok 94 - mp_compare_uint(255, 1) > 0
-    ok 95 - mp_compare_uint(255, 126) > 0
-    ok 96 - mp_compare_uint(255, 127) > 0
-    ok 97 - mp_compare_uint(255, 128) > 0
-    ok 98 - mp_compare_uint(255, 254) > 0
-    ok 99 - mp_compare_uint(255, 255) == 0
-    ok 100 - mp_compare_uint(255, 65534) < 0
-    ok 101 - mp_compare_uint(255, 65535) < 0
-    ok 102 - mp_compare_uint(255, 65536) < 0
-    ok 103 - mp_compare_uint(255, 4294967294) < 0
-    ok 104 - mp_compare_uint(255, 4294967295) < 0
-    ok 105 - mp_compare_uint(255, 4294967296) < 0
-    ok 106 - mp_compare_uint(255, 18446744073709551614) < 0
-    ok 107 - mp_compare_uint(255, 18446744073709551615) < 0
-    ok 108 - mp_compare_uint(65534, 0) > 0
-    ok 109 - mp_compare_uint(65534, 1) > 0
-    ok 110 - mp_compare_uint(65534, 126) > 0
-    ok 111 - mp_compare_uint(65534, 127) > 0
-    ok 112 - mp_compare_uint(65534, 128) > 0
-    ok 113 - mp_compare_uint(65534, 254) > 0
-    ok 114 - mp_compare_uint(65534, 255) > 0
-    ok 115 - mp_compare_uint(65534, 65534) == 0
-    ok 116 - mp_compare_uint(65534, 65535) < 0
-    ok 117 - mp_compare_uint(65534, 65536) < 0
-    ok 118 - mp_compare_uint(65534, 4294967294) < 0
-    ok 119 - mp_compare_uint(65534, 4294967295) < 0
-    ok 120 - mp_compare_uint(65534, 4294967296) < 0
-    ok 121 - mp_compare_uint(65534, 18446744073709551614) < 0
-    ok 122 - mp_compare_uint(65534, 18446744073709551615) < 0
-    ok 123 - mp_compare_uint(65535, 0) > 0
-    ok 124 - mp_compare_uint(65535, 1) > 0
-    ok 125 - mp_compare_uint(65535, 126) > 0
-    ok 126 - mp_compare_uint(65535, 127) > 0
-    ok 127 - mp_compare_uint(65535, 128) > 0
-    ok 128 - mp_compare_uint(65535, 254) > 0
-    ok 129 - mp_compare_uint(65535, 255) > 0
-    ok 130 - mp_compare_uint(65535, 65534) > 0
-    ok 131 - mp_compare_uint(65535, 65535) == 0
-    ok 132 - mp_compare_uint(65535, 65536) < 0
-    ok 133 - mp_compare_uint(65535, 4294967294) < 0
-    ok 134 - mp_compare_uint(65535, 4294967295) < 0
-    ok 135 - mp_compare_uint(65535, 4294967296) < 0
-    ok 136 - mp_compare_uint(65535, 18446744073709551614) < 0
-    ok 137 - mp_compare_uint(65535, 18446744073709551615) < 0
-    ok 138 - mp_compare_uint(65536, 0) > 0
-    ok 139 - mp_compare_uint(65536, 1) > 0
-    ok 140 - mp_compare_uint(65536, 126) > 0
-    ok 141 - mp_compare_uint(65536, 127) > 0
-    ok 142 - mp_compare_uint(65536, 128) > 0
-    ok 143 - mp_compare_uint(65536, 254) > 0
-    ok 144 - mp_compare_uint(65536, 255) > 0
-    ok 145 - mp_compare_uint(65536, 65534) > 0
-    ok 146 - mp_compare_uint(65536, 65535) > 0
-    ok 147 - mp_compare_uint(65536, 65536) == 0
-    ok 148 - mp_compare_uint(65536, 4294967294) < 0
-    ok 149 - mp_compare_uint(65536, 4294967295) < 0
-    ok 150 - mp_compare_uint(65536, 4294967296) < 0
-    ok 151 - mp_compare_uint(65536, 18446744073709551614) < 0
-    ok 152 - mp_compare_uint(65536, 18446744073709551615) < 0
-    ok 153 - mp_compare_uint(4294967294, 0) > 0
-    ok 154 - mp_compare_uint(4294967294, 1) > 0
-    ok 155 - mp_compare_uint(4294967294, 126) > 0
-    ok 156 - mp_compare_uint(4294967294, 127) > 0
-    ok 157 - mp_compare_uint(4294967294, 128) > 0
-    ok 158 - mp_compare_uint(4294967294, 254) > 0
-    ok 159 - mp_compare_uint(4294967294, 255) > 0
-    ok 160 - mp_compare_uint(4294967294, 65534) > 0
-    ok 161 - mp_compare_uint(4294967294, 65535) > 0
-    ok 162 - mp_compare_uint(4294967294, 65536) > 0
-    ok 163 - mp_compare_uint(4294967294, 4294967294) == 0
-    ok 164 - mp_compare_uint(4294967294, 4294967295) < 0
-    ok 165 - mp_compare_uint(4294967294, 4294967296) < 0
-    ok 166 - mp_compare_uint(4294967294, 18446744073709551614) < 0
-    ok 167 - mp_compare_uint(4294967294, 18446744073709551615) < 0
-    ok 168 - mp_compare_uint(4294967295, 0) > 0
-    ok 169 - mp_compare_uint(4294967295, 1) > 0
-    ok 170 - mp_compare_uint(4294967295, 126) > 0
-    ok 171 - mp_compare_uint(4294967295, 127) > 0
-    ok 172 - mp_compare_uint(4294967295, 128) > 0
-    ok 173 - mp_compare_uint(4294967295, 254) > 0
-    ok 174 - mp_compare_uint(4294967295, 255) > 0
-    ok 175 - mp_compare_uint(4294967295, 65534) > 0
-    ok 176 - mp_compare_uint(4294967295, 65535) > 0
-    ok 177 - mp_compare_uint(4294967295, 65536) > 0
-    ok 178 - mp_compare_uint(4294967295, 4294967294) > 0
-    ok 179 - mp_compare_uint(4294967295, 4294967295) == 0
-    ok 180 - mp_compare_uint(4294967295, 4294967296) < 0
-    ok 181 - mp_compare_uint(4294967295, 18446744073709551614) < 0
-    ok 182 - mp_compare_uint(4294967295, 18446744073709551615) < 0
-    ok 183 - mp_compare_uint(4294967296, 0) > 0
-    ok 184 - mp_compare_uint(4294967296, 1) > 0
-    ok 185 - mp_compare_uint(4294967296, 126) > 0
-    ok 186 - mp_compare_uint(4294967296, 127) > 0
-    ok 187 - mp_compare_uint(4294967296, 128) > 0
-    ok 188 - mp_compare_uint(4294967296, 254) > 0
-    ok 189 - mp_compare_uint(4294967296, 255) > 0
-    ok 190 - mp_compare_uint(4294967296, 65534) > 0
-    ok 191 - mp_compare_uint(4294967296, 65535) > 0
-    ok 192 - mp_compare_uint(4294967296, 65536) > 0
-    ok 193 - mp_compare_uint(4294967296, 4294967294) > 0
-    ok 194 - mp_compare_uint(4294967296, 4294967295) > 0
-    ok 195 - mp_compare_uint(4294967296, 4294967296) == 0
-    ok 196 - mp_compare_uint(4294967296, 18446744073709551614) < 0
-    ok 197 - mp_compare_uint(4294967296, 18446744073709551615) < 0
-    ok 198 - mp_compare_uint(18446744073709551614, 0) > 0
-    ok 199 - mp_compare_uint(18446744073709551614, 1) > 0
-    ok 200 - mp_compare_uint(18446744073709551614, 126) > 0
-    ok 201 - mp_compare_uint(18446744073709551614, 127) > 0
-    ok 202 - mp_compare_uint(18446744073709551614, 128) > 0
-    ok 203 - mp_compare_uint(18446744073709551614, 254) > 0
-    ok 204 - mp_compare_uint(18446744073709551614, 255) > 0
-    ok 205 - mp_compare_uint(18446744073709551614, 65534) > 0
-    ok 206 - mp_compare_uint(18446744073709551614, 65535) > 0
-    ok 207 - mp_compare_uint(18446744073709551614, 65536) > 0
-    ok 208 - mp_compare_uint(18446744073709551614, 4294967294) > 0
-    ok 209 - mp_compare_uint(18446744073709551614, 4294967295) > 0
-    ok 210 - mp_compare_uint(18446744073709551614, 4294967296) > 0
-    ok 211 - mp_compare_uint(18446744073709551614, 18446744073709551614) == 0
-    ok 212 - mp_compare_uint(18446744073709551614, 18446744073709551615) < 0
-    ok 213 - mp_compare_uint(18446744073709551615, 0) > 0
-    ok 214 - mp_compare_uint(18446744073709551615, 1) > 0
-    ok 215 - mp_compare_uint(18446744073709551615, 126) > 0
-    ok 216 - mp_compare_uint(18446744073709551615, 127) > 0
-    ok 217 - mp_compare_uint(18446744073709551615, 128) > 0
-    ok 218 - mp_compare_uint(18446744073709551615, 254) > 0
-    ok 219 - mp_compare_uint(18446744073709551615, 255) > 0
-    ok 220 - mp_compare_uint(18446744073709551615, 65534) > 0
-    ok 221 - mp_compare_uint(18446744073709551615, 65535) > 0
-    ok 222 - mp_compare_uint(18446744073709551615, 65536) > 0
-    ok 223 - mp_compare_uint(18446744073709551615, 4294967294) > 0
-    ok 224 - mp_compare_uint(18446744073709551615, 4294967295) > 0
-    ok 225 - mp_compare_uint(18446744073709551615, 4294967296) > 0
-    ok 226 - mp_compare_uint(18446744073709551615, 18446744073709551614) > 0
-    ok 227 - mp_compare_uint(18446744073709551615, 18446744073709551615) == 0
-    # *** test_compare_uints: done ***
-ok 17 - subtests
-    1..282
-    # *** test_format ***
-    ok 1 - Test type on step 0
-    ok 2 - Test value on step 0
-    ok 3 - Test type on step 1
-    ok 4 - Test value on step 1
-    ok 5 - Test type on step 2
-    ok 6 - Test value on step 2
-    ok 7 - Test type on step 3
-    ok 8 - Test value on step 3
-    ok 9 - Test type on step 4
-    ok 10 - Test value on step 4
-    ok 11 - Test type on step 5
-    ok 12 - Test value on step 5
-    ok 13 - Test type on step 6
-    ok 14 - Test value on step 6
-    ok 15 - Test type on step 7
-    ok 16 - Test value on step 7
-    ok 17 - Test type on step 8
-    ok 18 - Test value on step 8
-    ok 19 - Test type on step 9
-    ok 20 - Test value on step 9
-    ok 21 - Test type on step 10
-    ok 22 - Test value on step 10
-    ok 23 - Test type on step 11
-    ok 24 - Test value on step 11
-    ok 25 - Test type on step 12
-    ok 26 - Test value on step 12
-    ok 27 - Test type on step 13
-    ok 28 - Test value on step 13
-    ok 29 - Test type on step 14
-    ok 30 - Test value on step 14
-    ok 31 - Test type on step 0
-    ok 32 - Test value on step 0
-    ok 33 - Test type on step 1
-    ok 34 - Test value on step 1
-    ok 35 - Test type on step 2
-    ok 36 - Test value on step 2
-    ok 37 - Test type on step 3
-    ok 38 - Test value on step 3
-    ok 39 - Test type on step 4
-    ok 40 - Test value on step 4
-    ok 41 - Test type on step 5
-    ok 42 - Test value on step 5
-    ok 43 - Test type on step 6
-    ok 44 - Test value on step 6
-    ok 45 - Test type on step 7
-    ok 46 - Test value on step 7
-    ok 47 - Test type on step 8
-    ok 48 - Test value on step 8
-    ok 49 - Test type on step 9
-    ok 50 - Test value on step 9
-    ok 51 - Test type on step 10
-    ok 52 - Test value on step 10
-    ok 53 - Test type on step 11
-    ok 54 - Test value on step 11
-    ok 55 - Test type on step 12
-    ok 56 - Test value on step 12
-    ok 57 - Test type on step 13
-    ok 58 - Test value on step 13
-    ok 59 - Test type on step 14
-    ok 60 - Test value on step 14
-    ok 61 - check
-    ok 62 - type
-    ok 63 - decode
-    ok 64 - check
-    ok 65 - type
-    ok 66 - check
-    ok 67 - type
-    ok 68 - decode
-    ok 69 - check
-    ok 70 - type
-    ok 71 - decode
-    ok 72 - check
-    ok 73 - type
-    ok 74 - decode
-    ok 75 - check
-    ok 76 - type
-    ok 77 - decode
-    ok 78 - check
-    ok 79 - type
-    ok 80 - decode
-    ok 81 - check
-    ok 82 - type
-    ok 83 - decode
-    ok 84 - check
-    ok 85 - type
-    ok 86 - decode
-    ok 87 - check
-    ok 88 - type
-    ok 89 - decode
-    ok 90 - check
-    ok 91 - type
-    ok 92 - decode
-    ok 93 - check
-    ok 94 - type
-    ok 95 - decode
-    ok 96 - check
-    ok 97 - type
-    ok 98 - decode
-    ok 99 - compare
-    ok 100 - check
-    ok 101 - type
-    ok 102 - decode
-    ok 103 - check
-    ok 104 - type
-    ok 105 - decode
-    ok 106 - compare
-    ok 107 - check
-    ok 108 - type
-    ok 109 - decode
-    ok 110 - check
-    ok 111 - type
-    ok 112 - decode
-    ok 113 - check
-    ok 114 - type
-    ok 115 - check
-    ok 116 - compare
-    ok 117 - check
-    ok 118 - type
-    ok 119 - decode
-    ok 120 - check
-    ok 121 - type
-    ok 122 - decode
-    ok 123 - check
-    ok 124 - type
-    ok 125 - decode
-    ok 126 - compare
-    ok 127 - check
-    ok 128 - type
-    ok 129 - decode
-    ok 130 - check
-    ok 131 - type
-    ok 132 - decode
-    ok 133 - check
-    ok 134 - type
-    ok 135 - decode
-    ok 136 - check
-    ok 137 - type
-    ok 138 - decode
-    ok 139 - nothing more
-    ok 140 - no magic detected
-    ok 141 - return value on step 0
-    ok 142 - buffer overflow on step 0
-    ok 143 - return value on step 1
-    ok 144 - buffer overflow on step 1
-    ok 145 - return value on step 2
-    ok 146 - buffer overflow on step 2
-    ok 147 - return value on step 3
-    ok 148 - buffer overflow on step 3
-    ok 149 - return value on step 4
-    ok 150 - buffer overflow on step 4
-    ok 151 - return value on step 5
-    ok 152 - buffer overflow on step 5
-    ok 153 - return value on step 6
-    ok 154 - buffer overflow on step 6
-    ok 155 - return value on step 7
-    ok 156 - buffer overflow on step 7
-    ok 157 - return value on step 8
-    ok 158 - buffer overflow on step 8
-    ok 159 - return value on step 9
-    ok 160 - buffer overflow on step 9
-    ok 161 - return value on step 10
-    ok 162 - buffer overflow on step 10
-    ok 163 - return value on step 11
-    ok 164 - buffer overflow on step 11
-    ok 165 - return value on step 12
-    ok 166 - buffer overflow on step 12
-    ok 167 - return value on step 13
-    ok 168 - buffer overflow on step 13
-    ok 169 - return value on step 14
-    ok 170 - buffer overflow on step 14
-    ok 171 - return value on step 15
-    ok 172 - buffer overflow on step 15
-    ok 173 - return value on step 16
-    ok 174 - buffer overflow on step 16
-    ok 175 - return value on step 17
-    ok 176 - buffer overflow on step 17
-    ok 177 - return value on step 18
-    ok 178 - buffer overflow on step 18
-    ok 179 - return value on step 19
-    ok 180 - buffer overflow on step 19
-    ok 181 - return value on step 20
-    ok 182 - buffer overflow on step 20
-    ok 183 - return value on step 21
-    ok 184 - buffer overflow on step 21
-    ok 185 - return value on step 22
-    ok 186 - buffer overflow on step 22
-    ok 187 - return value on step 23
-    ok 188 - buffer overflow on step 23
-    ok 189 - return value on step 24
-    ok 190 - buffer overflow on step 24
-    ok 191 - return value on step 25
-    ok 192 - buffer overflow on step 25
-    ok 193 - return value on step 26
-    ok 194 - buffer overflow on step 26
-    ok 195 - return value on step 27
-    ok 196 - buffer overflow on step 27
-    ok 197 - return value on step 28
-    ok 198 - buffer overflow on step 28
-    ok 199 - return value on step 29
-    ok 200 - buffer overflow on step 29
-    ok 201 - return value on step 30
-    ok 202 - buffer overflow on step 30
-    ok 203 - return value on step 31
-    ok 204 - buffer overflow on step 31
-    ok 205 - return value on step 32
-    ok 206 - buffer overflow on step 32
-    ok 207 - return value on step 33
-    ok 208 - buffer overflow on step 33
-    ok 209 - return value on step 34
-    ok 210 - buffer overflow on step 34
-    ok 211 - return value on step 35
-    ok 212 - buffer overflow on step 35
-    ok 213 - return value on step 36
-    ok 214 - buffer overflow on step 36
-    ok 215 - return value on step 37
-    ok 216 - buffer overflow on step 37
-    ok 217 - return value on step 38
-    ok 218 - buffer overflow on step 38
-    ok 219 - return value on step 39
-    ok 220 - buffer overflow on step 39
-    ok 221 - return value on step 40
-    ok 222 - buffer overflow on step 40
-    ok 223 - return value on step 41
-    ok 224 - buffer overflow on step 41
-    ok 225 - return value on step 42
-    ok 226 - buffer overflow on step 42
-    ok 227 - return value on step 43
-    ok 228 - buffer overflow on step 43
-    ok 229 - return value on step 44
-    ok 230 - buffer overflow on step 44
-    ok 231 - return value on step 45
-    ok 232 - buffer overflow on step 45
-    ok 233 - return value on step 46
-    ok 234 - buffer overflow on step 46
-    ok 235 - return value on step 47
-    ok 236 - buffer overflow on step 47
-    ok 237 - return value on step 48
-    ok 238 - buffer overflow on step 48
-    ok 239 - return value on step 49
-    ok 240 - buffer overflow on step 49
-    ok 241 - return value on step 50
-    ok 242 - buffer overflow on step 50
-    ok 243 - return value on step 51
-    ok 244 - buffer overflow on step 51
-    ok 245 - return value on step 52
-    ok 246 - buffer overflow on step 52
-    ok 247 - return value on step 53
-    ok 248 - buffer overflow on step 53
-    ok 249 - return value on step 54
-    ok 250 - buffer overflow on step 54
-    ok 251 - return value on step 55
-    ok 252 - buffer overflow on step 55
-    ok 253 - return value on step 56
-    ok 254 - buffer overflow on step 56
-    ok 255 - return value on step 57
-    ok 256 - buffer overflow on step 57
-    ok 257 - return value on step 58
-    ok 258 - buffer overflow on step 58
-    ok 259 - return value on step 59
-    ok 260 - buffer overflow on step 59
-    ok 261 - return value on step 60
-    ok 262 - buffer overflow on step 60
-    ok 263 - return value on step 61
-    ok 264 - buffer overflow on step 61
-    ok 265 - return value on step 62
-    ok 266 - buffer overflow on step 62
-    ok 267 - return value on step 63
-    ok 268 - buffer overflow on step 63
-    ok 269 - return value on step 64
-    ok 270 - buffer overflow on step 64
-    ok 271 - return value on step 65
-    ok 272 - buffer overflow on step 65
-    ok 273 - return value on step 66
-    ok 274 - buffer overflow on step 66
-    ok 275 - return value on step 67
-    ok 276 - buffer overflow on step 67
-    ok 277 - return value on step 68
-    ok 278 - buffer overflow on step 68
-    ok 279 - return value on step 69
-    ok 280 - buffer overflow on step 69
-    ok 281 - return value on step 70
-    ok 282 - buffer overflow on step 70
-    # *** test_format: done ***
-ok 18 - subtests
-    1..12
-    # *** test_mp_print ***
-    ok 1 - mp_snprint return value
-    ok 2 - mp_snprint result
-    ok 3 - mp_snprint limit = 0
-    ok 4 - mp_snprint limit = 1
-    ok 5 - mp_snprint limit = 2
-    ok 6 - mp_snprint limit = expected
-    ok 7 - mp_snprint limit = expected + 1
-    ok 8 - mp_fprint return value
-    ok 9 - mp_fprint result
-    ok 10 - mp_fprint I/O error
-    ok 11 - mp_snprint max nesting depth return value
-    ok 12 - mp_snprint max nesting depth result
-    # *** test_mp_print: done ***
-ok 19 - subtests
-    1..65
-    # *** test_mp_check ***
-    ok 1 - invalid fixmap 1
-    ok 2 - invalid fixmap 2
-    ok 3 - invalid fixmap 3
-    ok 4 - invalid fixarray 1
-    ok 5 - invalid fixarray 2
-    ok 6 - invalid fixarray 3
-    ok 7 - invalid fixstr 1
-    ok 8 - invalid fixstr 2
-    ok 9 - invalid fixstr 3
-    ok 10 - invalid bin8 1
-    ok 11 - invalid bin8 2
-    ok 12 - invalid bin16 1
-    ok 13 - invalid bin16 2
-    ok 14 - invalid bin32 1
-    ok 15 - invalid bin32 2
-    ok 16 - invalid ext8 1
-    ok 17 - invalid ext8 2
-    ok 18 - invalid ext8 3
-    ok 19 - invalid ext8 4
-    ok 20 - invalid ext16 1
-    ok 21 - invalid ext16 2
-    ok 22 - invalid ext16 3
-    ok 23 - invalid ext16 4
-    ok 24 - invalid ext32 1
-    ok 25 - invalid ext32 2
-    ok 26 - invalid ext32 3
-    ok 27 - invalid ext32 4
-    ok 28 - invalid float32 1
-    ok 29 - invalid float32 2
-    ok 30 - invalid float64 1
-    ok 31 - invalid float64 2
-    ok 32 - invalid uint8 1
-    ok 33 - invalid uint16 1
-    ok 34 - invalid uint32 1
-    ok 35 - invalid uint64 1
-    ok 36 - invalid int8 1
-    ok 37 - invalid int16 1
-    ok 38 - invalid int32 1
-    ok 39 - invalid int64 1
-    ok 40 - invalid fixext8 1
-    ok 41 - invalid fixext8 2
-    ok 42 - invalid fixext16 1
-    ok 43 - invalid fixext16 2
-    ok 44 - invalid fixext32 1
-    ok 45 - invalid fixext32 2
-    ok 46 - invalid fixext64 1
-    ok 47 - invalid fixext64 2
-    ok 48 - invalid fixext128 1
-    ok 49 - invalid fixext128 2
-    ok 50 - invalid str8 1
-    ok 51 - invalid str8 2
-    ok 52 - invalid str16 1
-    ok 53 - invalid str16 2
-    ok 54 - invalid str32 1
-    ok 55 - invalid str32 2
-    ok 56 - invalid array16 1
-    ok 57 - invalid array16 2
-    ok 58 - invalid array32 1
-    ok 59 - invalid array32 2
-    ok 60 - invalid map16 1
-    ok 61 - invalid map16 2
-    ok 62 - invalid map16 2
-    ok 63 - invalid map32 1
-    ok 64 - invalid map32 2
-    ok 65 - invalid map32 3
-    # *** test_mp_check: done ***
-ok 20 - subtests
-    1..96
-    # *** test_numbers ***
-    ok 1 - mp_read_int32(mp_encode_uint(123)) check success
-    ok 2 - mp_read_int32(mp_encode_uint(123)) check pos advanced
-    ok 3 - mp_read_int32(mp_encode_uint(123)) check result
-    ok 4 - mp_read_int32(mp_encode_uint(12345)) check success
-    ok 5 - mp_read_int32(mp_encode_uint(12345)) check pos advanced
-    ok 6 - mp_read_int32(mp_encode_uint(12345)) check result
-    ok 7 - mp_read_int32(mp_encode_uint(2147483647)) check success
-    ok 8 - mp_read_int32(mp_encode_uint(2147483647)) check pos advanced
-    ok 9 - mp_read_int32(mp_encode_uint(2147483647)) check result
-    ok 10 - mp_read_int32(mp_encode_uint(2147483648)) check fail
-    ok 11 - mp_read_int32(mp_encode_uint(2147483648)) check pos unchanged
-    ok 12 - mp_read_int32(mp_encode_int(-123)) check success
-    ok 13 - mp_read_int32(mp_encode_int(-123)) check pos advanced
-    ok 14 - mp_read_int32(mp_encode_int(-123)) check result
-    ok 15 - mp_read_int32(mp_encode_int(-12345)) check success
-    ok 16 - mp_read_int32(mp_encode_int(-12345)) check pos advanced
-    ok 17 - mp_read_int32(mp_encode_int(-12345)) check result
-    ok 18 - mp_read_int32(mp_encode_int(-2147483648)) check success
-    ok 19 - mp_read_int32(mp_encode_int(-2147483648)) check pos advanced
-    ok 20 - mp_read_int32(mp_encode_int(-2147483648)) check result
-    ok 21 - mp_read_int32(mp_encode_int(-2147483649LL)) check fail
-    ok 22 - mp_read_int32(mp_encode_int(-2147483649LL)) check pos unchanged
-    ok 23 - mp_read_int32(mp_encode_float(-1e2)) check fail
-    ok 24 - mp_read_int32(mp_encode_float(-1e2)) check pos unchanged
-    ok 25 - mp_read_int32(mp_encode_double(1.2345)) check fail
-    ok 26 - mp_read_int32(mp_encode_double(1.2345)) check pos unchanged
-    ok 27 - mp_read_int32(mp_encode_map(5)) check fail
-    ok 28 - mp_read_int32(mp_encode_map(5)) check pos unchanged
-    ok 29 - mp_read_int64(mp_encode_uint(123)) check success
-    ok 30 - mp_read_int64(mp_encode_uint(123)) check pos advanced
-    ok 31 - mp_read_int64(mp_encode_uint(123)) check result
-    ok 32 - mp_read_int64(mp_encode_uint(12345)) check success
-    ok 33 - mp_read_int64(mp_encode_uint(12345)) check pos advanced
-    ok 34 - mp_read_int64(mp_encode_uint(12345)) check result
-    ok 35 - mp_read_int64(mp_encode_uint(123456789)) check success
-    ok 36 - mp_read_int64(mp_encode_uint(123456789)) check pos advanced
-    ok 37 - mp_read_int64(mp_encode_uint(123456789)) check result
-    ok 38 - mp_read_int64(mp_encode_uint(9223372036854775807ULL)) check success
-    ok 39 - mp_read_int64(mp_encode_uint(9223372036854775807ULL)) check pos advanced
-    ok 40 - mp_read_int64(mp_encode_uint(9223372036854775807ULL)) check result
-    ok 41 - mp_read_int64(mp_encode_uint(9223372036854775808ULL)) check fail
-    ok 42 - mp_read_int64(mp_encode_uint(9223372036854775808ULL)) check pos unchanged
-    ok 43 - mp_read_int64(mp_encode_int(-123)) check success
-    ok 44 - mp_read_int64(mp_encode_int(-123)) check pos advanced
-    ok 45 - mp_read_int64(mp_encode_int(-123)) check result
-    ok 46 - mp_read_int64(mp_encode_int(-12345)) check success
-    ok 47 - mp_read_int64(mp_encode_int(-12345)) check pos advanced
-    ok 48 - mp_read_int64(mp_encode_int(-12345)) check result
-    ok 49 - mp_read_int64(mp_encode_int(-123456789)) check success
-    ok 50 - mp_read_int64(mp_encode_int(-123456789)) check pos advanced
-    ok 51 - mp_read_int64(mp_encode_int(-123456789)) check result
-    ok 52 - mp_read_int64(mp_encode_int(-9223372036854775807LL)) check success
-    ok 53 - mp_read_int64(mp_encode_int(-9223372036854775807LL)) check pos advanced
-    ok 54 - mp_read_int64(mp_encode_int(-9223372036854775807LL)) check result
-    ok 55 - mp_read_int64(mp_encode_float(100)) check fail
-    ok 56 - mp_read_int64(mp_encode_float(100)) check pos unchanged
-    ok 57 - mp_read_int64(mp_encode_double(-5.4321)) check fail
-    ok 58 - mp_read_int64(mp_encode_double(-5.4321)) check pos unchanged
-    ok 59 - mp_read_int64(mp_encode_array(10)) check fail
-    ok 60 - mp_read_int64(mp_encode_array(10)) check pos unchanged
-    ok 61 - mp_read_double(mp_encode_uint(123)) check success
-    ok 62 - mp_read_double(mp_encode_uint(123)) check pos advanced
-    ok 63 - mp_read_double(mp_encode_uint(123)) check result
-    ok 64 - mp_read_double(mp_encode_uint(12345)) check success
-    ok 65 - mp_read_double(mp_encode_uint(12345)) check pos advanced
-    ok 66 - mp_read_double(mp_encode_uint(12345)) check result
-    ok 67 - mp_read_double(mp_encode_uint(123456789)) check success
-    ok 68 - mp_read_double(mp_encode_uint(123456789)) check pos advanced
-    ok 69 - mp_read_double(mp_encode_uint(123456789)) check result
-    ok 70 - mp_read_double(mp_encode_uint(1234567890000ULL)) check success
-    ok 71 - mp_read_double(mp_encode_uint(1234567890000ULL)) check pos advanced
-    ok 72 - mp_read_double(mp_encode_uint(1234567890000ULL)) check result
-    ok 73 - mp_read_double(mp_encode_uint(123456789123456789ULL)) check fail
-    ok 74 - mp_read_double(mp_encode_uint(123456789123456789ULL)) check pos unchanged
-    ok 75 - mp_read_double(mp_encode_int(-123)) check success
-    ok 76 - mp_read_double(mp_encode_int(-123)) check pos advanced
-    ok 77 - mp_read_double(mp_encode_int(-123)) check result
-    ok 78 - mp_read_double(mp_encode_int(-12345)) check success
-    ok 79 - mp_read_double(mp_encode_int(-12345)) check pos advanced
-    ok 80 - mp_read_double(mp_encode_int(-12345)) check result
-    ok 81 - mp_read_double(mp_encode_int(-123456789)) check success
-    ok 82 - mp_read_double(mp_encode_int(-123456789)) check pos advanced
-    ok 83 - mp_read_double(mp_encode_int(-123456789)) check result
-    ok 84 - mp_read_double(mp_encode_int(-1234567890000LL)) check success
-    ok 85 - mp_read_double(mp_encode_int(-1234567890000LL)) check pos advanced
-    ok 86 - mp_read_double(mp_encode_int(-1234567890000LL)) check result
-    ok 87 - mp_read_double(mp_encode_int(-123456789123456789LL)) check fail
-    ok 88 - mp_read_double(mp_encode_int(-123456789123456789LL)) check pos unchanged
-    ok 89 - mp_read_double(mp_encode_float(6.565e6)) check success
-    ok 90 - mp_read_double(mp_encode_float(6.565e6)) check pos advanced
-    ok 91 - mp_read_double(mp_encode_float(6.565e6)) check result
-    ok 92 - mp_read_double(mp_encode_double(-5.555)) check success
-    ok 93 - mp_read_double(mp_encode_double(-5.555)) check pos advanced
-    ok 94 - mp_read_double(mp_encode_double(-5.555)) check result
-    ok 95 - mp_read_double(mp_encode_strl(100)) check fail
-    ok 96 - mp_read_double(mp_encode_strl(100)) check pos unchanged
-    # *** test_numbers: done ***
-ok 21 - subtests
-    1..4
-    # *** test_overflow ***
-    ok 1 - mp_check array overflow
-    ok 2 - mp_check map overflow
-    ok 3 - mp_check str overflow
-    ok 4 - mp_check bin overflow
-    # *** test_overflow: done ***
-ok 22 - subtests
diff --git a/test/unit/popen.result b/test/unit/popen.result
deleted file mode 100644
index f5e6bc2ca..000000000
--- a/test/unit/popen.result
+++ /dev/null
@@ -1,30 +0,0 @@
-1..3
-	*** main_f ***
-    1..6
-	*** popen_write_exit ***
-    ok 1 - popen_new
-    ok 2 - state alive
-    ok 3 - write flag check
-    ok 4 - write to pipe
-    ok 5 - child exited
-    ok 6 - popen_delete
-	*** popen_write_exit: done ***
-ok 1 - subtests
-    1..5
-	*** popen_read_exit ***
-    ok 1 - popen_new
-    ok 2 - child exited
-    ok 3 - read flag check
-    ok 4 - read from pipe
-    ok 5 - popen_delete
-	*** popen_read_exit: done ***
-ok 2 - subtests
-    1..4
-	*** popen_kill ***
-    ok 1 - popen_new
-    ok 2 - popen_send_signal
-    ok 3 - child terminated
-    ok 4 - popen_delete
-	*** popen_kill: done ***
-ok 3 - subtests
-	*** main_f: done ***
diff --git a/test/unit/queue.c b/test/unit/queue.c
index 3caec1a41..d8bea5f78 100644
--- a/test/unit/queue.c
+++ b/test/unit/queue.c
@@ -31,7 +31,6 @@
 #include "third_party/queue.h"
 #include "unit.h"
 #include <stdio.h>
-#include <assert.h>
 
 struct elem
 {
@@ -58,12 +57,15 @@ queue2str(struct elem_queue *queue)
 void test0()
 {
 	header();
+	plan(1);
 	struct elem_queue queue = STAILQ_HEAD_INITIALIZER(queue);
-	printf("Initialized: %s\n", queue2str(&queue));
+	note("Initialized: %s", queue2str(&queue));
 	STAILQ_INIT(&queue);
-	printf("STAILQ_INIT: %s\n", queue2str(&queue));
+	note("STAILQ_INIT: %s", queue2str(&queue));
 	STAILQ_REVERSE(&queue, elem, entry);
-	printf("STAILQ_REVERSE: %s\n", queue2str(&queue));
+	note("STAILQ_REVERSE: %s", queue2str(&queue));
+	ok(1, "test 0");
+	check_plan();
 	footer();
 }
 
@@ -71,13 +73,16 @@ void test0()
 void test1()
 {
 	header();
+	plan(1);
 	struct elem el1;
 	struct elem_queue queue = STAILQ_HEAD_INITIALIZER(queue);
 	el1.val = 1;
 	STAILQ_INSERT_TAIL(&queue, &el1, entry);
-	printf("STAILQ_INIT: %s\n", queue2str(&queue));
+	note("STAILQ_INIT: %s", queue2str(&queue));
 	STAILQ_REVERSE(&queue, elem, entry);
-	printf("STAILQ_REVERSE: %s\n", queue2str(&queue));
+	note("STAILQ_REVERSE: %s", queue2str(&queue));
+	ok(1, "test 1");
+	check_plan();
 	footer();
 }
 
@@ -85,21 +90,25 @@ void test1()
 void test2()
 {
 	header();
+	plan(1);
 	struct elem el1, el2;
 	struct elem_queue queue = STAILQ_HEAD_INITIALIZER(queue);
 	el1.val = 1;
 	el2.val = 2;
 	STAILQ_INSERT_TAIL(&queue, &el1, entry);
 	STAILQ_INSERT_TAIL(&queue, &el2, entry);
-	printf("STAILQ_INIT: %s\n", queue2str(&queue));
+	note("STAILQ_INIT: %s", queue2str(&queue));
 	STAILQ_REVERSE(&queue, elem, entry);
-	printf("STAILQ_REVERSE: %s\n", queue2str(&queue));
+	note("STAILQ_REVERSE: %s", queue2str(&queue));
+	ok(1, "test 2");
+	check_plan();
 	footer();
 }
 
 void test3()
 {
 	header();
+	plan(1);
 	struct elem el1, el2, el3;
 	struct elem_queue queue = STAILQ_HEAD_INITIALIZER(queue);
 	el1.val = 1;
@@ -108,9 +117,11 @@ void test3()
 	STAILQ_INSERT_TAIL(&queue, &el1, entry);
 	STAILQ_INSERT_TAIL(&queue, &el2, entry);
 	STAILQ_INSERT_TAIL(&queue, &el3, entry);
-	printf("STAILQ_INIT: %s\n", queue2str(&queue));
+	note("STAILQ_INIT: %s", queue2str(&queue));
 	STAILQ_REVERSE(&queue, elem, entry);
-	printf("STAILQ_REVERSE: %s\n", queue2str(&queue));
+	note("STAILQ_REVERSE: %s", queue2str(&queue));
+	ok(1, "test 3");
+	check_plan();
 	footer();
 }
 
@@ -118,48 +129,52 @@ void test3()
 void test_splice()
 {
 	header();
+	plan(1);
 	struct elem el1, el2, el3;
 	struct elem_queue queue1 = STAILQ_HEAD_INITIALIZER(queue1);
 	struct elem_queue queue2 = STAILQ_HEAD_INITIALIZER(queue2);
 	STAILQ_SPLICE(&queue1, STAILQ_FIRST(&queue1), entry, &queue2);
-	printf("q1: %s\n", queue2str(&queue1));
-	printf("q2: %s\n", queue2str(&queue2));
+	note("q1: %s", queue2str(&queue1));
+	note("q2: %s", queue2str(&queue2));
 	STAILQ_SPLICE(&queue2, STAILQ_FIRST(&queue2), entry, &queue1);
-	printf("q1: %s\n", queue2str(&queue1));
-	printf("q2: %s\n", queue2str(&queue2));
+	note("q1: %s", queue2str(&queue1));
+	note("q2: %s", queue2str(&queue2));
 	el1.val = 1;
 	el2.val = 2;
 	el3.val = 3;
 	STAILQ_INSERT_TAIL(&queue1, &el1, entry);
 	STAILQ_INSERT_TAIL(&queue1, &el2, entry);
 	STAILQ_INSERT_TAIL(&queue1, &el3, entry);
-	printf("STAILQ_INIT: %s\n", queue2str(&queue1));
+	note("STAILQ_INIT: %s", queue2str(&queue1));
 	STAILQ_SPLICE(&queue1, STAILQ_FIRST(&queue1), entry, &queue2);
-	printf("q1: %s\n", queue2str(&queue1));
-	printf("q2: %s\n", queue2str(&queue2));
+	note("q1: %s", queue2str(&queue1));
+	note("q2: %s", queue2str(&queue2));
 	STAILQ_SPLICE(&queue2, STAILQ_FIRST(&queue2), entry, &queue1);
-	printf("q1: %s\n", queue2str(&queue1));
-	printf("q2: %s\n", queue2str(&queue2));
+	note("q1: %s", queue2str(&queue1));
+	note("q2: %s", queue2str(&queue2));
 	STAILQ_SPLICE(&queue1, STAILQ_NEXT(STAILQ_FIRST(&queue1), entry),
 					   entry, &queue2);
-	printf("q1: %s\n", queue2str(&queue1));
-	printf("q2: %s\n", queue2str(&queue2));
+	note("q1: %s", queue2str(&queue1));
+	note("q2: %s", queue2str(&queue2));
 	STAILQ_SPLICE(&queue2, STAILQ_NEXT(STAILQ_FIRST(&queue2), entry),
 		      entry, &queue1);
-	printf("q1: %s\n", queue2str(&queue1));
-	printf("q2: %s\n", queue2str(&queue2));
+	note("q1: %s", queue2str(&queue1));
+	note("q2: %s", queue2str(&queue2));
 	STAILQ_SPLICE(&queue2, STAILQ_FIRST(&queue2), entry, &queue1);
-	printf("q1: %s\n", queue2str(&queue1));
-	printf("q2: %s\n", queue2str(&queue2));
+	note("q1: %s", queue2str(&queue1));
+	note("q2: %s", queue2str(&queue2));
+	ok(1, "test splice");
 	footer();
 }
 
 int main()
 {
+	plan(5);
 	test0();
 	test1();
 	test2();
 	test3();
 	test_splice();
+	check_plan();
 	return 0;
 }
diff --git a/test/unit/queue.result b/test/unit/queue.result
deleted file mode 100644
index 18b0c0758..000000000
--- a/test/unit/queue.result
+++ /dev/null
@@ -1,34 +0,0 @@
-	*** test0 ***
-Initialized: 
-STAILQ_INIT: 
-STAILQ_REVERSE: 
-	*** test0: done ***
-	*** test1 ***
-STAILQ_INIT: 1 
-STAILQ_REVERSE: 1 
-	*** test1: done ***
-	*** test2 ***
-STAILQ_INIT: 1 2 
-STAILQ_REVERSE: 2 1 
-	*** test2: done ***
-	*** test3 ***
-STAILQ_INIT: 1 2 3 
-STAILQ_REVERSE: 3 2 1 
-	*** test3: done ***
-	*** test_splice ***
-q1: 
-q2: 
-q1: 
-q2: 
-STAILQ_INIT: 1 2 3 
-q1: 
-q2: 1 2 3 
-q1: 1 2 3 
-q2: 
-q1: 1 
-q2: 2 3 
-q1: 1 3 
-q2: 2 
-q1: 1 3 2 
-q2: 
-	*** test_splice: done ***
diff --git a/test/unit/ratelimit.result b/test/unit/ratelimit.result
deleted file mode 100644
index 8a755c64d..000000000
--- a/test/unit/ratelimit.result
+++ /dev/null
@@ -1,13 +0,0 @@
-	*** main ***
-1..10
-ok 1 - emitted 10 expected 10
-ok 2 - suppressed 0 expected 0
-ok 3 - emitted 0 expected 0
-ok 4 - suppressed 0 expected 0
-ok 5 - emitted 1 expected 1
-ok 6 - suppressed 10 expected 10
-ok 7 - emitted 1 expected 1
-ok 8 - suppressed 0 expected 0
-ok 9 - emitted 1000 expected 1000
-ok 10 - suppressed 3000 expected 3000
-	*** main: done ***
diff --git a/test/unit/reflection_c.result b/test/unit/reflection_c.result
deleted file mode 100644
index 294fa9799..000000000
--- a/test/unit/reflection_c.result
+++ /dev/null
@@ -1,5 +0,0 @@
-1..4
-ok 1 - assignable
-ok 2 - assignable
-ok 3 - assignable
-ok 4 - assignable
diff --git a/test/unit/reflection_cxx.result b/test/unit/reflection_cxx.result
deleted file mode 100644
index 0f4f51eb4..000000000
--- a/test/unit/reflection_cxx.result
+++ /dev/null
@@ -1,31 +0,0 @@
-1..30
-ok 1 - type.name
-ok 2 - type.parent
-ok 3 - type.parent
-ok 4 - is_instance
-ok 5 - is_instance
-ok 6 - is_instance
-ok 7 - is_instance
-ok 8 - methods order
-ok 9 - methods order
-ok 10 - methods order
-ok 11 - methods order
-ok 12 - methods order
-ok 13 - method.owner
-ok 14 - method.name
-ok 15 - method.rtype (non void)
-ok 16 - method.rtype (void)
-ok 17 - method.nargs (zero)
-ok 18 - method.nargs (non-zero)
-ok 19 - method.atype
-ok 20 - method.isconst
-ok 21 - !method.isconst
-ok 22 - !invokable<invalid args>
-ok 23 - !invokable<extra args>
-ok 24 - !invokable<>(invalid object)
-ok 25 - invokable<const char *>
-ok 26 - invokable<void, const char *>
-ok 27 - invoke (int)
-ok 28 - invoke (const char *)
-ok 29 - invoke (void)
-ok 30 - !invokable<>() on const method with non-const object
diff --git a/test/unit/rmean.cc b/test/unit/rmean.cc
index 50db96f6d..6f8667284 100644
--- a/test/unit/rmean.cc
+++ b/test/unit/rmean.cc
@@ -5,7 +5,7 @@
 
 int print_stat(const char *name, int rps, int64_t total, void* ctx)
 {
-	printf("%s: rps %d, total %d%c", name, rps, (int)total,
+	note("%s: rps %d, total %d%c", name, rps, (int)total,
 	       name[2] == '2' ? '\n' : '\t');
 	return 0;
 }
@@ -13,8 +13,9 @@ int print_stat(const char *name, int rps, int64_t total, void* ctx)
 void test_100rps(rmean *st)
 {
 	header();
-	printf("Send 100 requests every second for 10 seconds\n");
-	printf("Calc rps at third and last second\n");
+	plan(1);
+	note("Send 100 requests every second for 10 seconds");
+	note("Calc rps at third and last second");
 	for(int i = 0; i < 10; i++) { /* 10 seconds */
 		rmean_collect(st, 0, 100); /* send 100 requests */
 		rmean_roll(st->stats[0].value, 1);
@@ -29,13 +30,16 @@ void test_100rps(rmean *st)
 		}
 	}
 	/* 10 seconds, 1000 in EV1, 100 rps */
+	ok(1, "test 100rps");
+	check_plan();
 	footer();
 }
 
 void test_mean15rps(rmean *st)
 {
 	header();
-	printf("Send 15 rps on the average, and 3 rps to EV2\n");
+	plan(1);
+	note("Send 15 rps on the average, and 3 rps to EV2");
 	for(int i = 0; i < 10; i++) { /* 10 seconds */
 		for(int j = 0; j < 15; j++) {
 			rmean_collect(st, 0, 1); /* send 15 requests */
@@ -53,12 +57,15 @@ void test_mean15rps(rmean *st)
 		   rmean_mean(st, 1),
 		   rmean_total(st, 1), NULL);
 	/* 10 seconds, 1000 + 150 in EV1, 15 rps. 30 in EV2, 3 rps*/
+	ok(1, "test mean15rps");
 	footer();
+	check_plan();
 }
 
 int main()
 {
-	printf("Stat. 2 names, timer simulation\n");
+	plan(2);
+	note("Stat. 2 names, timer simulation");
 
 	memory_init();
 	fiber_init(fiber_cxx_invoke);
@@ -74,5 +81,7 @@ int main()
 
 	fiber_free();
 	memory_free();
+	check_plan();
+
 	return 0;
 }
diff --git a/test/unit/rmean.result b/test/unit/rmean.result
deleted file mode 100644
index ce050f050..000000000
--- a/test/unit/rmean.result
+++ /dev/null
@@ -1,11 +0,0 @@
-Stat. 2 names, timer simulation
-	*** test_100rps ***
-Send 100 requests every second for 10 seconds
-Calc rps at third and last second
-EV1: rps 60, total 300	EV2: rps 0, total 0
-EV1: rps 100, total 1000	EV2: rps 0, total 0
-	*** test_100rps: done ***
-	*** test_mean15rps ***
-Send 15 rps on the average, and 3 rps to EV2
-EV1: rps 15, total 1150	EV2: rps 3, total 30
-	*** test_mean15rps: done ***
diff --git a/test/unit/rope.c b/test/unit/rope.c
index 5ab4c51f7..e86c94155 100644
--- a/test/unit/rope.c
+++ b/test/unit/rope.c
@@ -4,7 +4,7 @@
 static void
 test_rope_extract(struct rope *rope, rope_size_t pos)
 {
-	printf("extract pos = %zu: ", (size_t) pos);
+	printf("# extract pos = %zu: ", (size_t) pos);
 	struct rope_node *node = rope_extract_node(rope, pos);
 	rope_check(rope);
 	str_print(node->data, node->leaf_size);
@@ -14,10 +14,10 @@ test_rope_extract(struct rope *rope, rope_size_t pos)
 static inline void
 test_rope_cut(struct rope *rope, rope_size_t offset, rope_size_t size)
 {
-	printf("erase offset = %zu, size = %zu \n", (size_t) offset, (size_t) size);
+	note("erase offset = %zu, size = %zu", (size_t) offset, (size_t) size);
 	while (size-- > 0)
 		rope_erase(rope, offset);
-	rope_pretty_print(rope, str_print);
+	/* rope_pretty_print(rope, str_print); */
 	rope_check(rope);
 }
 
@@ -58,11 +58,15 @@ test_rope()
 	test_rope_extract(rope, 124);
 
 	rope_delete(rope);
+	ok(1, "test rope");
+	check_plan();
 }
 
 int
 main()
 {
+	plan(1);
 	test_rope();
+	check_plan();
 	return 0;
 }
diff --git a/test/unit/rope.result b/test/unit/rope.result
deleted file mode 100644
index 996063800..000000000
--- a/test/unit/rope.result
+++ /dev/null
@@ -1,299 +0,0 @@
-insert offset = 0, str = 'who's gonna be'
-size = 14
-string = 'who's gonna be'
-└──{ len = 14, height = 1, data = 'who's gonna be'}
-
-insert offset = 14, str = '<Mr.X>'
-size = 20
-string = 'who's gonna be<Mr.X>'
-│  ┌──nil
-└──{ len = 14, height = 2, data = 'who's gonna be'}
-   └──{ len = 6, height = 1, data = '<Mr.X>'}
-
-insert offset = 20, str = ', Mr. <black!?!>Black'
-size = 41
-string = 'who's gonna be<Mr.X>, Mr. <black!?!>Black'
-│  ┌──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 6, height = 2, data = '<Mr.X>'}
-   └──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
-
-insert offset = 41, str = ', but they <know-something-'
-size = 68
-string = 'who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-'
-│  ┌──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 6, height = 3, data = '<Mr.X>'}
-   │  ┌──nil
-   └──{ len = 21, height = 2, data = ', Mr. <black!?!>Black'}
-      └──{ len = 27, height = 1, data = ', but they <know-something-'}
-
-insert offset = 0, str = 'guys all '
-size = 77
-string = 'guys all who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-'
-│     ┌──{ len = 9, height = 1, data = 'guys all '}
-│  ┌──{ len = 14, height = 2, data = 'who's gonna be'}
-│  │  └──nil
-└──{ len = 6, height = 3, data = '<Mr.X>'}
-   │  ┌──nil
-   └──{ len = 21, height = 2, data = ', Mr. <black!?!>Black'}
-      └──{ len = 27, height = 1, data = ', but they <know-something-'}
-
-insert offset = 9, str = 'five fighting over '
-size = 96
-string = 'guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-'
-│     ┌──{ len = 9, height = 1, data = 'guys all '}
-│  ┌──{ len = 19, height = 2, data = 'five fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 6, height = 3, data = '<Mr.X>'}
-   │  ┌──nil
-   └──{ len = 21, height = 2, data = ', Mr. <black!?!>Black'}
-      └──{ len = 27, height = 1, data = ', but they <know-something-'}
-
-insert offset = 0, str = '<yes, got got>You got four of '
-size = 126
-string = '<yes, got got>You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-'
-│        ┌──{ len = 30, height = 1, data = '<yes, got got>You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 6, height = 4, data = '<Mr.X>'}
-   │  ┌──nil
-   └──{ len = 21, height = 2, data = ', Mr. <black!?!>Black'}
-      └──{ len = 27, height = 1, data = ', but they <know-something-'}
-
-insert offset = 126, str = 'special> don't know each other'
-size = 156
-string = '<yes, got got>You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other'
-│        ┌──{ len = 30, height = 1, data = '<yes, got got>You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 6, height = 4, data = '<Mr.X>'}
-   │  ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
-   └──{ len = 27, height = 2, data = ', but they <know-something-'}
-      └──{ len = 30, height = 1, data = 'special> don't know each other'}
-
-insert offset = 4294967295, str = ', so nobody wants to back.'
-size = 182
-string = '<yes, got got>You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back.'
-│        ┌──{ len = 30, height = 1, data = '<yes, got got>You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 6, height = 4, data = '<Mr.X>'}
-   │  ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
-   └──{ len = 27, height = 3, data = ', but they <know-something-'}
-      │  ┌──nil
-      └──{ len = 30, height = 2, data = 'special> don't know each other'}
-         └──{ len = 26, height = 1, data = ', so nobody wants to back.'}
-
-insert offset = 181, str = ' down'
-size = 187
-string = '<yes, got got>You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.'
-│        ┌──{ len = 30, height = 1, data = '<yes, got got>You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 6, height = 4, data = '<Mr.X>'}
-   │     ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
-   │  ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
-   │  │  └──nil
-   └──{ len = 30, height = 3, data = 'special> don't know each other'}
-      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
-      └──{ len = 5, height = 2, data = ' down'}
-         └──{ len = 1, height = 1, data = '.'}
-
-insert offset = 4294967295, str = '<point-point>'
-size = 200
-string = '<yes, got got>You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.<point-point>'
-│        ┌──{ len = 30, height = 1, data = '<yes, got got>You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 6, height = 5, data = '<Mr.X>'}
-   │     ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
-   │  ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
-   │  │  └──nil
-   └──{ len = 30, height = 4, data = 'special> don't know each other'}
-      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
-      └──{ len = 5, height = 3, data = ' down'}
-         │  ┌──nil
-         └──{ len = 1, height = 2, data = '.'}
-            └──{ len = 13, height = 1, data = '<point-point>'}
-
-erase offset = 0, size = 5 
-size = 195
-string = ' got got>You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.<point-point>'
-│        ┌──{ len = 25, height = 1, data = ' got got>You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 6, height = 5, data = '<Mr.X>'}
-   │     ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
-   │  ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
-   │  │  └──nil
-   └──{ len = 30, height = 4, data = 'special> don't know each other'}
-      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
-      └──{ len = 5, height = 3, data = ' down'}
-         │  ┌──nil
-         └──{ len = 1, height = 2, data = '.'}
-            └──{ len = 13, height = 1, data = '<point-point>'}
-
-erase offset = 0, size = 9 
-size = 186
-string = 'You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.<point-point>'
-│        ┌──{ len = 16, height = 1, data = 'You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 6, height = 5, data = '<Mr.X>'}
-   │     ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
-   │  ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
-   │  │  └──nil
-   └──{ len = 30, height = 4, data = 'special> don't know each other'}
-      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
-      └──{ len = 5, height = 3, data = ' down'}
-         │  ┌──nil
-         └──{ len = 1, height = 2, data = '.'}
-            └──{ len = 13, height = 1, data = '<point-point>'}
-
-erase offset = 179, size = 7 
-size = 179
-string = 'You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.<point'
-│        ┌──{ len = 16, height = 1, data = 'You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 6, height = 5, data = '<Mr.X>'}
-   │     ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
-   │  ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
-   │  │  └──nil
-   └──{ len = 30, height = 4, data = 'special> don't know each other'}
-      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
-      └──{ len = 5, height = 3, data = ' down'}
-         │  ┌──{ len = 1, height = 1, data = '.'}
-         └──{ len = 6, height = 2, data = '<point'}
-            └──nil
-
-erase offset = 173, size = 1 
-size = 178
-string = 'You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.point'
-│        ┌──{ len = 16, height = 1, data = 'You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 6, height = 5, data = '<Mr.X>'}
-   │     ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
-   │  ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
-   │  │  └──nil
-   └──{ len = 30, height = 4, data = 'special> don't know each other'}
-      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
-      └──{ len = 5, height = 3, data = ' down'}
-         │  ┌──{ len = 1, height = 1, data = '.'}
-         └──{ len = 5, height = 2, data = 'point'}
-            └──nil
-
-erase offset = 58, size = 7 
-size = 171
-string = 'You got four of guys all five fighting over who's gonna be Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.point'
-│        ┌──{ len = 16, height = 1, data = 'You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 20, height = 4, data = ' Mr. <black!?!>Black'}
-   │     ┌──{ len = 27, height = 1, data = ', but they <know-something-'}
-   │  ┌──{ len = 30, height = 2, data = 'special> don't know each other'}
-   │  │  └──{ len = 25, height = 1, data = ', so nobody wants to back'}
-   └──{ len = 5, height = 3, data = ' down'}
-      │  ┌──{ len = 1, height = 1, data = '.'}
-      └──{ len = 5, height = 2, data = 'point'}
-         └──nil
-
-erase offset = 63, size = 10 
-size = 161
-string = 'You got four of guys all five fighting over who's gonna be Mr. Black, but they <know-something-special> don't know each other, so nobody wants to back down.point'
-│        ┌──{ len = 16, height = 1, data = 'You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 5, height = 5, data = ' Mr. '}
-   │        ┌──{ len = 5, height = 1, data = 'Black'}
-   │     ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
-   │     │  └──nil
-   │  ┌──{ len = 30, height = 3, data = 'special> don't know each other'}
-   │  │  └──{ len = 25, height = 1, data = ', so nobody wants to back'}
-   └──{ len = 5, height = 4, data = ' down'}
-      │  ┌──{ len = 1, height = 1, data = '.'}
-      └──{ len = 5, height = 2, data = 'point'}
-         └──nil
-
-erase offset = 79, size = 25 
-size = 136
-string = 'You got four of guys all five fighting over who's gonna be Mr. Black, but they don't know each other, so nobody wants to back down.point'
-│        ┌──{ len = 16, height = 1, data = 'You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 5, height = 5, data = ' Mr. '}
-   │        ┌──{ len = 5, height = 1, data = 'Black'}
-   │     ┌──{ len = 11, height = 2, data = ', but they '}
-   │     │  └──nil
-   │  ┌──{ len = 21, height = 3, data = 'don't know each other'}
-   │  │  └──{ len = 25, height = 1, data = ', so nobody wants to back'}
-   └──{ len = 5, height = 4, data = ' down'}
-      │  ┌──{ len = 1, height = 1, data = '.'}
-      └──{ len = 5, height = 2, data = 'point'}
-         └──nil
-
-erase offset = 25, size = 5 
-size = 131
-string = 'You got four of guys all fighting over who's gonna be Mr. Black, but they don't know each other, so nobody wants to back down.point'
-│        ┌──{ len = 16, height = 1, data = 'You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 14, height = 3, data = 'fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 5, height = 5, data = ' Mr. '}
-   │        ┌──{ len = 5, height = 1, data = 'Black'}
-   │     ┌──{ len = 11, height = 2, data = ', but they '}
-   │     │  └──nil
-   │  ┌──{ len = 21, height = 3, data = 'don't know each other'}
-   │  │  └──{ len = 25, height = 1, data = ', so nobody wants to back'}
-   └──{ len = 5, height = 4, data = ' down'}
-      │  ┌──{ len = 1, height = 1, data = '.'}
-      └──{ len = 5, height = 2, data = 'point'}
-         └──nil
-
-erase offset = 126, size = 5 
-size = 126
-string = 'You got four of guys all fighting over who's gonna be Mr. Black, but they don't know each other, so nobody wants to back down.'
-│        ┌──{ len = 16, height = 1, data = 'You got four of '}
-│     ┌──{ len = 9, height = 2, data = 'guys all '}
-│     │  └──nil
-│  ┌──{ len = 14, height = 3, data = 'fighting over '}
-│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
-└──{ len = 5, height = 4, data = ' Mr. '}
-   │     ┌──{ len = 5, height = 1, data = 'Black'}
-   │  ┌──{ len = 11, height = 2, data = ', but they '}
-   │  │  └──nil
-   └──{ len = 21, height = 3, data = 'don't know each other'}
-      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
-      └──{ len = 5, height = 2, data = ' down'}
-         └──{ len = 1, height = 1, data = '.'}
-
-extract pos = 0: You got four of 
-extract pos = 5: ot four of 
-extract pos = 19: s all 
-extract pos = 59: lack
-extract pos = 124: n
diff --git a/test/unit/rope_avl.c b/test/unit/rope_avl.c
index b095fb1a6..cfefd2e48 100644
--- a/test/unit/rope_avl.c
+++ b/test/unit/rope_avl.c
@@ -7,6 +7,7 @@ static void
 test_avl_rotations()
 {
 	header();
+	plan(1);
 
 	struct rope *rope = test_rope_new();
 
@@ -29,6 +30,8 @@ test_avl_rotations()
 	test_rope_insert(rope, 3, "*");
 
 	rope_delete(rope);
+	ok(1, "test avl rotations");
+	check_plan();
 
 	footer();
 }
@@ -36,6 +39,8 @@ test_avl_rotations()
 int
 main()
 {
+	plan(1);
 	test_avl_rotations();
+	check_plan();
 	return 0;
 }
diff --git a/test/unit/rope_avl.result b/test/unit/rope_avl.result
deleted file mode 100644
index 141ffe967..000000000
--- a/test/unit/rope_avl.result
+++ /dev/null
@@ -1,123 +0,0 @@
-	*** test_avl_rotations ***
-insert offset = 0, str = '1'
-size = 1
-string = '1'
-└──{ len = 1, height = 1, data = '1'}
-
-insert offset = 1, str = '2'
-size = 2
-string = '12'
-│  ┌──nil
-└──{ len = 1, height = 2, data = '1'}
-   └──{ len = 1, height = 1, data = '2'}
-
-insert offset = 2, str = '<'
-size = 3
-string = '12<'
-│  ┌──{ len = 1, height = 1, data = '1'}
-└──{ len = 1, height = 2, data = '2'}
-   └──{ len = 1, height = 1, data = '<'}
-
-insert offset = 0, str = '0'
-size = 4
-string = '012<'
-│     ┌──{ len = 1, height = 1, data = '0'}
-│  ┌──{ len = 1, height = 2, data = '1'}
-│  │  └──nil
-└──{ len = 1, height = 3, data = '2'}
-   └──{ len = 1, height = 1, data = '<'}
-
-insert offset = 0, str = '>'
-size = 5
-string = '>012<'
-│     ┌──{ len = 1, height = 1, data = '>'}
-│  ┌──{ len = 1, height = 2, data = '0'}
-│  │  └──{ len = 1, height = 1, data = '1'}
-└──{ len = 1, height = 3, data = '2'}
-   └──{ len = 1, height = 1, data = '<'}
-
-insert offset = 1, str = '*'
-size = 6
-string = '>*012<'
-│     ┌──nil
-│  ┌──{ len = 1, height = 2, data = '>'}
-│  │  └──{ len = 1, height = 1, data = '*'}
-└──{ len = 1, height = 3, data = '0'}
-   │  ┌──{ len = 1, height = 1, data = '1'}
-   └──{ len = 1, height = 2, data = '2'}
-      └──{ len = 1, height = 1, data = '<'}
-
-insert offset = 3, str = 'p'
-size = 7
-string = '>*0p12<'
-│     ┌──nil
-│  ┌──{ len = 1, height = 2, data = '>'}
-│  │  └──{ len = 1, height = 1, data = '*'}
-└──{ len = 1, height = 4, data = '0'}
-   │     ┌──{ len = 1, height = 1, data = 'p'}
-   │  ┌──{ len = 1, height = 2, data = '1'}
-   │  │  └──nil
-   └──{ len = 1, height = 3, data = '2'}
-      └──{ len = 1, height = 1, data = '<'}
-
-insert offset = 3, str = 'p'
-size = 8
-string = '>*0pp12<'
-│     ┌──nil
-│  ┌──{ len = 1, height = 2, data = '>'}
-│  │  └──{ len = 1, height = 1, data = '*'}
-└──{ len = 1, height = 4, data = '0'}
-   │     ┌──{ len = 1, height = 1, data = 'p'}
-   │  ┌──{ len = 1, height = 2, data = 'p'}
-   │  │  └──{ len = 1, height = 1, data = '1'}
-   └──{ len = 1, height = 3, data = '2'}
-      └──{ len = 1, height = 1, data = '<'}
-
-insert offset = 3, str = 'p'
-size = 9
-string = '>*0ppp12<'
-│     ┌──nil
-│  ┌──{ len = 1, height = 2, data = '>'}
-│  │  └──{ len = 1, height = 1, data = '*'}
-└──{ len = 1, height = 4, data = '0'}
-   │     ┌──{ len = 1, height = 1, data = 'p'}
-   │  ┌──{ len = 1, height = 2, data = 'p'}
-   │  │  └──nil
-   └──{ len = 1, height = 3, data = 'p'}
-      │  ┌──{ len = 1, height = 1, data = '1'}
-      └──{ len = 1, height = 2, data = '2'}
-         └──{ len = 1, height = 1, data = '<'}
-
-insert offset = 3, str = 'p'
-size = 10
-string = '>*0pppp12<'
-│     ┌──nil
-│  ┌──{ len = 1, height = 2, data = '>'}
-│  │  └──{ len = 1, height = 1, data = '*'}
-└──{ len = 1, height = 4, data = '0'}
-   │     ┌──{ len = 1, height = 1, data = 'p'}
-   │  ┌──{ len = 1, height = 2, data = 'p'}
-   │  │  └──{ len = 1, height = 1, data = 'p'}
-   └──{ len = 1, height = 3, data = 'p'}
-      │  ┌──{ len = 1, height = 1, data = '1'}
-      └──{ len = 1, height = 2, data = '2'}
-         └──{ len = 1, height = 1, data = '<'}
-
-insert offset = 3, str = '*'
-size = 11
-string = '>*0*pppp12<'
-│        ┌──nil
-│     ┌──{ len = 1, height = 2, data = '>'}
-│     │  └──{ len = 1, height = 1, data = '*'}
-│  ┌──{ len = 1, height = 3, data = '0'}
-│  │  │  ┌──{ len = 1, height = 1, data = '*'}
-│  │  └──{ len = 1, height = 2, data = 'p'}
-│  │     └──nil
-└──{ len = 1, height = 4, data = 'p'}
-   │  ┌──{ len = 1, height = 1, data = 'p'}
-   └──{ len = 1, height = 3, data = 'p'}
-      │  ┌──{ len = 1, height = 1, data = '1'}
-      └──{ len = 1, height = 2, data = '2'}
-         └──{ len = 1, height = 1, data = '<'}
-
-	*** test_avl_rotations: done ***
diff --git a/test/unit/rope_basic.c b/test/unit/rope_basic.c
index d9e116292..5ef49cb8d 100644
--- a/test/unit/rope_basic.c
+++ b/test/unit/rope_basic.c
@@ -7,6 +7,7 @@ static void
 test_empty_rope()
 {
 	header();
+	plan(1);
 
 	struct rope *rope = test_rope_new();
 
@@ -19,13 +20,15 @@ test_empty_rope()
 
 	rope_traverse(rope, str_print);
 	rope_check(rope);
-	rope_pretty_print(rope, str_print);
+	/* rope_pretty_print(rope, str_print); */
 
 	/* rope_erase(), rope_extract() expect a non-empty rope */
 
 	rope_iter_delete(iter);
 	rope_delete(rope);
+	ok(1, "test empty rope");
 
+	check_plan();
 	footer();
 }
 
@@ -33,13 +36,16 @@ static void
 test_prepend()
 {
 	header();
+	plan(1);
 
 	struct rope *rope = test_rope_new();
 	test_rope_insert(rope, 0, " c ");
 	test_rope_insert(rope, 0, " b ");
 	test_rope_insert(rope, 0, " a ");
 	rope_delete(rope);
+	ok(1, "test prepend");
 
+	check_plan();
 	footer();
 }
 
@@ -47,13 +53,16 @@ static void
 test_append()
 {
 	header();
+	plan(1);
 
 	struct rope *rope = test_rope_new();
 	test_rope_insert(rope, rope_size(rope), " a ");
 	test_rope_insert(rope, rope_size(rope), " b ");
 	test_rope_insert(rope, rope_size(rope), " c ");
 	rope_delete(rope);
+	ok(1, "test append");
 
+	check_plan();
 	footer();
 }
 
@@ -61,6 +70,7 @@ static void
 test_insert()
 {
 	header();
+	plan(1);
 
 	struct rope *rope = test_rope_new();
 
@@ -73,6 +83,8 @@ test_insert()
 	test_rope_insert(rope, 8, "*");
 
 	rope_delete(rope);
+	ok(1, "test insert");
+	check_plan();
 
 	footer();
 }
@@ -81,6 +93,7 @@ static void
 test_erase()
 {
 	header();
+	plan(1);
 
 	struct rope *rope = test_rope_new();
 	rope_insert(rope, rope_size(rope), "a", 1);
@@ -90,6 +103,8 @@ test_erase()
 	test_rope_erase(rope, 0);
 
 	rope_delete(rope);
+	ok(1, "test erase")
+	check_plan();
 
 	footer();
 }
@@ -97,10 +112,12 @@ test_erase()
 int
 main()
 {
+	plan(5);
 	test_empty_rope();
 	test_append();
 	test_prepend();
 	test_insert();
 	test_erase();
+	check_plan();
 	return 0;
 }
diff --git a/test/unit/rope_basic.result b/test/unit/rope_basic.result
deleted file mode 100644
index fd8ef015e..000000000
--- a/test/unit/rope_basic.result
+++ /dev/null
@@ -1,139 +0,0 @@
-	*** test_empty_rope ***
-size = 0
-string = ''
-└──nil
-
-	*** test_empty_rope: done ***
-	*** test_append ***
-insert offset = 0, str = ' a '
-size = 3
-string = ' a '
-└──{ len = 3, height = 1, data = ' a '}
-
-insert offset = 3, str = ' b '
-size = 6
-string = ' a  b '
-│  ┌──nil
-└──{ len = 3, height = 2, data = ' a '}
-   └──{ len = 3, height = 1, data = ' b '}
-
-insert offset = 6, str = ' c '
-size = 9
-string = ' a  b  c '
-│  ┌──{ len = 3, height = 1, data = ' a '}
-└──{ len = 3, height = 2, data = ' b '}
-   └──{ len = 3, height = 1, data = ' c '}
-
-	*** test_append: done ***
-	*** test_prepend ***
-insert offset = 0, str = ' c '
-size = 3
-string = ' c '
-└──{ len = 3, height = 1, data = ' c '}
-
-insert offset = 0, str = ' b '
-size = 6
-string = ' b  c '
-│  ┌──{ len = 3, height = 1, data = ' b '}
-└──{ len = 3, height = 2, data = ' c '}
-   └──nil
-
-insert offset = 0, str = ' a '
-size = 9
-string = ' a  b  c '
-│  ┌──{ len = 3, height = 1, data = ' a '}
-└──{ len = 3, height = 2, data = ' b '}
-   └──{ len = 3, height = 1, data = ' c '}
-
-	*** test_prepend: done ***
-	*** test_insert ***
-insert offset = 0, str = '   a '
-size = 5
-string = '   a '
-└──{ len = 5, height = 1, data = '   a '}
-
-insert offset = 4, str = 'b '
-size = 7
-string = '   ab  '
-│  ┌──{ len = 4, height = 1, data = '   a'}
-└──{ len = 2, height = 2, data = 'b '}
-   └──{ len = 1, height = 1, data = ' '}
-
-insert offset = 5, str = 'c '
-size = 9
-string = '   abc   '
-│  ┌──{ len = 4, height = 1, data = '   a'}
-└──{ len = 1, height = 3, data = 'b'}
-   │  ┌──{ len = 2, height = 1, data = 'c '}
-   └──{ len = 1, height = 2, data = ' '}
-      └──{ len = 1, height = 1, data = ' '}
-
-insert offset = 1, str = ' '
-size = 10
-string = '    abc   '
-│     ┌──{ len = 1, height = 1, data = ' '}
-│  ┌──{ len = 1, height = 2, data = ' '}
-│  │  └──{ len = 3, height = 1, data = '  a'}
-└──{ len = 1, height = 3, data = 'b'}
-   │  ┌──{ len = 2, height = 1, data = 'c '}
-   └──{ len = 1, height = 2, data = ' '}
-      └──{ len = 1, height = 1, data = ' '}
-
-insert offset = 9, str = ' '
-size = 11
-string = '    abc    '
-│     ┌──{ len = 1, height = 1, data = ' '}
-│  ┌──{ len = 1, height = 2, data = ' '}
-│  │  └──{ len = 3, height = 1, data = '  a'}
-└──{ len = 1, height = 4, data = 'b'}
-   │  ┌──{ len = 2, height = 1, data = 'c '}
-   └──{ len = 1, height = 3, data = ' '}
-      │  ┌──{ len = 1, height = 1, data = ' '}
-      └──{ len = 1, height = 2, data = ' '}
-         └──nil
-
-insert offset = 4, str = '*'
-size = 12
-string = '    *abc    '
-│     ┌──{ len = 1, height = 1, data = ' '}
-│  ┌──{ len = 1, height = 3, data = ' '}
-│  │  │  ┌──{ len = 2, height = 1, data = '  '}
-│  │  └──{ len = 1, height = 2, data = '*'}
-│  │     └──{ len = 1, height = 1, data = 'a'}
-└──{ len = 1, height = 4, data = 'b'}
-   │  ┌──{ len = 2, height = 1, data = 'c '}
-   └──{ len = 1, height = 3, data = ' '}
-      │  ┌──{ len = 1, height = 1, data = ' '}
-      └──{ len = 1, height = 2, data = ' '}
-         └──nil
-
-insert offset = 8, str = '*'
-size = 13
-string = '    *abc*    '
-│     ┌──{ len = 1, height = 1, data = ' '}
-│  ┌──{ len = 1, height = 3, data = ' '}
-│  │  │  ┌──{ len = 2, height = 1, data = '  '}
-│  │  └──{ len = 1, height = 2, data = '*'}
-│  │     └──{ len = 1, height = 1, data = 'a'}
-└──{ len = 1, height = 4, data = 'b'}
-   │     ┌──{ len = 1, height = 1, data = 'c'}
-   │  ┌──{ len = 1, height = 2, data = '*'}
-   │  │  └──{ len = 1, height = 1, data = ' '}
-   └──{ len = 1, height = 3, data = ' '}
-      │  ┌──{ len = 1, height = 1, data = ' '}
-      └──{ len = 1, height = 2, data = ' '}
-         └──nil
-
-	*** test_insert: done ***
-	*** test_erase ***
-erase offset = 0
-size = 0
-string = ''
-└──nil
-
-erase offset = 0
-size = 1
-string = 'b'
-└──{ len = 1, height = 1, data = 'b'}
-
-	*** test_erase: done ***
diff --git a/test/unit/rope_common.h b/test/unit/rope_common.h
index 3392e87e3..67e2dbc2b 100644
--- a/test/unit/rope_common.h
+++ b/test/unit/rope_common.h
@@ -3,6 +3,9 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
+
+#include "unit.h"
+
 static inline char *
 str_getn(void *ctx, char *data, size_t size, size_t offset)
 {
@@ -68,18 +71,18 @@ test_rope_new()
 static inline void
 test_rope_insert(struct rope *rope, rope_size_t offset, char *str)
 {
-	printf("insert offset = %zu, str = '%s'\n", (size_t) offset, str);
+	note("insert offset = %zu, str = '%s'", (size_t) offset, str);
 	rope_insert(rope, offset, str, strlen(str));
-	rope_pretty_print(rope, str_print);
+	/* rope_pretty_print(rope, str_print); */
 	rope_check(rope);
 }
 
 static inline void
 test_rope_erase(struct rope *rope, rope_size_t offset)
 {
-	printf("erase offset = %zu\n", (size_t) offset);
+	note("erase offset = %zu", (size_t) offset);
 	rope_erase(rope, offset);
-	rope_pretty_print(rope, str_print);
+	/* rope_pretty_print(rope, str_print); */
 	rope_check(rope);
 }
 
diff --git a/test/unit/rope_stress.c b/test/unit/rope_stress.c
index bc312d7c0..4d17ef6ef 100644
--- a/test/unit/rope_stress.c
+++ b/test/unit/rope_stress.c
@@ -8,6 +8,7 @@ static void
 test_rope_stress_small()
 {
 	header();
+	plan(1);
 
 	struct rope *rope = test_rope_new();
 	const int iterations = 500;
@@ -29,7 +30,9 @@ test_rope_stress_small()
 		rope_check(rope);
 	}
 	rope_delete(rope);
+	ok(1, "test rope stress small");
 
+	check_plan();
 	footer();
 }
 
@@ -37,6 +40,7 @@ static void
 test_rope_stress_large()
 {
 	header();
+	plan(1);
 
 	struct rope *rope = test_rope_new();
 	const int iterations = 50000;
@@ -58,14 +62,18 @@ test_rope_stress_large()
 			rope_check(rope);
 	}
 	rope_delete(rope);
+	ok(1, "test rope stress large");
 
+	check_plan();
 	footer();
 }
 int
 main()
 {
+	plan(2);
 	srand(time(NULL));
 	test_rope_stress_small();
 	test_rope_stress_large();
+	check_plan();
 	return 0;
 }
diff --git a/test/unit/rope_stress.result b/test/unit/rope_stress.result
deleted file mode 100644
index bd2e45b75..000000000
--- a/test/unit/rope_stress.result
+++ /dev/null
@@ -1,4 +0,0 @@
-	*** test_rope_stress_small ***
-	*** test_rope_stress_small: done ***
-	*** test_rope_stress_large ***
-	*** test_rope_stress_large: done ***
diff --git a/test/unit/rtree.cc b/test/unit/rtree.cc
index 02ca9cdd6..d623d0178 100644
--- a/test/unit/rtree.cc
+++ b/test/unit/rtree.cc
@@ -31,19 +31,20 @@ extent_free(void *ctx, void *page)
 static void
 simple_check()
 {
+	header();
+	plan(1);
+
 	struct rtree_rect rect;
 	struct rtree_iterator iterator;
 	rtree_iterator_init(&iterator);
 	const size_t rounds = 2000;
 
-	header();
-
 	struct rtree tree;
 	rtree_init(&tree, 2, extent_size,
 		   extent_alloc, extent_free, &page_count,
 		   RTREE_EUCLID);
 
-	printf("Insert 1..X, remove 1..X\n");
+	note("Insert 1..X, remove 1..X");
 	for (size_t i = 1; i <= rounds; i++) {
 		record_t rec = (record_t)i;
 
@@ -82,7 +83,7 @@ simple_check()
 		fail("Tree count mismatch (1)", "true");
 	}
 
-	printf("Insert 1..X, remove X..1\n");
+	note("Insert 1..X, remove X..1");
 	for (size_t i = 1; i <= rounds; i++) {
 		record_t rec = (record_t)i;
 
@@ -122,7 +123,7 @@ simple_check()
 	}
 
 
-	printf("Insert X..1, remove 1..X\n");
+	note("Insert X..1, remove 1..X");
 	for (size_t i = rounds; i != 0; i--) {
 		record_t rec = (record_t)i;
 
@@ -162,7 +163,7 @@ simple_check()
 	}
 
 
-	printf("Insert X..1, remove X..1\n");
+	note("Insert X..1, remove X..1");
 	for (size_t i = rounds; i != 0; i--) {
 		record_t rec = (record_t)i;
 
@@ -205,8 +206,10 @@ simple_check()
 	rtree_destroy(&tree);
 
 	rtree_iterator_destroy(&iterator);
+	ok(1, "simple test");
 
 	footer();
+	check_plan();
 }
 
 static void
@@ -222,6 +225,7 @@ static void
 neighbor_test()
 {
 	header();
+	plan(1);
 
 	const unsigned int test_count = 1000;
 	struct rtree_rect arr[test_count];
@@ -271,17 +275,21 @@ neighbor_test()
 		fail("something found from empty iterator ", "true");
 	}
 	rtree_iterator_destroy(&iterator);
+	ok(1, "neighbor test");
 
 	footer();
+	check_plan();
 }
 
 
 int
 main(void)
 {
+	plan(2);
 	simple_check();
 	neighbor_test();
 	if (page_count != 0) {
 		fail("memory leak!", "true");
 	}
+	check_plan();
 }
diff --git a/test/unit/rtree.result b/test/unit/rtree.result
deleted file mode 100644
index 6efa93438..000000000
--- a/test/unit/rtree.result
+++ /dev/null
@@ -1,8 +0,0 @@
-	*** simple_check ***
-Insert 1..X, remove 1..X
-Insert 1..X, remove X..1
-Insert X..1, remove 1..X
-Insert X..1, remove X..1
-	*** simple_check: done ***
-	*** neighbor_test ***
-	*** neighbor_test: done ***
diff --git a/test/unit/rtree_iterator.cc b/test/unit/rtree_iterator.cc
index b3c8695e9..ee1bcc131 100644
--- a/test/unit/rtree_iterator.cc
+++ b/test/unit/rtree_iterator.cc
@@ -31,6 +31,7 @@ static void
 iterator_check()
 {
 	header();
+	plan(1);
 
 	struct rtree tree;
 	rtree_init(&tree, 2, extent_size,
@@ -53,7 +54,7 @@ iterator_check()
 			rtree_insert(&tree, &rect, record_t(++count));
 		}
 	}
-	printf("Test tree size: %d\n", (int)rtree_number_of_records(&tree));
+	note("Test tree size: %d", (int)rtree_number_of_records(&tree));
 
 	/* Test that tree filled ok */
 	for (size_t i = 0; i < count1; i++) {
@@ -81,8 +82,8 @@ iterator_check()
 
 	/* Print 7 elems closest to coordinate basis */
 	{
+		fprintf(stderr, "--> ");
 		static struct rtree_rect basis;
-		printf("--> ");
 		if (!rtree_search(&tree, &basis, SOP_NEIGHBOR, &iterator)) {
 			fail("Integrity check failed (5)", "false");
 		}
@@ -91,13 +92,13 @@ iterator_check()
 			if (rec == 0) {
 				fail("Integrity check failed (6)", "false");
 			}
-			printf("%p ", rec);
+			fprintf(stderr, "%p ", rec);
 		}
-		printf("\n");
+		fprintf(stderr, "\n");
 	}
 	/* Print 7 elems closest to the point [(count1-1)*count2*2, (count1-1)*count2*2] */
 	{
-		printf("<-- ");
+		fprintf(stderr, "<-- ");
 		coord_t coord = (count1 - 1) * count2 * 2;
 		rtree_set2d(&rect, coord, coord, coord, coord);
 		if (!rtree_search(&tree, &rect, SOP_NEIGHBOR, &iterator)) {
@@ -108,9 +109,9 @@ iterator_check()
 			if (rec == 0) {
 				fail("Integrity check failed (6)", "false");
 			}
-			printf("%p ", rec);
+			fprintf(stderr, "%p ", rec);
 		}
-		printf("\n");
+		fprintf(stderr, "\n");
 	}
 
 	/* Test strict belongs */
@@ -192,6 +193,8 @@ iterator_check()
 	rtree_iterator_destroy(&iterator);
 	rtree_destroy(&tree);
 
+	ok(1, "iterator check");
+	check_plan();
 	footer();
 }
 
@@ -199,6 +202,7 @@ static void
 iterator_invalidate_check()
 {
 	header();
+	plan(1);
 
 	const size_t test_size = 300;
 	const size_t max_delete_count = 100;
@@ -299,15 +303,21 @@ iterator_invalidate_check()
 		rtree_destroy(&tree);
 	}
 
+	ok(1, "iterator invalidate check");
+	check_plan();
 	footer();
 }
 
 int
 main(void)
 {
+	header();
+	plan(2);
 	iterator_check();
 	iterator_invalidate_check();
 	if (extent_count != 0) {
 		fail("memory leak!", "false");
 	}
+	check_plan();
+	footer();
 }
diff --git a/test/unit/rtree_iterator.result b/test/unit/rtree_iterator.result
deleted file mode 100644
index 5eac9f090..000000000
--- a/test/unit/rtree_iterator.result
+++ /dev/null
@@ -1,7 +0,0 @@
-	*** iterator_check ***
-Test tree size: 50000
---> 0x1 0x2 0x3 0x4 0x5 0x6 0x7 
-<-- 0xc34c 0xc34d 0xc34e 0xc34f 0xc350 0xc34b 0xc34a 
-	*** iterator_check: done ***
-	*** iterator_invalidate_check ***
-	*** iterator_invalidate_check: done ***
diff --git a/test/unit/rtree_multidim.cc b/test/unit/rtree_multidim.cc
index e09f6190b..8fa44e6a9 100644
--- a/test/unit/rtree_multidim.cc
+++ b/test/unit/rtree_multidim.cc
@@ -348,14 +348,14 @@ test_select_neigh(const CBoxSet<DIMENSION> &set, const struct rtree *tree)
 		}
 	}
 	if (res1.size() != res2.size()) {
-		printf("%s result size differ %d %d\n", __func__,
+		diag("%s result size differ %d %d\n", __func__,
 		       (int)res1.size(), (int)res2.size());
 	} else {
 		for (size_t i = 0; i < res1.size(); i++)
 			if (res1[i].id != res2[i].id &&
 			    res1[i].box.Distance2(box) !=
 			    res2[i].box.Distance2(box))
-				printf("%s result differ!\n", __func__);
+				diag("%s result differ!\n", __func__);
 	}
 	rtree_iterator_destroy(&iterator);
 
@@ -388,14 +388,14 @@ test_select_neigh_man(const CBoxSet<DIMENSION> &set, struct rtree *tree)
 		}
 	}
 	if (res1.size() != res2.size()) {
-		printf("%s result size differ %d %d\n", __func__,
+		diag("%s result size differ %d %d\n", __func__,
 		       (int)res1.size(), (int)res2.size());
 	} else {
 		for (size_t i = 0; i < res1.size(); i++)
 			if (res1[i].id != res2[i].id &&
 			    res1[i].box.DistanceMan(box) !=
 			    res2[i].box.DistanceMan(box))
-				printf("%s result differ!\n", __func__);
+				diag("%s result differ!\n", __func__);
 	}
 	tree->distance_type = RTREE_EUCLID; /* dirty hack */
 	rtree_iterator_destroy(&iterator);
@@ -428,12 +428,12 @@ test_select_in(const CBoxSet<DIMENSION> &set, const struct rtree *tree)
 	sort(res1.begin(), res1.end());
 	sort(res2.begin(), res2.end());
 	if (res1.size() != res2.size()) {
-		printf("%s result size differ %d %d\n", __func__,
+		diag("%s result size differ %d %d\n", __func__,
 		       (int)res1.size(), (int)res2.size());
 	} else {
 		for (size_t i = 0; i < res1.size(); i++)
 			if (res1[i].id != res2[i].id)
-				printf("%s result differ!\n", __func__);
+				diag("%s result differ!\n", __func__);
 	}
 	rtree_iterator_destroy(&iterator);
 
@@ -465,12 +465,12 @@ test_select_strict_in(const CBoxSet<DIMENSION> &set, const struct rtree *tree)
 	sort(res1.begin(), res1.end());
 	sort(res2.begin(), res2.end());
 	if (res1.size() != res2.size()) {
-		printf("%s result size differ %d %d\n", __func__,
+		diag("%s result size differ %d %d\n", __func__,
 		       (int)res1.size(), (int)res2.size());
 	} else {
 		for (size_t i = 0; i < res1.size(); i++)
 			if (res1[i].id != res2[i].id)
-				printf("%s result differ!\n", __func__);
+				diag("%s result differ!\n", __func__);
 	}
 	rtree_iterator_destroy(&iterator);
 
@@ -481,6 +481,7 @@ static void
 rand_test()
 {
 	header();
+	plan(1);
 
 	CBoxSet<DIMENSION> set;
 
@@ -489,7 +490,7 @@ rand_test()
 		   extent_alloc, extent_free, &page_count,
 		   RTREE_EUCLID);
 
-	printf("\tDIMENSION: %u, page size: %u, max fill good: %d\n",
+	note("\tDIMENSION: %u, page size: %u, max fill good: %d\n",
 	       DIMENSION, tree.page_size, tree.page_max_fill >= 10);
 
 	for (unsigned i = 0; i < TEST_ROUNDS; i++) {
@@ -513,7 +514,7 @@ rand_test()
 			struct rtree_rect rt;
 			set.entries[id].box.FillRTreeRect(&rt);
 			if (!rtree_remove(&tree, &rt, (void *)(id + 1))) {
-				printf("Error in remove\n");
+				diag("Error in remove\n");
 			}
 			set.DeleteBox(id);
 		}
@@ -525,13 +526,21 @@ rand_test()
 	}
 
 	rtree_destroy(&tree);
+	ok(1, "rand_test %u", DIMENSION);
+
+	/*
+	note("\tDIMENSION: %u, page size: %u, max fill good: %d\n",
+	       DIMENSION, tree.page_size, tree.page_max_fill >= 10);
+	*/
 
 	footer();
+	check_plan();
 }
 
 int
 main(void)
 {
+	plan(5);
 	srand(time(0));
 	rand_test<1>();
 	rand_test<2>();
@@ -541,4 +550,5 @@ main(void)
 	if (page_count != 0) {
 		fail("memory leak!", "true");
 	}
+	check_plan();
 }
diff --git a/test/unit/rtree_multidim.result b/test/unit/rtree_multidim.result
deleted file mode 100644
index 9370ecc3a..000000000
--- a/test/unit/rtree_multidim.result
+++ /dev/null
@@ -1,15 +0,0 @@
-	*** rand_test ***
-	DIMENSION: 1, page size: 512, max fill good: 1
-	*** rand_test: done ***
-	*** rand_test ***
-	DIMENSION: 2, page size: 1024, max fill good: 1
-	*** rand_test: done ***
-	*** rand_test ***
-	DIMENSION: 3, page size: 1024, max fill good: 1
-	*** rand_test: done ***
-	*** rand_test ***
-	DIMENSION: 8, page size: 4096, max fill good: 1
-	*** rand_test: done ***
-	*** rand_test ***
-	DIMENSION: 16, page size: 8192, max fill good: 1
-	*** rand_test: done ***
diff --git a/test/unit/say.result b/test/unit/say.result
deleted file mode 100644
index 8dfed7b61..000000000
--- a/test/unit/say.result
+++ /dev/null
@@ -1,67 +0,0 @@
-1..33
-# type: file
-# next: 
-ok 1 - 
-# type: file
-# next: /dev/null
-ok 2 - /dev/null
-# type: pipe
-# next: 
-ok 3 - |
-# type: pipe
-# next: /usr/bin/cronolog
-ok 4 - |/usr/bin/cronolog
-# type: file
-# next: 
-ok 5 - file:
-# type: file
-# next: instance.log
-ok 6 - file:instance.log
-# type: pipe
-# next: 
-ok 7 - pipe:
-# type: pipe
-# next: gzip > instance.log.gz
-ok 8 - pipe:gzip > instance.log.gz
-# type: syslog
-# next: 
-ok 9 - syslog:
-# type: syslog
-# next: identity=
-ok 10 - syslog:identity=
-# next: unknown:
-ok 11 - unknown:
-# next: unknown:example.org
-ok 12 - unknown:example.org
-# facility: 24
-ok 13 - 
-# identity: tarantool
-# facility: 24
-ok 14 - identity=tarantool
-# facility: 1
-ok 15 - facility=user
-# identity: xtarantoolx
-# facility: 17
-ok 16 - identity=xtarantoolx,facility=local1
-# identity: xtarantoolx
-ok 17 - identity=xtarantoolx,facility=kern
-# identity: xtarantoolx
-# facility: 8
-ok 18 - identity=xtarantoolx,facility=uucp
-ok 19 - identity=xtarantoolx,facility=foo
-# identity: bar
-# facility: 10
-ok 20 - facility=authpriv,identity=bar
-ok 21 - invalid=
-ok 22 - facility=local1,facility=local2
-ok 23 - identity=foo,identity=bar
-ok 24 - plain
-ok 25 - json
-ok 26 - custom
-ok 27 - freopen
-ok 28 - parsed identity
-ok 29 - parsed facility
-ok 30 - ftell
-ok 31 - log_say
-ok 32 - fseek
-ok 33 - syslog line
diff --git a/test/unit/scramble.c b/test/unit/scramble.c
index 8f1ee55af..d4f684efb 100644
--- a/test/unit/scramble.c
+++ b/test/unit/scramble.c
@@ -9,6 +9,9 @@
 void
 test_scramble()
 {
+	header();
+	plan(1);
+
 	int salt[SCRAMBLE_SIZE/sizeof(int)];
 	for (unsigned i = 0; i < sizeof(salt)/sizeof(int); i++)
 		salt[i] = rand();
@@ -30,7 +33,7 @@ test_scramble()
 
 	scramble_prepare(scramble, salt, password, strlen(password));
 
-	printf("%d\n", scramble_check(scramble, salt, hash2));
+	note("%d", scramble_check(scramble, salt, hash2));
 
 	int remote_salt[SCRAMBLE_SIZE/sizeof(int)];
 	for(size_t i = 0; i < sizeof(salt)/sizeof(int); ++i)
@@ -40,21 +43,26 @@ test_scramble()
 
 	scramble_reencode(new_scramble, scramble, salt, remote_salt, hash2);
 
-	printf("%d\n", scramble_check(new_scramble, remote_salt, hash2));
+	note("%d", scramble_check(new_scramble, remote_salt, hash2));
 
 	password = "wrongpass";
 	scramble_prepare(scramble, salt, password, strlen(password));
 
-	printf("%d\n", scramble_check(scramble, salt, hash2) != 0);
+	note("%d", scramble_check(scramble, salt, hash2) != 0);
 
 	scramble_prepare(scramble, salt, password, 0);
 
-	printf("%d\n", scramble_check(scramble, salt, hash2) != 0);
+	note("%d", scramble_check(scramble, salt, hash2) != 0);
+
+	ok(1, "test scramble");
+	check_plan();	
 }
 
 void
 test_password_prepare()
 {
+	header();
+	plan(1);
 	char buf[SCRAMBLE_BASE64_SIZE * 2];
 	int password[5];
 	for (unsigned i = 0; i < sizeof(password)/sizeof(int); i++)
@@ -62,14 +70,19 @@ test_password_prepare()
 	password_prepare((char *) password, sizeof(password),
 			 buf, sizeof(buf));
 	fail_unless(strlen(buf) == SCRAMBLE_BASE64_SIZE);
+
+	ok(1, "test password prepare");
+	check_plan();
 }
 
 int main()
 {
 	random_init();
 
+	plan(2);
 	test_scramble();
 	test_password_prepare();
+	check_plan();
 
 	return 0;
 }
diff --git a/test/unit/scramble.result b/test/unit/scramble.result
deleted file mode 100644
index 0463db267..000000000
--- a/test/unit/scramble.result
+++ /dev/null
@@ -1,4 +0,0 @@
-0
-0
-1
-1
diff --git a/test/unit/sio.result b/test/unit/sio.result
deleted file mode 100644
index 896736bf9..000000000
--- a/test/unit/sio.result
+++ /dev/null
@@ -1,36 +0,0 @@
-	*** main ***
-1..2
-	*** check_uri_to_addr ***
-    1..22
-    ok 1 - invalid uri is detected
-    ok 2 - too long UNIX path
-    ok 3 - UNIX
-    ok 4 - UNIX path
-    ok 5 - UNIX family
-    ok 6 - unix host is not empty
-    ok 7 - localhost
-    ok 8 - localhost family
-    ok 9 - localhost address
-    ok 10 - localhost port
-    ok 11 - 'localhost' host is not empty
-    ok 12 - 'any'
-    ok 13 - 'any' family
-    ok 14 - 'any' address
-    ok 15 - 'any' port
-    ok 16 - only port specified - host is empty
-    ok 17 - IP
-    ok 18 - IP family
-    ok 19 - IP address
-    ok 20 - IP port
-    ok 21 - IPv4 host is not empty
-    ok 22 - invalid IP
-ok 1 - subtests
-	*** check_uri_to_addr: done ***
-	*** check_auto_bind ***
-    1..3
-    ok 1 - bind to 0 works
-    ok 2 - getsockname works on 0 bind
-    ok 3 - a real port is returned
-ok 2 - subtests
-	*** check_auto_bind: done ***
-	*** main: done ***
diff --git a/test/unit/stailq.result b/test/unit/stailq.result
deleted file mode 100644
index 041545008..000000000
--- a/test/unit/stailq.result
+++ /dev/null
@@ -1,76 +0,0 @@
-1..75
-ok 1 - list is empty
-ok 2 - list is empty after reverse
-ok 3 - first item
-ok 4 - last item
-ok 5 - element (foreach) 0
-ok 6 - element (foreach) 1
-ok 7 - element (foreach) 2
-ok 8 - element (foreach) 3
-ok 9 - element (foreach) 4
-ok 10 - element (foreach) 5
-ok 11 - element (foreach) 6
-ok 12 - first item
-ok 13 - head is not empty
-ok 14 - first entry
-ok 15 - shift item 0
-ok 16 - shift item 1
-ok 17 - shift item 2
-ok 18 - shift item 3
-ok 19 - shift item 4
-ok 20 - shift item 5
-ok 21 - shift item 6
-ok 22 - list is empty after shift
-ok 23 - next is empty
-ok 24 - element (foreach_entry) 6
-ok 25 - element (foreach_entry) 5
-ok 26 - element (foreach_entry) 4
-ok 27 - element (foreach_entry) 3
-ok 28 - element (foreach_entry) 2
-ok 29 - element (foreach_entry) 1
-ok 30 - element (foreach_entry) 0
-ok 31 - element (foreach_entry) 0
-ok 32 - element (foreach_entry) 1
-ok 33 - element (foreach_entry) 2
-ok 34 - element (foreach_entry) 3
-ok 35 - element (foreach_entry) 4
-ok 36 - element (foreach_entry) 5
-ok 37 - element (foreach_entry) 6
-ok 38 - head is empty after cut at first
-ok 39 - tail element after cut at first 0
-ok 40 - tail element after cut at first 1
-ok 41 - tail element after cut at first 2
-ok 42 - tail element after cut at first 3
-ok 43 - tail element after cut at first 4
-ok 44 - tail element after cut at first 5
-ok 45 - tail element after cut at first 6
-ok 46 - tail is empty after cut at last
-ok 47 - head element after cut at last 0
-ok 48 - head element after cut at last 1
-ok 49 - head element after cut at last 2
-ok 50 - head element after cut at last 3
-ok 51 - head element after cut at last 4
-ok 52 - head element after cut at last 5
-ok 53 - head element after cut at last 6
-ok 54 - head element after cut at middle 0
-ok 55 - head element after cut at middle 1
-ok 56 - head element after cut at middle 2
-ok 57 - head element after cut at middle 3
-ok 58 - tail element after cut at middle 4
-ok 59 - tail element after cut at middle 5
-ok 60 - tail element after cut at middle 6
-ok 61 - tail is empty after concat
-ok 62 - head element after concat 0
-ok 63 - head element after concat 1
-ok 64 - head element after concat 2
-ok 65 - head element after concat 3
-ok 66 - head element after concat 4
-ok 67 - head element after concat 5
-ok 68 - head element after concat 6
-ok 69 - element 0 (insert)
-ok 70 - element 1 (insert)
-ok 71 - element 2 (insert)
-ok 72 - element 3 (insert)
-ok 73 - element 4 (insert)
-ok 74 - first item (insert)
-ok 75 - last item (insert)
diff --git a/test/unit/swim.result b/test/unit/swim.result
deleted file mode 100644
index 07ea6a1a0..000000000
--- a/test/unit/swim.result
+++ /dev/null
@@ -1,234 +0,0 @@
-	*** main_f ***
-1..23
-	*** swim_test_one_link ***
-    1..6
-    ok 1 - no rounds - no fullmesh
-    ok 2 - one link
-    ok 3 - self 0 is alive
-    ok 4 - self 1 is alive
-    ok 5 - 0 sees 1 as alive
-    ok 6 - 1 sees 0 as alive
-ok 1 - subtests
-	*** swim_test_one_link: done ***
-	*** swim_test_sequence ***
-    1..1
-    ok 1 - sequence
-ok 2 - subtests
-	*** swim_test_sequence: done ***
-	*** swim_test_uuid_update ***
-    1..7
-    ok 1 - UUID update
-    ok 2 - old UUID is marked as 'left'
-    ok 3 - old UUID is dropped after a while
-    ok 4 - dropped everywhere
-    ok 5 - two members in each
-    ok 6 - can not update to an existing UUID - swim_cfg fails
-    ok 7 - diag says 'exists'
-ok 3 - subtests
-	*** swim_test_uuid_update: done ***
-	*** swim_test_cfg ***
-    1..16
-    ok 1 - first cfg failed - no URI
-    ok 2 - diag says 'mandatory'
-    ok 3 - first cfg failed - no UUID
-    ok 4 - diag says 'mandatory'
-    ok 5 - configured first time
-    ok 6 - second time can omit URI, UUID
-    ok 7 - hearbeat is dynamic
-    ok 8 - URI is unchanged after recfg with NULL URI
-    ok 9 - can not use invalid URI
-    ok 10 - diag says 'invalid uri'
-    ok 11 - can not use domain names
-    ok 12 - diag says 'invalid uri'
-    ok 13 - UNIX sockets are not supported
-    ok 14 - diag says 'only IP'
-    ok 15 - can not bind to an occupied port
-    ok 16 - diag says 'bind'
-ok 4 - subtests
-	*** swim_test_cfg: done ***
-	*** swim_test_add_remove ***
-    1..14
-    ok 1 - can not add an existing member
-    ok 2 - diag says 'already exists'
-    ok 3 - can not add a invalid uri
-    ok 4 - diag says 'invalid uri'
-    ok 5 - can not remove self
-    ok 6 - diag says the same
-    ok 7 - find by UUID works
-    ok 8 - now remove one element
-    ok 9 - and it can not be found anymore
-    ok 10 - remove of a not existing member
-    ok 11 - after removal the cluster is not in fullmesh
-    ok 12 - but it is back in 1 step
-    ok 13 - back in fullmesh after a member removal in the middle of a step
-    ok 14 - if a referenced member is dropped, it can be detected from the public API
-ok 5 - subtests
-	*** swim_test_add_remove: done ***
-	*** swim_test_basic_failure_detection ***
-    1..9
-    ok 1 - node is added as alive
-    ok 2 - member still is not suspected after 1 noack
-    ok 3 - but it is suspected after one more
-    ok 4 - it is not dead after 2 more noacks
-    ok 5 - but it is dead after one more
-    ok 6 - after 2 more unacks the member still is not deleted - dissemination TTD keeps it
-    ok 7 - but it is dropped after 2 rounds when TTD gets 0
-    ok 8 - fullmesh is restored
-    ok 9 - a member is added back on an ACK
-ok 6 - subtests
-	*** swim_test_basic_failure_detection: done ***
-	*** swim_test_probe ***
-    1..3
-    ok 1 - probe validates URI
-    ok 2 - send probe
-    ok 3 - receive ACK on probe and get fullmesh
-ok 7 - subtests
-	*** swim_test_probe: done ***
-	*** swim_test_refute ***
-    1..6
-    ok 1 - S2 increments its own incarnation to refute its suspicion
-    ok 2 - new incarnation has reached S1 with a next round message
-    ok 3 - after restart S2's version is 0 again
-    ok 4 - but generation is new
-    ok 5 - S2 disseminates new incarnation, S1 learns it
-    ok 6 - and considers S2 alive
-ok 8 - subtests
-	*** swim_test_refute: done ***
-	*** swim_test_basic_gossip ***
-    1..4
-    ok 1 - S1 still thinks that S2 is alive
-    ok 2 - but one more second, and a second ack timed out - S1 sees S2 as suspected
-    ok 3 - S3 still thinks that S2 is alive
-    ok 4 - S3 learns about suspected S2 from S1
-ok 9 - subtests
-	*** swim_test_basic_gossip: done ***
-	*** swim_test_too_big_packet ***
-    1..3
-    ok 1 - despite S1 can not send all the 50 members in a one packet, fullmesh is eventually reached
-    ok 2 - a dead member is detected in time not depending on cluster size
-    ok 3 - S26 death is eventually learned by everyone
-ok 10 - subtests
-	*** swim_test_too_big_packet: done ***
-	*** swim_test_undead ***
-    1..2
-    ok 1 - member S2 is dead
-    ok 2 - but it is never deleted due to the cfg option
-ok 11 - subtests
-	*** swim_test_undead: done ***
-	*** swim_test_packet_loss ***
-    1..5
-    ok 1 - drop rate = 5.00, but the failure is disseminated
-    ok 2 - drop rate = 10.00, but the failure is disseminated
-    ok 3 - drop rate = 20.00, but the failure is disseminated
-    ok 4 - drop rate = 50.00, but the failure is disseminated
-    ok 5 - drop rate = 90.00, but the failure is disseminated
-ok 12 - subtests
-	*** swim_test_packet_loss: done ***
-	*** swim_test_quit ***
-    1..10
-    ok 1 - 'self' is 'left' immediately after quit
-    ok 2 - 'quit' is sent to all the members without delays between dispatches
-    ok 3 - quited member S1 has returned and refuted the old status
-    ok 4 - another member S2 has taken the quited UUID
-    ok 5 - S3 did not add S1 back when received its 'quit'
-    ok 6 - S2 finally got 'quit' message from S1, but with its 'own' UUID - refute it
-    ok 7 - S3 sees S1 as left
-    ok 8 - S2 does not see S1 at all
-    ok 9 - after more time S1 is dropped from S3
-    ok 10 - and still is not added to S2 - left members can not be added
-ok 13 - subtests
-	*** swim_test_quit: done ***
-	*** swim_test_uri_update ***
-    1..2
-    ok 1 - S1 updated its URI and S2 sees that
-    ok 2 - S2 still keeps new S1's URI, even received the old one from S3
-ok 14 - subtests
-	*** swim_test_uri_update: done ***
-	*** swim_test_broadcast ***
-    1..6
-    ok 1 - S1 chooses to broadcast with port 2
-    ok 2 - S2 receives the broadcast from S1
-    ok 3 - others don't
-    ok 4 - S1 broadcasts ping without port
-    ok 5 - now everyone sees S1
-    ok 6 - fullmesh is reached, and no one link was added explicitly
-ok 15 - subtests
-	*** swim_test_broadcast: done ***
-	*** swim_test_payload_basic ***
-    1..11
-    ok 1 - no payload by default
-    ok 2 - can not set too big payload
-    ok 3 - diag says too big
-    ok 4 - payload is set
-    ok 5 - version is incremented on each payload update
-    ok 6 - payload is successfully obtained back
-    ok 7 - payload is disseminated
-    ok 8 - payload is changed
-    ok 9 - version is incremented on each payload update
-    ok 10 - second payload is disseminated
-    ok 11 - third payload is disseminated via anti-entropy
-ok 16 - subtests
-	*** swim_test_payload_basic: done ***
-	*** swim_test_indirect_ping ***
-    1..2
-    ok 1 - S1 is still alive everywhere
-    ok 2 - as well as S2 - they communicated via S3
-ok 17 - subtests
-	*** swim_test_indirect_ping: done ***
-	*** swim_test_encryption ***
-    1..3
-    ok 1 - cluster works with encryption
-    ok 2 - different encryption keys - can't interact
-    ok 3 - cluster works after encryption has been disabled
-ok 18 - subtests
-	*** swim_test_encryption: done ***
-	*** swim_test_slow_net ***
-    1..0
-    # slow network leads to idle round steps, they should not produce a new message
-ok 19 - subtests
-	*** swim_test_slow_net: done ***
-	*** swim_test_triggers ***
-    1..20
-    ok 1 - trigger is fired
-    ok 2 - is not deleted
-    ok 3 - ctx.member is set
-    ok 4 - ctx.events is set
-    ok 5 - self payload is updated
-    ok 6 - self is set as a member
-    ok 7 - both version and payload events are presented
-    ok 8 - suspicion fired a trigger
-    ok 9 - status suspected
-    ok 10 - death fired a trigger
-    ok 11 - status dead
-    ok 12 - drop fired a trigger
-    ok 13 - status dropped
-    ok 14 - dropped member is not presented in the member table
-    ok 15 - but is in the event context
-    ok 16 - yielding trigger is fired
-    ok 17 - non-yielding still is not
-    ok 18 - trigger is not deleted until all currently sleeping triggers are finished
-    # now all the triggers are done and deleted
-    ok 19 - local URI update warns about version update
-    ok 20 - version is a part of incarnation, so the latter is updated too
-ok 20 - subtests
-	*** swim_test_triggers: done ***
-	*** swim_test_generation ***
-    1..3
-    ok 1 - S1 disseminated its payload to S2
-    ok 2 - S1 restarted and set another payload. Without generation it could lead to never disseminated new payload.
-    ok 3 - S2 sees new generation of S1
-ok 21 - subtests
-	*** swim_test_generation: done ***
-	*** swim_test_dissemination_speed ***
-    1..2
-    ok 1 - dissemination work in log time even at the very start of a cluster
-    ok 2 - dissemination can withstand an event storm
-ok 22 - subtests
-	*** swim_test_dissemination_speed: done ***
-	*** swim_test_suspect_new_members ***
-    1..2
-    ok 1 - S2 dropped S1 as dead
-    ok 2 - S3 didn't add S1 from S2's messages, because S1 didn't answer on a ping
-ok 23 - subtests
-	*** swim_test_suspect_new_members: done ***
-	*** main_f: done ***
diff --git a/test/unit/swim_errinj.result b/test/unit/swim_errinj.result
deleted file mode 100644
index c60389d7f..000000000
--- a/test/unit/swim_errinj.result
+++ /dev/null
@@ -1,18 +0,0 @@
-	*** main_f ***
-1..1
-	*** swim_test_payload_refutation ***
-    1..11
-    ok 1 - S2 sees new version of S1
-    ok 2 - S3 does the same
-    ok 3 - but S2 does not known the new payload
-    ok 4 - as well as S3
-    ok 5 - S2 learned S1's payload via anti-entropy
-    ok 6 - version still is the same
-    ok 7 - S3 was blocked and does not know anything
-    ok 8 - version still is the same
-    ok 9 - S2 keeps the same new S1's payload, S3 did not rewrite it
-    ok 10 - S3 still does not know anything
-    ok 11 - S3 learns S1's payload from S2
-ok 1 - subtests
-	*** swim_test_payload_refutation: done ***
-	*** main_f: done ***
diff --git a/test/unit/swim_proto.result b/test/unit/swim_proto.result
deleted file mode 100644
index 8a41a5d40..000000000
--- a/test/unit/swim_proto.result
+++ /dev/null
@@ -1,40 +0,0 @@
-	*** main ***
-1..3
-	*** swim_test_member_def ***
-    1..12
-    ok 1 - not map header
-    ok 2 - not uint member key
-    ok 3 - too big member key
-    ok 4 - STATUS is not uint
-    ok 5 - invalid STATUS
-    ok 6 - invalid address
-    ok 7 - bad port
-    ok 8 - unexpected buffer end
-    ok 9 - unexpected buffer end
-    ok 10 - uuid is nil/undefined
-    ok 11 - port is 0/undefined
-    ok 12 - normal member def
-ok 1 - subtests
-	*** swim_test_member_def: done ***
-	*** swim_test_meta ***
-    1..8
-    ok 1 - not map header
-    ok 2 - not uint meta key
-    ok 3 - unknown meta key
-    ok 4 - unexpected end
-    ok 5 - invalid version
-    ok 6 - port is 0/undefined
-    ok 7 - version is 0/undefined
-    ok 8 - normal meta
-ok 2 - subtests
-	*** swim_test_meta: done ***
-	*** swim_test_route ***
-    1..5
-    ok 1 - route was expected, but map is too short
-    ok 2 - no route map
-    ok 3 - empty route map
-    ok 4 - zero addresses
-    ok 5 - normal route
-ok 3 - subtests
-	*** swim_test_route: done ***
-	*** main: done ***
diff --git a/test/unit/tuple_bigref.result b/test/unit/tuple_bigref.result
deleted file mode 100644
index 6e3f0cfa4..000000000
--- a/test/unit/tuple_bigref.result
+++ /dev/null
@@ -1,17 +0,0 @@
-	*** main ***
-1..2
-	*** test_bigrefs_overall ***
-    1..3
-    ok 1 - All tuples have refs == 1.
-    ok 2 - All tuples have bigrefs.
-    ok 3 - All tuples were deleted.
-	*** test_bigrefs_overall: done ***
-ok 1 - subtests
-	*** test_bigrefs_non_consistent ***
-    1..3
-    ok 1 - All tuples have bigrefs.
-    ok 2 - 11 tuples don't have bigrefs and all other tuples have
-    ok 3 - All tuples have bigrefs and their indexes are in right order.
-	*** test_bigrefs_non_consistent: done ***
-ok 2 - subtests
-	*** main: done ***
diff --git a/test/unit/uri.result b/test/unit/uri.result
deleted file mode 100644
index 804560b69..000000000
--- a/test/unit/uri.result
+++ /dev/null
@@ -1,1307 +0,0 @@
-1..63
-    1..19
-    ok 1 - host: parse
-    ok 2 - host: scheme
-    ok 3 - host: login
-    ok 4 - host: password
-    ok 5 - host: host
-    ok 6 - host: service
-    ok 7 - host: path
-    ok 8 - host: query
-    ok 9 - host: fragment
-    ok 10 - host: host_hint
-    ok 11 - host: parse
-    ok 12 - host: scheme
-    ok 13 - host: login
-    ok 14 - host: password
-    ok 15 - host: host
-    ok 16 - host: service
-    ok 17 - host: path
-    ok 18 - host: query
-    ok 19 - host: fragment
-ok 1 - subtests
-    1..19
-    ok 1 - host/: parse
-    ok 2 - host/: scheme
-    ok 3 - host/: login
-    ok 4 - host/: password
-    ok 5 - host/: host
-    ok 6 - host/: service
-    ok 7 - host/: path
-    ok 8 - host/: query
-    ok 9 - host/: fragment
-    ok 10 - host/: host_hint
-    ok 11 - host/: parse
-    ok 12 - host/: scheme
-    ok 13 - host/: login
-    ok 14 - host/: password
-    ok 15 - host/: host
-    ok 16 - host/: service
-    ok 17 - host/: path
-    ok 18 - host/: query
-    ok 19 - host/: fragment
-ok 2 - subtests
-    1..19
-    ok 1 - host/path1/path2/path3: parse
-    ok 2 - host/path1/path2/path3: scheme
-    ok 3 - host/path1/path2/path3: login
-    ok 4 - host/path1/path2/path3: password
-    ok 5 - host/path1/path2/path3: host
-    ok 6 - host/path1/path2/path3: service
-    ok 7 - host/path1/path2/path3: path
-    ok 8 - host/path1/path2/path3: query
-    ok 9 - host/path1/path2/path3: fragment
-    ok 10 - host/path1/path2/path3: host_hint
-    ok 11 - host/path1/path2/path3: parse
-    ok 12 - host/path1/path2/path3: scheme
-    ok 13 - host/path1/path2/path3: login
-    ok 14 - host/path1/path2/path3: password
-    ok 15 - host/path1/path2/path3: host
-    ok 16 - host/path1/path2/path3: service
-    ok 17 - host/path1/path2/path3: path
-    ok 18 - host/path1/path2/path3: query
-    ok 19 - host/path1/path2/path3: fragment
-ok 3 - subtests
-    1..19
-    ok 1 - host/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 2 - host/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 3 - host/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 4 - host/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 5 - host/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 6 - host/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 7 - host/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 8 - host/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 9 - host/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-    ok 10 - host/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
-    ok 11 - host/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 12 - host/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 13 - host/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 14 - host/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 15 - host/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 16 - host/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 17 - host/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 18 - host/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 19 - host/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-ok 4 - subtests
-    1..19
-    ok 1 - host:service: parse
-    ok 2 - host:service: scheme
-    ok 3 - host:service: login
-    ok 4 - host:service: password
-    ok 5 - host:service: host
-    ok 6 - host:service: service
-    ok 7 - host:service: path
-    ok 8 - host:service: query
-    ok 9 - host:service: fragment
-    ok 10 - host:service: host_hint
-    ok 11 - host:service: parse
-    ok 12 - host:service: scheme
-    ok 13 - host:service: login
-    ok 14 - host:service: password
-    ok 15 - host:service: host
-    ok 16 - host:service: service
-    ok 17 - host:service: path
-    ok 18 - host:service: query
-    ok 19 - host:service: fragment
-ok 5 - subtests
-    1..19
-    ok 1 - host:service/: parse
-    ok 2 - host:service/: scheme
-    ok 3 - host:service/: login
-    ok 4 - host:service/: password
-    ok 5 - host:service/: host
-    ok 6 - host:service/: service
-    ok 7 - host:service/: path
-    ok 8 - host:service/: query
-    ok 9 - host:service/: fragment
-    ok 10 - host:service/: host_hint
-    ok 11 - host:service/: parse
-    ok 12 - host:service/: scheme
-    ok 13 - host:service/: login
-    ok 14 - host:service/: password
-    ok 15 - host:service/: host
-    ok 16 - host:service/: service
-    ok 17 - host:service/: path
-    ok 18 - host:service/: query
-    ok 19 - host:service/: fragment
-ok 6 - subtests
-    1..19
-    ok 1 - host:service/path1/path2/path3: parse
-    ok 2 - host:service/path1/path2/path3: scheme
-    ok 3 - host:service/path1/path2/path3: login
-    ok 4 - host:service/path1/path2/path3: password
-    ok 5 - host:service/path1/path2/path3: host
-    ok 6 - host:service/path1/path2/path3: service
-    ok 7 - host:service/path1/path2/path3: path
-    ok 8 - host:service/path1/path2/path3: query
-    ok 9 - host:service/path1/path2/path3: fragment
-    ok 10 - host:service/path1/path2/path3: host_hint
-    ok 11 - host:service/path1/path2/path3: parse
-    ok 12 - host:service/path1/path2/path3: scheme
-    ok 13 - host:service/path1/path2/path3: login
-    ok 14 - host:service/path1/path2/path3: password
-    ok 15 - host:service/path1/path2/path3: host
-    ok 16 - host:service/path1/path2/path3: service
-    ok 17 - host:service/path1/path2/path3: path
-    ok 18 - host:service/path1/path2/path3: query
-    ok 19 - host:service/path1/path2/path3: fragment
-ok 7 - subtests
-    1..19
-    ok 1 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 2 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 3 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 4 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 5 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 6 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 7 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 8 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 9 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-    ok 10 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
-    ok 11 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 12 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 13 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 14 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 15 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 16 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 17 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 18 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 19 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-ok 8 - subtests
-    1..19
-    ok 1 - login@host: parse
-    ok 2 - login@host: scheme
-    ok 3 - login@host: login
-    ok 4 - login@host: password
-    ok 5 - login@host: host
-    ok 6 - login@host: service
-    ok 7 - login@host: path
-    ok 8 - login@host: query
-    ok 9 - login@host: fragment
-    ok 10 - login@host: host_hint
-    ok 11 - login@host: parse
-    ok 12 - login@host: scheme
-    ok 13 - login@host: login
-    ok 14 - login@host: password
-    ok 15 - login@host: host
-    ok 16 - login@host: service
-    ok 17 - login@host: path
-    ok 18 - login@host: query
-    ok 19 - login@host: fragment
-ok 9 - subtests
-    1..19
-    ok 1 - login@host/: parse
-    ok 2 - login@host/: scheme
-    ok 3 - login@host/: login
-    ok 4 - login@host/: password
-    ok 5 - login@host/: host
-    ok 6 - login@host/: service
-    ok 7 - login@host/: path
-    ok 8 - login@host/: query
-    ok 9 - login@host/: fragment
-    ok 10 - login@host/: host_hint
-    ok 11 - login@host/: parse
-    ok 12 - login@host/: scheme
-    ok 13 - login@host/: login
-    ok 14 - login@host/: password
-    ok 15 - login@host/: host
-    ok 16 - login@host/: service
-    ok 17 - login@host/: path
-    ok 18 - login@host/: query
-    ok 19 - login@host/: fragment
-ok 10 - subtests
-    1..19
-    ok 1 - login@host/path1/path2/path3: parse
-    ok 2 - login@host/path1/path2/path3: scheme
-    ok 3 - login@host/path1/path2/path3: login
-    ok 4 - login@host/path1/path2/path3: password
-    ok 5 - login@host/path1/path2/path3: host
-    ok 6 - login@host/path1/path2/path3: service
-    ok 7 - login@host/path1/path2/path3: path
-    ok 8 - login@host/path1/path2/path3: query
-    ok 9 - login@host/path1/path2/path3: fragment
-    ok 10 - login@host/path1/path2/path3: host_hint
-    ok 11 - login@host/path1/path2/path3: parse
-    ok 12 - login@host/path1/path2/path3: scheme
-    ok 13 - login@host/path1/path2/path3: login
-    ok 14 - login@host/path1/path2/path3: password
-    ok 15 - login@host/path1/path2/path3: host
-    ok 16 - login@host/path1/path2/path3: service
-    ok 17 - login@host/path1/path2/path3: path
-    ok 18 - login@host/path1/path2/path3: query
-    ok 19 - login@host/path1/path2/path3: fragment
-ok 11 - subtests
-    1..19
-    ok 1 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 2 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 3 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 4 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 5 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 6 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 7 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 8 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 9 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-    ok 10 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
-    ok 11 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 12 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 13 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 14 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 15 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 16 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 17 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 18 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 19 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-ok 12 - subtests
-    1..19
-    ok 1 - login:password@host: parse
-    ok 2 - login:password@host: scheme
-    ok 3 - login:password@host: login
-    ok 4 - login:password@host: password
-    ok 5 - login:password@host: host
-    ok 6 - login:password@host: service
-    ok 7 - login:password@host: path
-    ok 8 - login:password@host: query
-    ok 9 - login:password@host: fragment
-    ok 10 - login:password@host: host_hint
-    ok 11 - login:password@host: parse
-    ok 12 - login:password@host: scheme
-    ok 13 - login:password@host: login
-    ok 14 - login:password@host: password
-    ok 15 - login:password@host: host
-    ok 16 - login:password@host: service
-    ok 17 - login:password@host: path
-    ok 18 - login:password@host: query
-    ok 19 - login:password@host: fragment
-ok 13 - subtests
-    1..19
-    ok 1 - login:@host: parse
-    ok 2 - login:@host: scheme
-    ok 3 - login:@host: login
-    ok 4 - login:@host: password
-    ok 5 - login:@host: host
-    ok 6 - login:@host: service
-    ok 7 - login:@host: path
-    ok 8 - login:@host: query
-    ok 9 - login:@host: fragment
-    ok 10 - login:@host: host_hint
-    ok 11 - login:@host: parse
-    ok 12 - login:@host: scheme
-    ok 13 - login:@host: login
-    ok 14 - login:@host: password
-    ok 15 - login:@host: host
-    ok 16 - login:@host: service
-    ok 17 - login:@host: path
-    ok 18 - login:@host: query
-    ok 19 - login:@host: fragment
-ok 14 - subtests
-    1..19
-    ok 1 - login:password@host/: parse
-    ok 2 - login:password@host/: scheme
-    ok 3 - login:password@host/: login
-    ok 4 - login:password@host/: password
-    ok 5 - login:password@host/: host
-    ok 6 - login:password@host/: service
-    ok 7 - login:password@host/: path
-    ok 8 - login:password@host/: query
-    ok 9 - login:password@host/: fragment
-    ok 10 - login:password@host/: host_hint
-    ok 11 - login:password@host/: parse
-    ok 12 - login:password@host/: scheme
-    ok 13 - login:password@host/: login
-    ok 14 - login:password@host/: password
-    ok 15 - login:password@host/: host
-    ok 16 - login:password@host/: service
-    ok 17 - login:password@host/: path
-    ok 18 - login:password@host/: query
-    ok 19 - login:password@host/: fragment
-ok 15 - subtests
-    1..19
-    ok 1 - login:password@host/path1/path2/path3: parse
-    ok 2 - login:password@host/path1/path2/path3: scheme
-    ok 3 - login:password@host/path1/path2/path3: login
-    ok 4 - login:password@host/path1/path2/path3: password
-    ok 5 - login:password@host/path1/path2/path3: host
-    ok 6 - login:password@host/path1/path2/path3: service
-    ok 7 - login:password@host/path1/path2/path3: path
-    ok 8 - login:password@host/path1/path2/path3: query
-    ok 9 - login:password@host/path1/path2/path3: fragment
-    ok 10 - login:password@host/path1/path2/path3: host_hint
-    ok 11 - login:password@host/path1/path2/path3: parse
-    ok 12 - login:password@host/path1/path2/path3: scheme
-    ok 13 - login:password@host/path1/path2/path3: login
-    ok 14 - login:password@host/path1/path2/path3: password
-    ok 15 - login:password@host/path1/path2/path3: host
-    ok 16 - login:password@host/path1/path2/path3: service
-    ok 17 - login:password@host/path1/path2/path3: path
-    ok 18 - login:password@host/path1/path2/path3: query
-    ok 19 - login:password@host/path1/path2/path3: fragment
-ok 16 - subtests
-    1..19
-    ok 1 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 2 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 3 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 4 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 5 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 6 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 7 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 8 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 9 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-    ok 10 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
-    ok 11 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 12 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 13 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 14 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 15 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 16 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 17 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 18 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 19 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-ok 17 - subtests
-    1..19
-    ok 1 - login:password@host:service: parse
-    ok 2 - login:password@host:service: scheme
-    ok 3 - login:password@host:service: login
-    ok 4 - login:password@host:service: password
-    ok 5 - login:password@host:service: host
-    ok 6 - login:password@host:service: service
-    ok 7 - login:password@host:service: path
-    ok 8 - login:password@host:service: query
-    ok 9 - login:password@host:service: fragment
-    ok 10 - login:password@host:service: host_hint
-    ok 11 - login:password@host:service: parse
-    ok 12 - login:password@host:service: scheme
-    ok 13 - login:password@host:service: login
-    ok 14 - login:password@host:service: password
-    ok 15 - login:password@host:service: host
-    ok 16 - login:password@host:service: service
-    ok 17 - login:password@host:service: path
-    ok 18 - login:password@host:service: query
-    ok 19 - login:password@host:service: fragment
-ok 18 - subtests
-    1..19
-    ok 1 - login:password@host:service/: parse
-    ok 2 - login:password@host:service/: scheme
-    ok 3 - login:password@host:service/: login
-    ok 4 - login:password@host:service/: password
-    ok 5 - login:password@host:service/: host
-    ok 6 - login:password@host:service/: service
-    ok 7 - login:password@host:service/: path
-    ok 8 - login:password@host:service/: query
-    ok 9 - login:password@host:service/: fragment
-    ok 10 - login:password@host:service/: host_hint
-    ok 11 - login:password@host:service/: parse
-    ok 12 - login:password@host:service/: scheme
-    ok 13 - login:password@host:service/: login
-    ok 14 - login:password@host:service/: password
-    ok 15 - login:password@host:service/: host
-    ok 16 - login:password@host:service/: service
-    ok 17 - login:password@host:service/: path
-    ok 18 - login:password@host:service/: query
-    ok 19 - login:password@host:service/: fragment
-ok 19 - subtests
-    1..19
-    ok 1 - login:password@host:service/path1/path2/path3: parse
-    ok 2 - login:password@host:service/path1/path2/path3: scheme
-    ok 3 - login:password@host:service/path1/path2/path3: login
-    ok 4 - login:password@host:service/path1/path2/path3: password
-    ok 5 - login:password@host:service/path1/path2/path3: host
-    ok 6 - login:password@host:service/path1/path2/path3: service
-    ok 7 - login:password@host:service/path1/path2/path3: path
-    ok 8 - login:password@host:service/path1/path2/path3: query
-    ok 9 - login:password@host:service/path1/path2/path3: fragment
-    ok 10 - login:password@host:service/path1/path2/path3: host_hint
-    ok 11 - login:password@host:service/path1/path2/path3: parse
-    ok 12 - login:password@host:service/path1/path2/path3: scheme
-    ok 13 - login:password@host:service/path1/path2/path3: login
-    ok 14 - login:password@host:service/path1/path2/path3: password
-    ok 15 - login:password@host:service/path1/path2/path3: host
-    ok 16 - login:password@host:service/path1/path2/path3: service
-    ok 17 - login:password@host:service/path1/path2/path3: path
-    ok 18 - login:password@host:service/path1/path2/path3: query
-    ok 19 - login:password@host:service/path1/path2/path3: fragment
-ok 20 - subtests
-    1..19
-    ok 1 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 2 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 3 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 4 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 5 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 6 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 7 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 8 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 9 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-    ok 10 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
-    ok 11 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 12 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 13 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 14 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 15 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 16 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 17 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 18 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 19 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-ok 21 - subtests
-    1..19
-    ok 1 - scheme://login:password@host:service: parse
-    ok 2 - scheme://login:password@host:service: scheme
-    ok 3 - scheme://login:password@host:service: login
-    ok 4 - scheme://login:password@host:service: password
-    ok 5 - scheme://login:password@host:service: host
-    ok 6 - scheme://login:password@host:service: service
-    ok 7 - scheme://login:password@host:service: path
-    ok 8 - scheme://login:password@host:service: query
-    ok 9 - scheme://login:password@host:service: fragment
-    ok 10 - scheme://login:password@host:service: host_hint
-    ok 11 - scheme://login:password@host:service: parse
-    ok 12 - scheme://login:password@host:service: scheme
-    ok 13 - scheme://login:password@host:service: login
-    ok 14 - scheme://login:password@host:service: password
-    ok 15 - scheme://login:password@host:service: host
-    ok 16 - scheme://login:password@host:service: service
-    ok 17 - scheme://login:password@host:service: path
-    ok 18 - scheme://login:password@host:service: query
-    ok 19 - scheme://login:password@host:service: fragment
-ok 22 - subtests
-    1..19
-    ok 1 - scheme://login:password@host:service/: parse
-    ok 2 - scheme://login:password@host:service/: scheme
-    ok 3 - scheme://login:password@host:service/: login
-    ok 4 - scheme://login:password@host:service/: password
-    ok 5 - scheme://login:password@host:service/: host
-    ok 6 - scheme://login:password@host:service/: service
-    ok 7 - scheme://login:password@host:service/: path
-    ok 8 - scheme://login:password@host:service/: query
-    ok 9 - scheme://login:password@host:service/: fragment
-    ok 10 - scheme://login:password@host:service/: host_hint
-    ok 11 - scheme://login:password@host:service/: parse
-    ok 12 - scheme://login:password@host:service/: scheme
-    ok 13 - scheme://login:password@host:service/: login
-    ok 14 - scheme://login:password@host:service/: password
-    ok 15 - scheme://login:password@host:service/: host
-    ok 16 - scheme://login:password@host:service/: service
-    ok 17 - scheme://login:password@host:service/: path
-    ok 18 - scheme://login:password@host:service/: query
-    ok 19 - scheme://login:password@host:service/: fragment
-ok 23 - subtests
-    1..19
-    ok 1 - scheme://login:password@host:service/path1/path2/path3: parse
-    ok 2 - scheme://login:password@host:service/path1/path2/path3: scheme
-    ok 3 - scheme://login:password@host:service/path1/path2/path3: login
-    ok 4 - scheme://login:password@host:service/path1/path2/path3: password
-    ok 5 - scheme://login:password@host:service/path1/path2/path3: host
-    ok 6 - scheme://login:password@host:service/path1/path2/path3: service
-    ok 7 - scheme://login:password@host:service/path1/path2/path3: path
-    ok 8 - scheme://login:password@host:service/path1/path2/path3: query
-    ok 9 - scheme://login:password@host:service/path1/path2/path3: fragment
-    ok 10 - scheme://login:password@host:service/path1/path2/path3: host_hint
-    ok 11 - scheme://login:password@host:service/path1/path2/path3: parse
-    ok 12 - scheme://login:password@host:service/path1/path2/path3: scheme
-    ok 13 - scheme://login:password@host:service/path1/path2/path3: login
-    ok 14 - scheme://login:password@host:service/path1/path2/path3: password
-    ok 15 - scheme://login:password@host:service/path1/path2/path3: host
-    ok 16 - scheme://login:password@host:service/path1/path2/path3: service
-    ok 17 - scheme://login:password@host:service/path1/path2/path3: path
-    ok 18 - scheme://login:password@host:service/path1/path2/path3: query
-    ok 19 - scheme://login:password@host:service/path1/path2/path3: fragment
-ok 24 - subtests
-    1..19
-    ok 1 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 2 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 3 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 4 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 5 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 6 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 7 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 8 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 9 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-    ok 10 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
-    ok 11 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 12 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 13 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 14 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 15 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 16 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 17 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 18 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 19 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-ok 25 - subtests
-    1..19
-    ok 1 - host/path: parse
-    ok 2 - host/path: scheme
-    ok 3 - host/path: login
-    ok 4 - host/path: password
-    ok 5 - host/path: host
-    ok 6 - host/path: service
-    ok 7 - host/path: path
-    ok 8 - host/path: query
-    ok 9 - host/path: fragment
-    ok 10 - host/path: host_hint
-    ok 11 - host/path: parse
-    ok 12 - host/path: scheme
-    ok 13 - host/path: login
-    ok 14 - host/path: password
-    ok 15 - host/path: host
-    ok 16 - host/path: service
-    ok 17 - host/path: path
-    ok 18 - host/path: query
-    ok 19 - host/path: fragment
-ok 26 - subtests
-    1..19
-    ok 1 - host//: parse
-    ok 2 - host//: scheme
-    ok 3 - host//: login
-    ok 4 - host//: password
-    ok 5 - host//: host
-    ok 6 - host//: service
-    ok 7 - host//: path
-    ok 8 - host//: query
-    ok 9 - host//: fragment
-    ok 10 - host//: host_hint
-    ok 11 - host//: parse
-    ok 12 - host//: scheme
-    ok 13 - host//: login
-    ok 14 - host//: password
-    ok 15 - host//: host
-    ok 16 - host//: service
-    ok 17 - host//: path
-    ok 18 - host//: query
-    ok 19 - host//: fragment
-ok 27 - subtests
-    1..19
-    ok 1 - host//path: parse
-    ok 2 - host//path: scheme
-    ok 3 - host//path: login
-    ok 4 - host//path: password
-    ok 5 - host//path: host
-    ok 6 - host//path: service
-    ok 7 - host//path: path
-    ok 8 - host//path: query
-    ok 9 - host//path: fragment
-    ok 10 - host//path: host_hint
-    ok 11 - host//path: parse
-    ok 12 - host//path: scheme
-    ok 13 - host//path: login
-    ok 14 - host//path: password
-    ok 15 - host//path: host
-    ok 16 - host//path: service
-    ok 17 - host//path: path
-    ok 18 - host//path: query
-    ok 19 - host//path: fragment
-ok 28 - subtests
-    1..19
-    ok 1 - host/;abc?q: parse
-    ok 2 - host/;abc?q: scheme
-    ok 3 - host/;abc?q: login
-    ok 4 - host/;abc?q: password
-    ok 5 - host/;abc?q: host
-    ok 6 - host/;abc?q: service
-    ok 7 - host/;abc?q: path
-    ok 8 - host/;abc?q: query
-    ok 9 - host/;abc?q: fragment
-    ok 10 - host/;abc?q: host_hint
-    ok 11 - host/;abc?q: parse
-    ok 12 - host/;abc?q: scheme
-    ok 13 - host/;abc?q: login
-    ok 14 - host/;abc?q: password
-    ok 15 - host/;abc?q: host
-    ok 16 - host/;abc?q: service
-    ok 17 - host/;abc?q: path
-    ok 18 - host/;abc?q: query
-    ok 19 - host/;abc?q: fragment
-ok 29 - subtests
-    1..19
-    ok 1 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: parse
-    ok 2 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: scheme
-    ok 3 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: login
-    ok 4 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: password
-    ok 5 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: host
-    ok 6 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: service
-    ok 7 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: path
-    ok 8 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: query
-    ok 9 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: fragment
-    ok 10 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: host_hint
-    ok 11 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: parse
-    ok 12 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: scheme
-    ok 13 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: login
-    ok 14 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: password
-    ok 15 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: host
-    ok 16 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: service
-    ok 17 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: path
-    ok 18 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: query
-    ok 19 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: fragment
-ok 30 - subtests
-    1..19
-    ok 1 - host/~user: parse
-    ok 2 - host/~user: scheme
-    ok 3 - host/~user: login
-    ok 4 - host/~user: password
-    ok 5 - host/~user: host
-    ok 6 - host/~user: service
-    ok 7 - host/~user: path
-    ok 8 - host/~user: query
-    ok 9 - host/~user: fragment
-    ok 10 - host/~user: host_hint
-    ok 11 - host/~user: parse
-    ok 12 - host/~user: scheme
-    ok 13 - host/~user: login
-    ok 14 - host/~user: password
-    ok 15 - host/~user: host
-    ok 16 - host/~user: service
-    ok 17 - host/~user: path
-    ok 18 - host/~user: query
-    ok 19 - host/~user: fragment
-ok 31 - subtests
-    1..19
-    ok 1 - try.tarantool.org: parse
-    ok 2 - try.tarantool.org: scheme
-    ok 3 - try.tarantool.org: login
-    ok 4 - try.tarantool.org: password
-    ok 5 - try.tarantool.org: host
-    ok 6 - try.tarantool.org: service
-    ok 7 - try.tarantool.org: path
-    ok 8 - try.tarantool.org: query
-    ok 9 - try.tarantool.org: fragment
-    ok 10 - try.tarantool.org: host_hint
-    ok 11 - try.tarantool.org: parse
-    ok 12 - try.tarantool.org: scheme
-    ok 13 - try.tarantool.org: login
-    ok 14 - try.tarantool.org: password
-    ok 15 - try.tarantool.org: host
-    ok 16 - try.tarantool.org: service
-    ok 17 - try.tarantool.org: path
-    ok 18 - try.tarantool.org: query
-    ok 19 - try.tarantool.org: fragment
-ok 32 - subtests
-    1..19
-    ok 1 - try.tarantool.org: parse
-    ok 2 - try.tarantool.org: scheme
-    ok 3 - try.tarantool.org: login
-    ok 4 - try.tarantool.org: password
-    ok 5 - try.tarantool.org: host
-    ok 6 - try.tarantool.org: service
-    ok 7 - try.tarantool.org: path
-    ok 8 - try.tarantool.org: query
-    ok 9 - try.tarantool.org: fragment
-    ok 10 - try.tarantool.org: host_hint
-    ok 11 - try.tarantool.org: parse
-    ok 12 - try.tarantool.org: scheme
-    ok 13 - try.tarantool.org: login
-    ok 14 - try.tarantool.org: password
-    ok 15 - try.tarantool.org: host
-    ok 16 - try.tarantool.org: service
-    ok 17 - try.tarantool.org: path
-    ok 18 - try.tarantool.org: query
-    ok 19 - try.tarantool.org: fragment
-ok 33 - subtests
-    1..19
-    ok 1 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: parse
-    ok 2 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: scheme
-    ok 3 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: login
-    ok 4 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: password
-    ok 5 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: host
-    ok 6 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: service
-    ok 7 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: path
-    ok 8 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: query
-    ok 9 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: fragment
-    ok 10 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: host_hint
-    ok 11 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: parse
-    ok 12 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: scheme
-    ok 13 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: login
-    ok 14 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: password
-    ok 15 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: host
-    ok 16 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: service
-    ok 17 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: path
-    ok 18 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: query
-    ok 19 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: fragment
-ok 34 - subtests
-    1..19
-    ok 1 - 0.0.0.0: parse
-    ok 2 - 0.0.0.0: scheme
-    ok 3 - 0.0.0.0: login
-    ok 4 - 0.0.0.0: password
-    ok 5 - 0.0.0.0: host
-    ok 6 - 0.0.0.0: service
-    ok 7 - 0.0.0.0: path
-    ok 8 - 0.0.0.0: query
-    ok 9 - 0.0.0.0: fragment
-    ok 10 - 0.0.0.0: host_hint
-    ok 11 - 0.0.0.0: parse
-    ok 12 - 0.0.0.0: scheme
-    ok 13 - 0.0.0.0: login
-    ok 14 - 0.0.0.0: password
-    ok 15 - 0.0.0.0: host
-    ok 16 - 0.0.0.0: service
-    ok 17 - 0.0.0.0: path
-    ok 18 - 0.0.0.0: query
-    ok 19 - 0.0.0.0: fragment
-ok 35 - subtests
-    1..19
-    ok 1 - 127.0.0.1: parse
-    ok 2 - 127.0.0.1: scheme
-    ok 3 - 127.0.0.1: login
-    ok 4 - 127.0.0.1: password
-    ok 5 - 127.0.0.1: host
-    ok 6 - 127.0.0.1: service
-    ok 7 - 127.0.0.1: path
-    ok 8 - 127.0.0.1: query
-    ok 9 - 127.0.0.1: fragment
-    ok 10 - 127.0.0.1: host_hint
-    ok 11 - 127.0.0.1: parse
-    ok 12 - 127.0.0.1: scheme
-    ok 13 - 127.0.0.1: login
-    ok 14 - 127.0.0.1: password
-    ok 15 - 127.0.0.1: host
-    ok 16 - 127.0.0.1: service
-    ok 17 - 127.0.0.1: path
-    ok 18 - 127.0.0.1: query
-    ok 19 - 127.0.0.1: fragment
-ok 36 - subtests
-    1..19
-    ok 1 - 127.0.0.1:3313: parse
-    ok 2 - 127.0.0.1:3313: scheme
-    ok 3 - 127.0.0.1:3313: login
-    ok 4 - 127.0.0.1:3313: password
-    ok 5 - 127.0.0.1:3313: host
-    ok 6 - 127.0.0.1:3313: service
-    ok 7 - 127.0.0.1:3313: path
-    ok 8 - 127.0.0.1:3313: query
-    ok 9 - 127.0.0.1:3313: fragment
-    ok 10 - 127.0.0.1:3313: host_hint
-    ok 11 - 127.0.0.1:3313: parse
-    ok 12 - 127.0.0.1:3313: scheme
-    ok 13 - 127.0.0.1:3313: login
-    ok 14 - 127.0.0.1:3313: password
-    ok 15 - 127.0.0.1:3313: host
-    ok 16 - 127.0.0.1:3313: service
-    ok 17 - 127.0.0.1:3313: path
-    ok 18 - 127.0.0.1:3313: query
-    ok 19 - 127.0.0.1:3313: fragment
-ok 37 - subtests
-    1..19
-    ok 1 - scheme://login:password@127.0.0.1:3313: parse
-    ok 2 - scheme://login:password@127.0.0.1:3313: scheme
-    ok 3 - scheme://login:password@127.0.0.1:3313: login
-    ok 4 - scheme://login:password@127.0.0.1:3313: password
-    ok 5 - scheme://login:password@127.0.0.1:3313: host
-    ok 6 - scheme://login:password@127.0.0.1:3313: service
-    ok 7 - scheme://login:password@127.0.0.1:3313: path
-    ok 8 - scheme://login:password@127.0.0.1:3313: query
-    ok 9 - scheme://login:password@127.0.0.1:3313: fragment
-    ok 10 - scheme://login:password@127.0.0.1:3313: host_hint
-    ok 11 - scheme://login:password@127.0.0.1:3313: parse
-    ok 12 - scheme://login:password@127.0.0.1:3313: scheme
-    ok 13 - scheme://login:password@127.0.0.1:3313: login
-    ok 14 - scheme://login:password@127.0.0.1:3313: password
-    ok 15 - scheme://login:password@127.0.0.1:3313: host
-    ok 16 - scheme://login:password@127.0.0.1:3313: service
-    ok 17 - scheme://login:password@127.0.0.1:3313: path
-    ok 18 - scheme://login:password@127.0.0.1:3313: query
-    ok 19 - scheme://login:password@127.0.0.1:3313: fragment
-ok 38 - subtests
-    1..19
-    ok 1 - [2001::11a3:09d7::1]: parse
-    ok 2 - [2001::11a3:09d7::1]: scheme
-    ok 3 - [2001::11a3:09d7::1]: login
-    ok 4 - [2001::11a3:09d7::1]: password
-    ok 5 - [2001::11a3:09d7::1]: host
-    ok 6 - [2001::11a3:09d7::1]: service
-    ok 7 - [2001::11a3:09d7::1]: path
-    ok 8 - [2001::11a3:09d7::1]: query
-    ok 9 - [2001::11a3:09d7::1]: fragment
-    ok 10 - [2001::11a3:09d7::1]: host_hint
-    ok 11 - [2001::11a3:09d7::1]: parse
-    ok 12 - [2001::11a3:09d7::1]: scheme
-    ok 13 - [2001::11a3:09d7::1]: login
-    ok 14 - [2001::11a3:09d7::1]: password
-    ok 15 - [2001::11a3:09d7::1]: host
-    ok 16 - [2001::11a3:09d7::1]: service
-    ok 17 - [2001::11a3:09d7::1]: path
-    ok 18 - [2001::11a3:09d7::1]: query
-    ok 19 - [2001::11a3:09d7::1]: fragment
-ok 39 - subtests
-    1..19
-    ok 1 - scheme://login:password@[2001::11a3:09d7::1]:3313: parse
-    ok 2 - scheme://login:password@[2001::11a3:09d7::1]:3313: scheme
-    ok 3 - scheme://login:password@[2001::11a3:09d7::1]:3313: login
-    ok 4 - scheme://login:password@[2001::11a3:09d7::1]:3313: password
-    ok 5 - scheme://login:password@[2001::11a3:09d7::1]:3313: host
-    ok 6 - scheme://login:password@[2001::11a3:09d7::1]:3313: service
-    ok 7 - scheme://login:password@[2001::11a3:09d7::1]:3313: path
-    ok 8 - scheme://login:password@[2001::11a3:09d7::1]:3313: query
-    ok 9 - scheme://login:password@[2001::11a3:09d7::1]:3313: fragment
-    ok 10 - scheme://login:password@[2001::11a3:09d7::1]:3313: host_hint
-    ok 11 - scheme://login:password@[2001::11a3:09d7::1]:3313: parse
-    ok 12 - scheme://login:password@[2001::11a3:09d7::1]:3313: scheme
-    ok 13 - scheme://login:password@[2001::11a3:09d7::1]:3313: login
-    ok 14 - scheme://login:password@[2001::11a3:09d7::1]:3313: password
-    ok 15 - scheme://login:password@[2001::11a3:09d7::1]:3313: host
-    ok 16 - scheme://login:password@[2001::11a3:09d7::1]:3313: service
-    ok 17 - scheme://login:password@[2001::11a3:09d7::1]:3313: path
-    ok 18 - scheme://login:password@[2001::11a3:09d7::1]:3313: query
-    ok 19 - scheme://login:password@[2001::11a3:09d7::1]:3313: fragment
-ok 40 - subtests
-    1..19
-    ok 1 - scheme://[2001:0db8:11a3:09d7::1]: parse
-    ok 2 - scheme://[2001:0db8:11a3:09d7::1]: scheme
-    ok 3 - scheme://[2001:0db8:11a3:09d7::1]: login
-    ok 4 - scheme://[2001:0db8:11a3:09d7::1]: password
-    ok 5 - scheme://[2001:0db8:11a3:09d7::1]: host
-    ok 6 - scheme://[2001:0db8:11a3:09d7::1]: service
-    ok 7 - scheme://[2001:0db8:11a3:09d7::1]: path
-    ok 8 - scheme://[2001:0db8:11a3:09d7::1]: query
-    ok 9 - scheme://[2001:0db8:11a3:09d7::1]: fragment
-    ok 10 - scheme://[2001:0db8:11a3:09d7::1]: host_hint
-    ok 11 - scheme://[2001:0db8:11a3:09d7::1]: parse
-    ok 12 - scheme://[2001:0db8:11a3:09d7::1]: scheme
-    ok 13 - scheme://[2001:0db8:11a3:09d7::1]: login
-    ok 14 - scheme://[2001:0db8:11a3:09d7::1]: password
-    ok 15 - scheme://[2001:0db8:11a3:09d7::1]: host
-    ok 16 - scheme://[2001:0db8:11a3:09d7::1]: service
-    ok 17 - scheme://[2001:0db8:11a3:09d7::1]: path
-    ok 18 - scheme://[2001:0db8:11a3:09d7::1]: query
-    ok 19 - scheme://[2001:0db8:11a3:09d7::1]: fragment
-ok 41 - subtests
-    1..19
-    ok 1 - [::ffff:11.2.3.4]: parse
-    ok 2 - [::ffff:11.2.3.4]: scheme
-    ok 3 - [::ffff:11.2.3.4]: login
-    ok 4 - [::ffff:11.2.3.4]: password
-    ok 5 - [::ffff:11.2.3.4]: host
-    ok 6 - [::ffff:11.2.3.4]: service
-    ok 7 - [::ffff:11.2.3.4]: path
-    ok 8 - [::ffff:11.2.3.4]: query
-    ok 9 - [::ffff:11.2.3.4]: fragment
-    ok 10 - [::ffff:11.2.3.4]: host_hint
-    ok 11 - [::ffff:11.2.3.4]: parse
-    ok 12 - [::ffff:11.2.3.4]: scheme
-    ok 13 - [::ffff:11.2.3.4]: login
-    ok 14 - [::ffff:11.2.3.4]: password
-    ok 15 - [::ffff:11.2.3.4]: host
-    ok 16 - [::ffff:11.2.3.4]: service
-    ok 17 - [::ffff:11.2.3.4]: path
-    ok 18 - [::ffff:11.2.3.4]: query
-    ok 19 - [::ffff:11.2.3.4]: fragment
-ok 42 - subtests
-    1..19
-    ok 1 - scheme://login:password@[::ffff:11.2.3.4]:3313: parse
-    ok 2 - scheme://login:password@[::ffff:11.2.3.4]:3313: scheme
-    ok 3 - scheme://login:password@[::ffff:11.2.3.4]:3313: login
-    ok 4 - scheme://login:password@[::ffff:11.2.3.4]:3313: password
-    ok 5 - scheme://login:password@[::ffff:11.2.3.4]:3313: host
-    ok 6 - scheme://login:password@[::ffff:11.2.3.4]:3313: service
-    ok 7 - scheme://login:password@[::ffff:11.2.3.4]:3313: path
-    ok 8 - scheme://login:password@[::ffff:11.2.3.4]:3313: query
-    ok 9 - scheme://login:password@[::ffff:11.2.3.4]:3313: fragment
-    ok 10 - scheme://login:password@[::ffff:11.2.3.4]:3313: host_hint
-    ok 11 - scheme://login:password@[::ffff:11.2.3.4]:3313: parse
-    ok 12 - scheme://login:password@[::ffff:11.2.3.4]:3313: scheme
-    ok 13 - scheme://login:password@[::ffff:11.2.3.4]:3313: login
-    ok 14 - scheme://login:password@[::ffff:11.2.3.4]:3313: password
-    ok 15 - scheme://login:password@[::ffff:11.2.3.4]:3313: host
-    ok 16 - scheme://login:password@[::ffff:11.2.3.4]:3313: service
-    ok 17 - scheme://login:password@[::ffff:11.2.3.4]:3313: path
-    ok 18 - scheme://login:password@[::ffff:11.2.3.4]:3313: query
-    ok 19 - scheme://login:password@[::ffff:11.2.3.4]:3313: fragment
-ok 43 - subtests
-    1..19
-    ok 1 - 1: parse
-    ok 2 - 1: scheme
-    ok 3 - 1: login
-    ok 4 - 1: password
-    ok 5 - 1: host
-    ok 6 - 1: service
-    ok 7 - 1: path
-    ok 8 - 1: query
-    ok 9 - 1: fragment
-    ok 10 - 1: host_hint
-    ok 11 - 1: parse
-    ok 12 - 1: scheme
-    ok 13 - 1: login
-    ok 14 - 1: password
-    ok 15 - 1: host
-    ok 16 - 1: service
-    ok 17 - 1: path
-    ok 18 - 1: query
-    ok 19 - 1: fragment
-ok 44 - subtests
-    1..19
-    ok 1 - 10: parse
-    ok 2 - 10: scheme
-    ok 3 - 10: login
-    ok 4 - 10: password
-    ok 5 - 10: host
-    ok 6 - 10: service
-    ok 7 - 10: path
-    ok 8 - 10: query
-    ok 9 - 10: fragment
-    ok 10 - 10: host_hint
-    ok 11 - 10: parse
-    ok 12 - 10: scheme
-    ok 13 - 10: login
-    ok 14 - 10: password
-    ok 15 - 10: host
-    ok 16 - 10: service
-    ok 17 - 10: path
-    ok 18 - 10: query
-    ok 19 - 10: fragment
-ok 45 - subtests
-    1..19
-    ok 1 - 331: parse
-    ok 2 - 331: scheme
-    ok 3 - 331: login
-    ok 4 - 331: password
-    ok 5 - 331: host
-    ok 6 - 331: service
-    ok 7 - 331: path
-    ok 8 - 331: query
-    ok 9 - 331: fragment
-    ok 10 - 331: host_hint
-    ok 11 - 331: parse
-    ok 12 - 331: scheme
-    ok 13 - 331: login
-    ok 14 - 331: password
-    ok 15 - 331: host
-    ok 16 - 331: service
-    ok 17 - 331: path
-    ok 18 - 331: query
-    ok 19 - 331: fragment
-ok 46 - subtests
-    1..19
-    ok 1 - 3313: parse
-    ok 2 - 3313: scheme
-    ok 3 - 3313: login
-    ok 4 - 3313: password
-    ok 5 - 3313: host
-    ok 6 - 3313: service
-    ok 7 - 3313: path
-    ok 8 - 3313: query
-    ok 9 - 3313: fragment
-    ok 10 - 3313: host_hint
-    ok 11 - 3313: parse
-    ok 12 - 3313: scheme
-    ok 13 - 3313: login
-    ok 14 - 3313: password
-    ok 15 - 3313: host
-    ok 16 - 3313: service
-    ok 17 - 3313: path
-    ok 18 - 3313: query
-    ok 19 - 3313: fragment
-ok 47 - subtests
-    1..19
-    ok 1 - /: parse
-    ok 2 - /: scheme
-    ok 3 - /: login
-    ok 4 - /: password
-    ok 5 - /: host
-    ok 6 - /: service
-    ok 7 - /: path
-    ok 8 - /: query
-    ok 9 - /: fragment
-    ok 10 - /: host_hint
-    ok 11 - /: parse
-    ok 12 - /: scheme
-    ok 13 - /: login
-    ok 14 - /: password
-    ok 15 - /: host
-    ok 16 - /: service
-    ok 17 - /: path
-    ok 18 - /: query
-    ok 19 - /: fragment
-ok 48 - subtests
-    1..19
-    ok 1 - /path1/path2/path3: parse
-    ok 2 - /path1/path2/path3: scheme
-    ok 3 - /path1/path2/path3: login
-    ok 4 - /path1/path2/path3: password
-    ok 5 - /path1/path2/path3: host
-    ok 6 - /path1/path2/path3: service
-    ok 7 - /path1/path2/path3: path
-    ok 8 - /path1/path2/path3: query
-    ok 9 - /path1/path2/path3: fragment
-    ok 10 - /path1/path2/path3: host_hint
-    ok 11 - /path1/path2/path3: parse
-    ok 12 - /path1/path2/path3: scheme
-    ok 13 - /path1/path2/path3: login
-    ok 14 - /path1/path2/path3: password
-    ok 15 - /path1/path2/path3: host
-    ok 16 - /path1/path2/path3: service
-    ok 17 - /path1/path2/path3: path
-    ok 18 - /path1/path2/path3: query
-    ok 19 - /path1/path2/path3: fragment
-ok 49 - subtests
-    1..19
-    ok 1 - login:password@/path1/path2/path3: parse
-    ok 2 - login:password@/path1/path2/path3: scheme
-    ok 3 - login:password@/path1/path2/path3: login
-    ok 4 - login:password@/path1/path2/path3: password
-    ok 5 - login:password@/path1/path2/path3: host
-    ok 6 - login:password@/path1/path2/path3: service
-    ok 7 - login:password@/path1/path2/path3: path
-    ok 8 - login:password@/path1/path2/path3: query
-    ok 9 - login:password@/path1/path2/path3: fragment
-    ok 10 - login:password@/path1/path2/path3: host_hint
-    ok 11 - login:password@/path1/path2/path3: parse
-    ok 12 - login:password@/path1/path2/path3: scheme
-    ok 13 - login:password@/path1/path2/path3: login
-    ok 14 - login:password@/path1/path2/path3: password
-    ok 15 - login:password@/path1/path2/path3: host
-    ok 16 - login:password@/path1/path2/path3: service
-    ok 17 - login:password@/path1/path2/path3: path
-    ok 18 - login:password@/path1/path2/path3: query
-    ok 19 - login:password@/path1/path2/path3: fragment
-ok 50 - subtests
-    1..19
-    ok 1 - unix/:/path1/path2/path3: parse
-    ok 2 - unix/:/path1/path2/path3: scheme
-    ok 3 - unix/:/path1/path2/path3: login
-    ok 4 - unix/:/path1/path2/path3: password
-    ok 5 - unix/:/path1/path2/path3: host
-    ok 6 - unix/:/path1/path2/path3: service
-    ok 7 - unix/:/path1/path2/path3: path
-    ok 8 - unix/:/path1/path2/path3: query
-    ok 9 - unix/:/path1/path2/path3: fragment
-    ok 10 - unix/:/path1/path2/path3: host_hint
-    ok 11 - unix/:/path1/path2/path3: parse
-    ok 12 - unix/:/path1/path2/path3: scheme
-    ok 13 - unix/:/path1/path2/path3: login
-    ok 14 - unix/:/path1/path2/path3: password
-    ok 15 - unix/:/path1/path2/path3: host
-    ok 16 - unix/:/path1/path2/path3: service
-    ok 17 - unix/:/path1/path2/path3: path
-    ok 18 - unix/:/path1/path2/path3: query
-    ok 19 - unix/:/path1/path2/path3: fragment
-ok 51 - subtests
-    1..19
-    ok 1 - unix/:/path1/path2/path3:: parse
-    ok 2 - unix/:/path1/path2/path3:: scheme
-    ok 3 - unix/:/path1/path2/path3:: login
-    ok 4 - unix/:/path1/path2/path3:: password
-    ok 5 - unix/:/path1/path2/path3:: host
-    ok 6 - unix/:/path1/path2/path3:: service
-    ok 7 - unix/:/path1/path2/path3:: path
-    ok 8 - unix/:/path1/path2/path3:: query
-    ok 9 - unix/:/path1/path2/path3:: fragment
-    ok 10 - unix/:/path1/path2/path3:: host_hint
-    ok 11 - unix/:/path1/path2/path3:: parse
-    ok 12 - unix/:/path1/path2/path3:: scheme
-    ok 13 - unix/:/path1/path2/path3:: login
-    ok 14 - unix/:/path1/path2/path3:: password
-    ok 15 - unix/:/path1/path2/path3:: host
-    ok 16 - unix/:/path1/path2/path3:: service
-    ok 17 - unix/:/path1/path2/path3:: path
-    ok 18 - unix/:/path1/path2/path3:: query
-    ok 19 - unix/:/path1/path2/path3:: fragment
-ok 52 - subtests
-    1..19
-    ok 1 - unix/:/path1/path2/path3:/: parse
-    ok 2 - unix/:/path1/path2/path3:/: scheme
-    ok 3 - unix/:/path1/path2/path3:/: login
-    ok 4 - unix/:/path1/path2/path3:/: password
-    ok 5 - unix/:/path1/path2/path3:/: host
-    ok 6 - unix/:/path1/path2/path3:/: service
-    ok 7 - unix/:/path1/path2/path3:/: path
-    ok 8 - unix/:/path1/path2/path3:/: query
-    ok 9 - unix/:/path1/path2/path3:/: fragment
-    ok 10 - unix/:/path1/path2/path3:/: host_hint
-    ok 11 - unix/:/path1/path2/path3:/: parse
-    ok 12 - unix/:/path1/path2/path3:/: scheme
-    ok 13 - unix/:/path1/path2/path3:/: login
-    ok 14 - unix/:/path1/path2/path3:/: password
-    ok 15 - unix/:/path1/path2/path3:/: host
-    ok 16 - unix/:/path1/path2/path3:/: service
-    ok 17 - unix/:/path1/path2/path3:/: path
-    ok 18 - unix/:/path1/path2/path3:/: query
-    ok 19 - unix/:/path1/path2/path3:/: fragment
-ok 53 - subtests
-    1..19
-    ok 1 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 2 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 3 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 4 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 5 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 6 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 7 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 8 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 9 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-    ok 10 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
-    ok 11 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: parse
-    ok 12 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
-    ok 13 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: login
-    ok 14 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: password
-    ok 15 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: host
-    ok 16 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: service
-    ok 17 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: path
-    ok 18 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: query
-    ok 19 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
-ok 54 - subtests
-    1..19
-    ok 1 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: parse
-    ok 2 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: scheme
-    ok 3 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: login
-    ok 4 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: password
-    ok 5 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: host
-    ok 6 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: service
-    ok 7 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: path
-    ok 8 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: query
-    ok 9 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: fragment
-    ok 10 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: host_hint
-    ok 11 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: parse
-    ok 12 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: scheme
-    ok 13 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: login
-    ok 14 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: password
-    ok 15 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: host
-    ok 16 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: service
-    ok 17 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: path
-    ok 18 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: query
-    ok 19 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: fragment
-ok 55 - subtests
-    1..19
-    ok 1 - login:password@unix/:/path1/path2/path3: parse
-    ok 2 - login:password@unix/:/path1/path2/path3: scheme
-    ok 3 - login:password@unix/:/path1/path2/path3: login
-    ok 4 - login:password@unix/:/path1/path2/path3: password
-    ok 5 - login:password@unix/:/path1/path2/path3: host
-    ok 6 - login:password@unix/:/path1/path2/path3: service
-    ok 7 - login:password@unix/:/path1/path2/path3: path
-    ok 8 - login:password@unix/:/path1/path2/path3: query
-    ok 9 - login:password@unix/:/path1/path2/path3: fragment
-    ok 10 - login:password@unix/:/path1/path2/path3: host_hint
-    ok 11 - login:password@unix/:/path1/path2/path3: parse
-    ok 12 - login:password@unix/:/path1/path2/path3: scheme
-    ok 13 - login:password@unix/:/path1/path2/path3: login
-    ok 14 - login:password@unix/:/path1/path2/path3: password
-    ok 15 - login:password@unix/:/path1/path2/path3: host
-    ok 16 - login:password@unix/:/path1/path2/path3: service
-    ok 17 - login:password@unix/:/path1/path2/path3: path
-    ok 18 - login:password@unix/:/path1/path2/path3: query
-    ok 19 - login:password@unix/:/path1/path2/path3: fragment
-ok 56 - subtests
-    1..19
-    ok 1 - login:password@unix/:/path1/path2/path3:: parse
-    ok 2 - login:password@unix/:/path1/path2/path3:: scheme
-    ok 3 - login:password@unix/:/path1/path2/path3:: login
-    ok 4 - login:password@unix/:/path1/path2/path3:: password
-    ok 5 - login:password@unix/:/path1/path2/path3:: host
-    ok 6 - login:password@unix/:/path1/path2/path3:: service
-    ok 7 - login:password@unix/:/path1/path2/path3:: path
-    ok 8 - login:password@unix/:/path1/path2/path3:: query
-    ok 9 - login:password@unix/:/path1/path2/path3:: fragment
-    ok 10 - login:password@unix/:/path1/path2/path3:: host_hint
-    ok 11 - login:password@unix/:/path1/path2/path3:: parse
-    ok 12 - login:password@unix/:/path1/path2/path3:: scheme
-    ok 13 - login:password@unix/:/path1/path2/path3:: login
-    ok 14 - login:password@unix/:/path1/path2/path3:: password
-    ok 15 - login:password@unix/:/path1/path2/path3:: host
-    ok 16 - login:password@unix/:/path1/path2/path3:: service
-    ok 17 - login:password@unix/:/path1/path2/path3:: path
-    ok 18 - login:password@unix/:/path1/path2/path3:: query
-    ok 19 - login:password@unix/:/path1/path2/path3:: fragment
-ok 57 - subtests
-    1..19
-    ok 1 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: parse
-    ok 2 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: scheme
-    ok 3 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: login
-    ok 4 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: password
-    ok 5 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: host
-    ok 6 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: service
-    ok 7 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: path
-    ok 8 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: query
-    ok 9 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: fragment
-    ok 10 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: host_hint
-    ok 11 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: parse
-    ok 12 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: scheme
-    ok 13 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: login
-    ok 14 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: password
-    ok 15 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: host
-    ok 16 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: service
-    ok 17 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: path
-    ok 18 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: query
-    ok 19 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: fragment
-ok 58 - subtests
-    1..19
-    ok 1 - unix/:./relative/path.sock:/test: parse
-    ok 2 - unix/:./relative/path.sock:/test: scheme
-    ok 3 - unix/:./relative/path.sock:/test: login
-    ok 4 - unix/:./relative/path.sock:/test: password
-    ok 5 - unix/:./relative/path.sock:/test: host
-    ok 6 - unix/:./relative/path.sock:/test: service
-    ok 7 - unix/:./relative/path.sock:/test: path
-    ok 8 - unix/:./relative/path.sock:/test: query
-    ok 9 - unix/:./relative/path.sock:/test: fragment
-    ok 10 - unix/:./relative/path.sock:/test: host_hint
-    ok 11 - unix/:./relative/path.sock:/test: parse
-    ok 12 - unix/:./relative/path.sock:/test: scheme
-    ok 13 - unix/:./relative/path.sock:/test: login
-    ok 14 - unix/:./relative/path.sock:/test: password
-    ok 15 - unix/:./relative/path.sock:/test: host
-    ok 16 - unix/:./relative/path.sock:/test: service
-    ok 17 - unix/:./relative/path.sock:/test: path
-    ok 18 - unix/:./relative/path.sock:/test: query
-    ok 19 - unix/:./relative/path.sock:/test: fragment
-ok 59 - subtests
-    1..19
-    ok 1 - scheme://unix/:./relative/path.sock:/test: parse
-    ok 2 - scheme://unix/:./relative/path.sock:/test: scheme
-    ok 3 - scheme://unix/:./relative/path.sock:/test: login
-    ok 4 - scheme://unix/:./relative/path.sock:/test: password
-    ok 5 - scheme://unix/:./relative/path.sock:/test: host
-    ok 6 - scheme://unix/:./relative/path.sock:/test: service
-    ok 7 - scheme://unix/:./relative/path.sock:/test: path
-    ok 8 - scheme://unix/:./relative/path.sock:/test: query
-    ok 9 - scheme://unix/:./relative/path.sock:/test: fragment
-    ok 10 - scheme://unix/:./relative/path.sock:/test: host_hint
-    ok 11 - scheme://unix/:./relative/path.sock:/test: parse
-    ok 12 - scheme://unix/:./relative/path.sock:/test: scheme
-    ok 13 - scheme://unix/:./relative/path.sock:/test: login
-    ok 14 - scheme://unix/:./relative/path.sock:/test: password
-    ok 15 - scheme://unix/:./relative/path.sock:/test: host
-    ok 16 - scheme://unix/:./relative/path.sock:/test: service
-    ok 17 - scheme://unix/:./relative/path.sock:/test: path
-    ok 18 - scheme://unix/:./relative/path.sock:/test: query
-    ok 19 - scheme://unix/:./relative/path.sock:/test: fragment
-ok 60 - subtests
-    1..19
-    ok 1 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: parse
-    ok 2 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: scheme
-    ok 3 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: login
-    ok 4 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: password
-    ok 5 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: host
-    ok 6 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: service
-    ok 7 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: path
-    ok 8 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: query
-    ok 9 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: fragment
-    ok 10 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: host_hint
-    ok 11 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: parse
-    ok 12 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: scheme
-    ok 13 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: login
-    ok 14 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: password
-    ok 15 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: host
-    ok 16 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: service
-    ok 17 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: path
-    ok 18 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: query
-    ok 19 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: fragment
-ok 61 - subtests
-    1..19
-    ok 1 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: parse
-    ok 2 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: scheme
-    ok 3 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: login
-    ok 4 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: password
-    ok 5 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: host
-    ok 6 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: service
-    ok 7 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: path
-    ok 8 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: query
-    ok 9 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: fragment
-    ok 10 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: host_hint
-    ok 11 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: parse
-    ok 12 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: scheme
-    ok 13 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: login
-    ok 14 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: password
-    ok 15 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: host
-    ok 16 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: service
-    ok 17 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: path
-    ok 18 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: query
-    ok 19 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: fragment
-ok 62 - subtests
-    1..2
-    ok 1 - empty is invalid
-    ok 2 - :// is invalid
-ok 63 - subtests
diff --git a/test/unit/uuid.result b/test/unit/uuid.result
deleted file mode 100644
index 50a1140c5..000000000
--- a/test/unit/uuid.result
+++ /dev/null
@@ -1,9 +0,0 @@
-1..3
-ok 1 - 6611265b-8852-4832-af8b-4164d52c62eb > 186ebbf7-cf97-4e2e-8b1b-76154f6f3949
-ok 2 - 075b4148-8fb0-2e7f-af50-4164d52c62eb < 1fbc929f-5da8-28c5-8b36-76154f6f3949
-    1..4
-    ok 1 - mp_sizeof_uuid() == encoded length
-    ok 2 - mp_decode_uuid() return code
-    ok 3 - mp_sizeof_uuid() == decoded length
-    ok 4 - mp_decode_uuid(mp_encode_uuid(uu)) == uu
-ok 3 - subtests
diff --git a/test/unit/vclock.result b/test/unit/vclock.result
deleted file mode 100644
index 2ca741bbd..000000000
--- a/test/unit/vclock.result
+++ /dev/null
@@ -1,149 +0,0 @@
-1..5
-    1..40
-	*** test_compare ***
-    ok 1 - compare (), () => 0
-    ok 2 - compare (), () => 0
-    ok 3 - compare (), (10) => -1
-    ok 4 - compare (10), () => 1
-    ok 5 - compare (0), (0) => 0
-    ok 6 - compare (0), (0) => 0
-    ok 7 - compare (1), (1) => 0
-    ok 8 - compare (1), (1) => 0
-    ok 9 - compare (1), (2) => -1
-    ok 10 - compare (2), (1) => 1
-    ok 11 - compare (), (10, 1, 0) => -1
-    ok 12 - compare (10, 1, 0), () => 1
-    ok 13 - compare (5), (10, 1, 0) => -1
-    ok 14 - compare (10, 1, 0), (5) => 1
-    ok 15 - compare (10), (10, 1, 0) => -1
-    ok 16 - compare (10, 1, 0), (10) => 1
-    ok 17 - compare (15), (10, 1, 0) => 2147483647
-    ok 18 - compare (10, 1, 0), (15) => 2147483647
-    ok 19 - compare (10, 1, 0), (10, 1, 1) => -1
-    ok 20 - compare (10, 1, 1), (10, 1, 0) => 1
-    ok 21 - compare (10, 1, 0), (10, 2, 0) => -1
-    ok 22 - compare (10, 2, 0), (10, 1, 0) => 1
-    ok 23 - compare (10, 1, 0), (10, 1, 0) => 0
-    ok 24 - compare (10, 1, 0), (10, 1, 0) => 0
-    ok 25 - compare (10, 0, 1), (10, 1, 0) => 2147483647
-    ok 26 - compare (10, 1, 0), (10, 0, 1) => 2147483647
-    ok 27 - compare (10, 2, 1), (10, 1, 2) => 2147483647
-    ok 28 - compare (10, 1, 2), (10, 2, 1) => 2147483647
-    ok 29 - compare (10, 0, 1), (11, 0, 0) => 2147483647
-    ok 30 - compare (11, 0, 0), (10, 0, 1) => 2147483647
-    ok 31 - compare (10, 0, 5), (5, 0, 10) => 2147483647
-    ok 32 - compare (5, 0, 10), (10, 0, 5) => 2147483647
-    ok 33 - compare (10, 10, 10), (10, 10, 10) => 0
-    ok 34 - compare (10, 10, 10), (10, 10, 10) => 0
-    ok 35 - compare (10, 10, 10), (10, 10, 10, 1) => -1
-    ok 36 - compare (10, 10, 10, 1), (10, 10, 10) => 1
-    ok 37 - compare (10, 10, 10), (10, 10, 10, 1, 2, 3) => -1
-    ok 38 - compare (10, 10, 10, 1, 2, 3), (10, 10, 10) => 1
-    ok 39 - compare (0, 0, 0), (10, 0, 0, 0, 0) => -1
-    ok 40 - compare (10, 0, 0, 0, 0), (0, 0, 0) => 1
-	*** test_compare: done ***
-ok 1 - subtests
-    1..36
-	*** test_isearch ***
-    ok 1 - query #1
-    ok 2 - query #2
-    ok 3 - query #3
-    ok 4 - query #4
-    ok 5 - query #5
-    ok 6 - query #6
-    ok 7 - query #7
-    ok 8 - query #8
-    ok 9 - query #9
-    ok 10 - query #10
-    ok 11 - query #11
-    ok 12 - query #12
-    ok 13 - query #13
-    ok 14 - query #14
-    ok 15 - query #15
-    ok 16 - query #16
-    ok 17 - query #17
-    ok 18 - query #18
-    ok 19 - query #19
-    ok 20 - query #20
-    ok 21 - query #21
-    ok 22 - query #22
-    ok 23 - query #23
-    ok 24 - query #24
-    ok 25 - query #25
-    ok 26 - query #26
-    ok 27 - query #27
-    ok 28 - query #28
-    ok 29 - query #29
-    ok 30 - query #30
-    ok 31 - query #31
-    ok 32 - query #32
-    ok 33 - query #33
-    ok 34 - query #34
-    ok 35 - query #35
-    ok 36 - query #36
-	*** test_isearch: done ***
-ok 2 - subtests
-    1..8
-	*** test_tostring ***
-    ok 1 - tostring () => {}
-    ok 2 - tostring (-1, -1, -1) => {}
-    ok 3 - tostring (1) => {0: 1}
-    ok 4 - tostring (1, 2) => {0: 1, 1: 2}
-    ok 5 - tostring (10, 15, 20) => {0: 10, 1: 15, 2: 20}
-    ok 6 - tostring (10, -1, 15, -1, 20) => {0: 10, 2: 15, 4: 20}
-    ok 7 - tostring (0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15) => {1: 1, 2: 2, 3: 3, 4: 4, 5: 5, 6: 6, 7: 7, 8: 8, 9: 9, 10: 10, 11: 11, 12: 12, 13: 13, 14: 14, 15: 15}
-    ok 8 - tostring (9223372036854775000, 9223372036854775001, 9223372036854775002, 9223372036854775003, 9223372036854775004, 9223372036854775005, 9223372036854775006, 9223372036854775007, 9223372036854775008, 9223372036854775009, 9223372036854775010, 9223372036854775011, 9223372036854775012, 9223372036854775013, 9223372036854775014, 9223372036854775015) => {0: 9223372036854775000, 1: 9223372036854775001, 2: 9223372036854775002, 3: 9223372036854775003, 4: 9223372036854775004, 5: 9223372036854775005, 6: 9223372036854775006, 7: 9223372036854775007, 8: 9223372036854775008, 9: 9223372036854775009, 10: 9223372036854775010, 11: 9223372036854775011, 12: 9223372036854775012, 13: 9223372036854775013, 14: 9223372036854775014, 15: 9223372036854775015}
-	*** test_tostring: done ***
-ok 3 - subtests
-    1..12
-	*** test_fromstring ***
-    ok 1 - fromstring {} => ()
-    ok 2 - fromstring  	 	 { 	 	 } 	 	  => ()
-    ok 3 - fromstring {0: 10} => (10)
-    ok 4 - fromstring {0: 10,} => (10)
-    ok 5 - fromstring {	 0	 :	  10	 ,	 } => (10)
-    ok 6 - fromstring {0: 10, 1: 15, 3: 20} => (10, 15, -1, 20)
-    ok 7 - fromstring {2: 20, 0: 10, 4: 30} => (10, -1, 20, -1, 30)
-    ok 8 - fromstring {4: 30, 2: 20} => (-1, -1, 20, -1, 30)
-    ok 9 - fromstring {4: 30, 2: 20,} => (-1, -1, 20, -1, 30)
-    ok 10 - fromstring {0: 4294967295} => (4294967295)
-    ok 11 - fromstring {0: 4294967296} => (4294967296)
-    ok 12 - fromstring {0: 9223372036854775807} => (9223372036854775807)
-	*** test_fromstring: done ***
-ok 4 - subtests
-    1..32
-	*** test_fromstring_invalid ***
-    ok 1 - fromstring "" => 1
-    ok 2 - fromstring " " => 2
-    ok 3 - fromstring "	 	 	 " => 7
-    ok 4 - fromstring "}" => 1
-    ok 5 - fromstring "1: 10" => 1
-    ok 6 - fromstring "abcde" => 1
-    ok 7 - fromstring "12345" => 1
-    ok 8 - fromstring "\x01\x02\x03\x04\x05\x06" => 1
-    ok 9 - fromstring "{" => 2
-    ok 10 - fromstring "{1	 " => 5
-    ok 11 - fromstring "{1:	 " => 6
-    ok 12 - fromstring "{1:10" => 6
-    ok 13 - fromstring "{1:10	 " => 8
-    ok 14 - fromstring "{1:10," => 7
-    ok 15 - fromstring "{1:10,	 	 " => 11
-    ok 16 - fromstring "{1:10 2:20" => 7
-    ok 17 - fromstring "{1:10,," => 7
-    ok 18 - fromstring "{1:10, 10,}" => 10
-    ok 19 - fromstring "{1:-1}" => 4
-    ok 20 - fromstring "{-1:1}" => 2
-    ok 21 - fromstring "{128:1}" => 5
-    ok 22 - fromstring "{1:abcde}" => 4
-    ok 23 - fromstring "{abcde:1}" => 2
-    ok 24 - fromstring "{1:1.1}" => 5
-    ok 25 - fromstring "{1.1:1}" => 3
-    ok 26 - fromstring "{4294967296:1}" => 12
-    ok 27 - fromstring "{1:9223372036854775808}" => 23
-    ok 28 - fromstring "{1:18446744073709551616}" => 24
-    ok 29 - fromstring "{1:18446744073709551616}" => 24
-    ok 30 - fromstring "{1:340282366920938463463374607431768211456}" => 43
-    ok 31 - fromstring "{1:10, 1:20}" => 12
-    ok 32 - fromstring "{1:20, 1:10}" => 12
-	*** test_fromstring_invalid: done ***
-ok 5 - subtests
diff --git a/test/unit/vy_cache.result b/test/unit/vy_cache.result
deleted file mode 100644
index a67e8edb0..000000000
--- a/test/unit/vy_cache.result
+++ /dev/null
@@ -1,9 +0,0 @@
-	*** test_basic ***
-1..6
-ok 1 - cache is filled with 6 statements
-ok 2 - cache is filled with 12 statements
-ok 3 - cache is filled with 18 statements
-ok 4 - next_key * 4
-ok 5 - restore
-ok 6 - restore on position after last
-	*** test_basic: done ***
diff --git a/test/unit/vy_mem.c b/test/unit/vy_mem.c
index 2e461f312..4e136b72b 100644
--- a/test/unit/vy_mem.c
+++ b/test/unit/vy_mem.c
@@ -9,7 +9,7 @@ test_basic(void)
 {
 	header();
 
-	plan(12);
+	plan(9);
 
 	/* Create key_def */
 	uint32_t fields[] = { 0 };
@@ -334,11 +334,13 @@ test_iterator_restore_after_insertion()
 int
 main(int argc, char *argv[])
 {
+	plan(2);
 	vy_iterator_C_test_init(0);
 
 	test_basic();
 	test_iterator_restore_after_insertion();
 
 	vy_iterator_C_test_finish();
+	check_plan();
 	return 0;
 }
diff --git a/test/unit/vy_mem.result b/test/unit/vy_mem.result
deleted file mode 100644
index 5c9c7af58..000000000
--- a/test/unit/vy_mem.result
+++ /dev/null
@@ -1,17 +0,0 @@
-# Looks like you planned 12 tests but ran 9.
-	*** test_basic ***
-1..12
-ok 1 - mem->dump_lsn on empty mem
-ok 2 - mem->dump_lsn after prepare
-ok 3 - mem->dump_lsn after commit
-ok 4 - vy_mem_older_lsn 1
-ok 5 - vy_mem_older_lsn 2
-ok 6 - vy_mem_rollback 1
-ok 7 - vy_mem_rollback 2
-ok 8 - vy_mem->version
-ok 9 - vy_mem->version
-	*** test_basic: done ***
-	*** test_iterator_restore_after_insertion ***
-1..1
-ok 1 - check wrong_output 0
-	*** test_iterator_restore_after_insertion: done ***
diff --git a/test/unit/vy_point_lookup.result b/test/unit/vy_point_lookup.result
deleted file mode 100644
index 4e68dda6d..000000000
--- a/test/unit/vy_point_lookup.result
+++ /dev/null
@@ -1,20 +0,0 @@
-1..1
-	*** test_basic ***
-    1..15
-    ok 1 - vy_lsm_env_create
-    ok 2 - key_def is not NULL
-    ok 3 - tuple_format_new is not NULL
-    ok 4 - lsm is not NULL
-    ok 5 - range is not NULL
-    ok 6 - temp dir name is not NULL
-    ok 7 - temp dir create (2)
-    ok 8 - temp dir create (3)
-    ok 9 - vy_lsm_rotate_mem
-    ok 10 - vy_run_new
-    ok 11 - vy_run_write
-    ok 12 - vy_run_new
-    ok 13 - vy_run_write
-    ok 14 - select results
-    ok 15 - no errors happened
-ok 1 - subtests
-	*** test_basic: done ***
diff --git a/test/unit/vy_write_iterator.result b/test/unit/vy_write_iterator.result
deleted file mode 100644
index a80116852..000000000
--- a/test/unit/vy_write_iterator.result
+++ /dev/null
@@ -1,61 +0,0 @@
-	*** test_basic ***
-1..58
-ok 1 - stmt 0 is correct
-ok 2 - stmt 1 is correct
-ok 3 - stmt 2 is correct
-ok 4 - stmt 3 is correct
-ok 5 - correct results count
-ok 6 - stmt 0 is correct
-ok 7 - stmt 1 is correct
-ok 8 - stmt 2 is correct
-ok 9 - stmt 3 is correct
-ok 10 - correct results count
-ok 11 - stmt 0 is correct
-ok 12 - stmt 1 is correct
-ok 13 - correct results count
-ok 14 - stmt 0 is correct
-ok 15 - stmt 1 is correct
-ok 16 - correct results count
-ok 17 - stmt 0 is correct
-ok 18 - correct results count
-ok 19 - stmt 0 is correct
-ok 20 - stmt 1 is correct
-ok 21 - correct results count
-ok 22 - stmt 0 is correct
-ok 23 - stmt 1 is correct
-ok 24 - correct results count
-ok 25 - stmt 0 is correct
-ok 26 - stmt 1 is correct
-ok 27 - stmt 2 is correct
-ok 28 - correct results count
-ok 29 - stmt 0 is correct
-ok 30 - correct results count
-ok 31 - stmt 0 is correct
-ok 32 - stmt 1 is correct
-ok 33 - stmt 2 is correct
-ok 34 - correct results count
-ok 35 - stmt 0 is correct
-ok 36 - stmt 1 is correct
-ok 37 - stmt 2 is correct
-ok 38 - correct results count
-ok 39 - stmt 0 is correct
-ok 40 - stmt 1 is correct
-ok 41 - stmt 2 is correct
-ok 42 - correct results count
-ok 43 - deferred stmt 0 is correct
-ok 44 - deferred stmt 1 is correct
-ok 45 - deferred stmt 2 is correct
-ok 46 - deferred stmt 3 is correct
-ok 47 - correct deferred stmt count
-ok 48 - stmt 0 is correct
-ok 49 - stmt 1 is correct
-ok 50 - correct results count
-ok 51 - correct deferred stmt count
-ok 52 - stmt 0 is correct
-ok 53 - stmt 1 is correct
-ok 54 - correct results count
-ok 55 - correct deferred stmt count
-ok 56 - stmt 0 is correct
-ok 57 - correct results count
-ok 58 - correct deferred stmt count
-	*** test_basic: done ***
diff --git a/test/unit/xrow.result b/test/unit/xrow.result
deleted file mode 100644
index 5ee92ad7b..000000000
--- a/test/unit/xrow.result
+++ /dev/null
@@ -1,58 +0,0 @@
-1..3
-    1..40
-    ok 1 - round trip
-    ok 2 - roundtrip.version_id
-    ok 3 - roundtrip.protocol
-    ok 4 - roundtrip.uuid
-    ok 5 - roundtrip.salt_len
-    ok 6 - roundtrip.salt
-    ok 7 - decode iproto
-    ok 8 - iproto.version_id
-    ok 9 - iproto.protocol
-    ok 10 - iproto.uuid
-    ok 11 - iproto.salt_len
-    ok 12 - iproto.salt
-    ok 13 - decode lua
-    ok 14 - lua.version_id
-    ok 15 - lua.protocol
-    ok 16 - lua.uuid
-    ok 17 - lua.salt_len
-    ok 18 - decode iproto166
-    ok 19 - iproto166.version_id
-    ok 20 - iproto166.protocol
-    ok 21 - iproto166.uuid
-    ok 22 - iproto166.salt_len
-    ok 23 - iproto166.salt
-    ok 24 - decode lua166
-    ok 25 - lua166.version_id
-    ok 26 - lua166.protocol
-    ok 27 - lua166.uuid
-    ok 28 - lua166.salt_len
-    ok 29 - invalid 0
-    ok 30 - invalid 1
-    ok 31 - invalid 2
-    ok 32 - invalid 3
-    ok 33 - invalid 4
-    ok 34 - invalid 5
-    ok 35 - invalid 6
-    ok 36 - invalid 7
-    ok 37 - invalid 8
-    ok 38 - invalid 9
-    ok 39 - invalid 10
-    ok 40 - invalid 11
-ok 1 - subtests
-    1..10
-    ok 1 - bad msgpack end
-    ok 2 - encode
-    ok 3 - header map size
-    ok 4 - header decode
-    ok 5 - decoded type
-    ok 6 - decoded replica_id
-    ok 7 - decoded lsn
-    ok 8 - decoded tm
-    ok 9 - decoded sync
-    ok 10 - decoded bodycnt
-ok 2 - subtests
-    1..1
-    ok 1 - request_str
-ok 3 - subtests
-- 
2.23.0

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Tarantool-patches] [PATCH 1/2] test: update unit test lib to produce TAP-compliant output
  2020-05-21  9:59 ` [Tarantool-patches] [PATCH 1/2] test: update unit test lib to produce TAP-compliant output sergeyb
@ 2020-06-02  9:20   ` Sergey Bronnikov
  2020-06-03 22:52   ` Vladislav Shpilevoy
  1 sibling, 0 replies; 12+ messages in thread
From: Sergey Bronnikov @ 2020-06-02  9:20 UTC (permalink / raw)
  To: tarantool-patches, Vladislav Shpilevoy

Vladislav,

please join to review as we discussed.

On 12:59 Thu 21 May , sergeyb@tarantool.org wrote:
> From: Alexander Turenko <alexander.turenko@tarantool.org>
> 
> Closes #5000
> ---
>  test/unit/CMakeLists.txt | 49 +++++++++++++++++++++-------------------
>  test/unit/unit.c         |  3 +++
>  test/unit/unit.h         | 13 ++++++++---
>  3 files changed, 39 insertions(+), 26 deletions(-)
> 
> diff --git a/test/unit/CMakeLists.txt b/test/unit/CMakeLists.txt
> index 84eb066bd..0704d10f0 100644
> --- a/test/unit/CMakeLists.txt
> +++ b/test/unit/CMakeLists.txt
> @@ -23,46 +23,48 @@ target_link_libraries(stailq.test unit)
>  add_executable(uri.test uri.c unit.c)
>  target_link_libraries(uri.test uri unit)
>  add_executable(queue.test queue.c)
> +target_link_libraries(queue.test unit)
>  add_executable(mhash.test mhash.c)
>  target_link_libraries(mhash.test unit)
>  add_executable(mhash_bytemap.test mhash_bytemap.c)
>  target_link_libraries(mhash_bytemap.test unit)
>  add_executable(rope_basic.test rope_basic.c)
> -target_link_libraries(rope_basic.test salad)
> +target_link_libraries(rope_basic.test salad unit)
>  add_executable(rope_avl.test rope_avl.c)
> -target_link_libraries(rope_avl.test salad)
> +target_link_libraries(rope_avl.test salad unit)
>  add_executable(rope_stress.test rope_stress.c)
> -target_link_libraries(rope_stress.test salad)
> +target_link_libraries(rope_stress.test salad unit)
>  add_executable(rope.test rope.c)
> -target_link_libraries(rope.test salad)
> +target_link_libraries(rope.test salad unit)
>  add_executable(int96.test int96.cc)
> +target_link_libraries(int96.test unit)
>  add_executable(bit.test bit.c bit.c)
> -target_link_libraries(bit.test bit)
> +target_link_libraries(bit.test bit unit)
>  add_executable(bitset_basic.test bitset_basic.c)
> -target_link_libraries(bitset_basic.test bitset)
> +target_link_libraries(bitset_basic.test bitset unit)
>  add_executable(bitset_iterator.test bitset_iterator.c)
> -target_link_libraries(bitset_iterator.test bitset)
> +target_link_libraries(bitset_iterator.test bitset unit)
>  add_executable(bitset_index.test bitset_index.c)
> -target_link_libraries(bitset_index.test bitset)
> +target_link_libraries(bitset_index.test bitset unit)
>  add_executable(base64.test base64.c)
>  target_link_libraries(base64.test misc unit)
>  add_executable(uuid.test uuid.c)
>  target_link_libraries(uuid.test uuid unit)
>  
>  add_executable(bps_tree.test bps_tree.cc)
> -target_link_libraries(bps_tree.test small misc)
> +target_link_libraries(bps_tree.test small misc unit)
>  add_executable(bps_tree_iterator.test bps_tree_iterator.cc)
> -target_link_libraries(bps_tree_iterator.test small misc)
> +target_link_libraries(bps_tree_iterator.test small misc unit)
>  add_executable(rtree.test rtree.cc)
> -target_link_libraries(rtree.test salad small)
> +target_link_libraries(rtree.test salad small unit)
>  add_executable(rtree_iterator.test rtree_iterator.cc)
> -target_link_libraries(rtree_iterator.test salad small)
> +target_link_libraries(rtree_iterator.test salad small unit)
>  add_executable(rtree_multidim.test rtree_multidim.cc)
> -target_link_libraries(rtree_multidim.test salad small)
> +target_link_libraries(rtree_multidim.test salad small unit)
>  add_executable(light.test light.cc)
> -target_link_libraries(light.test small)
> +target_link_libraries(light.test small unit)
>  add_executable(bloom.test bloom.cc)
> -target_link_libraries(bloom.test salad)
> +target_link_libraries(bloom.test salad unit)
>  add_executable(vclock.test vclock.cc)
>  target_link_libraries(vclock.test vclock unit)
>  add_executable(xrow.test xrow.cc)
> @@ -87,19 +89,19 @@ if (NOT ENABLE_GCOV)
>  endif ()
>  
>  add_executable(fiber_stress.test fiber_stress.cc)
> -target_link_libraries(fiber_stress.test core)
> +target_link_libraries(fiber_stress.test core unit)
>  
>  add_executable(fiber_cond.test fiber_cond.c unit.c)
> -target_link_libraries(fiber_cond.test core)
> +target_link_libraries(fiber_cond.test core unit)
>  
>  add_executable(fiber_channel.test fiber_channel.cc unit.c)
> -target_link_libraries(fiber_channel.test core)
> +target_link_libraries(fiber_channel.test core unit)
>  
>  add_executable(fiber_channel_stress.test fiber_channel_stress.cc)
> -target_link_libraries(fiber_channel_stress.test core)
> +target_link_libraries(fiber_channel_stress.test core unit)
>  
>  add_executable(cbus_stress.test cbus_stress.c)
> -target_link_libraries(cbus_stress.test core stat)
> +target_link_libraries(cbus_stress.test core stat unit)
>  
>  add_executable(cbus.test cbus.c)
>  target_link_libraries(cbus.test core unit stat)
> @@ -129,21 +131,22 @@ if (ENABLE_BUNDLED_MSGPUCK)
>  endif ()
>  
>  add_executable(scramble.test scramble.c)
> -target_link_libraries(scramble.test scramble)
> +target_link_libraries(scramble.test scramble unit)
>  
>  add_executable(guava.test guava.c)
> -target_link_libraries(guava.test salad small)
> +target_link_libraries(guava.test salad small unit)
>  
>  add_executable(find_path.test find_path.c
>      ${CMAKE_SOURCE_DIR}/src/find_path.c
>  )
> +target_link_libraries(find_path.test unit)
>  
>  add_executable(reflection_c.test reflection_c.c unit.c
>      ${CMAKE_SOURCE_DIR}/src/lib/core/reflection.c)
>  add_executable(reflection_cxx.test reflection_cxx.cc unit.c
>      ${CMAKE_SOURCE_DIR}/src/lib/core/reflection.c)
>  add_executable(csv.test csv.c)
> -target_link_libraries(csv.test csv)
> +target_link_libraries(csv.test csv unit)
>  
>  add_executable(json.test json.c)
>  target_link_libraries(json.test json unit ${ICU_LIBRARIES})
> diff --git a/test/unit/unit.c b/test/unit/unit.c
> index d12b66f91..302dce2ef 100644
> --- a/test/unit/unit.c
> +++ b/test/unit/unit.c
> @@ -26,6 +26,9 @@ plan(int count)
>  	tests_done[level] = 0;
>  	tests_failed[level] = 0;
>  
> +	if (level == 0)
> +		printf("TAP version 13\n");
> +
>  	_space(stdout);
>  	printf("%d..%d\n", 1, plan_test[level]);
>  }
> diff --git a/test/unit/unit.h b/test/unit/unit.h
> index 43c301b28..27879ea98 100644
> --- a/test/unit/unit.h
> +++ b/test/unit/unit.h
> @@ -33,9 +33,6 @@
>  #include <stdio.h>
>  #include <stdlib.h> /* exit() */
>  
> -#define header() printf("\t*** %s ***\n", __func__)
> -#define footer() printf("\t*** %s: done ***\n", __func__)
> -
>  #define fail(expr, result) do {					\
>  	fprintf(stderr, "Test failed: %s is %s at %s:%d, in function '%s'\n",\
>  		expr, result, __FILE__, __LINE__, __func__);		\
> @@ -129,6 +126,16 @@ int check_plan(void);
>  	}						\
>  }
>  
> +#define header() do {				\
> +	_space(stdout);				\
> +	printf("# *** %s ***\n", __func__);	\
> +} while(0)
> +
> +#define footer() do {					\
> +	_space(stdout);					\
> +	printf("# *** %s: done ***\n", __func__);	\
> +} while(0)
> +
>  #if defined(__cplusplus)
>  }
>  #endif /* defined(__cplusplus) */
> -- 
> 2.23.0
> 

-- 
sergeyb@

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Tarantool-patches] [PATCH 2/2] test: update unit tests to make them TAP-compliant
  2020-05-21  9:59 ` [Tarantool-patches] [PATCH 2/2] test: update unit tests to make them TAP-compliant sergeyb
@ 2020-06-02  9:20   ` Sergey Bronnikov
  2020-06-03 22:52   ` Vladislav Shpilevoy
  1 sibling, 0 replies; 12+ messages in thread
From: Sergey Bronnikov @ 2020-06-02  9:20 UTC (permalink / raw)
  To: tarantool-patches, Vladislav Shpilevoy

Vladislav, please join to review.

On 12:59 Thu 21 May , sergeyb@tarantool.org wrote:
> From: Sergey Bronnikov <sergeyb@tarantool.org>
> 
> Closes #5000
> ---
>  test/unit/base64.result               |  178 --
>  test/unit/bit.c                       |   75 +-
>  test/unit/bit.result                  |  895 ----------
>  test/unit/bitset_basic.c              |   38 +-
>  test/unit/bitset_basic.result         |   12 -
>  test/unit/bitset_index.c              |   42 +-
>  test/unit/bitset_index.result         |   21 -
>  test/unit/bitset_iterator.c           |   32 +
>  test/unit/bitset_iterator.result      |   22 -
>  test/unit/bloom.cc                    |   20 +-
>  test/unit/bloom.result                |    6 -
>  test/unit/bps_tree.cc                 |   80 +-
>  test/unit/bps_tree.result             |  284 ---
>  test/unit/bps_tree_iterator.cc        |   42 +-
>  test/unit/bps_tree_iterator.result    |   21 -
>  test/unit/cbus.c                      |   20 +-
>  test/unit/cbus.result                 |   24 -
>  test/unit/cbus_hang.c                 |    2 +-
>  test/unit/cbus_hang.result            |    4 -
>  test/unit/cbus_stress.c               |   53 +-
>  test/unit/cbus_stress.result          |    2 -
>  test/unit/checkpoint_schedule.result  |   41 -
>  test/unit/coio.result                 |   12 -
>  test/unit/coll.cpp                    |   51 +-
>  test/unit/coll.result                 |   90 -
>  test/unit/column_mask.result          |   36 -
>  test/unit/crypto.result               |  132 --
>  test/unit/csv.result                  |   80 +-
>  test/unit/decimal.result              |  700 --------
>  test/unit/fiber.cc                    |   21 +-
>  test/unit/fiber.result                |   19 -
>  test/unit/fiber_channel.cc            |    2 +
>  test/unit/fiber_channel.result        |   23 -
>  test/unit/fiber_channel_stress.cc     |    3 +
>  test/unit/fiber_channel_stress.result |    2 -
>  test/unit/fiber_cond.result           |    8 -
>  test/unit/fiber_stack.c               |    3 +
>  test/unit/fiber_stack.result          |   11 -
>  test/unit/fiber_stress.cc             |    4 +
>  test/unit/fiber_stress.result         |    0
>  test/unit/find_path.c                 |    3 +
>  test/unit/find_path.result            |    2 -
>  test/unit/guard.cc                    |    3 +-
>  test/unit/guard.result                |    1 -
>  test/unit/guava.c                     |   11 +
>  test/unit/guava.result                |    6 -
>  test/unit/heap.c                      |   38 +
>  test/unit/heap.result                 |   24 -
>  test/unit/heap_iterator.c             |   14 +
>  test/unit/heap_iterator.result        |    8 -
>  test/unit/histogram.c                 |   11 +
>  test/unit/histogram.result            |    6 -
>  test/unit/int96.cc                    |   51 +-
>  test/unit/int96.result                |    2 -
>  test/unit/json.result                 |  208 ---
>  test/unit/light.cc                    |   16 +-
>  test/unit/light.result                |    8 -
>  test/unit/luaL_iterator.result        |   89 -
>  test/unit/luaT_tuple_new.result       |   22 -
>  test/unit/merger.result               |   71 -
>  test/unit/mhash.result                |   18 -
>  test/unit/mhash_bytemap.result        |   18 -
>  test/unit/mp_error.result             |   44 -
>  test/unit/msgpack.result              | 2282 -------------------------
>  test/unit/popen.result                |   30 -
>  test/unit/queue.c                     |   65 +-
>  test/unit/queue.result                |   34 -
>  test/unit/ratelimit.result            |   13 -
>  test/unit/reflection_c.result         |    5 -
>  test/unit/reflection_cxx.result       |   31 -
>  test/unit/rmean.cc                    |   19 +-
>  test/unit/rmean.result                |   11 -
>  test/unit/rope.c                      |   10 +-
>  test/unit/rope.result                 |  299 ----
>  test/unit/rope_avl.c                  |    5 +
>  test/unit/rope_avl.result             |  123 --
>  test/unit/rope_basic.c                |   19 +-
>  test/unit/rope_basic.result           |  139 --
>  test/unit/rope_common.h               |   11 +-
>  test/unit/rope_stress.c               |    8 +
>  test/unit/rope_stress.result          |    4 -
>  test/unit/rtree.cc                    |   20 +-
>  test/unit/rtree.result                |    8 -
>  test/unit/rtree_iterator.cc           |   24 +-
>  test/unit/rtree_iterator.result       |    7 -
>  test/unit/rtree_multidim.cc           |   30 +-
>  test/unit/rtree_multidim.result       |   15 -
>  test/unit/say.result                  |   67 -
>  test/unit/scramble.c                  |   21 +-
>  test/unit/scramble.result             |    4 -
>  test/unit/sio.result                  |   36 -
>  test/unit/stailq.result               |   76 -
>  test/unit/swim.result                 |  234 ---
>  test/unit/swim_errinj.result          |   18 -
>  test/unit/swim_proto.result           |   40 -
>  test/unit/tuple_bigref.result         |   17 -
>  test/unit/uri.result                  | 1307 --------------
>  test/unit/uuid.result                 |    9 -
>  test/unit/vclock.result               |  149 --
>  test/unit/vy_cache.result             |    9 -
>  test/unit/vy_mem.c                    |    4 +-
>  test/unit/vy_mem.result               |   17 -
>  test/unit/vy_point_lookup.result      |   20 -
>  test/unit/vy_write_iterator.result    |   61 -
>  test/unit/xrow.result                 |   58 -
>  105 files changed, 649 insertions(+), 8495 deletions(-)
>  delete mode 100644 test/unit/base64.result
>  delete mode 100644 test/unit/bit.result
>  delete mode 100644 test/unit/bitset_basic.result
>  delete mode 100644 test/unit/bitset_index.result
>  delete mode 100644 test/unit/bitset_iterator.result
>  delete mode 100644 test/unit/bloom.result
>  delete mode 100644 test/unit/bps_tree.result
>  delete mode 100644 test/unit/bps_tree_iterator.result
>  delete mode 100644 test/unit/cbus.result
>  delete mode 100644 test/unit/cbus_hang.result
>  delete mode 100644 test/unit/cbus_stress.result
>  delete mode 100644 test/unit/checkpoint_schedule.result
>  delete mode 100644 test/unit/coio.result
>  delete mode 100644 test/unit/coll.result
>  delete mode 100644 test/unit/column_mask.result
>  delete mode 100644 test/unit/crypto.result
>  delete mode 100644 test/unit/decimal.result
>  delete mode 100644 test/unit/fiber.result
>  delete mode 100644 test/unit/fiber_channel.result
>  delete mode 100644 test/unit/fiber_channel_stress.result
>  delete mode 100644 test/unit/fiber_cond.result
>  delete mode 100644 test/unit/fiber_stack.result
>  delete mode 100644 test/unit/fiber_stress.result
>  delete mode 100644 test/unit/find_path.result
>  delete mode 100644 test/unit/guard.result
>  delete mode 100644 test/unit/guava.result
>  delete mode 100644 test/unit/heap.result
>  delete mode 100644 test/unit/heap_iterator.result
>  delete mode 100644 test/unit/histogram.result
>  delete mode 100644 test/unit/int96.result
>  delete mode 100644 test/unit/json.result
>  delete mode 100644 test/unit/light.result
>  delete mode 100644 test/unit/luaL_iterator.result
>  delete mode 100644 test/unit/luaT_tuple_new.result
>  delete mode 100644 test/unit/merger.result
>  delete mode 100644 test/unit/mhash.result
>  delete mode 100644 test/unit/mhash_bytemap.result
>  delete mode 100644 test/unit/mp_error.result
>  delete mode 100644 test/unit/msgpack.result
>  delete mode 100644 test/unit/popen.result
>  delete mode 100644 test/unit/queue.result
>  delete mode 100644 test/unit/ratelimit.result
>  delete mode 100644 test/unit/reflection_c.result
>  delete mode 100644 test/unit/reflection_cxx.result
>  delete mode 100644 test/unit/rmean.result
>  delete mode 100644 test/unit/rope.result
>  delete mode 100644 test/unit/rope_avl.result
>  delete mode 100644 test/unit/rope_basic.result
>  delete mode 100644 test/unit/rope_stress.result
>  delete mode 100644 test/unit/rtree.result
>  delete mode 100644 test/unit/rtree_iterator.result
>  delete mode 100644 test/unit/rtree_multidim.result
>  delete mode 100644 test/unit/say.result
>  delete mode 100644 test/unit/scramble.result
>  delete mode 100644 test/unit/sio.result
>  delete mode 100644 test/unit/stailq.result
>  delete mode 100644 test/unit/swim.result
>  delete mode 100644 test/unit/swim_errinj.result
>  delete mode 100644 test/unit/swim_proto.result
>  delete mode 100644 test/unit/tuple_bigref.result
>  delete mode 100644 test/unit/uri.result
>  delete mode 100644 test/unit/uuid.result
>  delete mode 100644 test/unit/vclock.result
>  delete mode 100644 test/unit/vy_cache.result
>  delete mode 100644 test/unit/vy_mem.result
>  delete mode 100644 test/unit/vy_point_lookup.result
>  delete mode 100644 test/unit/vy_write_iterator.result
>  delete mode 100644 test/unit/xrow.result
> 
> diff --git a/test/unit/base64.result b/test/unit/base64.result
> deleted file mode 100644
> index cd1f2b3f6..000000000
> --- a/test/unit/base64.result
> +++ /dev/null
> @@ -1,178 +0,0 @@
> -1..28
> -	*** main ***
> -    1..3
> -    ok 1 - length
> -    ok 2 - decode length ok
> -    ok 3 - encode/decode
> -ok 1 - subtests
> -    1..6
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - no + symbols
> -    ok 4 - no = symbols
> -    ok 5 - decode length ok
> -    ok 6 - encode/decode
> -ok 2 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no = symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 3 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 4 - subtests
> -    1..3
> -    ok 1 - length
> -    ok 2 - decode length ok
> -    ok 3 - encode/decode
> -ok 5 - subtests
> -    1..6
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - no + symbols
> -    ok 4 - no = symbols
> -    ok 5 - decode length ok
> -    ok 6 - encode/decode
> -ok 6 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no = symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 7 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 8 - subtests
> -    1..3
> -    ok 1 - length
> -    ok 2 - decode length ok
> -    ok 3 - encode/decode
> -ok 9 - subtests
> -    1..6
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - no + symbols
> -    ok 4 - no = symbols
> -    ok 5 - decode length ok
> -    ok 6 - encode/decode
> -ok 10 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no = symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 11 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 12 - subtests
> -    1..3
> -    ok 1 - length
> -    ok 2 - decode length ok
> -    ok 3 - encode/decode
> -ok 13 - subtests
> -    1..6
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - no + symbols
> -    ok 4 - no = symbols
> -    ok 5 - decode length ok
> -    ok 6 - encode/decode
> -ok 14 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no = symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 15 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 16 - subtests
> -    1..3
> -    ok 1 - length
> -    ok 2 - decode length ok
> -    ok 3 - encode/decode
> -ok 17 - subtests
> -    1..6
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - no + symbols
> -    ok 4 - no = symbols
> -    ok 5 - decode length ok
> -    ok 6 - encode/decode
> -ok 18 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no = symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 19 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 20 - subtests
> -    1..3
> -    ok 1 - length
> -    ok 2 - decode length ok
> -    ok 3 - encode/decode
> -ok 21 - subtests
> -    1..6
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - no + symbols
> -    ok 4 - no = symbols
> -    ok 5 - decode length ok
> -    ok 6 - encode/decode
> -ok 22 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no = symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 23 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 24 - subtests
> -    1..3
> -    ok 1 - length
> -    ok 2 - decode length ok
> -    ok 3 - encode/decode
> -ok 25 - subtests
> -    1..6
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - no + symbols
> -    ok 4 - no = symbols
> -    ok 5 - decode length ok
> -    ok 6 - encode/decode
> -ok 26 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no = symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 27 - subtests
> -    1..4
> -    ok 1 - length
> -    ok 2 - no \n symbols
> -    ok 3 - decode length ok
> -    ok 4 - encode/decode
> -ok 28 - subtests
> -	*** main: done ***
> diff --git a/test/unit/bit.c b/test/unit/bit.c
> index da514484d..d18aa5579 100644
> --- a/test/unit/bit.c
> +++ b/test/unit/bit.c
> @@ -2,7 +2,6 @@
>  
>  #include <stdio.h>
>  #include <inttypes.h>
> -#include <assert.h>
>  #include <stdlib.h>
>  
>  #include "unit.h"
> @@ -21,6 +20,7 @@ static void
>  test_ctz_clz(void)
>  {
>  	header();
> +	plan(1);
>  
>  	for (size_t i = 0; i < sizeof(vals) / sizeof(vals[0]); i++) {
>  		if (vals[i] == 0)
> @@ -29,20 +29,22 @@ test_ctz_clz(void)
>  		uint64_t val64 = vals[i];
>  		uint32_t val32 = (uint32_t) vals[i];
>  
> -		printf("bit_ctz_u64(%" PRIu64 ") => %d\n", val64,
> +		note("bit_ctz_u64(%" PRIu64 ") => %d", val64,
>  			bit_ctz_u64(val64));
> -		printf("bit_clz_u64(%" PRIu64 ") => %d\n", val64,
> +		note("bit_clz_u64(%" PRIu64 ") => %d", val64,
>  			bit_clz_u64(val64));
>  
>  		if (vals[i] > UINT32_MAX)
>  			continue;
>  
> -		printf("bit_ctz_u32(%" PRIu32 ") => %d\n", val32,
> +		note("bit_ctz_u32(%" PRIu32 ") => %d", val32,
>  			bit_ctz_u32(val32));
> -		printf("bit_clz_u32(%" PRIu32 ") => %d\n", val32,
> +		note("bit_clz_u32(%" PRIu32 ") => %d", val32,
>  			bit_clz_u32(val32));
>  	}
>  
> +	ok(1, "test ctz clz");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -50,21 +52,24 @@ static void
>  test_count(void)
>  {
>  	header();
> +	plan(1);
>  
>  	for (size_t i = 0; i < sizeof(vals) / sizeof(vals[0]); i++) {
>  		uint64_t val64 = vals[i];
>  		uint32_t val32 = (uint32_t) vals[i];
>  
> -		printf("bit_count_u64(%" PRIu64 ") => %d\n", val64,
> +		note("bit_count_u64(%" PRIu64 ") => %d", val64,
>  			bit_count_u64(val64));
>  
>  		if (vals[i] > UINT32_MAX)
>  			continue;
>  
> -		printf("bit_count_u32(%" PRIu32 ") => %d\n", val32,
> +		note("bit_count_u32(%" PRIu32 ") => %d", val32,
>  			bit_count_u32(val32));
>  	}
>  
> +	ok(1, "test count");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -75,17 +80,17 @@ test_rotl_rotr_one(int rot)
>  		uint64_t val64 = vals[i];
>  		uint32_t val32 = (uint32_t) vals[i];
>  
> -		printf("bit_rotl_u64(%" PRIu64 ", %d) => %" PRIu64 "\n",
> +		note("bit_rotl_u64(%" PRIu64 ", %d) => %" PRIu64,
>  		       val64, rot, bit_rotl_u64(val64, rot));
> -		printf("bit_rotr_u64(%" PRIu64 ", %d) => %" PRIu64 "\n",
> +		note("bit_rotr_u64(%" PRIu64 ", %d) => %" PRIu64,
>  		       val64, rot, bit_rotr_u64(val64, rot));
>  
>  		if (vals[i] > UINT32_MAX || rot > 32)
>  			continue;
>  
> -		printf("bit_rotl_u32(%" PRIu32 ", %d) => %" PRIu32 "\n",
> +		note("bit_rotl_u32(%" PRIu32 ", %d) => %" PRIu32,
>  		       val32, rot, bit_rotl_u32(val32, rot));
> -		printf("bit_rotr_u32(%" PRIu32 ", %d) => %" PRIu32 "\n",
> +		note("bit_rotr_u32(%" PRIu32 ", %d) => %" PRIu32,
>  		       val32, rot, bit_rotr_u32(val32, rot));
>  	}
>  }
> @@ -94,12 +99,15 @@ static void
>  test_rotl_rotr(void)
>  {
>  	header();
> +	plan(1);
>  
>  	int rots[] = { 0, 1, 15, 16, 31, 32, 63, 64 };
>  	for (unsigned r = 0; r < sizeof(rots) / sizeof(rots[0]); r++) {
>  		test_rotl_rotr_one(rots[r]);
>  	}
>  
> +	ok(1, "test rotl rotr");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -107,36 +115,42 @@ static void
>  test_bswap(void)
>  {
>  	header();
> +	plan(1);
>  
>  	for (size_t i = 0; i < sizeof(vals) / sizeof(vals[0]); i++) {
>  		uint64_t val64 = vals[i];
>  		uint32_t val32 = (uint32_t) vals[i];
>  
> -		printf("bswap_u64(%" PRIu64 ") => %" PRIu64 "\n", val64,
> +		note("bswap_u64(%" PRIu64 ") => %" PRIu64, val64,
>  			bswap_u64(val64));
>  
>  		if (vals[i] > UINT32_MAX)
>  			continue;
>  
> -		printf("bswap_u32(%" PRIu32 ") => %" PRIu32 "\n", val32,
> +		note("bswap_u32(%" PRIu32 ") => %" PRIu32, val32,
>  			bswap_u32(val32));
>  	}
>  
> +	ok(1, "test bswap");
> +	check_plan();
>  	footer();
>  }
>  
>  static inline void
>  test_index_print(const int *start, const int *end)
>  {
> +	/*
>  	for (const int *cur = start; cur < end; cur++) {
>  		printf("%d ", *cur);
>  	}
> +	*/
>  }
>  
>  static void
>  test_index(void)
>  {
>  	header();
> +	plan(1);
>  
>  	int indexes[sizeof(int64_t) * CHAR_BIT + 1];
>  
> @@ -144,18 +158,20 @@ test_index(void)
>  		uint64_t val64 = vals[i];
>  		uint32_t val32 = (uint32_t) vals[i];
>  
> -		printf("bit_index_u64(%" PRIu64 ", *, -1) => ", val64);
> +		//printf("bit_index_u64(%" PRIu64 ", *, -1) => ", val64);
>  		test_index_print(indexes, bit_index_u64(val64, indexes, -1));
> -		printf("\n");
> +		//printf("\n");
>  
>  		if (vals[i] > UINT32_MAX)
>  			continue;
>  
> -		printf("bit_index_u32(%" PRIu32 ", *, -1) => ", val32);
> +		//printf("bit_index_u32(%" PRIu32 ", *, -1) => ", val32);
>  		test_index_print(indexes, bit_index_u32(val32, indexes, -1));
> -		printf("\n");
> +		//printf("\n");
>  	}
>  
> +	ok(1, "test index");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -164,6 +180,7 @@ static void
>  test_bit_iter(void)
>  {
>  	header();
> +	plan(1);
>  
>  	struct bit_iterator it;
>  	uint64_t *data = vals + 6;
> @@ -171,22 +188,24 @@ test_bit_iter(void)
>  
>  	size_t pos = 0;
>  
> -	printf("Set: ");
> +	note("Set: ");
>  	bit_iterator_init(&it, data, size, true);
>  	while ( (pos = bit_iterator_next(&it)) != SIZE_MAX) {
> -		printf("%zu, ", pos);
> +		//printf("%zu, ", pos);
>  		fail_unless(bit_test(data, pos));
>  	}
> -	printf("\n");
> +	//printf("\n");
>  
> -	printf("Clear: ");
> +	note("Clear: ");
>  	bit_iterator_init(&it, data, size, false);
>  	while ( (pos = bit_iterator_next(&it)) != SIZE_MAX) {
> -		printf("%zu, ", pos);
> +		//printf("%zu, ", pos);
>  		fail_if(bit_test(data, pos));
>  	}
> -	printf("\n");
> +	//printf("\n");
>  
> +	ok(1, "test bit iter");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -194,6 +213,7 @@ static void
>  test_bit_iter_empty(void)
>  {
>  	header();
> +	plan(1);
>  
>  	struct bit_iterator it;
>  
> @@ -202,7 +222,9 @@ test_bit_iter_empty(void)
>  
>  	bit_iterator_init(&it, NULL, 0, false);
>  	fail_unless(bit_iterator_next(&it) == SIZE_MAX);
> -
> +	
> +	ok(1, "test bit iter empty");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -210,6 +232,7 @@ static void
>  test_bitmap_size(void)
>  {
>  	header();
> +	plan(1);
>  	fail_unless(bitmap_size(1) == sizeof(long));
>  	fail_unless(bitmap_size(10) == sizeof(long));
>  	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT) == sizeof(long));
> @@ -217,12 +240,15 @@ test_bitmap_size(void)
>  	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT * 4) == sizeof(long) * 4);
>  	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT * 4 - 1) == sizeof(long) * 4);
>  	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT * 9 / 2) == sizeof(long) * 5);
> +	ok(1, "test bitmap size");
> +	check_plan();
>  	footer();
>  }
>  
>  int
>  main(void)
>  {
> +	plan(8);
>  	test_ctz_clz();
>  	test_count();
>  	test_rotl_rotr();
> @@ -231,4 +257,5 @@ main(void)
>  	test_bit_iter();
>  	test_bit_iter_empty();
>  	test_bitmap_size();
> +	check_plan();
>  }
> diff --git a/test/unit/bit.result b/test/unit/bit.result
> deleted file mode 100644
> index 2d4ccc6f4..000000000
> --- a/test/unit/bit.result
> +++ /dev/null
> @@ -1,895 +0,0 @@
> -	*** test_ctz_clz ***
> -bit_ctz_u64(1) => 0
> -bit_clz_u64(1) => 63
> -bit_ctz_u32(1) => 0
> -bit_clz_u32(1) => 31
> -bit_ctz_u64(2) => 1
> -bit_clz_u64(2) => 62
> -bit_ctz_u32(2) => 1
> -bit_clz_u32(2) => 30
> -bit_ctz_u64(32768) => 15
> -bit_clz_u64(32768) => 48
> -bit_ctz_u32(32768) => 15
> -bit_clz_u32(32768) => 16
> -bit_ctz_u64(65535) => 0
> -bit_clz_u64(65535) => 48
> -bit_ctz_u32(65535) => 0
> -bit_clz_u32(65535) => 16
> -bit_ctz_u64(65536) => 16
> -bit_clz_u64(65536) => 47
> -bit_ctz_u32(65536) => 16
> -bit_clz_u32(65536) => 15
> -bit_ctz_u64(726075912) => 3
> -bit_clz_u64(726075912) => 34
> -bit_ctz_u32(726075912) => 3
> -bit_clz_u32(726075912) => 2
> -bit_ctz_u64(858993459) => 0
> -bit_clz_u64(858993459) => 34
> -bit_ctz_u32(858993459) => 0
> -bit_clz_u32(858993459) => 2
> -bit_ctz_u64(1073741824) => 30
> -bit_clz_u64(1073741824) => 33
> -bit_ctz_u32(1073741824) => 30
> -bit_clz_u32(1073741824) => 1
> -bit_ctz_u64(1245250552) => 3
> -bit_clz_u64(1245250552) => 33
> -bit_ctz_u32(1245250552) => 3
> -bit_clz_u32(1245250552) => 1
> -bit_ctz_u64(1431655765) => 0
> -bit_clz_u64(1431655765) => 33
> -bit_ctz_u32(1431655765) => 0
> -bit_clz_u32(1431655765) => 1
> -bit_ctz_u64(1656977767) => 0
> -bit_clz_u64(1656977767) => 33
> -bit_ctz_u32(1656977767) => 0
> -bit_clz_u32(1656977767) => 1
> -bit_ctz_u64(2147483648) => 31
> -bit_clz_u64(2147483648) => 32
> -bit_ctz_u32(2147483648) => 31
> -bit_clz_u32(2147483648) => 0
> -bit_ctz_u64(2283114629) => 0
> -bit_clz_u64(2283114629) => 32
> -bit_ctz_u32(2283114629) => 0
> -bit_clz_u32(2283114629) => 0
> -bit_ctz_u64(2502548245) => 0
> -bit_clz_u64(2502548245) => 32
> -bit_ctz_u32(2502548245) => 0
> -bit_clz_u32(2502548245) => 0
> -bit_ctz_u64(4294967295) => 0
> -bit_clz_u64(4294967295) => 32
> -bit_ctz_u32(4294967295) => 0
> -bit_clz_u32(4294967295) => 0
> -bit_ctz_u64(708915120906848425) => 0
> -bit_clz_u64(708915120906848425) => 4
> -bit_ctz_u64(1960191741125985428) => 2
> -bit_clz_u64(1960191741125985428) => 3
> -bit_ctz_u64(3689348814741910323) => 0
> -bit_clz_u64(3689348814741910323) => 2
> -bit_ctz_u64(5578377670650038654) => 1
> -bit_clz_u64(5578377670650038654) => 1
> -bit_ctz_u64(9223372036854775808) => 63
> -bit_clz_u64(9223372036854775808) => 0
> -bit_ctz_u64(10755112315580060033) => 0
> -bit_clz_u64(10755112315580060033) => 0
> -bit_ctz_u64(11163782031541429823) => 0
> -bit_clz_u64(11163782031541429823) => 0
> -bit_ctz_u64(13903686156871869732) => 2
> -bit_clz_u64(13903686156871869732) => 0
> -bit_ctz_u64(14237897302422917095) => 0
> -bit_clz_u64(14237897302422917095) => 0
> -bit_ctz_u64(14302190498657618739) => 0
> -bit_clz_u64(14302190498657618739) => 0
> -bit_ctz_u64(15766411510232741269) => 0
> -bit_clz_u64(15766411510232741269) => 0
> -bit_ctz_u64(15984546468465238145) => 0
> -bit_clz_u64(15984546468465238145) => 0
> -bit_ctz_u64(18446744073709551615) => 0
> -bit_clz_u64(18446744073709551615) => 0
> -	*** test_ctz_clz: done ***
> -	*** test_count ***
> -bit_count_u64(0) => 0
> -bit_count_u32(0) => 0
> -bit_count_u64(1) => 1
> -bit_count_u32(1) => 1
> -bit_count_u64(2) => 1
> -bit_count_u32(2) => 1
> -bit_count_u64(32768) => 1
> -bit_count_u32(32768) => 1
> -bit_count_u64(65535) => 16
> -bit_count_u32(65535) => 16
> -bit_count_u64(65536) => 1
> -bit_count_u32(65536) => 1
> -bit_count_u64(726075912) => 11
> -bit_count_u32(726075912) => 11
> -bit_count_u64(858993459) => 16
> -bit_count_u32(858993459) => 16
> -bit_count_u64(1073741824) => 1
> -bit_count_u32(1073741824) => 1
> -bit_count_u64(1245250552) => 14
> -bit_count_u32(1245250552) => 14
> -bit_count_u64(1431655765) => 16
> -bit_count_u32(1431655765) => 16
> -bit_count_u64(1656977767) => 17
> -bit_count_u32(1656977767) => 17
> -bit_count_u64(2147483648) => 1
> -bit_count_u32(2147483648) => 1
> -bit_count_u64(2283114629) => 10
> -bit_count_u32(2283114629) => 10
> -bit_count_u64(2502548245) => 16
> -bit_count_u32(2502548245) => 16
> -bit_count_u64(4294967295) => 32
> -bit_count_u32(4294967295) => 32
> -bit_count_u64(708915120906848425) => 29
> -bit_count_u64(1960191741125985428) => 19
> -bit_count_u64(3689348814741910323) => 32
> -bit_count_u64(5578377670650038654) => 31
> -bit_count_u64(9223372036854775808) => 1
> -bit_count_u64(10755112315580060033) => 24
> -bit_count_u64(11163782031541429823) => 35
> -bit_count_u64(13903686156871869732) => 28
> -bit_count_u64(14237897302422917095) => 33
> -bit_count_u64(14302190498657618739) => 37
> -bit_count_u64(15766411510232741269) => 33
> -bit_count_u64(15984546468465238145) => 25
> -bit_count_u64(18446744073709551615) => 64
> -	*** test_count: done ***
> -	*** test_rotl_rotr ***
> -bit_rotl_u64(0, 0) => 0
> -bit_rotr_u64(0, 0) => 0
> -bit_rotl_u32(0, 0) => 0
> -bit_rotr_u32(0, 0) => 0
> -bit_rotl_u64(1, 0) => 1
> -bit_rotr_u64(1, 0) => 1
> -bit_rotl_u32(1, 0) => 1
> -bit_rotr_u32(1, 0) => 1
> -bit_rotl_u64(2, 0) => 2
> -bit_rotr_u64(2, 0) => 2
> -bit_rotl_u32(2, 0) => 2
> -bit_rotr_u32(2, 0) => 2
> -bit_rotl_u64(32768, 0) => 32768
> -bit_rotr_u64(32768, 0) => 32768
> -bit_rotl_u32(32768, 0) => 32768
> -bit_rotr_u32(32768, 0) => 32768
> -bit_rotl_u64(65535, 0) => 65535
> -bit_rotr_u64(65535, 0) => 65535
> -bit_rotl_u32(65535, 0) => 65535
> -bit_rotr_u32(65535, 0) => 65535
> -bit_rotl_u64(65536, 0) => 65536
> -bit_rotr_u64(65536, 0) => 65536
> -bit_rotl_u32(65536, 0) => 65536
> -bit_rotr_u32(65536, 0) => 65536
> -bit_rotl_u64(726075912, 0) => 726075912
> -bit_rotr_u64(726075912, 0) => 726075912
> -bit_rotl_u32(726075912, 0) => 726075912
> -bit_rotr_u32(726075912, 0) => 726075912
> -bit_rotl_u64(858993459, 0) => 858993459
> -bit_rotr_u64(858993459, 0) => 858993459
> -bit_rotl_u32(858993459, 0) => 858993459
> -bit_rotr_u32(858993459, 0) => 858993459
> -bit_rotl_u64(1073741824, 0) => 1073741824
> -bit_rotr_u64(1073741824, 0) => 1073741824
> -bit_rotl_u32(1073741824, 0) => 1073741824
> -bit_rotr_u32(1073741824, 0) => 1073741824
> -bit_rotl_u64(1245250552, 0) => 1245250552
> -bit_rotr_u64(1245250552, 0) => 1245250552
> -bit_rotl_u32(1245250552, 0) => 1245250552
> -bit_rotr_u32(1245250552, 0) => 1245250552
> -bit_rotl_u64(1431655765, 0) => 1431655765
> -bit_rotr_u64(1431655765, 0) => 1431655765
> -bit_rotl_u32(1431655765, 0) => 1431655765
> -bit_rotr_u32(1431655765, 0) => 1431655765
> -bit_rotl_u64(1656977767, 0) => 1656977767
> -bit_rotr_u64(1656977767, 0) => 1656977767
> -bit_rotl_u32(1656977767, 0) => 1656977767
> -bit_rotr_u32(1656977767, 0) => 1656977767
> -bit_rotl_u64(2147483648, 0) => 2147483648
> -bit_rotr_u64(2147483648, 0) => 2147483648
> -bit_rotl_u32(2147483648, 0) => 2147483648
> -bit_rotr_u32(2147483648, 0) => 2147483648
> -bit_rotl_u64(2283114629, 0) => 2283114629
> -bit_rotr_u64(2283114629, 0) => 2283114629
> -bit_rotl_u32(2283114629, 0) => 2283114629
> -bit_rotr_u32(2283114629, 0) => 2283114629
> -bit_rotl_u64(2502548245, 0) => 2502548245
> -bit_rotr_u64(2502548245, 0) => 2502548245
> -bit_rotl_u32(2502548245, 0) => 2502548245
> -bit_rotr_u32(2502548245, 0) => 2502548245
> -bit_rotl_u64(4294967295, 0) => 4294967295
> -bit_rotr_u64(4294967295, 0) => 4294967295
> -bit_rotl_u32(4294967295, 0) => 4294967295
> -bit_rotr_u32(4294967295, 0) => 4294967295
> -bit_rotl_u64(708915120906848425, 0) => 708915120906848425
> -bit_rotr_u64(708915120906848425, 0) => 708915120906848425
> -bit_rotl_u64(1960191741125985428, 0) => 1960191741125985428
> -bit_rotr_u64(1960191741125985428, 0) => 1960191741125985428
> -bit_rotl_u64(3689348814741910323, 0) => 3689348814741910323
> -bit_rotr_u64(3689348814741910323, 0) => 3689348814741910323
> -bit_rotl_u64(5578377670650038654, 0) => 5578377670650038654
> -bit_rotr_u64(5578377670650038654, 0) => 5578377670650038654
> -bit_rotl_u64(9223372036854775808, 0) => 9223372036854775808
> -bit_rotr_u64(9223372036854775808, 0) => 9223372036854775808
> -bit_rotl_u64(10755112315580060033, 0) => 10755112315580060033
> -bit_rotr_u64(10755112315580060033, 0) => 10755112315580060033
> -bit_rotl_u64(11163782031541429823, 0) => 11163782031541429823
> -bit_rotr_u64(11163782031541429823, 0) => 11163782031541429823
> -bit_rotl_u64(13903686156871869732, 0) => 13903686156871869732
> -bit_rotr_u64(13903686156871869732, 0) => 13903686156871869732
> -bit_rotl_u64(14237897302422917095, 0) => 14237897302422917095
> -bit_rotr_u64(14237897302422917095, 0) => 14237897302422917095
> -bit_rotl_u64(14302190498657618739, 0) => 14302190498657618739
> -bit_rotr_u64(14302190498657618739, 0) => 14302190498657618739
> -bit_rotl_u64(15766411510232741269, 0) => 15766411510232741269
> -bit_rotr_u64(15766411510232741269, 0) => 15766411510232741269
> -bit_rotl_u64(15984546468465238145, 0) => 15984546468465238145
> -bit_rotr_u64(15984546468465238145, 0) => 15984546468465238145
> -bit_rotl_u64(18446744073709551615, 0) => 18446744073709551615
> -bit_rotr_u64(18446744073709551615, 0) => 18446744073709551615
> -bit_rotl_u64(0, 1) => 0
> -bit_rotr_u64(0, 1) => 0
> -bit_rotl_u32(0, 1) => 0
> -bit_rotr_u32(0, 1) => 0
> -bit_rotl_u64(1, 1) => 2
> -bit_rotr_u64(1, 1) => 9223372036854775808
> -bit_rotl_u32(1, 1) => 2
> -bit_rotr_u32(1, 1) => 2147483648
> -bit_rotl_u64(2, 1) => 4
> -bit_rotr_u64(2, 1) => 1
> -bit_rotl_u32(2, 1) => 4
> -bit_rotr_u32(2, 1) => 1
> -bit_rotl_u64(32768, 1) => 65536
> -bit_rotr_u64(32768, 1) => 16384
> -bit_rotl_u32(32768, 1) => 65536
> -bit_rotr_u32(32768, 1) => 16384
> -bit_rotl_u64(65535, 1) => 131070
> -bit_rotr_u64(65535, 1) => 9223372036854808575
> -bit_rotl_u32(65535, 1) => 131070
> -bit_rotr_u32(65535, 1) => 2147516415
> -bit_rotl_u64(65536, 1) => 131072
> -bit_rotr_u64(65536, 1) => 32768
> -bit_rotl_u32(65536, 1) => 131072
> -bit_rotr_u32(65536, 1) => 32768
> -bit_rotl_u64(726075912, 1) => 1452151824
> -bit_rotr_u64(726075912, 1) => 363037956
> -bit_rotl_u32(726075912, 1) => 1452151824
> -bit_rotr_u32(726075912, 1) => 363037956
> -bit_rotl_u64(858993459, 1) => 1717986918
> -bit_rotr_u64(858993459, 1) => 9223372037284272537
> -bit_rotl_u32(858993459, 1) => 1717986918
> -bit_rotr_u32(858993459, 1) => 2576980377
> -bit_rotl_u64(1073741824, 1) => 2147483648
> -bit_rotr_u64(1073741824, 1) => 536870912
> -bit_rotl_u32(1073741824, 1) => 2147483648
> -bit_rotr_u32(1073741824, 1) => 536870912
> -bit_rotl_u64(1245250552, 1) => 2490501104
> -bit_rotr_u64(1245250552, 1) => 622625276
> -bit_rotl_u32(1245250552, 1) => 2490501104
> -bit_rotr_u32(1245250552, 1) => 622625276
> -bit_rotl_u64(1431655765, 1) => 2863311530
> -bit_rotr_u64(1431655765, 1) => 9223372037570603690
> -bit_rotl_u32(1431655765, 1) => 2863311530
> -bit_rotr_u32(1431655765, 1) => 2863311530
> -bit_rotl_u64(1656977767, 1) => 3313955534
> -bit_rotr_u64(1656977767, 1) => 9223372037683264691
> -bit_rotl_u32(1656977767, 1) => 3313955534
> -bit_rotr_u32(1656977767, 1) => 2975972531
> -bit_rotl_u64(2147483648, 1) => 4294967296
> -bit_rotr_u64(2147483648, 1) => 1073741824
> -bit_rotl_u32(2147483648, 1) => 1
> -bit_rotr_u32(2147483648, 1) => 1073741824
> -bit_rotl_u64(2283114629, 1) => 4566229258
> -bit_rotr_u64(2283114629, 1) => 9223372037996333122
> -bit_rotl_u32(2283114629, 1) => 271261963
> -bit_rotr_u32(2283114629, 1) => 3289040962
> -bit_rotl_u64(2502548245, 1) => 5005096490
> -bit_rotr_u64(2502548245, 1) => 9223372038106049930
> -bit_rotl_u32(2502548245, 1) => 710129195
> -bit_rotr_u32(2502548245, 1) => 3398757770
> -bit_rotl_u64(4294967295, 1) => 8589934590
> -bit_rotr_u64(4294967295, 1) => 9223372039002259455
> -bit_rotl_u32(4294967295, 1) => 4294967295
> -bit_rotr_u32(4294967295, 1) => 4294967295
> -bit_rotl_u64(708915120906848425, 1) => 1417830241813696850
> -bit_rotr_u64(708915120906848425, 1) => 9577829597308200020
> -bit_rotl_u64(1960191741125985428, 1) => 3920383482251970856
> -bit_rotr_u64(1960191741125985428, 1) => 980095870562992714
> -bit_rotl_u64(3689348814741910323, 1) => 7378697629483820646
> -bit_rotr_u64(3689348814741910323, 1) => 11068046444225730969
> -bit_rotl_u64(5578377670650038654, 1) => 11156755341300077308
> -bit_rotr_u64(5578377670650038654, 1) => 2789188835325019327
> -bit_rotl_u64(9223372036854775808, 1) => 1
> -bit_rotr_u64(9223372036854775808, 1) => 4611686018427387904
> -bit_rotl_u64(10755112315580060033, 1) => 3063480557450568451
> -bit_rotr_u64(10755112315580060033, 1) => 14600928194644805824
> -bit_rotl_u64(11163782031541429823, 1) => 3880819989373308031
> -bit_rotr_u64(11163782031541429823, 1) => 14805263052625490719
> -bit_rotl_u64(13903686156871869732, 1) => 9360628240034187849
> -bit_rotr_u64(13903686156871869732, 1) => 6951843078435934866
> -bit_rotl_u64(14237897302422917095, 1) => 10029050531136282575
> -bit_rotr_u64(14237897302422917095, 1) => 16342320688066234355
> -bit_rotl_u64(14302190498657618739, 1) => 10157636923605685863
> -bit_rotr_u64(14302190498657618739, 1) => 16374467286183585177
> -bit_rotl_u64(15766411510232741269, 1) => 13086078946755930923
> -bit_rotr_u64(15766411510232741269, 1) => 17106577791971146442
> -bit_rotl_u64(15984546468465238145, 1) => 13522348863220924675
> -bit_rotr_u64(15984546468465238145, 1) => 17215645271087394880
> -bit_rotl_u64(18446744073709551615, 1) => 18446744073709551615
> -bit_rotr_u64(18446744073709551615, 1) => 18446744073709551615
> -bit_rotl_u64(0, 15) => 0
> -bit_rotr_u64(0, 15) => 0
> -bit_rotl_u32(0, 15) => 0
> -bit_rotr_u32(0, 15) => 0
> -bit_rotl_u64(1, 15) => 32768
> -bit_rotr_u64(1, 15) => 562949953421312
> -bit_rotl_u32(1, 15) => 32768
> -bit_rotr_u32(1, 15) => 131072
> -bit_rotl_u64(2, 15) => 65536
> -bit_rotr_u64(2, 15) => 1125899906842624
> -bit_rotl_u32(2, 15) => 65536
> -bit_rotr_u32(2, 15) => 262144
> -bit_rotl_u64(32768, 15) => 1073741824
> -bit_rotr_u64(32768, 15) => 1
> -bit_rotl_u32(32768, 15) => 1073741824
> -bit_rotr_u32(32768, 15) => 1
> -bit_rotl_u64(65535, 15) => 2147450880
> -bit_rotr_u64(65535, 15) => 18446181123756130305
> -bit_rotl_u32(65535, 15) => 2147450880
> -bit_rotr_u32(65535, 15) => 4294836225
> -bit_rotl_u64(65536, 15) => 2147483648
> -bit_rotr_u64(65536, 15) => 2
> -bit_rotl_u32(65536, 15) => 2147483648
> -bit_rotr_u32(65536, 15) => 2
> -bit_rotl_u64(726075912, 15) => 23792055484416
> -bit_rotr_u64(726075912, 15) => 1445655480385951374
> -bit_rotl_u32(726075912, 15) => 2231637411
> -bit_rotr_u32(726075912, 15) => 336615054
> -bit_rotl_u64(858993459, 15) => 28147497664512
> -bit_rotr_u64(858993459, 15) => 7378585039493162598
> -bit_rotl_u32(858993459, 15) => 2576980377
> -bit_rotr_u32(858993459, 15) => 1717986918
> -bit_rotl_u64(1073741824, 15) => 35184372088832
> -bit_rotr_u64(1073741824, 15) => 32768
> -bit_rotl_u32(1073741824, 15) => 8192
> -bit_rotr_u32(1073741824, 15) => 32768
> -bit_rotl_u64(1245250552, 15) => 40804370087936
> -bit_rotr_u64(1245250552, 15) => 571957152676090994
> -bit_rotl_u32(1245250552, 15) => 2180785436
> -bit_rotr_u32(1245250552, 15) => 133207154
> -bit_rotl_u64(1431655765, 15) => 46912496107520
> -bit_rotr_u64(1431655765, 15) => 12297641732488604330
> -bit_rotl_u32(1431655765, 15) => 2863311530
> -bit_rotr_u32(1431655765, 15) => 2863311530
> -bit_rotl_u64(1656977767, 15) => 54295847469056
> -bit_rotr_u64(1656977767, 15) => 17495921602381006214
> -bit_rotl_u32(1656977767, 15) => 3165892961
> -bit_rotr_u32(1656977767, 15) => 4073637254
> -bit_rotl_u64(2147483648, 15) => 70368744177664
> -bit_rotr_u64(2147483648, 15) => 65536
> -bit_rotl_u32(2147483648, 15) => 16384
> -bit_rotr_u32(2147483648, 15) => 65536
> -bit_rotl_u64(2283114629, 15) => 74813100163072
> -bit_rotr_u64(2283114629, 15) => 2380715353018798123
> -bit_rotl_u32(2283114629, 15) => 3359818762
> -bit_rotr_u32(2283114629, 15) => 554373163
> -bit_rotl_u64(2502548245, 15) => 82003500892160
> -bit_rotr_u64(2502548245, 15) => 13126304063924808275
> -bit_rotl_u32(2502548245, 15) => 3985296020
> -bit_rotr_u32(2502548245, 15) => 3056282195
> -bit_rotl_u64(4294967295, 15) => 140737488322560
> -bit_rotr_u64(4294967295, 15) => 18446181123756261375
> -bit_rotl_u32(4294967295, 15) => 4294967295
> -bit_rotr_u32(4294967295, 15) => 4294967295
> -bit_rotl_u64(708915120906848425, 15) => 5279893075283707115
> -bit_rotr_u64(708915120906848425, 15) => 10471453717962410780
> -bit_rotl_u64(1960191741125985428, 15) => 108559631781274
> -bit_rotr_u64(1960191741125985428, 15) => 659837165714377456
> -bit_rotl_u64(3689348814741910323, 15) => 11068046444225730969
> -bit_rotr_u64(3689348814741910323, 15) => 7378697629483820646
> -bit_rotl_u64(5578377670650038654, 15) => 3492485472519661237
> -bit_rotr_u64(5578377670650038654, 15) => 1368138625390162978
> -bit_rotl_u64(9223372036854775808, 15) => 16384
> -bit_rotr_u64(9223372036854775808, 15) => 281474976710656
> -bit_rotl_u64(10755112315580060033, 15) => 16921572780133108384
> -bit_rotr_u64(10755112315580060033, 15) => 2522906961261232936
> -bit_rotl_u64(11163782031541429823, 15) => 15874627889163914614
> -bit_rotr_u64(11163782031541429823, 15) => 14735555722393159636
> -bit_rotl_u64(13903686156871869732, 15) => 16749599972631142521
> -bit_rotr_u64(13903686156871869732, 15) => 5352952463958352314
> -bit_rotl_u64(14237897302422917095, 15) => 10814437605877473995
> -bit_rotr_u64(14237897302422917095, 15) => 2292203766521423570
> -bit_rotl_u64(14302190498657618739, 15) => 14645067421692060477
> -bit_rotr_u64(14302190498657618739, 15) => 10837786021529578728
> -bit_rotl_u64(15766411510232741269, 15) => 14257838996763372902
> -bit_rotr_u64(15766411510232741269, 15) => 16945837700629926938
> -bit_rotl_u64(15984546468465238145, 15) => 4767449759914979050
> -bit_rotr_u64(15984546468465238145, 15) => 13908166408919157040
> -bit_rotl_u64(18446744073709551615, 15) => 18446744073709551615
> -bit_rotr_u64(18446744073709551615, 15) => 18446744073709551615
> -bit_rotl_u64(0, 16) => 0
> -bit_rotr_u64(0, 16) => 0
> -bit_rotl_u32(0, 16) => 0
> -bit_rotr_u32(0, 16) => 0
> -bit_rotl_u64(1, 16) => 65536
> -bit_rotr_u64(1, 16) => 281474976710656
> -bit_rotl_u32(1, 16) => 65536
> -bit_rotr_u32(1, 16) => 65536
> -bit_rotl_u64(2, 16) => 131072
> -bit_rotr_u64(2, 16) => 562949953421312
> -bit_rotl_u32(2, 16) => 131072
> -bit_rotr_u32(2, 16) => 131072
> -bit_rotl_u64(32768, 16) => 2147483648
> -bit_rotr_u64(32768, 16) => 9223372036854775808
> -bit_rotl_u32(32768, 16) => 2147483648
> -bit_rotr_u32(32768, 16) => 2147483648
> -bit_rotl_u64(65535, 16) => 4294901760
> -bit_rotr_u64(65535, 16) => 18446462598732840960
> -bit_rotl_u32(65535, 16) => 4294901760
> -bit_rotr_u32(65535, 16) => 4294901760
> -bit_rotl_u64(65536, 16) => 4294967296
> -bit_rotr_u64(65536, 16) => 1
> -bit_rotl_u32(65536, 16) => 1
> -bit_rotr_u32(65536, 16) => 1
> -bit_rotl_u64(726075912, 16) => 47584110968832
> -bit_rotr_u64(726075912, 16) => 722827740192975687
> -bit_rotl_u32(726075912, 16) => 168307527
> -bit_rotr_u32(726075912, 16) => 168307527
> -bit_rotl_u64(858993459, 16) => 56294995329024
> -bit_rotr_u64(858993459, 16) => 3689292519746581299
> -bit_rotl_u32(858993459, 16) => 858993459
> -bit_rotr_u32(858993459, 16) => 858993459
> -bit_rotl_u64(1073741824, 16) => 70368744177664
> -bit_rotr_u64(1073741824, 16) => 16384
> -bit_rotl_u32(1073741824, 16) => 16384
> -bit_rotr_u32(1073741824, 16) => 16384
> -bit_rotl_u64(1245250552, 16) => 81608740175872
> -bit_rotr_u64(1245250552, 16) => 285978576338045497
> -bit_rotl_u32(1245250552, 16) => 66603577
> -bit_rotr_u32(1245250552, 16) => 66603577
> -bit_rotl_u64(1431655765, 16) => 93824992215040
> -bit_rotr_u64(1431655765, 16) => 6148820866244302165
> -bit_rotl_u32(1431655765, 16) => 1431655765
> -bit_rotr_u32(1431655765, 16) => 1431655765
> -bit_rotl_u64(1656977767, 16) => 108591694938112
> -bit_rotr_u64(1656977767, 16) => 8747960801190503107
> -bit_rotl_u32(1656977767, 16) => 2036818627
> -bit_rotr_u32(1656977767, 16) => 2036818627
> -bit_rotl_u64(2147483648, 16) => 140737488355328
> -bit_rotr_u64(2147483648, 16) => 32768
> -bit_rotl_u32(2147483648, 16) => 32768
> -bit_rotr_u32(2147483648, 16) => 32768
> -bit_rotl_u64(2283114629, 16) => 149626200326144
> -bit_rotr_u64(2283114629, 16) => 10413729713364174869
> -bit_rotl_u32(2283114629, 16) => 2424670229
> -bit_rotr_u32(2283114629, 16) => 2424670229
> -bit_rotl_u64(2502548245, 16) => 164007001784320
> -bit_rotr_u64(2502548245, 16) => 15786524068817179945
> -bit_rotl_u32(2502548245, 16) => 3675624745
> -bit_rotr_u32(2502548245, 16) => 3675624745
> -bit_rotl_u64(4294967295, 16) => 281474976645120
> -bit_rotr_u64(4294967295, 16) => 18446462598732906495
> -bit_rotl_u32(4294967295, 16) => 4294967295
> -bit_rotr_u32(4294967295, 16) => 4294967295
> -bit_rotl_u64(708915120906848425, 16) => 10559786150567414230
> -bit_rotr_u64(708915120906848425, 16) => 5235726858981205390
> -bit_rotl_u64(1960191741125985428, 16) => 217119263562548
> -bit_rotr_u64(1960191741125985428, 16) => 329918582857188728
> -bit_rotl_u64(3689348814741910323, 16) => 3689348814741910323
> -bit_rotr_u64(3689348814741910323, 16) => 3689348814741910323
> -bit_rotl_u64(5578377670650038654, 16) => 6984970945039322474
> -bit_rotr_u64(5578377670650038654, 16) => 684069312695081489
> -bit_rotl_u64(9223372036854775808, 16) => 32768
> -bit_rotr_u64(9223372036854775808, 16) => 140737488355328
> -bit_rotl_u64(10755112315580060033, 16) => 15396401486556665153
> -bit_rotr_u64(10755112315580060033, 16) => 1261453480630616468
> -bit_rotl_u64(11163782031541429823, 16) => 13302511704618277613
> -bit_rotr_u64(11163782031541429823, 16) => 7367777861196579818
> -bit_rotl_u64(13903686156871869732, 16) => 15052455871552733427
> -bit_rotr_u64(13903686156871869732, 16) => 2676476231979176157
> -bit_rotl_u64(14237897302422917095, 16) => 3182131138045396375
> -bit_rotr_u64(14237897302422917095, 16) => 1146101883260711785
> -bit_rotl_u64(14302190498657618739, 16) => 10843390769674569339
> -bit_rotr_u64(14302190498657618739, 16) => 5418893010764789364
> -bit_rotl_u64(15766411510232741269, 16) => 10068933919817194189
> -bit_rotr_u64(15766411510232741269, 16) => 8472918850314963469
> -bit_rotl_u64(15984546468465238145, 16) => 9534899519829958100
> -bit_rotr_u64(15984546468465238145, 16) => 6954083204459578520
> -bit_rotl_u64(18446744073709551615, 16) => 18446744073709551615
> -bit_rotr_u64(18446744073709551615, 16) => 18446744073709551615
> -bit_rotl_u64(0, 31) => 0
> -bit_rotr_u64(0, 31) => 0
> -bit_rotl_u32(0, 31) => 0
> -bit_rotr_u32(0, 31) => 0
> -bit_rotl_u64(1, 31) => 2147483648
> -bit_rotr_u64(1, 31) => 8589934592
> -bit_rotl_u32(1, 31) => 2147483648
> -bit_rotr_u32(1, 31) => 2
> -bit_rotl_u64(2, 31) => 4294967296
> -bit_rotr_u64(2, 31) => 17179869184
> -bit_rotl_u32(2, 31) => 1
> -bit_rotr_u32(2, 31) => 4
> -bit_rotl_u64(32768, 31) => 70368744177664
> -bit_rotr_u64(32768, 31) => 281474976710656
> -bit_rotl_u32(32768, 31) => 16384
> -bit_rotr_u32(32768, 31) => 65536
> -bit_rotl_u64(65535, 31) => 140735340871680
> -bit_rotr_u64(65535, 31) => 562941363486720
> -bit_rotl_u32(65535, 31) => 2147516415
> -bit_rotr_u32(65535, 31) => 131070
> -bit_rotl_u64(65536, 31) => 140737488355328
> -bit_rotr_u64(65536, 31) => 562949953421312
> -bit_rotl_u32(65536, 31) => 32768
> -bit_rotr_u32(65536, 31) => 131072
> -bit_rotl_u64(726075912, 31) => 1559236148226686976
> -bit_rotr_u64(726075912, 31) => 6236944592906747904
> -bit_rotl_u32(726075912, 31) => 363037956
> -bit_rotr_u32(726075912, 31) => 1452151824
> -bit_rotl_u64(858993459, 31) => 1844674406941458432
> -bit_rotr_u64(858993459, 31) => 7378697627765833728
> -bit_rotl_u32(858993459, 31) => 2576980377
> -bit_rotr_u32(858993459, 31) => 1717986918
> -bit_rotl_u64(1073741824, 31) => 2305843009213693952
> -bit_rotr_u64(1073741824, 31) => 9223372036854775808
> -bit_rotl_u32(1073741824, 31) => 536870912
> -bit_rotr_u32(1073741824, 31) => 2147483648
> -bit_rotl_u64(1245250552, 31) => 2674155198082973696
> -bit_rotr_u64(1245250552, 31) => 10696620792331894784
> -bit_rotl_u32(1245250552, 31) => 622625276
> -bit_rotr_u32(1245250552, 31) => 2490501104
> -bit_rotl_u64(1431655765, 31) => 3074457344902430720
> -bit_rotr_u64(1431655765, 31) => 12297829379609722880
> -bit_rotl_u32(1431655765, 31) => 2863311530
> -bit_rotr_u32(1431655765, 31) => 2863311530
> -bit_rotl_u64(1656977767, 31) => 3558332659732054016
> -bit_rotr_u64(1656977767, 31) => 14233330638928216064
> -bit_rotl_u32(1656977767, 31) => 2975972531
> -bit_rotr_u32(1656977767, 31) => 3313955534
> -bit_rotl_u64(2147483648, 31) => 4611686018427387904
> -bit_rotr_u64(2147483648, 31) => 1
> -bit_rotl_u32(2147483648, 31) => 1073741824
> -bit_rotr_u32(2147483648, 31) => 1
> -bit_rotl_u64(2283114629, 31) => 4902951332287086592
> -bit_rotr_u64(2283114629, 31) => 1165061255438794753
> -bit_rotl_u32(2283114629, 31) => 3289040962
> -bit_rotr_u32(2283114629, 31) => 271261963
> -bit_rotl_u64(2502548245, 31) => 5374181434468597760
> -bit_rotr_u64(2502548245, 31) => 3049981664164839425
> -bit_rotl_u32(2502548245, 31) => 3398757770
> -bit_rotr_u32(2502548245, 31) => 710129195
> -bit_rotl_u64(4294967295, 31) => 9223372034707292160
> -bit_rotr_u64(4294967295, 31) => 18446744065119617025
> -bit_rotl_u32(4294967295, 31) => 4294967295
> -bit_rotr_u32(4294967295, 31) => 4294967295
> -bit_rotl_u64(708915120906848425, 31) => 17493991222969846085
> -bit_rotr_u64(708915120906848425, 31) => 14635732670750729495
> -bit_rotl_u64(1960191741125985428, 31) => 7114564028417572864
> -bit_rotr_u64(1960191741125985428, 31) => 10011512039960739841
> -bit_rotl_u64(3689348814741910323, 31) => 11068046444225730969
> -bit_rotr_u64(3689348814741910323, 31) => 7378697629483820646
> -bit_rotl_u64(5578377670650038654, 31) => 14774204534111940727
> -bit_rotr_u64(5578377670650038654, 31) => 3756585915319108063
> -bit_rotl_u64(9223372036854775808, 31) => 1073741824
> -bit_rotr_u64(9223372036854775808, 31) => 4294967296
> -bit_rotl_u64(10755112315580060033, 31) => 9280239606276614869
> -bit_rotr_u64(10755112315580060033, 31) => 227470277687356246
> -bit_rotl_u64(11163782031541429823, 31) => 141075175016160334
> -bit_rotr_u64(11163782031541429823, 31) => 564300700064641336
> -bit_rotl_u64(13903686156871869732, 31) => 9830956193977854066
> -bit_rotr_u64(13903686156871869732, 31) => 2430336628492313034
> -bit_rotl_u64(14237897302422917095, 31) => 11075626865162688020
> -bit_rotr_u64(14237897302422917095, 31) => 7409019313231648850
> -bit_rotl_u64(14302190498657618739, 31) => 13491136976614443837
> -bit_rotr_u64(14302190498657618739, 31) => 17071059759038672118
> -bit_rotl_u64(15766411510232741269, 31) => 362182200778999262
> -bit_rotr_u64(15766411510232741269, 31) => 1448728803115997048
> -bit_rotl_u64(15984546468465238145, 31) => 7083089369391317545
> -bit_rotr_u64(15984546468465238145, 31) => 9885613403855718565
> -bit_rotl_u64(18446744073709551615, 31) => 18446744073709551615
> -bit_rotr_u64(18446744073709551615, 31) => 18446744073709551615
> -bit_rotl_u64(0, 32) => 0
> -bit_rotr_u64(0, 32) => 0
> -bit_rotl_u32(0, 32) => 0
> -bit_rotr_u32(0, 32) => 0
> -bit_rotl_u64(1, 32) => 4294967296
> -bit_rotr_u64(1, 32) => 4294967296
> -bit_rotl_u32(1, 32) => 1
> -bit_rotr_u32(1, 32) => 1
> -bit_rotl_u64(2, 32) => 8589934592
> -bit_rotr_u64(2, 32) => 8589934592
> -bit_rotl_u32(2, 32) => 2
> -bit_rotr_u32(2, 32) => 2
> -bit_rotl_u64(32768, 32) => 140737488355328
> -bit_rotr_u64(32768, 32) => 140737488355328
> -bit_rotl_u32(32768, 32) => 32768
> -bit_rotr_u32(32768, 32) => 32768
> -bit_rotl_u64(65535, 32) => 281470681743360
> -bit_rotr_u64(65535, 32) => 281470681743360
> -bit_rotl_u32(65535, 32) => 65535
> -bit_rotr_u32(65535, 32) => 65535
> -bit_rotl_u64(65536, 32) => 281474976710656
> -bit_rotr_u64(65536, 32) => 281474976710656
> -bit_rotl_u32(65536, 32) => 65536
> -bit_rotr_u32(65536, 32) => 65536
> -bit_rotl_u64(726075912, 32) => 3118472296453373952
> -bit_rotr_u64(726075912, 32) => 3118472296453373952
> -bit_rotl_u32(726075912, 32) => 726075912
> -bit_rotr_u32(726075912, 32) => 726075912
> -bit_rotl_u64(858993459, 32) => 3689348813882916864
> -bit_rotr_u64(858993459, 32) => 3689348813882916864
> -bit_rotl_u32(858993459, 32) => 858993459
> -bit_rotr_u32(858993459, 32) => 858993459
> -bit_rotl_u64(1073741824, 32) => 4611686018427387904
> -bit_rotr_u64(1073741824, 32) => 4611686018427387904
> -bit_rotl_u32(1073741824, 32) => 1073741824
> -bit_rotr_u32(1073741824, 32) => 1073741824
> -bit_rotl_u64(1245250552, 32) => 5348310396165947392
> -bit_rotr_u64(1245250552, 32) => 5348310396165947392
> -bit_rotl_u32(1245250552, 32) => 1245250552
> -bit_rotr_u32(1245250552, 32) => 1245250552
> -bit_rotl_u64(1431655765, 32) => 6148914689804861440
> -bit_rotr_u64(1431655765, 32) => 6148914689804861440
> -bit_rotl_u32(1431655765, 32) => 1431655765
> -bit_rotr_u32(1431655765, 32) => 1431655765
> -bit_rotl_u64(1656977767, 32) => 7116665319464108032
> -bit_rotr_u64(1656977767, 32) => 7116665319464108032
> -bit_rotl_u32(1656977767, 32) => 1656977767
> -bit_rotr_u32(1656977767, 32) => 1656977767
> -bit_rotl_u64(2147483648, 32) => 9223372036854775808
> -bit_rotr_u64(2147483648, 32) => 9223372036854775808
> -bit_rotl_u32(2147483648, 32) => 2147483648
> -bit_rotr_u32(2147483648, 32) => 2147483648
> -bit_rotl_u64(2283114629, 32) => 9805902664574173184
> -bit_rotr_u64(2283114629, 32) => 9805902664574173184
> -bit_rotl_u32(2283114629, 32) => 2283114629
> -bit_rotr_u32(2283114629, 32) => 2283114629
> -bit_rotl_u64(2502548245, 32) => 10748362868937195520
> -bit_rotr_u64(2502548245, 32) => 10748362868937195520
> -bit_rotl_u32(2502548245, 32) => 2502548245
> -bit_rotr_u32(2502548245, 32) => 2502548245
> -bit_rotl_u64(4294967295, 32) => 18446744069414584320
> -bit_rotr_u64(4294967295, 32) => 18446744069414584320
> -bit_rotl_u32(4294967295, 32) => 4294967295
> -bit_rotr_u32(4294967295, 32) => 4294967295
> -bit_rotl_u64(708915120906848425, 32) => 16541238372230140555
> -bit_rotr_u64(708915120906848425, 32) => 16541238372230140555
> -bit_rotl_u64(1960191741125985428, 32) => 14229128056835145728
> -bit_rotr_u64(1960191741125985428, 32) => 14229128056835145728
> -bit_rotl_u64(3689348814741910323, 32) => 3689348814741910323
> -bit_rotr_u64(3689348814741910323, 32) => 3689348814741910323
> -bit_rotl_u64(5578377670650038654, 32) => 11101664994514329839
> -bit_rotr_u64(5578377670650038654, 32) => 11101664994514329839
> -bit_rotl_u64(9223372036854775808, 32) => 2147483648
> -bit_rotr_u64(9223372036854775808, 32) => 2147483648
> -bit_rotl_u64(10755112315580060033, 32) => 113735138843678123
> -bit_rotr_u64(10755112315580060033, 32) => 113735138843678123
> -bit_rotl_u64(11163782031541429823, 32) => 282150350032320668
> -bit_rotr_u64(11163782031541429823, 32) => 282150350032320668
> -bit_rotl_u64(13903686156871869732, 32) => 1215168314246156517
> -bit_rotr_u64(13903686156871869732, 32) => 1215168314246156517
> -bit_rotl_u64(14237897302422917095, 32) => 3704509656615824425
> -bit_rotr_u64(14237897302422917095, 32) => 3704509656615824425
> -bit_rotl_u64(14302190498657618739, 32) => 8535529879519336059
> -bit_rotr_u64(14302190498657618739, 32) => 8535529879519336059
> -bit_rotl_u64(15766411510232741269, 32) => 724364401557998524
> -bit_rotr_u64(15766411510232741269, 32) => 724364401557998524
> -bit_rotl_u64(15984546468465238145, 32) => 14166178738782635090
> -bit_rotr_u64(15984546468465238145, 32) => 14166178738782635090
> -bit_rotl_u64(18446744073709551615, 32) => 18446744073709551615
> -bit_rotr_u64(18446744073709551615, 32) => 18446744073709551615
> -bit_rotl_u64(0, 63) => 0
> -bit_rotr_u64(0, 63) => 0
> -bit_rotl_u64(1, 63) => 9223372036854775808
> -bit_rotr_u64(1, 63) => 2
> -bit_rotl_u64(2, 63) => 1
> -bit_rotr_u64(2, 63) => 4
> -bit_rotl_u64(32768, 63) => 16384
> -bit_rotr_u64(32768, 63) => 65536
> -bit_rotl_u64(65535, 63) => 9223372036854808575
> -bit_rotr_u64(65535, 63) => 131070
> -bit_rotl_u64(65536, 63) => 32768
> -bit_rotr_u64(65536, 63) => 131072
> -bit_rotl_u64(726075912, 63) => 363037956
> -bit_rotr_u64(726075912, 63) => 1452151824
> -bit_rotl_u64(858993459, 63) => 9223372037284272537
> -bit_rotr_u64(858993459, 63) => 1717986918
> -bit_rotl_u64(1073741824, 63) => 536870912
> -bit_rotr_u64(1073741824, 63) => 2147483648
> -bit_rotl_u64(1245250552, 63) => 622625276
> -bit_rotr_u64(1245250552, 63) => 2490501104
> -bit_rotl_u64(1431655765, 63) => 9223372037570603690
> -bit_rotr_u64(1431655765, 63) => 2863311530
> -bit_rotl_u64(1656977767, 63) => 9223372037683264691
> -bit_rotr_u64(1656977767, 63) => 3313955534
> -bit_rotl_u64(2147483648, 63) => 1073741824
> -bit_rotr_u64(2147483648, 63) => 4294967296
> -bit_rotl_u64(2283114629, 63) => 9223372037996333122
> -bit_rotr_u64(2283114629, 63) => 4566229258
> -bit_rotl_u64(2502548245, 63) => 9223372038106049930
> -bit_rotr_u64(2502548245, 63) => 5005096490
> -bit_rotl_u64(4294967295, 63) => 9223372039002259455
> -bit_rotr_u64(4294967295, 63) => 8589934590
> -bit_rotl_u64(708915120906848425, 63) => 9577829597308200020
> -bit_rotr_u64(708915120906848425, 63) => 1417830241813696850
> -bit_rotl_u64(1960191741125985428, 63) => 980095870562992714
> -bit_rotr_u64(1960191741125985428, 63) => 3920383482251970856
> -bit_rotl_u64(3689348814741910323, 63) => 11068046444225730969
> -bit_rotr_u64(3689348814741910323, 63) => 7378697629483820646
> -bit_rotl_u64(5578377670650038654, 63) => 2789188835325019327
> -bit_rotr_u64(5578377670650038654, 63) => 11156755341300077308
> -bit_rotl_u64(9223372036854775808, 63) => 4611686018427387904
> -bit_rotr_u64(9223372036854775808, 63) => 1
> -bit_rotl_u64(10755112315580060033, 63) => 14600928194644805824
> -bit_rotr_u64(10755112315580060033, 63) => 3063480557450568451
> -bit_rotl_u64(11163782031541429823, 63) => 14805263052625490719
> -bit_rotr_u64(11163782031541429823, 63) => 3880819989373308031
> -bit_rotl_u64(13903686156871869732, 63) => 6951843078435934866
> -bit_rotr_u64(13903686156871869732, 63) => 9360628240034187849
> -bit_rotl_u64(14237897302422917095, 63) => 16342320688066234355
> -bit_rotr_u64(14237897302422917095, 63) => 10029050531136282575
> -bit_rotl_u64(14302190498657618739, 63) => 16374467286183585177
> -bit_rotr_u64(14302190498657618739, 63) => 10157636923605685863
> -bit_rotl_u64(15766411510232741269, 63) => 17106577791971146442
> -bit_rotr_u64(15766411510232741269, 63) => 13086078946755930923
> -bit_rotl_u64(15984546468465238145, 63) => 17215645271087394880
> -bit_rotr_u64(15984546468465238145, 63) => 13522348863220924675
> -bit_rotl_u64(18446744073709551615, 63) => 18446744073709551615
> -bit_rotr_u64(18446744073709551615, 63) => 18446744073709551615
> -bit_rotl_u64(0, 64) => 0
> -bit_rotr_u64(0, 64) => 0
> -bit_rotl_u64(1, 64) => 1
> -bit_rotr_u64(1, 64) => 1
> -bit_rotl_u64(2, 64) => 2
> -bit_rotr_u64(2, 64) => 2
> -bit_rotl_u64(32768, 64) => 32768
> -bit_rotr_u64(32768, 64) => 32768
> -bit_rotl_u64(65535, 64) => 65535
> -bit_rotr_u64(65535, 64) => 65535
> -bit_rotl_u64(65536, 64) => 65536
> -bit_rotr_u64(65536, 64) => 65536
> -bit_rotl_u64(726075912, 64) => 726075912
> -bit_rotr_u64(726075912, 64) => 726075912
> -bit_rotl_u64(858993459, 64) => 858993459
> -bit_rotr_u64(858993459, 64) => 858993459
> -bit_rotl_u64(1073741824, 64) => 1073741824
> -bit_rotr_u64(1073741824, 64) => 1073741824
> -bit_rotl_u64(1245250552, 64) => 1245250552
> -bit_rotr_u64(1245250552, 64) => 1245250552
> -bit_rotl_u64(1431655765, 64) => 1431655765
> -bit_rotr_u64(1431655765, 64) => 1431655765
> -bit_rotl_u64(1656977767, 64) => 1656977767
> -bit_rotr_u64(1656977767, 64) => 1656977767
> -bit_rotl_u64(2147483648, 64) => 2147483648
> -bit_rotr_u64(2147483648, 64) => 2147483648
> -bit_rotl_u64(2283114629, 64) => 2283114629
> -bit_rotr_u64(2283114629, 64) => 2283114629
> -bit_rotl_u64(2502548245, 64) => 2502548245
> -bit_rotr_u64(2502548245, 64) => 2502548245
> -bit_rotl_u64(4294967295, 64) => 4294967295
> -bit_rotr_u64(4294967295, 64) => 4294967295
> -bit_rotl_u64(708915120906848425, 64) => 708915120906848425
> -bit_rotr_u64(708915120906848425, 64) => 708915120906848425
> -bit_rotl_u64(1960191741125985428, 64) => 1960191741125985428
> -bit_rotr_u64(1960191741125985428, 64) => 1960191741125985428
> -bit_rotl_u64(3689348814741910323, 64) => 3689348814741910323
> -bit_rotr_u64(3689348814741910323, 64) => 3689348814741910323
> -bit_rotl_u64(5578377670650038654, 64) => 5578377670650038654
> -bit_rotr_u64(5578377670650038654, 64) => 5578377670650038654
> -bit_rotl_u64(9223372036854775808, 64) => 9223372036854775808
> -bit_rotr_u64(9223372036854775808, 64) => 9223372036854775808
> -bit_rotl_u64(10755112315580060033, 64) => 10755112315580060033
> -bit_rotr_u64(10755112315580060033, 64) => 10755112315580060033
> -bit_rotl_u64(11163782031541429823, 64) => 11163782031541429823
> -bit_rotr_u64(11163782031541429823, 64) => 11163782031541429823
> -bit_rotl_u64(13903686156871869732, 64) => 13903686156871869732
> -bit_rotr_u64(13903686156871869732, 64) => 13903686156871869732
> -bit_rotl_u64(14237897302422917095, 64) => 14237897302422917095
> -bit_rotr_u64(14237897302422917095, 64) => 14237897302422917095
> -bit_rotl_u64(14302190498657618739, 64) => 14302190498657618739
> -bit_rotr_u64(14302190498657618739, 64) => 14302190498657618739
> -bit_rotl_u64(15766411510232741269, 64) => 15766411510232741269
> -bit_rotr_u64(15766411510232741269, 64) => 15766411510232741269
> -bit_rotl_u64(15984546468465238145, 64) => 15984546468465238145
> -bit_rotr_u64(15984546468465238145, 64) => 15984546468465238145
> -bit_rotl_u64(18446744073709551615, 64) => 18446744073709551615
> -bit_rotr_u64(18446744073709551615, 64) => 18446744073709551615
> -	*** test_rotl_rotr: done ***
> -	*** test_bswap ***
> -bswap_u64(0) => 0
> -bswap_u32(0) => 0
> -bswap_u64(1) => 72057594037927936
> -bswap_u32(1) => 16777216
> -bswap_u64(2) => 144115188075855872
> -bswap_u32(2) => 33554432
> -bswap_u64(32768) => 36028797018963968
> -bswap_u32(32768) => 8388608
> -bswap_u64(65535) => 18446462598732840960
> -bswap_u32(65535) => 4294901760
> -bswap_u64(65536) => 1099511627776
> -bswap_u32(65536) => 256
> -bswap_u64(726075912) => 579353752079695872
> -bswap_u32(726075912) => 134891307
> -bswap_u64(858993459) => 3689348813882916864
> -bswap_u32(858993459) => 858993459
> -bswap_u64(1073741824) => 274877906944
> -bswap_u32(1073741824) => 64
> -bswap_u64(1245250552) => 17871190736326623232
> -bswap_u32(1245250552) => 4160960842
> -bswap_u64(1431655765) => 6148914689804861440
> -bswap_u32(1431655765) => 1431655765
> -bswap_u64(1656977767) => 7456205483762778112
> -bswap_u32(1656977767) => 1736033122
> -bswap_u64(2147483648) => 549755813888
> -bswap_u32(2147483648) => 128
> -bswap_u64(2283114629) => 9624216077550485504
> -bswap_u32(2283114629) => 2240812424
> -bswap_u64(2502548245) => 1574898214622986240
> -bswap_u32(2502548245) => 366684565
> -bswap_u64(4294967295) => 18446744069414584320
> -bswap_u32(4294967295) => 4294967295
> -bswap_u64(708915120906848425) => 12198156707273299465
> -bswap_u64(1960191741125985428) => 10665782605024080923
> -bswap_u64(3689348814741910323) => 3689348814741910323
> -bswap_u64(5578377670650038654) => 9081809480708024909
> -bswap_u64(9223372036854775808) => 128
> -bswap_u64(10755112315580060033) => 9300377440395542933
> -bswap_u64(11163782031541429823) => 4568596173249113498
> -bswap_u64(13903686156871869732) => 2604731024148591552
> -bswap_u64(14237897302422917095) => 16649642015867049925
> -bswap_u64(14302190498657618739) => 3696175971416046534
> -bswap_u64(15766411510232741269) => 10769528423690522074
> -bswap_u64(15984546468465238145) => 9322619197622375645
> -bswap_u64(18446744073709551615) => 18446744073709551615
> -	*** test_bswap: done ***
> -	*** test_index ***
> -bit_index_u64(0, *, -1) => 
> -bit_index_u32(0, *, -1) => 
> -bit_index_u64(1, *, -1) => 0 
> -bit_index_u32(1, *, -1) => 0 
> -bit_index_u64(2, *, -1) => 1 
> -bit_index_u32(2, *, -1) => 1 
> -bit_index_u64(32768, *, -1) => 15 
> -bit_index_u32(32768, *, -1) => 15 
> -bit_index_u64(65535, *, -1) => 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 
> -bit_index_u32(65535, *, -1) => 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 
> -bit_index_u64(65536, *, -1) => 16 
> -bit_index_u32(65536, *, -1) => 16 
> -bit_index_u64(726075912, *, -1) => 3 9 11 16 17 18 22 24 25 27 29 
> -bit_index_u32(726075912, *, -1) => 3 9 11 16 17 18 22 24 25 27 29 
> -bit_index_u64(858993459, *, -1) => 0 1 4 5 8 9 12 13 16 17 20 21 24 25 28 29 
> -bit_index_u32(858993459, *, -1) => 0 1 4 5 8 9 12 13 16 17 20 21 24 25 28 29 
> -bit_index_u64(1073741824, *, -1) => 30 
> -bit_index_u32(1073741824, *, -1) => 30 
> -bit_index_u64(1245250552, *, -1) => 3 4 5 6 7 8 9 16 19 20 21 25 27 30 
> -bit_index_u32(1245250552, *, -1) => 3 4 5 6 7 8 9 16 19 20 21 25 27 30 
> -bit_index_u64(1431655765, *, -1) => 0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 
> -bit_index_u32(1431655765, *, -1) => 0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 
> -bit_index_u64(1656977767, *, -1) => 0 1 2 5 6 8 11 12 13 14 16 17 22 23 25 29 30 
> -bit_index_u32(1656977767, *, -1) => 0 1 2 5 6 8 11 12 13 14 16 17 22 23 25 29 30 
> -bit_index_u64(2147483648, *, -1) => 31 
> -bit_index_u32(2147483648, *, -1) => 31 
> -bit_index_u64(2283114629, *, -1) => 0 2 7 12 15 16 18 20 27 31 
> -bit_index_u32(2283114629, *, -1) => 0 2 7 12 15 16 18 20 27 31 
> -bit_index_u64(2502548245, *, -1) => 0 2 4 8 9 11 12 14 15 16 19 21 24 26 28 31 
> -bit_index_u32(2502548245, *, -1) => 0 2 4 8 9 11 12 14 15 16 19 21 24 26 28 31 
> -bit_index_u64(4294967295, *, -1) => 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 
> -bit_index_u32(4294967295, *, -1) => 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 
> -bit_index_u64(708915120906848425, *, -1) => 0 3 5 7 11 14 17 18 19 23 24 26 29 30 31 32 33 35 39 41 44 47 49 50 52 54 55 56 59 
> -bit_index_u64(1960191741125985428, *, -1) => 2 4 7 10 19 20 21 22 24 26 30 31 50 52 53 56 57 59 60 
> -bit_index_u64(3689348814741910323, *, -1) => 0 1 4 5 8 9 12 13 16 17 20 21 24 25 28 29 32 33 36 37 40 41 44 45 48 49 52 53 56 57 60 61 
> -bit_index_u64(5578377670650038654, *, -1) => 1 2 3 4 5 6 8 11 16 20 25 27 28 31 32 33 34 35 37 38 39 45 46 49 51 53 54 56 58 59 62 
> -bit_index_u64(9223372036854775808, *, -1) => 63 
> -bit_index_u64(10755112315580060033, *, -1) => 0 7 8 12 18 20 23 24 32 33 35 37 39 40 42 44 46 47 48 54 56 58 60 63 
> -bit_index_u64(11163782031541429823, *, -1) => 0 1 2 3 4 5 9 10 13 14 17 19 21 22 23 24 25 34 35 36 39 43 44 45 47 48 50 51 53 54 55 57 59 60 63 
> -bit_index_u64(13903686156871869732, *, -1) => 2 5 8 10 13 16 18 19 20 22 23 28 32 34 37 38 39 44 46 47 48 49 52 53 54 55 62 63 
> -bit_index_u64(14237897302422917095, *, -1) => 0 1 2 5 6 7 8 9 10 11 16 19 21 22 24 25 28 29 32 35 37 42 43 45 48 49 50 52 55 56 58 62 63 
> -bit_index_u64(14302190498657618739, *, -1) => 0 1 4 5 8 9 11 14 18 20 21 22 25 26 28 29 30 32 33 35 36 37 38 41 42 44 47 48 49 51 52 53 54 57 58 62 63 
> -bit_index_u64(15766411510232741269, *, -1) => 0 2 4 7 8 10 12 13 14 16 18 19 25 27 34 35 36 37 39 40 41 43 47 48 50 51 54 55 57 59 60 62 63 
> -bit_index_u64(15984546468465238145, *, -1) => 0 7 13 14 19 20 23 26 30 31 33 36 38 42 47 50 52 54 55 56 58 59 60 62 63 
> -bit_index_u64(18446744073709551615, *, -1) => 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 
> -	*** test_index: done ***
> -	*** test_bit_iter ***
> -Set: 3, 9, 11, 16, 17, 18, 22, 24, 25, 27, 29, 64, 65, 68, 69, 72, 73, 76, 77, 
> -Clear: 0, 1, 2, 4, 5, 6, 7, 8, 10, 12, 13, 14, 15, 19, 20, 21, 23, 26, 28, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 66, 67, 70, 71, 74, 75, 78, 79, 
> -	*** test_bit_iter: done ***
> -	*** test_bit_iter_empty ***
> -	*** test_bit_iter_empty: done ***
> -	*** test_bitmap_size ***
> -	*** test_bitmap_size: done ***
> diff --git a/test/unit/bitset_basic.c b/test/unit/bitset_basic.c
> index fe4b6ab07..be17b0f6b 100644
> --- a/test/unit/bitset_basic.c
> +++ b/test/unit/bitset_basic.c
> @@ -9,6 +9,7 @@ static
>  void test_cardinality()
>  {
>  	header();
> +	plan(1);
>  
>  	struct tt_bitset bm;
>  	tt_bitset_create(&bm, realloc);
> @@ -48,6 +49,8 @@ void test_cardinality()
>  
>  	tt_bitset_destroy(&bm);
>  
> +	ok(1, "test cardinality");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -85,6 +88,7 @@ static
>  void test_get_set()
>  {
>  	header();
> +	plan(1);
>  
>  	struct tt_bitset bm;
>  	tt_bitset_create(&bm, realloc);
> @@ -92,7 +96,7 @@ void test_get_set()
>  	const size_t NUM_SIZE = (size_t) 1 << 14;
>  	size_t *nums = malloc(NUM_SIZE * sizeof(size_t));
>  
> -	printf("Generating test set... ");
> +	note("Generating test set... ");
>  	for(size_t i = 0; i < NUM_SIZE; i++) {
>  		nums[i] = rand();
>  	}
> @@ -107,26 +111,23 @@ void test_get_set()
>  		}
>  	}
>  	shuffle(nums, NUM_SIZE);
> -	printf("ok\n");
>  
> -	printf("Settings bits... ");
> +	note("Settings bits... ");
>  	for(size_t i = 0; i < NUM_SIZE; i++) {
>  		if (nums[i] == SIZE_MAX)
>  			continue;
>  		fail_if(tt_bitset_set(&bm, nums[i]) < 0);
>  	}
> -	printf("ok\n");
>  
> -	printf("Checking bits... ");
> +	note("Checking bits... ");
>  	shuffle(nums, NUM_SIZE);
>  	for(size_t i = 0; i < NUM_SIZE; i++) {
>  		if (nums[i] == SIZE_MAX)
>  			continue;
>  		fail_unless(tt_bitset_test(&bm, nums[i]));
>  	}
> -	printf("ok\n");
>  
> -	printf("Unsetting random bits... ");
> +	note("Unsetting random bits... ");
>  	for(size_t k = 0; k < (NUM_SIZE >> 3); k++) {
>  		size_t i = rand() % NUM_SIZE;
>  		if (nums[i] == SIZE_MAX)
> @@ -135,23 +136,19 @@ void test_get_set()
>  		fail_if(tt_bitset_test(&bm, nums[i]));
>  		nums[i] = SIZE_MAX;
>  	}
> -	printf("ok\n");
>  
> -	printf("Checking set bits... ");
> +	note("Checking set bits... ");
>  	shuffle(nums, NUM_SIZE);
>  	for(size_t i = 0; i < NUM_SIZE; i++) {
>  		if (nums[i] == SIZE_MAX) {
>  			continue;
>  		}
>  
> -		if (!tt_bitset_test(&bm, nums[i])) {
> -			printf("Fail :%zu\n", nums[i]);
> -		}
> +		fail_if(!tt_bitset_test(&bm, nums[i]));
>  		fail_unless(tt_bitset_test(&bm, nums[i]));
>  	}
> -	printf("ok\n");
>  
> -	printf("Checking all bits... ");
> +	note("Checking all bits... ");
>  	qsort(nums, NUM_SIZE, sizeof(size_t), size_compator);
>  
>  	size_t *pn = nums;
> @@ -166,10 +163,8 @@ void test_get_set()
>  			fail_if(tt_bitset_test(&bm, i));
>  		}
>  	}
> -	printf("ok\n");
> -
>  
> -	printf("Unsetting all bits... ");
> +	note("Unsetting all bits... ");
>  	shuffle(nums, NUM_SIZE);
>  	for(size_t i = 0; i < NUM_SIZE; i++) {
>  		if (nums[i] == SIZE_MAX) {
> @@ -178,28 +173,29 @@ void test_get_set()
>  
>  		fail_if(tt_bitset_clear(&bm, nums[i]) < 0);
>  	}
> -	printf("ok\n");
> -
>  
> -	printf("Checking all bits... ");
> +	note("Checking all bits... ");
>  	for(size_t i = 0; i < i_max; i++) {
>  		fail_if(tt_bitset_test(&bm, i));
>  	}
> -	printf("ok\n");
>  
>  	free(nums);
>  
>  	tt_bitset_destroy(&bm);
>  
> +	ok(1, "test get set");
> +	check_plan();
>  	footer();
>  }
>  
>  int main(int argc, char *argv[])
>  {
> +	plan(2);
>  	setbuf(stdout, NULL);
>  	srand(time(NULL));
>  	test_cardinality();
>  	test_get_set();
> +	check_plan();
>  
>  	return 0;
>  }
> diff --git a/test/unit/bitset_basic.result b/test/unit/bitset_basic.result
> deleted file mode 100644
> index 54f0ae724..000000000
> --- a/test/unit/bitset_basic.result
> +++ /dev/null
> @@ -1,12 +0,0 @@
> -	*** test_cardinality ***
> -	*** test_cardinality: done ***
> -	*** test_get_set ***
> -Generating test set... ok
> -Settings bits... ok
> -Checking bits... ok
> -Unsetting random bits... ok
> -Checking set bits... ok
> -Checking all bits... ok
> -Unsetting all bits... ok
> -Checking all bits... ok
> -	*** test_get_set: done ***
> diff --git a/test/unit/bitset_index.c b/test/unit/bitset_index.c
> index c077fae49..d8542e7d1 100644
> --- a/test/unit/bitset_index.c
> +++ b/test/unit/bitset_index.c
> @@ -42,6 +42,7 @@ static
>  void test_size_and_count(void)
>  {
>  	header();
> +	plan(1);
>  
>  	struct tt_bitset_index index;
>  	tt_bitset_index_create(&index, realloc);
> @@ -60,8 +61,10 @@ void test_size_and_count(void)
>  	fail_unless(tt_bitset_index_count(&index, 2147483648) == 0);
>  
>  	tt_bitset_index_destroy(&index);
> +	ok(1, "test size and count");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static
> @@ -73,7 +76,7 @@ void check_keys(struct tt_bitset_index *index,
>  	struct tt_bitset_expr expr;
>  	tt_bitset_expr_create(&expr, realloc);
>  
> -	printf("Checking keys... ");
> +	note("Checking keys... ");
>  	for (size_t i = 0; i < size; i++) {
>  		/* ignore removed keys */
>  		if (keys[i] == SIZE_MAX) {
> @@ -97,7 +100,7 @@ void check_keys(struct tt_bitset_index *index,
>  		}
>  		fail_unless(pair_found);
>  	}
> -	printf("ok\n");
> +	note("ok");
>  
>  	tt_bitset_iterator_destroy(&it);
>  	tt_bitset_expr_destroy(&expr);
> @@ -107,6 +110,7 @@ static
>  void test_insert_remove(void)
>  {
>  	header();
> +	plan(1);
>  
>  	struct tt_bitset_index index;
>  	tt_bitset_index_create(&index, realloc);
> @@ -117,36 +121,36 @@ void test_insert_remove(void)
>  
>  	size_t count0 = 0;
>  	size_t count1 = 0;
> -	printf("Generating test set... ");
> +	note("Generating test set... ");
>  	for(size_t i = 0; i < NUMS_SIZE; i++) {
>  		keys[i] = rand();
>  		values[i] = rand();
>  		count0 += (keys[i] & 1) != 0 ? 1 : 0;
>  		count1 += (keys[i] & 2) != 0 ? 1 : 0;
>  	}
> -	printf("ok\n");
> +	note("ok");
>  
> -	printf("Inserting pairs... ");
> +	note("Inserting pairs... ");
>  	for(size_t i = 0; i < NUMS_SIZE; i++) {
>  		tt_bitset_index_insert(&index, &keys[i], sizeof(keys[i]),
>  				       values[i]);
>  
>  	}
> -	printf("ok\n");
> +	note("ok");
>  
>  	check_keys(&index, keys, values, NUMS_SIZE);
>  
>  	fail_unless(tt_bitset_index_count(&index, 0) == count0);
>  	fail_unless(tt_bitset_index_count(&index, 1) == count1);
>  
> -	printf("Removing random pairs... ");
> +	note("Removing random pairs... ");
>  	for(size_t i = 0; i < NUMS_SIZE; i++) {
>  		if (rand() % 5 == 0) {
>  			tt_bitset_index_remove_value(&index, values[i]);
>  			keys[i] = SIZE_MAX;
>  		}
>  	}
> -	printf("ok\n");
> +	note("ok");
>  
>  	check_keys(&index, keys, values, NUMS_SIZE);
>  
> @@ -154,8 +158,10 @@ void test_insert_remove(void)
>  
>  	free(keys);
>  	free(values);
> +	ok(1, "test_insert_remove");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  
> @@ -222,7 +228,10 @@ static void
>  test_empty_simple(void)
>  {
>  	header();
> +	plan(1);
>  	test_simple(1, 0); /* empty result */
> +	ok(1, "test empty simple");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -230,7 +239,10 @@ static void
>  test_all_simple(void)
>  {
>  	header();
> +	plan(1);
>  	test_simple(0, 0);  /* all */
> +	ok(1, "test all simple");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -238,8 +250,11 @@ static void
>  test_all_set_simple(void)
>  {
>  	header();
> +	plan(1);
>  	size_t search_mask = 66; /* 0b1000010 */
>  	test_simple(1, search_mask);  /* all bits set */
> +	ok(1, "test all set simple");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -247,8 +262,11 @@ static void
>  test_any_set_simple(void)
>  {
>  	header();
> +	plan(1);
>  	size_t search_mask = 66; /* 0b1000010 */
>  	test_simple(2, search_mask);  /* any bits set */
> +	ok(1, "test any set simple");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -256,6 +274,7 @@ static
>  void test_equals_simple(void)
>  {
>  	header();
> +	plan(1);
>  
>  	struct tt_bitset_index index;
>  	tt_bitset_index_create(&index, realloc);
> @@ -284,13 +303,17 @@ void test_equals_simple(void)
>  	tt_bitset_expr_destroy(&expr);
>  	tt_bitset_iterator_destroy(&it);
>  	tt_bitset_index_destroy(&index);
> +	ok(1, "test equals simple");
>  
> +	check_plan();
>  	footer();
>  }
>  
>  int main(void)
>  {
>  	setbuf(stdout, NULL);
> +	header();
> +	plan(7);
>  
>  	test_size_and_count();
>  	test_resize();
> @@ -301,5 +324,8 @@ int main(void)
>  	test_any_set_simple();
>  	test_equals_simple();
>  
> +	check_plan();
> +	footer();
> +
>  	return 0;
>  }
> diff --git a/test/unit/bitset_index.result b/test/unit/bitset_index.result
> deleted file mode 100644
> index c358cfbc4..000000000
> --- a/test/unit/bitset_index.result
> +++ /dev/null
> @@ -1,21 +0,0 @@
> -	*** test_size_and_count ***
> -	*** test_size_and_count: done ***
> -	*** test_resize ***
> -	*** test_resize: done ***
> -	*** test_insert_remove ***
> -Generating test set... ok
> -Inserting pairs... ok
> -Checking keys... ok
> -Removing random pairs... ok
> -Checking keys... ok
> -	*** test_insert_remove: done ***
> -	*** test_empty_simple ***
> -	*** test_empty_simple: done ***
> -	*** test_all_simple ***
> -	*** test_all_simple: done ***
> -	*** test_all_set_simple ***
> -	*** test_all_set_simple: done ***
> -	*** test_any_set_simple ***
> -	*** test_any_set_simple: done ***
> -	*** test_equals_simple ***
> -	*** test_equals_simple: done ***
> diff --git a/test/unit/bitset_iterator.c b/test/unit/bitset_iterator.c
> index 04f2f9f72..445a43486 100644
> --- a/test/unit/bitset_iterator.c
> +++ b/test/unit/bitset_iterator.c
> @@ -80,6 +80,7 @@ static
>  void test_empty_expr(void)
>  {
>  	header();
> +	plan(1);
>  
>  	struct tt_bitset_expr expr;
>  	tt_bitset_expr_create(&expr, realloc);
> @@ -94,6 +95,8 @@ void test_empty_expr(void)
>  
>  	tt_bitset_iterator_destroy(&it);
>  
> +	ok(1, "test empty expr")
> +	check_plan();
>  	footer();
>  }
>  
> @@ -101,6 +104,7 @@ static
>  void test_empty_expr_conj1(void)
>  {
>  	header();
> +	plan(1);
>  
>  	struct tt_bitset_expr expr;
>  	tt_bitset_expr_create(&expr, realloc);
> @@ -117,6 +121,8 @@ void test_empty_expr_conj1(void)
>  
>  	tt_bitset_iterator_destroy(&it);
>  
> +	ok(1, "test empty expr conj1");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -124,6 +130,7 @@ static
>  void test_empty_expr_conj2(void)
>  {
>  	header();
> +	plan(1);
>  
>  	size_t big_i = (size_t) 1 << 15;
>  	struct tt_bitset **bitsets = bitsets_create(2);
> @@ -154,6 +161,8 @@ void test_empty_expr_conj2(void)
>  	tt_bitset_iterator_destroy(&it);
>  	bitsets_destroy(bitsets, 2);
>  
> +	ok(1, "test empty expr conj2");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -161,6 +170,7 @@ static
>  void test_empty_result(void)
>  {
>  	header();
> +	plan(1);
>  
>  	struct tt_bitset **bitsets = bitsets_create(2);
>  
> @@ -199,6 +209,8 @@ void test_empty_result(void)
>  
>  	bitsets_destroy(bitsets, 2);
>  
> +	ok(1, "test empty result");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -206,6 +218,7 @@ static
>  void test_first_result(void)
>  {
>  	header();
> +	plan(1);
>  
>  	struct tt_bitset **bitsets = bitsets_create(2);
>  
> @@ -237,6 +250,8 @@ void test_first_result(void)
>  
>  	bitsets_destroy(bitsets, 2);
>  
> +	ok(1, "test first result");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -244,6 +259,7 @@ static
>  void test_simple()
>  {
>  	header();
> +	plan(1);
>  
>  	enum { BITSETS_SIZE = 32 };
>  
> @@ -286,12 +302,15 @@ void test_simple()
>  	tt_bitset_iterator_destroy(&it);
>  	bitsets_destroy(bitsets, BITSETS_SIZE);
>  
> +	ok(1, "test simple");
> +	check_plan();
>  	footer();
>  }
>  
>  static
>  void test_big() {
>  	header();
> +	plan(1);
>  
>  	const size_t BITSETS_SIZE = 32;
>  	struct tt_bitset **bitsets = bitsets_create(BITSETS_SIZE);
> @@ -338,12 +357,15 @@ void test_big() {
>  
>  	bitsets_destroy(bitsets, BITSETS_SIZE);
>  
> +	ok(1, "test big");
> +	check_plan();
>  	footer();
>  }
>  
>  static
>  void test_not_last() {
>  	header();
> +	plan(1);
>  
>  	struct tt_bitset **bitsets = bitsets_create(2);
>  
> @@ -385,12 +407,15 @@ void test_not_last() {
>  
>  	bitsets_destroy(bitsets, 2);
>  
> +	ok(1, "test not last");
> +	check_plan();
>  	footer();
>  }
>  
>  static
>  void test_not_empty() {
>  	header();
> +	plan(1);
>  
>  	enum {
>  		BITSETS_SIZE = 4,
> @@ -428,6 +453,8 @@ void test_not_empty() {
>  
>  	bitsets_destroy(bitsets, BITSETS_SIZE);
>  
> +	ok(1, "test not empty");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -435,6 +462,7 @@ static
>  void test_disjunction()
>  {
>  	header();
> +	plan(1);
>  
>  	enum { BITSETS_SIZE = 32 };
>  
> @@ -474,6 +502,8 @@ void test_disjunction()
>  
>  	bitsets_destroy(bitsets, BITSETS_SIZE);
>  
> +	ok(1, "test disjunction")
> +	check_plan();
>  	footer();
>  }
>  
> @@ -482,6 +512,7 @@ int main(void)
>  	setbuf(stdout, NULL);
>  	nums_fill(NUMS, NUMS_SIZE);
>  
> +	plan(10);
>  	test_empty_expr();
>  	test_empty_expr_conj1();
>  	test_empty_expr_conj2();
> @@ -493,5 +524,6 @@ int main(void)
>  	test_not_last();
>  	test_disjunction();
>  
> +	check_plan();
>  	return 0;
>  }
> diff --git a/test/unit/bitset_iterator.result b/test/unit/bitset_iterator.result
> deleted file mode 100644
> index 1f8369d74..000000000
> --- a/test/unit/bitset_iterator.result
> +++ /dev/null
> @@ -1,22 +0,0 @@
> -	*** test_empty_expr ***
> -	*** test_empty_expr: done ***
> -	*** test_empty_expr_conj1 ***
> -	*** test_empty_expr_conj1: done ***
> -	*** test_empty_expr_conj2 ***
> -	*** test_empty_expr_conj2: done ***
> -	*** test_empty_result ***
> -	*** test_empty_result: done ***
> -	*** test_first_result ***
> -	*** test_first_result: done ***
> -	*** test_simple ***
> -	*** test_simple: done ***
> -	*** test_big ***
> -Setting bits... ok
> -Iterating... ok
> -	*** test_big: done ***
> -	*** test_not_empty ***
> -	*** test_not_empty: done ***
> -	*** test_not_last ***
> -	*** test_not_last: done ***
> -	*** test_disjunction ***
> -	*** test_disjunction: done ***
> diff --git a/test/unit/bloom.cc b/test/unit/bloom.cc
> index 2e5b99412..23a36487c 100644
> --- a/test/unit/bloom.cc
> +++ b/test/unit/bloom.cc
> @@ -2,6 +2,7 @@
>  #include <unordered_set>
>  #include <vector>
>  #include <iostream>
> +#include "unit.h"
>  
>  using namespace std;
>  
> @@ -13,7 +14,8 @@ uint32_t h(uint32_t i)
>  void
>  simple_test()
>  {
> -	cout << "*** " << __func__ << " ***" << endl;
> +	header();
> +	plan(1);
>  	srand(time(0));
>  	uint32_t error_count = 0;
>  	uint32_t fp_rate_too_big = 0;
> @@ -45,14 +47,16 @@ simple_test()
>  		if (fp_rate > p + 0.001)
>  			fp_rate_too_big++;
>  	}
> -	cout << "error_count = " << error_count << endl;
> -	cout << "fp_rate_too_big = " << fp_rate_too_big << endl;
> +	note("error_count = %d", error_count);
> +	note("fp_rate_too_big = %d", fp_rate_too_big);
> +	ok(1, "%s", __func__);
> +	check_plan();
>  }
>  
>  void
>  store_load_test()
>  {
> -	cout << "*** " << __func__ << " ***" << endl;
> +	plan(1);
>  	srand(time(0));
>  	uint32_t error_count = 0;
>  	uint32_t fp_rate_too_big = 0;
> @@ -92,13 +96,17 @@ store_load_test()
>  		if (fp_rate > p + 0.001)
>  			fp_rate_too_big++;
>  	}
> -	cout << "error_count = " << error_count << endl;
> -	cout << "fp_rate_too_big = " << fp_rate_too_big << endl;
> +	note("error_count = %d", error_count);
> +	note("fp_rate_too_big = %d", fp_rate_too_big);
> +	ok(1, "%s", __func__);
> +	check_plan();
>  }
>  
>  int
>  main(void)
>  {
> +	plan(2);
>  	simple_test();
>  	store_load_test();
> +	check_plan();
>  }
> diff --git a/test/unit/bloom.result b/test/unit/bloom.result
> deleted file mode 100644
> index 91193a618..000000000
> --- a/test/unit/bloom.result
> +++ /dev/null
> @@ -1,6 +0,0 @@
> -*** simple_test ***
> -error_count = 0
> -fp_rate_too_big = 0
> -*** store_load_test ***
> -error_count = 0
> -fp_rate_too_big = 0
> diff --git a/test/unit/bps_tree.cc b/test/unit/bps_tree.cc
> index ef374deb1..d1a94ffb9 100644
> --- a/test/unit/bps_tree.cc
> +++ b/test/unit/bps_tree.cc
> @@ -124,7 +124,7 @@ static int compare_key(const elem_t &a, long b)
>  		type_t check_value =\
>  			*tree_name##_iterator_get_elem((tree), &iter);\
>  		if (check_value != (type_t)(elem)) {\
> -			printf("iterator doesn't point to the inserted "\
> +			diag("iterator doesn't point to the inserted "\
>  			       "element: %lld != %lld", (long long) (elem),\
>  			       (long long) check_value);\
>  			fail("elem != check_value", "true");\
> @@ -168,12 +168,13 @@ static void
>  simple_check()
>  {
>  	header();
> +	plan(1);
>  
>  	const unsigned int rounds = 2000;
>  	test tree;
>  	test_create(&tree, 0, extent_alloc, extent_free, &extents_count);
>  
> -	printf("Insert 1..X, remove 1..X\n");
> +	note("Insert 1..X, remove 1..X");
>  	for (unsigned int i = 0; i < rounds; i++) {
>  		type_t v = i;
>  		if (test_find(&tree, v) != NULL)
> @@ -200,7 +201,7 @@ simple_check()
>  	if (test_size(&tree) != 0)
>  		fail("Tree count mismatch (2)", "true");
>  
> -	printf("Insert 1..X, remove X..1\n");
> +	note("Insert 1..X, remove X..1");
>  	for (unsigned int i = 0; i < rounds; i++) {
>  		type_t v = i;
>  		if (test_find(&tree, v) != NULL)
> @@ -227,7 +228,7 @@ simple_check()
>  	if (test_size(&tree) != 0)
>  		fail("Tree count mismatch (4)", "true");
>  
> -	printf("Insert X..1, remove 1..X\n");
> +	note("Insert X..1, remove 1..X");
>  	for (unsigned int i = 0; i < rounds; i++) {
>  		type_t v = rounds - 1 - i;
>  		if (test_find(&tree, v) != NULL)
> @@ -254,7 +255,7 @@ simple_check()
>  	if (test_size(&tree) != 0)
>  		fail("Tree count mismatch (6)", "true");
>  
> -	printf("Insert X..1, remove X..1\n");
> +	note("Insert X..1, remove X..1");
>  	for (unsigned int i = 0; i < rounds; i++) {
>  		type_t v = rounds - 1 - i;
>  		if (test_find(&tree, v) != NULL)
> @@ -282,8 +283,10 @@ simple_check()
>  		fail("Tree count mismatch (8)", "true");
>  
>  	test_destroy(&tree);
> +	ok(1, "simple check");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static bool
> @@ -311,6 +314,7 @@ static void
>  compare_with_sptree_check()
>  {
>  	header();
> +	plan(1);
>  
>  	sptree_test spt_test;
>  	sptree_test_init(&spt_test, sizeof(type_t), 0, 0, 0, &node_comp, 0, 0);
> @@ -345,14 +349,17 @@ compare_with_sptree_check()
>  	sptree_test_destroy(&spt_test);
>  
>  	test_destroy(&tree);
> +	ok(1, "compare with sptree check");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static void
>  compare_with_sptree_check_branches()
>  {
>  	header();
> +	plan(1);
>  
>  	sptree_test spt_test;
>  	sptree_test_init(&spt_test, sizeof(type_t), 0, 0, 0, &node_comp, 0, 0);
> @@ -570,28 +577,34 @@ compare_with_sptree_check_branches()
>  	sptree_test_destroy(&spt_test);
>  
>  	test_destroy(&tree);
> +	ok(1, "compare with sptree check branches");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static void
>  bps_tree_debug_self_check()
>  {
>  	header();
> +	plan(1);
>  
>  	int res = test_debug_check_internal_functions(false);
>  	if (res)
> -		printf("self test returned error %d\n", res);
> +		note("self test returned error %d", res);
>  
>  	test_debug_check_internal_functions(true);
> +	ok(1, "bps tree debug self check");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static void
> -loading_test()
> +load_test()
>  {
>  	header();
> +	plan(1);
>  
>  	test tree;
>  
> @@ -623,14 +636,17 @@ loading_test()
>  
>  		test_destroy(&tree);
>  	}
> +	ok(1, "load test");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static void
>  printing_test()
>  {
>  	header();
> +	plan(1);
>  
>  	test tree;
>  	test_create(&tree, 0, extent_alloc, extent_free, &extents_count);
> @@ -639,24 +655,27 @@ printing_test()
>  
>  	for (type_t i = 0; i < rounds; i++) {
>  		type_t v = rounds + i;
> -		printf("Inserting " TYPE_F "\n", v);
> +		note("Inserting " TYPE_F, v);
>  		test_insert(&tree, v, 0);
>  		test_print(&tree, TYPE_F);
>  		v = rounds - i - 1;
> -		printf("Inserting " TYPE_F "\n", v);
> +		note("Inserting " TYPE_F, v);
>  		test_insert(&tree, v, 0);
>  		test_print(&tree, TYPE_F);
>  	}
>  
>  	test_destroy(&tree);
> +	ok(1, "printing test");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static void
>  white_box_test()
>  {
>  	header();
> +	plan(1);
>  
>  	test tree;
>  	test_create(&tree, 0, extent_alloc, extent_free, &extents_count);
> @@ -664,33 +683,33 @@ white_box_test()
>  	assert(BPS_TREE_test_MAX_COUNT_IN_LEAF == 14);
>  	assert(BPS_TREE_test_MAX_COUNT_IN_INNER == 10);
>  
> -	printf("full leaf:\n");
> +	note("full leaf:");
>  	for (type_t i = 0; i < 14; i++) {
>  		test_insert(&tree, i, 0);
>  	}
>  	test_print(&tree, TYPE_F);
>  
> -	printf("split now:\n");
> +	note("split now:");
>  	test_insert(&tree, 14, 0);
>  	test_print(&tree, TYPE_F);
>  
> -	printf("full 2 leafs:\n");
> +	note("full 2 leafs:");
>  	for (type_t i = 15; i < 28; i++) {
>  		test_insert(&tree, i, 0);
>  	}
>  	test_print(&tree, TYPE_F);
>  
> -	printf("split now:\n");
> +	note("split now:");
>  	test_insert(&tree, 28, 0);
>  	test_print(&tree, TYPE_F);
>  
> -	printf("full 3 leafs:\n");
> +	note("full 3 leafs:");
>  	for (type_t i = 29; i < 42; i++) {
>  		test_insert(&tree, i, 0);
>  	}
>  	test_print(&tree, TYPE_F);
>  
> -	printf("split now:\n");
> +	note("split now:");
>  	test_insert(&tree, 42, 0);
>  	test_print(&tree, TYPE_F);
>  
> @@ -700,22 +719,25 @@ white_box_test()
>  	for (type_t i = 0; i < 140; i++)
>  		arr[i] = i;
>  	test_build(&tree, arr, 140);
> -	printf("full 10 leafs:\n");
> +	note("full 10 leafs:");
>  	test_print(&tree, TYPE_F);
>  
> -	printf("2-level split now:\n");
> +	note("2-level split now:");
>  	test_insert(&tree, 140, 0);
>  	test_print(&tree, TYPE_F);
>  
>  	test_destroy(&tree);
> +	ok(1, "white box test");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static void
>  approximate_count()
>  {
>  	header();
> +	plan(1);
>  	srand(0);
>  
>  	approx tree;
> @@ -749,7 +771,7 @@ approximate_count()
>  	for (uint64_t i = 1; i <= long_sequence_count; i++)
>  		for (uint64_t j = 0; j < i * long_sequence_multiplier; j++)
>  			arr[count++] = ((i * 100 + 50) << 32) | j;
> -	printf("Count: %llu %u\n", (unsigned long long)count, arr_size);
> +	note("Count: %llu %u", (unsigned long long)count, arr_size);
>  	assert(count == arr_size);
>  
>  	for (uint64_t i = 0; i < count * 10; i++) {
> @@ -763,7 +785,7 @@ approximate_count()
>  	for (uint64_t i = 0; i < count; i++)
>  		approx_insert(&tree, arr[i], NULL);
>  
> -	printf("Count: %zu\n", tree.size);
> +	note("Count: %zu", tree.size);
>  
>  	count = 0;
>  	int err_count = 0;
> @@ -788,7 +810,7 @@ approximate_count()
>  			if (approx_count != true_count) {
>  				err_count++;
>  				if (err_count <= 10)
> -					printf("searching %u found %llu expected %llu\n",
> +					diag("searching %u found %llu expected %llu\n",
>  					       i, (unsigned long long)approx_count,
>  					       (unsigned long long)true_count);
>  			}
> @@ -802,24 +824,27 @@ approximate_count()
>  		if (true_count < low || true_count > up) {
>  			err_count++;
>  			if (err_count <= 10)
> -				printf("searching %u found %llu expected %llu\n",
> +				diag("searching %u found %llu expected %llu\n",
>  				       i, (unsigned long long)approx_count,
>  				       (unsigned long long)true_count);
>  		}
>  	};
>  
> -	printf("Error count: %d\n", err_count);
> -	printf("Count: %llu\n", (unsigned long long)count);
> +	note("Error count: %d", err_count);
> +	note("Count: %llu", (unsigned long long)count);
>  
>  	approx_destroy(&tree);
> +	ok(1, "approximate count");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static void
>  insert_get_iterator()
>  {
>  	header();
> +	plan(1);
>  
>  	test tree;
>  	test_create(&tree, 0, extent_alloc, extent_free, &extents_count);
> @@ -833,14 +858,17 @@ insert_get_iterator()
>  		bps_insert_and_check(test, &tree, i, NULL);
>  	for (i = -9999; i < 10000; i += 2)
>  		bps_insert_and_check(test, &tree, i, NULL)
> +	ok(1, "insert get iterator");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static void
>  delete_value_check()
>  {
>  	header();
> +	plan(1);
>  	struct_tree tree;
>  	struct_tree_create(&tree, 0, extent_alloc, extent_free, &extents_count);
>  	struct elem_t e1 = {1, 1};
> @@ -855,17 +883,20 @@ delete_value_check()
>  	if (struct_tree_find(&tree, 1) != NULL)
>  		fail("test identical element deletion completion", "false");
>  	struct_tree_destroy(&tree);
> +	ok(1, "delete value check");
>  	footer();
> +	check_plan();
>  }
>  
>  int
>  main(void)
>  {
> +	plan(10);
>  	simple_check();
>  	compare_with_sptree_check();
>  	compare_with_sptree_check_branches();
>  	bps_tree_debug_self_check();
> -	loading_test();
> +	load_test();
>  	printing_test();
>  	white_box_test();
>  	approximate_count();
> @@ -873,4 +904,5 @@ main(void)
>  		fail("memory leak!", "true");
>  	insert_get_iterator();
>  	delete_value_check();
> +	check_plan();
>  }
> diff --git a/test/unit/bps_tree.result b/test/unit/bps_tree.result
> deleted file mode 100644
> index 130ec555c..000000000
> --- a/test/unit/bps_tree.result
> +++ /dev/null
> @@ -1,284 +0,0 @@
> -	*** simple_check ***
> -Insert 1..X, remove 1..X
> -Insert 1..X, remove X..1
> -Insert X..1, remove 1..X
> -Insert X..1, remove X..1
> -	*** simple_check: done ***
> -	*** compare_with_sptree_check ***
> -	*** compare_with_sptree_check: done ***
> -	*** compare_with_sptree_check_branches ***
> -	*** compare_with_sptree_check_branches: done ***
> -	*** bps_tree_debug_self_check ***
> -	*** bps_tree_debug_self_check: done ***
> -	*** loading_test ***
> -	*** loading_test: done ***
> -	*** printing_test ***
> -Inserting 22
> -[(1) 22]
> -Inserting 21
> -[(2) 21 22]
> -Inserting 23
> -[(3) 21 22 23]
> -Inserting 20
> -[(4) 20 21 22 23]
> -Inserting 24
> -[(5) 20 21 22 23 24]
> -Inserting 19
> -[(6) 19 20 21 22 23 24]
> -Inserting 25
> -[(7) 19 20 21 22 23 24 25]
> -Inserting 18
> -[(8) 18 19 20 21 22 23 24 25]
> -Inserting 26
> -[(9) 18 19 20 21 22 23 24 25 26]
> -Inserting 17
> -[(10) 17 18 19 20 21 22 23 24 25 26]
> -Inserting 27
> -[(11) 17 18 19 20 21 22 23 24 25 26 27]
> -Inserting 16
> -[(12) 16 17 18 19 20 21 22 23 24 25 26 27]
> -Inserting 28
> -[(13) 16 17 18 19 20 21 22 23 24 25 26 27 28]
> -Inserting 15
> -[(14) 15 16 17 18 19 20 21 22 23 24 25 26 27 28]
> -Inserting 29
> -  [(8) 15 16 17 18 19 20 21 22]
> -22
> -  [(7) 23 24 25 26 27 28 29]
> -Inserting 14
> -  [(9) 14 15 16 17 18 19 20 21 22]
> -22
> -  [(7) 23 24 25 26 27 28 29]
> -Inserting 30
> -  [(9) 14 15 16 17 18 19 20 21 22]
> -22
> -  [(8) 23 24 25 26 27 28 29 30]
> -Inserting 13
> -  [(10) 13 14 15 16 17 18 19 20 21 22]
> -22
> -  [(8) 23 24 25 26 27 28 29 30]
> -Inserting 31
> -  [(10) 13 14 15 16 17 18 19 20 21 22]
> -22
> -  [(9) 23 24 25 26 27 28 29 30 31]
> -Inserting 12
> -  [(11) 12 13 14 15 16 17 18 19 20 21 22]
> -22
> -  [(9) 23 24 25 26 27 28 29 30 31]
> -Inserting 32
> -  [(11) 12 13 14 15 16 17 18 19 20 21 22]
> -22
> -  [(10) 23 24 25 26 27 28 29 30 31 32]
> -Inserting 11
> -  [(12) 11 12 13 14 15 16 17 18 19 20 21 22]
> -22
> -  [(10) 23 24 25 26 27 28 29 30 31 32]
> -Inserting 33
> -  [(12) 11 12 13 14 15 16 17 18 19 20 21 22]
> -22
> -  [(11) 23 24 25 26 27 28 29 30 31 32 33]
> -Inserting 10
> -  [(13) 10 11 12 13 14 15 16 17 18 19 20 21 22]
> -22
> -  [(11) 23 24 25 26 27 28 29 30 31 32 33]
> -Inserting 34
> -  [(13) 10 11 12 13 14 15 16 17 18 19 20 21 22]
> -22
> -  [(12) 23 24 25 26 27 28 29 30 31 32 33 34]
> -Inserting 9
> -  [(14) 9 10 11 12 13 14 15 16 17 18 19 20 21 22]
> -22
> -  [(12) 23 24 25 26 27 28 29 30 31 32 33 34]
> -Inserting 35
> -  [(14) 9 10 11 12 13 14 15 16 17 18 19 20 21 22]
> -22
> -  [(13) 23 24 25 26 27 28 29 30 31 32 33 34 35]
> -Inserting 8
> -  [(14) 8 9 10 11 12 13 14 15 16 17 18 19 20 21]
> -21
> -  [(14) 22 23 24 25 26 27 28 29 30 31 32 33 34 35]
> -Inserting 36
> -  [(10) 8 9 10 11 12 13 14 15 16 17]
> -17
> -  [(10) 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(9) 28 29 30 31 32 33 34 35 36]
> -Inserting 7
> -  [(11) 7 8 9 10 11 12 13 14 15 16 17]
> -17
> -  [(10) 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(9) 28 29 30 31 32 33 34 35 36]
> -Inserting 37
> -  [(11) 7 8 9 10 11 12 13 14 15 16 17]
> -17
> -  [(10) 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(10) 28 29 30 31 32 33 34 35 36 37]
> -Inserting 6
> -  [(12) 6 7 8 9 10 11 12 13 14 15 16 17]
> -17
> -  [(10) 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(10) 28 29 30 31 32 33 34 35 36 37]
> -Inserting 38
> -  [(12) 6 7 8 9 10 11 12 13 14 15 16 17]
> -17
> -  [(10) 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(11) 28 29 30 31 32 33 34 35 36 37 38]
> -Inserting 5
> -  [(13) 5 6 7 8 9 10 11 12 13 14 15 16 17]
> -17
> -  [(10) 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(11) 28 29 30 31 32 33 34 35 36 37 38]
> -Inserting 39
> -  [(13) 5 6 7 8 9 10 11 12 13 14 15 16 17]
> -17
> -  [(10) 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(12) 28 29 30 31 32 33 34 35 36 37 38 39]
> -Inserting 4
> -  [(14) 4 5 6 7 8 9 10 11 12 13 14 15 16 17]
> -17
> -  [(10) 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(12) 28 29 30 31 32 33 34 35 36 37 38 39]
> -Inserting 40
> -  [(14) 4 5 6 7 8 9 10 11 12 13 14 15 16 17]
> -17
> -  [(10) 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(13) 28 29 30 31 32 33 34 35 36 37 38 39 40]
> -Inserting 3
> -  [(12) 3 4 5 6 7 8 9 10 11 12 13 14]
> -14
> -  [(13) 15 16 17 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(13) 28 29 30 31 32 33 34 35 36 37 38 39 40]
> -Inserting 41
> -  [(12) 3 4 5 6 7 8 9 10 11 12 13 14]
> -14
> -  [(13) 15 16 17 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(14) 28 29 30 31 32 33 34 35 36 37 38 39 40 41]
> -Inserting 2
> -  [(13) 2 3 4 5 6 7 8 9 10 11 12 13 14]
> -14
> -  [(13) 15 16 17 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(14) 28 29 30 31 32 33 34 35 36 37 38 39 40 41]
> -Inserting 42
> -  [(13) 2 3 4 5 6 7 8 9 10 11 12 13 14]
> -14
> -  [(14) 15 16 17 18 19 20 21 22 23 24 25 26 27 28]
> -28
> -  [(14) 29 30 31 32 33 34 35 36 37 38 39 40 41 42]
> -Inserting 1
> -  [(14) 1 2 3 4 5 6 7 8 9 10 11 12 13 14]
> -14
> -  [(14) 15 16 17 18 19 20 21 22 23 24 25 26 27 28]
> -28
> -  [(14) 29 30 31 32 33 34 35 36 37 38 39 40 41 42]
> -Inserting 43
> -  [(11) 1 2 3 4 5 6 7 8 9 10 11]
> -11
> -  [(11) 12 13 14 15 16 17 18 19 20 21 22]
> -22
> -  [(11) 23 24 25 26 27 28 29 30 31 32 33]
> -33
> -  [(10) 34 35 36 37 38 39 40 41 42 43]
> -Inserting 0
> -  [(12) 0 1 2 3 4 5 6 7 8 9 10 11]
> -11
> -  [(11) 12 13 14 15 16 17 18 19 20 21 22]
> -22
> -  [(11) 23 24 25 26 27 28 29 30 31 32 33]
> -33
> -  [(10) 34 35 36 37 38 39 40 41 42 43]
> -	*** printing_test: done ***
> -	*** white_box_test ***
> -full leaf:
> -[(14) 0 1 2 3 4 5 6 7 8 9 10 11 12 13]
> -split now:
> -  [(8) 0 1 2 3 4 5 6 7]
> -7
> -  [(7) 8 9 10 11 12 13 14]
> -full 2 leafs:
> -  [(14) 0 1 2 3 4 5 6 7 8 9 10 11 12 13]
> -13
> -  [(14) 14 15 16 17 18 19 20 21 22 23 24 25 26 27]
> -split now:
> -  [(10) 0 1 2 3 4 5 6 7 8 9]
> -9
> -  [(10) 10 11 12 13 14 15 16 17 18 19]
> -19
> -  [(9) 20 21 22 23 24 25 26 27 28]
> -full 3 leafs:
> -  [(14) 0 1 2 3 4 5 6 7 8 9 10 11 12 13]
> -13
> -  [(14) 14 15 16 17 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(14) 28 29 30 31 32 33 34 35 36 37 38 39 40 41]
> -split now:
> -  [(11) 0 1 2 3 4 5 6 7 8 9 10]
> -10
> -  [(11) 11 12 13 14 15 16 17 18 19 20 21]
> -21
> -  [(11) 22 23 24 25 26 27 28 29 30 31 32]
> -32
> -  [(10) 33 34 35 36 37 38 39 40 41 42]
> -full 10 leafs:
> -  [(14) 0 1 2 3 4 5 6 7 8 9 10 11 12 13]
> -13
> -  [(14) 14 15 16 17 18 19 20 21 22 23 24 25 26 27]
> -27
> -  [(14) 28 29 30 31 32 33 34 35 36 37 38 39 40 41]
> -41
> -  [(14) 42 43 44 45 46 47 48 49 50 51 52 53 54 55]
> -55
> -  [(14) 56 57 58 59 60 61 62 63 64 65 66 67 68 69]
> -69
> -  [(14) 70 71 72 73 74 75 76 77 78 79 80 81 82 83]
> -83
> -  [(14) 84 85 86 87 88 89 90 91 92 93 94 95 96 97]
> -97
> -  [(14) 98 99 100 101 102 103 104 105 106 107 108 109 110 111]
> -111
> -  [(14) 112 113 114 115 116 117 118 119 120 121 122 123 124 125]
> -125
> -  [(14) 126 127 128 129 130 131 132 133 134 135 136 137 138 139]
> -2-level split now:
> -    [(14) 0 1 2 3 4 5 6 7 8 9 10 11 12 13]
> -  13
> -    [(14) 14 15 16 17 18 19 20 21 22 23 24 25 26 27]
> -  27
> -    [(14) 28 29 30 31 32 33 34 35 36 37 38 39 40 41]
> -  41
> -    [(14) 42 43 44 45 46 47 48 49 50 51 52 53 54 55]
> -  55
> -    [(14) 56 57 58 59 60 61 62 63 64 65 66 67 68 69]
> -  69
> -    [(14) 70 71 72 73 74 75 76 77 78 79 80 81 82 83]
> -83
> -    [(14) 84 85 86 87 88 89 90 91 92 93 94 95 96 97]
> -  97
> -    [(11) 98 99 100 101 102 103 104 105 106 107 108]
> -  108
> -    [(11) 109 110 111 112 113 114 115 116 117 118 119]
> -  119
> -    [(11) 120 121 122 123 124 125 126 127 128 129 130]
> -  130
> -    [(10) 131 132 133 134 135 136 137 138 139 140]
> -	*** white_box_test: done ***
> -	*** approximate_count ***
> -Count: 10575 10575
> -Count: 10575
> -Error count: 0
> -Count: 10575
> -	*** approximate_count: done ***
> -	*** insert_get_iterator ***
> -	*** insert_get_iterator: done ***
> -	*** delete_value_check ***
> -	*** delete_value_check: done ***
> diff --git a/test/unit/bps_tree_iterator.cc b/test/unit/bps_tree_iterator.cc
> index 5c800bc69..bf1685a47 100644
> --- a/test/unit/bps_tree_iterator.cc
> +++ b/test/unit/bps_tree_iterator.cc
> @@ -67,6 +67,7 @@ static void
>  iterator_check()
>  {
>  	header();
> +	plan(1);
>  
>  	test tree;
>  	test_create(&tree, 0, extent_alloc, extent_free,
> @@ -94,7 +95,7 @@ iterator_check()
>  			test_insert(&tree, e, 0);
>  		}
>  	}
> -	printf("Test tree size: %d\n", (int)test_size(&tree));
> +	note("Test tree size: %d\n", (int)test_size(&tree));
>  
>  	/* Test that tree filled ok */
>  	for (long i = 0; i < count1 * count2; i++) {
> @@ -107,25 +108,24 @@ iterator_check()
>  
>  	/* Print first 7 elems */
>  	{
> -		printf("--> ");
> +		note("--> ");
>  		test_iterator iterator = test_iterator_first(&tree);
>  		for (int i = 0; i < 7; i++) {
>  			elem_t *elem = test_iterator_get_elem(&tree, &iterator);
> -			printf("(%ld,%ld) ", elem->first, elem->second);
> +			note("(%ld,%ld) ", elem->first, elem->second);
>  			test_iterator_next(&tree, &iterator);
>  		}
> -		printf("\n");
>  	}
>  	/* Print last 7 elems */
>  	{
> -		printf("<-- ");
> +		note("<-- ");
>  		test_iterator iterator = test_iterator_last(&tree);
>  		for (int i = 0; i < 7; i++) {
>  			elem_t *elem = test_iterator_get_elem(&tree, &iterator);
> -			printf("(%ld,%ld) ", elem->first, elem->second);
> +			note("(%ld,%ld) ", elem->first, elem->second);
>  			test_iterator_prev(&tree, &iterator);
>  		}
> -		printf("\n");
> +		note("\n");
>  	}
>  
>  	/* Iterate forward all elements 5 times */
> @@ -180,24 +180,23 @@ iterator_check()
>  		test_iterator end = test_upper_bound(&tree, key, &has_this_key2);
>  		if (has_this_key1 != has_this_key2)
>  			fail("Exact flag is broken", "true");
> -		printf("Key %ld, %s range [%s, %s): ", key,
> +		note("Key %ld, %s range [%s, %s): ", key,
>  			has_this_key1 ? "not empty" : "empty",
>  			test_iterator_is_invalid(&begin) ? "eof" : "ptr",
>  			test_iterator_is_invalid(&end) ? "eof" : "ptr");
>  		test_iterator runner = begin;
>  		while (!test_iterator_are_equal(&tree, &runner, &end)) {
>  			elem_t *elem = test_iterator_get_elem(&tree, &runner);
> -			printf("(%ld,%ld) ", elem->first, elem->second);
> +			note("(%ld,%ld) ", elem->first, elem->second);
>  			test_iterator_next(&tree, &runner);
>  		}
> -		printf(" <-> ");
> +		note(" <-> ");
>  		runner = end;
>  		while (!test_iterator_are_equal(&tree, &runner, &begin)) {
>  			test_iterator_prev(&tree, &runner);
>  			elem_t *elem = test_iterator_get_elem(&tree, &runner);
> -			printf("(%ld,%ld) ", elem->first, elem->second);
> +			note("(%ld,%ld) ", elem->first, elem->second);
>  		}
> -		printf("\n");
>  	}
>  
>  	/* Check iterating in range from lower bound to upper bound */
> @@ -230,23 +229,22 @@ iterator_check()
>  		struct elem_t upper_elem_key = {key, LONG_MAX};
>  		test_iterator begin = test_lower_bound_elem(&tree, lower_elem_key, NULL);
>  		test_iterator end = test_upper_bound_elem(&tree, upper_elem_key, NULL);
> -		printf("Key %ld, range [%s, %s): ", key,
> +		note("Key %ld, range [%s, %s): ", key,
>  		       test_iterator_is_invalid(&begin) ? "eof" : "ptr",
>  		       test_iterator_is_invalid(&end) ? "eof" : "ptr");
>  		test_iterator runner = begin;
>  		while (!test_iterator_are_equal(&tree, &runner, &end)) {
>  			elem_t *elem = test_iterator_get_elem(&tree, &runner);
> -			printf("(%ld,%ld) ", elem->first, elem->second);
> +			note("(%ld,%ld) ", elem->first, elem->second);
>  			test_iterator_next(&tree, &runner);
>  		}
> -		printf(" <-> ");
> +		note(" <-> ");
>  		runner = end;
>  		while (!test_iterator_are_equal(&tree, &runner, &begin)) {
>  			test_iterator_prev(&tree, &runner);
>  			elem_t *elem = test_iterator_get_elem(&tree, &runner);
> -			printf("(%ld,%ld) ", elem->first, elem->second);
> +			note("(%ld,%ld) ", elem->first, elem->second);
>  		}
> -		printf("\n");
>  	}
>  
>  	/* Check iterating in range from lower bound to upper bound */
> @@ -274,6 +272,8 @@ iterator_check()
>  	}
>  
>  	test_destroy(&tree);
> +	ok(1, "iterator check");
> +	check_plan();
>  
>  	footer();
>  }
> @@ -282,6 +282,7 @@ static void
>  iterator_invalidate_check()
>  {
>  	header();
> +	plan(1);
>  
>  	const long test_size = 300;
>  	const long max_delete_count = 100;
> @@ -453,6 +454,8 @@ iterator_invalidate_check()
>  		test_destroy(&tree);
>  	}
>  
> +	ok(1, "iterator_invalidate_check");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -460,6 +463,7 @@ static void
>  iterator_freeze_check()
>  {
>  	header();
> +	plan(1);
>  
>  	const int test_rounds_size = 10;
>  	const int test_data_size = 1000;
> @@ -539,6 +543,8 @@ iterator_freeze_check()
>  		test_destroy(&tree);
>  	}
>  
> +	ok(1, "iterator_freeze_check");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -547,10 +553,12 @@ int
>  main(void)
>  {
>  	srand(time(0));
> +	plan(3);
>  	iterator_check();
>  	iterator_invalidate_check();
>  	iterator_freeze_check();
>  	if (total_extents_allocated) {
>  		fail("memory leak", "true");
>  	}
> +	check_plan();
>  }
> diff --git a/test/unit/bps_tree_iterator.result b/test/unit/bps_tree_iterator.result
> deleted file mode 100644
> index 8a2e97eec..000000000
> --- a/test/unit/bps_tree_iterator.result
> +++ /dev/null
> @@ -1,21 +0,0 @@
> -	*** iterator_check ***
> -Test tree size: 50000
> ---> (0,0) (0,1) (0,2) (0,3) (0,4) (2,0) (2,1) 
> -<-- (19998,4) (19998,3) (19998,2) (19998,1) (19998,0) (19996,4) (19996,3) 
> -Key -1, empty range [ptr, ptr):  <-> 
> -Key 0, not empty range [ptr, ptr): (0,0) (0,1) (0,2) (0,3) (0,4)  <-> (0,4) (0,3) (0,2) (0,1) (0,0) 
> -Key 10, not empty range [ptr, ptr): (10,0) (10,1) (10,2) (10,3) (10,4)  <-> (10,4) (10,3) (10,2) (10,1) (10,0) 
> -Key 15, empty range [ptr, ptr):  <-> 
> -Key 19998, not empty range [ptr, eof): (19998,0) (19998,1) (19998,2) (19998,3) (19998,4)  <-> (19998,4) (19998,3) (19998,2) (19998,1) (19998,0) 
> -Key 20000, empty range [eof, eof):  <-> 
> -Key -1, range [ptr, ptr):  <-> 
> -Key 0, range [ptr, ptr): (0,0) (0,1) (0,2) (0,3) (0,4)  <-> (0,4) (0,3) (0,2) (0,1) (0,0) 
> -Key 10, range [ptr, ptr): (10,0) (10,1) (10,2) (10,3) (10,4)  <-> (10,4) (10,3) (10,2) (10,1) (10,0) 
> -Key 15, range [ptr, ptr):  <-> 
> -Key 19998, range [ptr, eof): (19998,0) (19998,1) (19998,2) (19998,3) (19998,4)  <-> (19998,4) (19998,3) (19998,2) (19998,1) (19998,0) 
> -Key 20000, range [eof, eof):  <-> 
> -	*** iterator_check: done ***
> -	*** iterator_invalidate_check ***
> -	*** iterator_invalidate_check: done ***
> -	*** iterator_freeze_check ***
> -	*** iterator_freeze_check: done ***
> diff --git a/test/unit/cbus.c b/test/unit/cbus.c
> index ecf5fce72..09225c586 100644
> --- a/test/unit/cbus.c
> +++ b/test/unit/cbus.c
> @@ -49,7 +49,7 @@ flush_cb(struct trigger *t, void *e)
>  	(void) t;
>  	(void) e;
>  	++flushed_cnt;
> -	printf("flush event, counter = %d\n", flushed_cnt);
> +	note("flush event, counter = %d", flushed_cnt);
>  	return 0;
>  }
>  
> @@ -59,7 +59,7 @@ finish_execution(struct cmsg *m)
>  {
>  	(void) m;
>  	fiber_cancel(fiber());
> -	printf("break main fiber and finish test\n");
> +	note("break main fiber and finish test");
>  	is(flushed_cnt, expected_flushed_cnt,
>  	   "flushed_cnt at the end of the test");
>  }
> @@ -84,7 +84,7 @@ worker_f(va_list ap)
>  static void
>  worker_start()
>  {
> -	printf("start worker\n");
> +	note("start worker");
>  	fail_if(cord_costart(&worker, "worker", worker_f, NULL) != 0);
>  	cpipe_create(&pipe_to_worker, "worker");
>  }
> @@ -92,7 +92,7 @@ worker_start()
>  static void
>  worker_stop()
>  {
> -	printf("finish worker\n");
> +	note("finish worker");
>  	cbus_stop_loop(&pipe_to_worker);
>  	cpipe_destroy(&pipe_to_worker);
>  	fail_if(cord_join(&worker) != 0);
> @@ -126,7 +126,7 @@ test_forced_flush(struct cmsg *m)
>  {
>  	(void) m;
>  	is(flushed_cnt, 1, "1 flush after test_several_messages");
> -	printf("\n*** Test forced flush ***\n");
> +	note("*** Test forced flush ***");
>  	flushed_cnt = 0;
>  	static struct cmsg_hop test_forced_flush_route =
>  		{ do_forced_flush, NULL };
> @@ -160,7 +160,7 @@ test_several_messages(struct cmsg *m)
>  {
>  	(void) m;
>  	is(flushed_cnt, 1, "1 flush after test_single_msg");
> -	printf("\n*** Test several messages ***\n");
> +	note("*** Test several messages ***");
>  	flushed_cnt = 0;
>  	static struct cmsg_hop test_event_route[] = {
>  		{ do_some_event, &pipe_to_main },
> @@ -190,7 +190,7 @@ test_several_messages(struct cmsg *m)
>  static void
>  test_single_msg()
>  {
> -	printf("\n*** Test single message ***\n");
> +	note("*** Test single message ***");
>  	static struct cmsg_hop test_single_flush_route[] = {
>  		{ do_nothing, &pipe_to_main },
>  		/* Schedule the next test. */
> @@ -231,13 +231,13 @@ main()
>  	memory_init();
>  	fiber_init(fiber_c_invoke);
>  	cbus_init();
> -	printf("start main fiber\n");
> +	note("start main fiber");
>  	struct fiber *main_fiber = fiber_new("main", main_f);
>  	assert(main_fiber != NULL);
>  	fiber_wakeup(main_fiber);
> -	printf("start main loop\n");
> +	note("start main loop");
>  	ev_run(loop(), 0);
> -	printf("finish main loop\n");
> +	note("finish main loop");
>  	cbus_free();
>  	fiber_free();
>  	memory_free();
> diff --git a/test/unit/cbus.result b/test/unit/cbus.result
> deleted file mode 100644
> index e87f861f3..000000000
> --- a/test/unit/cbus.result
> +++ /dev/null
> @@ -1,24 +0,0 @@
> -	*** main ***
> -1..6
> -start main fiber
> -start main loop
> -start worker
> -
> -*** Test single message ***
> -flush event, counter = 1
> -ok 1 - 1 flush after test_single_msg
> -
> -*** Test several messages ***
> -ok 2 - no flush during loop
> -ok 3 - no flush during loop
> -ok 4 - no flush during loop
> -flush event, counter = 1
> -ok 5 - 1 flush after test_several_messages
> -
> -*** Test forced flush ***
> -flush event, counter = 1
> -break main fiber and finish test
> -ok 6 - flushed_cnt at the end of the test
> -finish worker
> -finish main loop
> -	*** main: done ***
> diff --git a/test/unit/cbus_hang.c b/test/unit/cbus_hang.c
> index 8b3671001..eac283890 100644
> --- a/test/unit/cbus_hang.c
> +++ b/test/unit/cbus_hang.c
> @@ -33,7 +33,7 @@ pthread_cond_t endpoint_hack_cond_2;
>  static
>  void join_fail(int signum) {
>  	(void)signum;
> -	printf("Can't join the hang worker\n");
> +	diag("Can't join the hang worker\n");
>  	exit(EXIT_FAILURE);
>  }
>  
> diff --git a/test/unit/cbus_hang.result b/test/unit/cbus_hang.result
> deleted file mode 100644
> index d5810e8cf..000000000
> --- a/test/unit/cbus_hang.result
> +++ /dev/null
> @@ -1,4 +0,0 @@
> -	*** main ***
> -1..1
> -ok 1 - The hang worker has been joined
> -	*** main: done ***
> diff --git a/test/unit/cbus_stress.c b/test/unit/cbus_stress.c
> index 37e8e0f77..4d0b58a35 100644
> --- a/test/unit/cbus_stress.c
> +++ b/test/unit/cbus_stress.c
> @@ -1,4 +1,3 @@
> -#include <assert.h>
>  #include <stdarg.h>
>  #include <stddef.h>
>  #include <stdlib.h>
> @@ -94,25 +93,25 @@ thread_func(va_list ap);
>  static void
>  thread_create(struct thread *t, int id)
>  {
> -	assert(thread_count > 1);
> -	assert(id >= 0 && id < thread_count);
> +	fail_if(thread_count <= 1);
> +	fail_if(!(id >= 0 && id < thread_count));
>  
>  	const int neighbor_count = thread_count - 1;
>  
>  	t->id = id;
>  	snprintf(t->name, sizeof(t->name), "thread_%d", id);
> -	assert(t->name != NULL);
> +	fail_if(t->name == NULL);
>  
>  	t->connections = calloc(thread_count, sizeof(*t->connections));
> -	assert(t->connections != NULL);
> +	fail_if(t->connections == NULL);
>  
>  	t->connected_count = 0;
>  	t->connected = calloc(neighbor_count, sizeof(*t->connected));
> -	assert(t->connected != NULL);
> +	fail_if(t->connected == NULL);
>  
>  	t->disconnected_count = 0;
>  	t->disconnected = calloc(neighbor_count, sizeof(*t->disconnected));
> -	assert(t->disconnected != NULL);
> +	fail_if(t->disconnected == NULL);
>  
>  	/* Initially, we are not connected to anyone. */
>  	for (int i = 0; i < thread_count; i++) {
> @@ -120,7 +119,7 @@ thread_create(struct thread *t, int id)
>  			continue; /* can't connect to self */
>  		t->disconnected[t->disconnected_count++] = i;
>  	}
> -	assert(t->disconnected_count == neighbor_count);
> +	fail_if(t->disconnected_count != neighbor_count);
>  
>  	t->sent = t->received = 0;
>  	active_thread_count++;
> @@ -139,7 +138,7 @@ thread_start_test_cb(struct cmsg *cmsg)
>  {
>  	struct thread *t = container_of(cmsg, struct thread, cmsg);
>  	struct fiber *test_fiber = fiber_new("test", test_func);
> -	assert(test_fiber != NULL);
> +	fail_if(test_fiber == NULL);
>  	fiber_start(test_fiber, t);
>  }
>  
> @@ -173,10 +172,10 @@ thread_destroy(struct thread *t)
>  static void
>  thread_connect(struct thread *t, int dest_id)
>  {
> -	assert(dest_id != t->id);
> -	assert(dest_id < thread_count);
> +	fail_if(dest_id == t->id);
> +	fail_if(dest_id >= thread_count);
>  	struct conn *conn = &t->connections[dest_id];
> -	assert(!conn->active);
> +	fail_if(conn->active);
>  	cbus_pair(thread_name(dest_id), t->name,
>  		  &conn->to, &conn->from, NULL, NULL, NULL);
>  	conn->active = true;
> @@ -186,10 +185,10 @@ thread_connect(struct thread *t, int dest_id)
>  static void
>  thread_disconnect(struct thread *t, int dest_id)
>  {
> -	assert(dest_id != t->id);
> -	assert(dest_id < thread_count);
> +	fail_if(dest_id == t->id);
> +	fail_if(dest_id >= thread_count);
>  	struct conn *conn = &t->connections[dest_id];
> -	assert(conn->active);
> +	fail_if(!(conn->active));
>  	cbus_unpair(&conn->to, &conn->from, NULL, NULL, NULL);
>  	conn->active = false;
>  }
> @@ -198,8 +197,8 @@ thread_disconnect(struct thread *t, int dest_id)
>  static void
>  thread_connect_random(struct thread *t)
>  {
> -	assert(t->disconnected_count > 0);
> -	assert(t->connected_count + t->disconnected_count == thread_count - 1);
> +	fail_if(t->disconnected_count <= 0);
> +	fail_if(t->connected_count + t->disconnected_count != thread_count - 1);
>  	int idx = rand() % t->disconnected_count;
>  	int dest_id = t->disconnected[idx];
>  	t->disconnected[idx] = t->disconnected[--t->disconnected_count];
> @@ -211,8 +210,8 @@ thread_connect_random(struct thread *t)
>  static void
>  thread_disconnect_random(struct thread *t)
>  {
> -	assert(t->connected_count > 0);
> -	assert(t->connected_count + t->disconnected_count == thread_count - 1);
> +	fail_if(t->connected_count <= 0);
> +	fail_if(t->connected_count + t->disconnected_count != thread_count - 1);
>  	int idx = rand() % t->connected_count;
>  	int dest_id = t->connected[idx];
>  	t->connected[idx] = t->connected[--t->connected_count];
> @@ -242,9 +241,9 @@ thread_send(struct thread *t, int dest_id)
>  		{ thread_msg_received_cb, NULL }
>  	};
>  	struct conn *c = &t->connections[dest_id];
> -	assert(c->active);
> +	fail_if(!(c->active));
>  	struct thread_msg *msg = malloc(sizeof(*msg));
> -	assert(msg != NULL);
> +	fail_if(msg == NULL);
>  	cmsg_init(&msg->cmsg, route);
>  	msg->dest_id = dest_id;
>  	cpipe_push(&c->to, &msg->cmsg);
> @@ -255,7 +254,7 @@ thread_send(struct thread *t, int dest_id)
>  static void
>  thread_send_random(struct thread *t)
>  {
> -	assert(t->connected_count > 0);
> +	fail_if(t->connected_count <= 0);
>  	int idx = rand() % t->connected_count;
>  	int dest_id = t->connected[idx];
>  	thread_send(t, dest_id);
> @@ -276,7 +275,7 @@ static void
>  test_complete_cb(struct cmsg *cmsg)
>  {
>  	(void)cmsg;
> -	assert(active_thread_count > 0);
> +	fail_if(active_thread_count <= 0);
>  	if (--active_thread_count == 0) {
>  		/* Stop the main fiber when all workers are done. */
>  		fiber_cancel(fiber());
> @@ -334,7 +333,7 @@ main_func(va_list ap)
>  	cbus_endpoint_create(&endpoint, "main", fiber_schedule_cb, fiber());
>  
>  	threads = calloc(thread_count, sizeof(*threads));
> -	assert(threads != NULL);
> +	fail_if(threads == NULL);
>  
>  	for (int i = 0; i < thread_count; i++)
>  		thread_create(&threads[i], i);
> @@ -351,7 +350,7 @@ main_func(va_list ap)
>  		received += t->received;
>  		thread_destroy(t);
>  	}
> -	assert(sent == received);
> +	fail_if(sent != received);
>  
>  	cbus_endpoint_destroy(&endpoint, cbus_process);
>  
> @@ -373,12 +372,14 @@ main()
>  	cbus_init();
>  
>  	header();
> +	plan(1);
>  
>  	struct fiber *main_fiber = fiber_new("main", main_func);
> -	assert(main_fiber != NULL);
> +	isnt(main_fiber, NULL, "fiber started");
>  	fiber_wakeup(main_fiber);
>  	ev_run(loop(), 0);
>  
> +	check_plan();
>  	footer();
>  
>  	cbus_free();
> diff --git a/test/unit/cbus_stress.result b/test/unit/cbus_stress.result
> deleted file mode 100644
> index 8300f0550..000000000
> --- a/test/unit/cbus_stress.result
> +++ /dev/null
> @@ -1,2 +0,0 @@
> -	*** main ***
> -	*** main: done ***
> diff --git a/test/unit/checkpoint_schedule.result b/test/unit/checkpoint_schedule.result
> deleted file mode 100644
> index e34c762a1..000000000
> --- a/test/unit/checkpoint_schedule.result
> +++ /dev/null
> @@ -1,41 +0,0 @@
> -	*** main ***
> -1..38
> -ok 1 - checkpointing disabled - timeout after configuration
> -ok 2 - checkpointing disabled - timeout after sleep
> -ok 3 - checkpointing disabled - timeout after reset
> -ok 4 - checkpoint interval 100 - timeout after configuration
> -ok 5 - checkpoint interval 100 - initial timeout randomization
> -ok 6 - checkpoint interval 100 - timeout after sleep 1
> -ok 7 - checkpoint interval 100 - timeout after sleep 2
> -ok 8 - checkpoint interval 100 - timeout after sleep 3
> -ok 9 - checkpoint interval 100 - timeout after sleep 4
> -ok 10 - checkpoint interval 100 - timeout after reset
> -ok 11 - checkpoint interval 600 - timeout after configuration
> -ok 12 - checkpoint interval 600 - initial timeout randomization
> -ok 13 - checkpoint interval 600 - timeout after sleep 1
> -ok 14 - checkpoint interval 600 - timeout after sleep 2
> -ok 15 - checkpoint interval 600 - timeout after sleep 3
> -ok 16 - checkpoint interval 600 - timeout after sleep 4
> -ok 17 - checkpoint interval 600 - timeout after reset
> -ok 18 - checkpoint interval 1200 - timeout after configuration
> -ok 19 - checkpoint interval 1200 - initial timeout randomization
> -ok 20 - checkpoint interval 1200 - timeout after sleep 1
> -ok 21 - checkpoint interval 1200 - timeout after sleep 2
> -ok 22 - checkpoint interval 1200 - timeout after sleep 3
> -ok 23 - checkpoint interval 1200 - timeout after sleep 4
> -ok 24 - checkpoint interval 1200 - timeout after reset
> -ok 25 - checkpoint interval 1800 - timeout after configuration
> -ok 26 - checkpoint interval 1800 - initial timeout randomization
> -ok 27 - checkpoint interval 1800 - timeout after sleep 1
> -ok 28 - checkpoint interval 1800 - timeout after sleep 2
> -ok 29 - checkpoint interval 1800 - timeout after sleep 3
> -ok 30 - checkpoint interval 1800 - timeout after sleep 4
> -ok 31 - checkpoint interval 1800 - timeout after reset
> -ok 32 - checkpoint interval 3600 - timeout after configuration
> -ok 33 - checkpoint interval 3600 - initial timeout randomization
> -ok 34 - checkpoint interval 3600 - timeout after sleep 1
> -ok 35 - checkpoint interval 3600 - timeout after sleep 2
> -ok 36 - checkpoint interval 3600 - timeout after sleep 3
> -ok 37 - checkpoint interval 3600 - timeout after sleep 4
> -ok 38 - checkpoint interval 3600 - timeout after reset
> -	*** main: done ***
> diff --git a/test/unit/coio.result b/test/unit/coio.result
> deleted file mode 100644
> index 5019fa48a..000000000
> --- a/test/unit/coio.result
> +++ /dev/null
> @@ -1,12 +0,0 @@
> -	*** stat_timeout_test ***
> -	*** stat_timeout_test: done ***
> -	*** stat_notify_test ***
> -# filename: 1.out
> -	*** stat_notify_test: done ***
> -	*** test_call_f ***
> -# call done with res 0
> -	*** test_call_f: done ***
> -	*** test_getaddrinfo ***
> -1..1
> -ok 1 - getaddrinfo
> -	*** test_getaddrinfo: done ***
> diff --git a/test/unit/coll.cpp b/test/unit/coll.cpp
> index 8d7a3ff1e..16d2e28b4 100644
> --- a/test/unit/coll.cpp
> +++ b/test/unit/coll.cpp
> @@ -2,7 +2,6 @@
>  #include <vector>
>  #include <algorithm>
>  #include <string.h>
> -#include <assert.h>
>  #include <msgpuck.h>
>  #include <diag.h>
>  #include <fiber.h>
> @@ -30,12 +29,13 @@ void
>  test_sort_strings(vector<const char *> &strings, struct coll *coll)
>  {
>  	sort(strings.begin(), strings.end(), comp(coll));
> -	cout << strings[0] << endl;
> +	cout << "# " << strings[0] << endl;
>  	for (size_t i = 1; i < strings.size(); i++) {
>  		int cmp = coll->cmp(strings[i], strlen(strings[i]),
>  				    strings[i - 1], strlen(strings[i - 1]),
>  				    coll);
> -		cout << strings[i]
> +		cout << "# "
> +		     << strings[i]
>  		     << (cmp < 0 ? " LESS" : cmp > 0 ? " GREATER " : " EQUAL")
>  		     << endl;
>  	}
> @@ -45,6 +45,7 @@ void
>  manual_test()
>  {
>  	header();
> +	plan(7);
>  
>  	vector<const char *> strings;
>  	struct coll_def def;
> @@ -54,62 +55,56 @@ manual_test()
>  	def.icu.strength = COLL_ICU_STRENGTH_IDENTICAL;
>  	struct coll *coll;
>  
> -	cout << " -- default ru_RU -- " << endl;
>  	coll = coll_new(&def);
> -	assert(coll != NULL);
> +	isnt(coll, NULL, "-- default ru_RU --")
>  	strings = {"Б", "бб", "е", "ЕЕЕЕ", "ё", "Ё", "и", "И", "123", "45" };
>  	test_sort_strings(strings, coll);
>  	coll_unref(coll);
>  
> -	cout << " -- --||-- + upper first -- " << endl;
>  	def.icu.case_first = COLL_ICU_CF_UPPER_FIRST;
>  	coll = coll_new(&def);
> -	assert(coll != NULL);
> +	isnt(coll, NULL, "-- --||-- + upper first --")
>  	strings = {"Б", "бб", "е", "ЕЕЕЕ", "ё", "Ё", "и", "И", "123", "45" };
>  	test_sort_strings(strings, coll);
>  	coll_unref(coll);
>  
> -	cout << " -- --||-- + lower first -- " << endl;
>  	def.icu.case_first = COLL_ICU_CF_LOWER_FIRST;
>  	coll = coll_new(&def);
> -	assert(coll != NULL);
> +	isnt(coll, NULL, "-- --||-- + lower first --")
>  	strings = {"Б", "бб", "е", "ЕЕЕЕ", "ё", "Ё", "и", "И", "123", "45" };
>  	test_sort_strings(strings, coll);
>  	coll_unref(coll);
>  
> -	cout << " -- --||-- + secondary strength + numeric -- " << endl;
>  	def.icu.strength = COLL_ICU_STRENGTH_SECONDARY;
>  	def.icu.numeric_collation = COLL_ICU_ON;
>  	coll = coll_new(&def);
> -	assert(coll != NULL);
> +	isnt(coll, NULL, "-- --||-- + secondary strength + numeric --")
>  	strings = {"Б", "бб", "е", "ЕЕЕЕ", "ё", "Ё", "и", "И", "123", "45" };
>  	test_sort_strings(strings, coll);
>  	coll_unref(coll);
>  
> -	cout << " -- --||-- + case level -- " << endl;
>  	def.icu.case_level = COLL_ICU_ON;
>  	coll = coll_new(&def);
> -	assert(coll != NULL);
> +	isnt(coll, NULL, "-- --||-- + case level --")
>  	strings = {"Б", "бб", "е", "ЕЕЕЕ", "ё", "Ё", "и", "И", "123", "45" };
>  	test_sort_strings(strings, coll);
>  	coll_unref(coll);
>  
> -	cout << " -- en_EN -- " << endl;
>  	snprintf(def.locale, sizeof(def.locale), "%s", "en_EN-EN");
>  	coll = coll_new(&def);
> -	assert(coll != NULL);
> +	isnt(coll, NULL, "-- en_EN --")
>  	strings = {"aa", "bb", "cc", "ch", "dd", "gg", "hh", "ii" };
>  	test_sort_strings(strings, coll);
>  	coll_unref(coll);
>  
> -	cout << " -- cs_CZ -- " << endl;
>  	snprintf(def.locale, sizeof(def.locale), "%s", "cs_CZ");
>  	coll = coll_new(&def);
> -	assert(coll != NULL);
> +	isnt(coll, NULL, "-- cs_CZ --")
>  	strings = {"aa", "bb", "cc", "ch", "dd", "gg", "hh", "ii" };
>  	test_sort_strings(strings, coll);
>  	coll_unref(coll);
>  
> +	check_plan();
>  	footer();
>  }
>  
> @@ -127,6 +122,7 @@ void
>  hash_test()
>  {
>  	header();
> +	plan(8);
>  
>  	struct coll_def def;
>  	memset(&def, 0, sizeof(def));
> @@ -137,23 +133,22 @@ hash_test()
>  
>  	/* Case sensitive */
>  	coll = coll_new(&def);
> -	assert(coll != NULL);
> -	cout << "Case sensitive" << endl;
> -	cout << (calc_hash("ае", coll) != calc_hash("аё", coll) ? "OK" : "Fail") << endl;
> -	cout << (calc_hash("ае", coll) != calc_hash("аЕ", coll) ? "OK" : "Fail") << endl;
> -	cout << (calc_hash("аЕ", coll) != calc_hash("аё", coll) ? "OK" : "Fail") << endl;
> +	isnt(coll, NULL, "Case sensitive");
> +	isnt(calc_hash("ае", coll), calc_hash("аё", coll), "ае != аё");
> +	isnt(calc_hash("ае", coll), calc_hash("аЕ", coll), "ае != аЕ");
> +	isnt(calc_hash("аЕ", coll), calc_hash("аё", coll), "аЕ != аё");
>  	coll_unref(coll);
>  
>  	/* Case insensitive */
>  	def.icu.strength = COLL_ICU_STRENGTH_SECONDARY;
>  	coll = coll_new(&def);
> -	assert(coll != NULL);
> -	cout << "Case insensitive" << endl;
> -	cout << (calc_hash("ае", coll) != calc_hash("аё", coll) ? "OK" : "Fail") << endl;
> -	cout << (calc_hash("ае", coll) == calc_hash("аЕ", coll) ? "OK" : "Fail") << endl;
> -	cout << (calc_hash("аЕ", coll) != calc_hash("аё", coll) ? "OK" : "Fail") << endl;
> +	isnt(coll, NULL, "Case insensitive");
> +	isnt(calc_hash("ае", coll), calc_hash("аё", coll), "ае != аё");
> +	is(calc_hash("ае", coll), calc_hash("аЕ", coll), "ае == аЕ");
> +	isnt(calc_hash("аЕ", coll), calc_hash("аё", coll), "аЕ != аё");
>  	coll_unref(coll);
>  
> +	check_plan();
>  	footer();
>  }
>  
> @@ -187,6 +182,7 @@ cache_test()
>  int
>  main(int, const char**)
>  {
> +	plan(3);
>  	coll_init();
>  	memory_init();
>  	fiber_init(fiber_c_invoke);
> @@ -196,4 +192,5 @@ main(int, const char**)
>  	fiber_free();
>  	memory_free();
>  	coll_free();
> +	check_plan();
>  }
> diff --git a/test/unit/coll.result b/test/unit/coll.result
> deleted file mode 100644
> index 269764246..000000000
> --- a/test/unit/coll.result
> +++ /dev/null
> @@ -1,90 +0,0 @@
> -	*** manual_test ***
> - -- default ru_RU -- 
> -123
> -45 GREATER 
> -Б GREATER 
> -бб GREATER 
> -е GREATER 
> -ё GREATER 
> -Ё GREATER 
> -ЕЕЕЕ GREATER 
> -и GREATER 
> -И GREATER 
> - -- --||-- + upper first -- 
> -123
> -45 GREATER 
> -Б GREATER 
> -бб GREATER 
> -е GREATER 
> -Ё GREATER 
> -ё GREATER 
> -ЕЕЕЕ GREATER 
> -И GREATER 
> -и GREATER 
> - -- --||-- + lower first -- 
> -123
> -45 GREATER 
> -Б GREATER 
> -бб GREATER 
> -е GREATER 
> -ё GREATER 
> -Ё GREATER 
> -ЕЕЕЕ GREATER 
> -и GREATER 
> -И GREATER 
> - -- --||-- + secondary strength + numeric -- 
> -45
> -123 GREATER 
> -Б GREATER 
> -бб GREATER 
> -е GREATER 
> -ё GREATER 
> -Ё EQUAL
> -ЕЕЕЕ GREATER 
> -и GREATER 
> -И EQUAL
> - -- --||-- + case level -- 
> -45
> -123 GREATER 
> -Б GREATER 
> -бб GREATER 
> -е GREATER 
> -ё GREATER 
> -Ё GREATER 
> -ЕЕЕЕ GREATER 
> -и GREATER 
> -И GREATER 
> - -- en_EN -- 
> -aa
> -bb GREATER 
> -cc GREATER 
> -ch GREATER 
> -dd GREATER 
> -gg GREATER 
> -hh GREATER 
> -ii GREATER 
> - -- cs_CZ -- 
> -aa
> -bb GREATER 
> -cc GREATER 
> -dd GREATER 
> -gg GREATER 
> -hh GREATER 
> -ch GREATER 
> -ii GREATER 
> -	*** manual_test: done ***
> -	*** hash_test ***
> -Case sensitive
> -OK
> -OK
> -OK
> -Case insensitive
> -OK
> -OK
> -OK
> -	*** hash_test: done ***
> -	*** cache_test ***
> -1..2
> -ok 1 - collations with the same definition are not duplicated
> -ok 2 - collations with different definitions are different objects
> -	*** cache_test: done ***
> diff --git a/test/unit/column_mask.result b/test/unit/column_mask.result
> deleted file mode 100644
> index 1d87a2f24..000000000
> --- a/test/unit/column_mask.result
> +++ /dev/null
> @@ -1,36 +0,0 @@
> -	*** main ***
> -1..28
> -ok 1 - check result length
> -ok 2 - tuple update is correct
> -ok 3 - column_mask is correct
> -ok 4 - check result length
> -ok 5 - tuple update is correct
> -ok 6 - column_mask is correct
> -ok 7 - check result length
> -ok 8 - tuple update is correct
> -ok 9 - column_mask is correct
> -ok 10 - check result length
> -ok 11 - tuple update is correct
> -ok 12 - column_mask is correct
> -ok 13 - check result length
> -ok 14 - tuple update is correct
> -ok 15 - column_mask is correct
> -ok 16 - check result length
> -ok 17 - tuple update is correct
> -ok 18 - column_mask is correct
> -ok 19 - check result length
> -ok 20 - tuple update is correct
> -ok 21 - column_mask is correct
> -ok 22 - check result length
> -ok 23 - tuple update is correct
> -ok 24 - column_mask is correct
> -ok 25 - check result length
> -ok 26 - tuple update is correct
> -ok 27 - column_mask is correct
> -	*** test_paths ***
> -    1..2
> -    ok 1 - JSON update works
> -    ok 2 - column mask match
> -ok 28 - subtests
> -	*** test_paths: done ***
> -	*** main: done ***
> diff --git a/test/unit/crypto.result b/test/unit/crypto.result
> deleted file mode 100644
> index 6e01896b1..000000000
> --- a/test/unit/crypto.result
> +++ /dev/null
> @@ -1,132 +0,0 @@
> -	*** main ***
> -1..5
> -ok 1 - crypto checks that algo argument is correct
> -	*** test_aes128_codec ***
> -    1..20
> -    ok 1 - encrypt returns needed number of bytes
> -    ok 2 - encrypt does not write anything when too small buffer
> -    ok 3 - encrypt does not allow 0 sized buffer
> -    ok 4 - encrypt requires additional block when buffer size is multiple of block size
> -    ok 5 - AES 126 IV size is 16
> -    ok 6 - encrypt works when buffer is big enough
> -    ok 7 - encrypt returns the same on second call
> -    ok 8 - encrypted data is the same
> -    ok 9 - and it is not just copied from the plain text
> -    ok 10 - decrypt also checks length and returns needed number of bytes
> -    ok 11 - decrypt returns correct number of bytes
> -    ok 12 - and correctly decrypts data
> -    ok 13 - decrypt can't correctly decode anything with a wrong IV
> -    ok 14 - in case decrypt has totally failed, diag is set
> -    ok 15 - encrypt with different IV and the same number of written bytes returned
> -    ok 16 - the encrypted data looks different
> -    ok 17 - decrypt works with correct but another IV
> -    ok 18 - data is the same
> -    ok 19 - encrypt with one codec, but decrypt with another codec and the same key
> -    ok 20 - data is the same
> -ok 2 - subtests
> -	*** test_aes128_codec: done ***
> -	*** test_aes128_stress ***
> -    1..1
> -    ok 1 - try encrypt/decrypt on a variety of sizes, keys, and ivs
> -ok 3 - subtests
> -	*** test_aes128_stress: done ***
> -	*** test_each ***
> -    1..80
> -    ok 1 - none 0 ECB, create iv of size 0
> -    ok 2 - encode
> -    ok 3 - decode
> -    ok 4 - data is correct
> -    ok 5 - none 0 CBC, create iv of size 0
> -    ok 6 - encode
> -    ok 7 - decode
> -    ok 8 - data is correct
> -    ok 9 - none 0 CFB, create iv of size 0
> -    ok 10 - encode
> -    ok 11 - decode
> -    ok 12 - data is correct
> -    ok 13 - none 0 OFB, create iv of size 0
> -    ok 14 - encode
> -    ok 15 - decode
> -    ok 16 - data is correct
> -    ok 17 - AES128 16 ECB, create iv of size 0
> -    ok 18 - encode
> -    ok 19 - decode
> -    ok 20 - data is correct
> -    ok 21 - AES128 16 CBC, create iv of size 16
> -    ok 22 - encode
> -    ok 23 - decode
> -    ok 24 - data is correct
> -    ok 25 - AES128 16 CFB, create iv of size 16
> -    ok 26 - encode
> -    ok 27 - decode
> -    ok 28 - data is correct
> -    ok 29 - AES128 16 OFB, create iv of size 16
> -    ok 30 - encode
> -    ok 31 - decode
> -    ok 32 - data is correct
> -    ok 33 - AES192 24 ECB, create iv of size 0
> -    ok 34 - encode
> -    ok 35 - decode
> -    ok 36 - data is correct
> -    ok 37 - AES192 24 CBC, create iv of size 16
> -    ok 38 - encode
> -    ok 39 - decode
> -    ok 40 - data is correct
> -    ok 41 - AES192 24 CFB, create iv of size 16
> -    ok 42 - encode
> -    ok 43 - decode
> -    ok 44 - data is correct
> -    ok 45 - AES192 24 OFB, create iv of size 16
> -    ok 46 - encode
> -    ok 47 - decode
> -    ok 48 - data is correct
> -    ok 49 - AES256 32 ECB, create iv of size 0
> -    ok 50 - encode
> -    ok 51 - decode
> -    ok 52 - data is correct
> -    ok 53 - AES256 32 CBC, create iv of size 16
> -    ok 54 - encode
> -    ok 55 - decode
> -    ok 56 - data is correct
> -    ok 57 - AES256 32 CFB, create iv of size 16
> -    ok 58 - encode
> -    ok 59 - decode
> -    ok 60 - data is correct
> -    ok 61 - AES256 32 OFB, create iv of size 16
> -    ok 62 - encode
> -    ok 63 - decode
> -    ok 64 - data is correct
> -    ok 65 - DES 8 ECB, create iv of size 0
> -    ok 66 - encode
> -    ok 67 - decode
> -    ok 68 - data is correct
> -    ok 69 - DES 8 CBC, create iv of size 8
> -    ok 70 - encode
> -    ok 71 - decode
> -    ok 72 - data is correct
> -    ok 73 - DES 8 CFB, create iv of size 8
> -    ok 74 - encode
> -    ok 75 - decode
> -    ok 76 - data is correct
> -    ok 77 - DES 8 OFB, create iv of size 8
> -    ok 78 - encode
> -    ok 79 - decode
> -    ok 80 - data is correct
> -ok 4 - subtests
> -	*** test_each: done ***
> -	*** test_stream ***
> -    1..11
> -    ok 1 - stream begin checks key size
> -    ok 2 - stream begin checks iv size
> -    ok 3 - begin encryption
> -    ok 4 - append checks size
> -    ok 5 - append 5
> -    ok 6 - append 10
> -    ok 7 - last append 30
> -    ok 8 - commit checks size
> -    ok 9 - commit 16
> -    ok 10 - decoder returned correct size
> -    ok 11 - data is decoded correctly
> -ok 5 - subtests
> -	*** test_stream: done ***
> -	*** main: done ***
> diff --git a/test/unit/csv.result b/test/unit/csv.result
> index 8f9dab5b2..783388aca 100644
> --- a/test/unit/csv.result
> +++ b/test/unit/csv.result
> @@ -1,30 +1,30 @@
> -	*** test1 ***
> +# *** test1 ***
>  |1|
>  ||
>  |1|	|2|	|3|
>  |123|
> -	*** test1: done ***
> -	*** test2 ***
> +# *** test1: done ***
> +# *** test2 ***
>  |123|	|456|	|abcac|	|'multiword field 4'|
>  |none|	|none|	|0|
>  ||	||	||
>  ||	||	||
> -	*** test2: done ***
> -	*** test3 ***
> +# *** test2: done ***
> +# *** test3 ***
>  |1|	||	|2|
> -	*** test3: done ***
> -	*** test4 ***
> +# *** test3: done ***
> +# *** test4 ***
>  |123|	|5|	|92|	|0|	|0|
>  |1|	|12  34|	|56|	|quote , |	|66|
>  |ok|
> -	*** test4: done ***
> -	*** test5 ***
> +# *** test4: done ***
> +# *** test5 ***
>  |abc|	|longlonglonglonglonglonglonglonglonglonglonglonglonglonglonglonglonglong|	|0|
>  |123|	|456|	||
>  |0|	||	||
>  valid: yes
> -	*** test5: done ***
> -	*** test6 ***
> +# *** test5: done ***
> +# *** test6 ***
>  ||
>  ||
>  |abc|
> @@ -36,67 +36,67 @@ valid: yes
>  ||
>  | |
>  valid: NO
> -	*** test6: done ***
> -	*** big_chunk_separated_test ***
> +# *** test6: done ***
> +# *** big_chunk_separated_test ***
>  line_cnt=10000, fieldsizes_cnt=1920000, 1920000
> -	*** big_chunk_separated_test: done ***
> -	*** random_generated_test ***
> +# *** big_chunk_separated_test: done ***
> +# *** random_generated_test ***
>  line_cnt=40, fieldsizes_cnt=183
>  valid: yes
> -	*** random_generated_test: done ***
> -	*** common_test ***
> +# *** random_generated_test: done ***
> +# *** common_test ***
>  |first|	|last|	|address|	|city|	|zip|
>  |John|	|Doe|	|120 any st.|	|Anytown, WW|	|08123|
> -	*** common_test: done ***
> -	*** common_test ***
> +# *** common_test: done ***
> +# *** common_test ***
>  |a|	|b|	|c|
>  |1|	|"|	|"|
>  |2|	|3|	|4|
> -	*** common_test: done ***
> -	*** common_test ***
> +# *** common_test: done ***
> +# *** common_test ***
>  |a|	|b|
>  |1|	|ha "ha" ha|
>  |3|	|4|
> -	*** common_test: done ***
> -	*** common_test ***
> +# *** common_test: done ***
> +# *** common_test ***
>  |key|	|val|
>  |1|	|{"type": "Point", "coordinates": [102.0, 0.5]}|
> -	*** common_test: done ***
> -	*** common_test ***
> +# *** common_test: done ***
> +# *** common_test ***
>  |a|	|b|	|c|
>  |1|	|2|	|3|
>  |Once upon 
>  a time|	|5|	|6|
>  |7|	|8|	|9|
> -	*** common_test: done ***
> -	*** common_test ***
> +# *** common_test: done ***
> +# *** common_test ***
>  |a|	|b|
>  |1|	|ha
>  "ha"
>  ha|
>  |3|	|4|
> -	*** common_test: done ***
> -	*** common_test ***
> +# *** common_test: done ***
> +# *** common_test ***
>  |a|	|b|	|c|
>  |1|	|2|	|3|
>  |4|	|5|	|а нет ли ошибок?|
> -	*** common_test: done ***
> -	*** common_test ***
> +# *** common_test: done ***
> +# *** common_test ***
>  |www|	|aaa|	|tt  |
> -	*** common_test: done ***
> -	*** iter_test1 ***
> +# *** common_test: done ***
> +# *** iter_test1 ***
>  ||	|d|	|e|
>  |12|	|42|	|3|
>  |o|
> -	*** iter_test1: done ***
> -	*** iter_test2 ***
> +# *** iter_test1: done ***
> +# *** iter_test2 ***
>  |1|
>  |23|
> -	*** iter_test2: done ***
> -	*** iter_test3 ***
> +# *** iter_test2: done ***
> +# *** iter_test3 ***
>  |1|	|2|	|3|
>  |4|	|5|	|6|
> -	*** iter_test3: done ***
> -	*** csv_out ***
> +# *** iter_test3: done ***
> +# *** csv_out ***
>  abc<len=3>,"with,comma"<len=12>,""in quotes""<len=13>,1 "" quote<len=10>
> -	*** csv_out: done ***
> +# *** csv_out: done ***
> diff --git a/test/unit/decimal.result b/test/unit/decimal.result
> deleted file mode 100644
> index e8432fb36..000000000
> --- a/test/unit/decimal.result
> +++ /dev/null
> @@ -1,700 +0,0 @@
> -1..281
> -ok 1 - decimal(314)
> -ok 2 - decimal(271)
> -ok 3 - decimal(314) + decimal(271)
> -ok 4 - decimal((314) + (271))
> -ok 5 - decimal(314) + decimal(271) == (314) + (271)
> -ok 6 - decimal(314) - decimal(271)
> -ok 7 - decimal((314) - (271))
> -ok 8 - decimal(314) - decimal(271) == (314) - (271)
> -ok 9 - decimal(314) * decimal(271)
> -ok 10 - decimal((314) * (271))
> -ok 11 - decimal_round((314) * (271), 15)
> -ok 12 - decimal(314) * decimal(271) == (314) * (271)
> -ok 13 - decimal(314) / decimal(271)
> -ok 14 - decimal((314) / (271))
> -ok 15 - decimal_round((314)/(271), 15)
> -ok 16 - decimal(314) / decimal(271) == (314) / (271)
> -ok 17 - decimal(65535)
> -ok 18 - decimal(23456)
> -ok 19 - decimal(65535) + decimal(23456)
> -ok 20 - decimal((65535) + (23456))
> -ok 21 - decimal(65535) + decimal(23456) == (65535) + (23456)
> -ok 22 - decimal(65535) - decimal(23456)
> -ok 23 - decimal((65535) - (23456))
> -ok 24 - decimal(65535) - decimal(23456) == (65535) - (23456)
> -ok 25 - decimal(65535) * decimal(23456)
> -ok 26 - decimal((65535) * (23456))
> -ok 27 - decimal_round((65535) * (23456), 15)
> -ok 28 - decimal(65535) * decimal(23456) == (65535) * (23456)
> -ok 29 - decimal(65535) / decimal(23456)
> -ok 30 - decimal((65535) / (23456))
> -ok 31 - decimal_round((65535)/(23456), 15)
> -ok 32 - decimal(65535) / decimal(23456) == (65535) / (23456)
> -ok 33 - decimal(0)
> -ok 34 - decimal(1)
> -ok 35 - decimal(0) + decimal(1)
> -ok 36 - decimal((0) + (1))
> -ok 37 - decimal(0) + decimal(1) == (0) + (1)
> -ok 38 - decimal(0) - decimal(1)
> -ok 39 - decimal((0) - (1))
> -ok 40 - decimal(0) - decimal(1) == (0) - (1)
> -ok 41 - decimal(0) * decimal(1)
> -ok 42 - decimal((0) * (1))
> -ok 43 - decimal_round((0) * (1), 15)
> -ok 44 - decimal(0) * decimal(1) == (0) * (1)
> -ok 45 - decimal(0) / decimal(1)
> -ok 46 - decimal((0) / (1))
> -ok 47 - decimal_round((0)/(1), 15)
> -ok 48 - decimal(0) / decimal(1) == (0) / (1)
> -ok 49 - decimal(0)
> -ok 50 - decimal(-1)
> -ok 51 - decimal(0) + decimal(-1)
> -ok 52 - decimal((0) + (-1))
> -ok 53 - decimal(0) + decimal(-1) == (0) + (-1)
> -ok 54 - decimal(0) - decimal(-1)
> -ok 55 - decimal((0) - (-1))
> -ok 56 - decimal(0) - decimal(-1) == (0) - (-1)
> -ok 57 - decimal(0) * decimal(-1)
> -ok 58 - decimal((0) * (-1))
> -ok 59 - decimal_round((0) * (-1), 15)
> -ok 60 - decimal(0) * decimal(-1) == (0) * (-1)
> -ok 61 - decimal(0) / decimal(-1)
> -ok 62 - decimal((0) / (-1))
> -ok 63 - decimal_round((0)/(-1), 15)
> -ok 64 - decimal(0) / decimal(-1) == (0) / (-1)
> -ok 65 - decimal(-1)
> -ok 66 - decimal(1)
> -ok 67 - decimal(-1) + decimal(1)
> -ok 68 - decimal((-1) + (1))
> -ok 69 - decimal(-1) + decimal(1) == (-1) + (1)
> -ok 70 - decimal(-1) - decimal(1)
> -ok 71 - decimal((-1) - (1))
> -ok 72 - decimal(-1) - decimal(1) == (-1) - (1)
> -ok 73 - decimal(-1) * decimal(1)
> -ok 74 - decimal((-1) * (1))
> -ok 75 - decimal_round((-1) * (1), 15)
> -ok 76 - decimal(-1) * decimal(1) == (-1) * (1)
> -ok 77 - decimal(-1) / decimal(1)
> -ok 78 - decimal((-1) / (1))
> -ok 79 - decimal_round((-1)/(1), 15)
> -ok 80 - decimal(-1) / decimal(1) == (-1) / (1)
> -ok 81 - decimal(INT_MIN)
> -ok 82 - decimal(INT_MAX)
> -ok 83 - decimal(INT_MIN) + decimal(INT_MAX)
> -ok 84 - decimal((INT_MIN) + (INT_MAX))
> -ok 85 - decimal(INT_MIN) + decimal(INT_MAX) == (INT_MIN) + (INT_MAX)
> -ok 86 - decimal(INT_MIN) - decimal(INT_MAX)
> -ok 87 - decimal((INT_MIN) - (INT_MAX))
> -ok 88 - decimal(INT_MIN) - decimal(INT_MAX) == (INT_MIN) - (INT_MAX)
> -ok 89 - decimal(INT_MIN) * decimal(INT_MAX)
> -ok 90 - decimal((INT_MIN) * (INT_MAX))
> -ok 91 - decimal_round((INT_MIN) * (INT_MAX), 15)
> -ok 92 - decimal(INT_MIN) * decimal(INT_MAX) == (INT_MIN) * (INT_MAX)
> -ok 93 - decimal(INT_MIN) / decimal(INT_MAX)
> -ok 94 - decimal((INT_MIN) / (INT_MAX))
> -ok 95 - decimal_round((INT_MIN)/(INT_MAX), 15)
> -ok 96 - decimal(INT_MIN) / decimal(INT_MAX) == (INT_MIN) / (INT_MAX)
> -ok 97 - decimal(-314)
> -ok 98 - decimal(-271)
> -ok 99 - decimal(-314) + decimal(-271)
> -ok 100 - decimal((-314) + (-271))
> -ok 101 - decimal(-314) + decimal(-271) == (-314) + (-271)
> -ok 102 - decimal(-314) - decimal(-271)
> -ok 103 - decimal((-314) - (-271))
> -ok 104 - decimal(-314) - decimal(-271) == (-314) - (-271)
> -ok 105 - decimal(-314) * decimal(-271)
> -ok 106 - decimal((-314) * (-271))
> -ok 107 - decimal_round((-314) * (-271), 15)
> -ok 108 - decimal(-314) * decimal(-271) == (-314) * (-271)
> -ok 109 - decimal(-314) / decimal(-271)
> -ok 110 - decimal((-314) / (-271))
> -ok 111 - decimal_round((-314)/(-271), 15)
> -ok 112 - decimal(-314) / decimal(-271) == (-314) / (-271)
> -ok 113 - decimal(-159615516)
> -ok 114 - decimal(172916921)
> -ok 115 - decimal(-159615516) + decimal(172916921)
> -ok 116 - decimal((-159615516) + (172916921))
> -ok 117 - decimal(-159615516) + decimal(172916921) == (-159615516) + (172916921)
> -ok 118 - decimal(-159615516) - decimal(172916921)
> -ok 119 - decimal((-159615516) - (172916921))
> -ok 120 - decimal(-159615516) - decimal(172916921) == (-159615516) - (172916921)
> -ok 121 - decimal(-159615516) * decimal(172916921)
> -ok 122 - decimal((-159615516) * (172916921))
> -ok 123 - decimal_round((-159615516) * (172916921), 15)
> -ok 124 - decimal(-159615516) * decimal(172916921) == (-159615516) * (172916921)
> -ok 125 - decimal(-159615516) / decimal(172916921)
> -ok 126 - decimal((-159615516) / (172916921))
> -ok 127 - decimal_round((-159615516)/(172916921), 15)
> -ok 128 - decimal(-159615516) / decimal(172916921) == (-159615516) / (172916921)
> -ok 129 - decimal(1.1)
> -ok 130 - decimal(2.3)
> -ok 131 - decimal(1.1) + decimal(2.3)
> -ok 132 - decimal((1.1) + (2.3))
> -ok 133 - decimal(1.1) + decimal(2.3) == (1.1) + (2.3)
> -ok 134 - decimal(1.1) - decimal(2.3)
> -ok 135 - decimal((1.1) - (2.3))
> -ok 136 - decimal(1.1) - decimal(2.3) == (1.1) - (2.3)
> -ok 137 - decimal(1.1) * decimal(2.3)
> -ok 138 - decimal((1.1) * (2.3))
> -ok 139 - decimal_round((1.1) * (2.3), 15)
> -ok 140 - decimal(1.1) * decimal(2.3) == (1.1) * (2.3)
> -ok 141 - decimal(1.1) / decimal(2.3)
> -ok 142 - decimal((1.1) / (2.3))
> -ok 143 - decimal_round((1.1)/(2.3), 15)
> -ok 144 - decimal(1.1) / decimal(2.3) == (1.1) / (2.3)
> -ok 145 - decimal(1e10)
> -ok 146 - decimal(1e10)
> -ok 147 - decimal(1e10) + decimal(1e10)
> -ok 148 - decimal((1e10) + (1e10))
> -ok 149 - decimal(1e10) + decimal(1e10) == (1e10) + (1e10)
> -ok 150 - decimal(1e10) - decimal(1e10)
> -ok 151 - decimal((1e10) - (1e10))
> -ok 152 - decimal(1e10) - decimal(1e10) == (1e10) - (1e10)
> -ok 153 - decimal(1e10) * decimal(1e10)
> -ok 154 - decimal((1e10) * (1e10))
> -ok 155 - decimal_round((1e10) * (1e10), 15)
> -ok 156 - decimal(1e10) * decimal(1e10) == (1e10) * (1e10)
> -ok 157 - decimal(1e10) / decimal(1e10)
> -ok 158 - decimal((1e10) / (1e10))
> -ok 159 - decimal_round((1e10)/(1e10), 15)
> -ok 160 - decimal(1e10) / decimal(1e10) == (1e10) / (1e10)
> -ok 161 - decimal(1.23456789)
> -ok 162 - decimal(4.567890123)
> -ok 163 - decimal(1.23456789) + decimal(4.567890123)
> -ok 164 - decimal((1.23456789) + (4.567890123))
> -ok 165 - decimal(1.23456789) + decimal(4.567890123) == (1.23456789) + (4.567890123)
> -ok 166 - decimal(1.23456789) - decimal(4.567890123)
> -ok 167 - decimal((1.23456789) - (4.567890123))
> -ok 168 - decimal(1.23456789) - decimal(4.567890123) == (1.23456789) - (4.567890123)
> -ok 169 - decimal(1.23456789) * decimal(4.567890123)
> -ok 170 - decimal((1.23456789) * (4.567890123))
> -ok 171 - decimal_round((1.23456789) * (4.567890123), 15)
> -ok 172 - decimal(1.23456789) * decimal(4.567890123) == (1.23456789) * (4.567890123)
> -ok 173 - decimal(1.23456789) / decimal(4.567890123)
> -ok 174 - decimal((1.23456789) / (4.567890123))
> -ok 175 - decimal_round((1.23456789)/(4.567890123), 15)
> -ok 176 - decimal(1.23456789) / decimal(4.567890123) == (1.23456789) / (4.567890123)
> -ok 177 - decimal_from_string(1e-38)
> -ok 178 - decimal_from_string(1e-38)
> -ok 179 - decimal_from_string(2e-38)
> -ok 180 - decimal_add(1e-38, 1e-38)
> -ok 181 - decimal_compare(2e-38)
> -ok 182 - decimal_from_string(-1e-38)
> -ok 183 - decimal_from_string(1e-38)
> -ok 184 - decimal_from_string(0)
> -ok 185 - decimal_add(-1e-38, 1e-38)
> -ok 186 - decimal_compare(0)
> -ok 187 - decimal_from_string(1e-39)
> -ok 188 - decimal_from_string(0)
> -ok 189 - decimal_from_string(0)
> -ok 190 - decimal_add(1e-39, 0)
> -ok 191 - decimal_compare(0)
> -ok 192 - decimal_from_string(1e-39)
> -ok 193 - decimal_from_string(1e-38)
> -ok 194 - decimal_from_string(1e-38)
> -ok 195 - decimal_add(1e-39, 1e-38)
> -ok 196 - decimal_compare(1e-38)
> -ok 197 - decimal_from_string(1e-19)
> -ok 198 - decimal_from_string(1e-19)
> -ok 199 - decimal_from_string(1e-38)
> -ok 200 - decimal_mul(1e-19, 1e-19)
> -ok 201 - decimal_compare(1e-38)
> -ok 202 - decimal_from_string(1e37)
> -ok 203 - decimal_from_string(0)
> -ok 204 - decimal_from_string(1e37)
> -ok 205 - decimal_add(1e37, 0)
> -ok 206 - decimal_compare(1e37)
> -ok 207 - decimal_from_string(1e18)
> -ok 208 - decimal_from_string(1e18)
> -ok 209 - decimal_from_string(1e36)
> -ok 210 - decimal_mul(1e18, 1e18)
> -ok 211 - decimal_compare(1e36)
> -ok 212 - decimal_from_string(10)
> -ok 213 - decimal_from_string(2)
> -ok 214 - decimal_from_string(100)
> -ok 215 - decimal_pow(10, 2)
> -ok 216 - decimal_compare(100)
> -ok 217 - decimal_from_string(2)
> -ok 218 - decimal_from_string(10)
> -ok 219 - decimal_from_string(1024)
> -ok 220 - decimal_pow(2, 10)
> -ok 221 - decimal_compare(1024)
> -ok 222 - decimal_from_string(100)
> -ok 223 - decimal_from_string(0.5)
> -ok 224 - decimal_from_string(10)
> -ok 225 - decimal_pow(100, 0.5)
> -ok 226 - decimal_compare(10)
> -ok 227 - decimal_from_string(100)
> -ok 228 - decimal_from_string(2)
> -ok 229 - decimal_log10(100)
> -ok 230 - decimal_compare(2)
> -ok 231 - decimal_from_string(10)
> -ok 232 - decimal_from_string(2.3)
> -ok 233 - decimal_ln(10)
> -ok 234 - decimal_compare(2.3)
> -ok 235 - decimal_from_string(1.1)
> -ok 236 - decimal_from_string(0.1)
> -ok 237 - decimal_ln(1.1)
> -ok 238 - decimal_compare(0.1)
> -ok 239 - decimal_from_string(1.0000000000000000000000000000000000001)
> -ok 240 - decimal_from_string(0.0000000000000000000000000000000000001)
> -ok 241 - decimal_ln(1.0000000000000000000000000000000000001)
> -ok 242 - decimal_compare(0.0000000000000000000000000000000000001)
> -ok 243 - decimal_from_string(2)
> -ok 244 - decimal_from_string(7.39)
> -ok 245 - decimal_exp(2)
> -ok 246 - decimal_compare(7.39)
> -ok 247 - decimal_from_string(100)
> -ok 248 - decimal_from_string(10)
> -ok 249 - decimal_sqrt(100)
> -ok 250 - decimal_compare(10)
> -ok 251 - decimal construction from 2e38 failure
> -ok 252 - decimal construction from "1e38" failure
> -ok 253 - decimal construction from "100000000000000000000000000000000000000" failure
> -ok 254 - decimal construction from "inf" failure
> -ok 255 - decimal construction from "NaN" failure
> -ok 256 - decimal construction from "a random string" failure
> -ok 257 - decimal construction from LONG_MIN success
> -ok 258 - decimal construction from LONG_MAX success
> -ok 259 - decimal construction from ULONG_MAX success
> -ok 260 - decimal_from_string(9e37)
> -ok 261 - decimal_from_string(1e37)
> -ok 262 - decimal_add(9e37, 1e37) - overflow
> -ok 263 - decimal_from_string(1e19)
> -ok 264 - decimal_from_string(1e19)
> -ok 265 - decimal_mul(1e19, 1e19) - overflow
> -ok 266 - decimal_from_string(1e19)
> -ok 267 - decimal_from_string(1e-19)
> -ok 268 - decimal_div(1e19, 1e-19) - overflow
> -ok 269 - decimal_from_string(0)
> -ok 270 - decimal_ln(0) - error on wrong operands.
> -ok 271 - decimal_from_string(-1)
> -ok 272 - decimal_ln(-1) - error on wrong operands.
> -ok 273 - decimal_from_string(0)
> -ok 274 - decimal_log10(0) - error on wrong operands.
> -ok 275 - decimal_from_string(-1)
> -ok 276 - decimal_log10(-1) - error on wrong operands.
> -ok 277 - decimal_from_string(-10)
> -ok 278 - decimal_sqrt(-10) - error on wrong operands.
> -    1..66
> -    ok 1 - Conversion of 18446744073709551615 to decimal and back to uint64 successful
> -    ok 2 - Conversion back to uint64 correct
> -    ok 3 - Conversion of 9223372036854775807 to decimal and back to int64 successful
> -    ok 4 - Conversion back to int64 correct
> -    ok 5 - Conversion of -9223372036854775808 to decimal and back to int64 successful
> -    ok 6 - Conversion back to int64 correct
> -    ok 7 - Conversion of 0 to decimal and back to uint64 successful
> -    ok 8 - Conversion back to uint64 correct
> -    ok 9 - Conversion of 0 to decimal and back to int64 successful
> -    ok 10 - Conversion back to int64 correct
> -    ok 11 - Conversion of -1 to decimal and back to int64 successful
> -    ok 12 - Conversion back to int64 correct
> -    ok 13 - Conversion of 117495185182863386 to decimal and back to uint64 successful
> -    ok 14 - Conversion back to uint64 correct
> -    ok 15 - Conversion of 58747592591431693 to decimal and back to int64 successful
> -    ok 16 - Conversion back to int64 correct
> -    ok 17 - Conversion of -58747592591431693 to decimal and back to int64 successful
> -    ok 18 - Conversion back to int64 correct
> -    ok 19 - Conversion of 778113809158035 to decimal and back to uint64 successful
> -    ok 20 - Conversion back to uint64 correct
> -    ok 21 - Conversion of 389056904579017 to decimal and back to int64 successful
> -    ok 22 - Conversion back to int64 correct
> -    ok 23 - Conversion of -389056904579017 to decimal and back to int64 successful
> -    ok 24 - Conversion back to int64 correct
> -    ok 25 - Conversion of 5222240329919 to decimal and back to uint64 successful
> -    ok 26 - Conversion back to uint64 correct
> -    ok 27 - Conversion of 2611120164959 to decimal and back to int64 successful
> -    ok 28 - Conversion back to int64 correct
> -    ok 29 - Conversion of -2611120164959 to decimal and back to int64 successful
> -    ok 30 - Conversion back to int64 correct
> -    ok 31 - Conversion of 37570074315 to decimal and back to uint64 successful
> -    ok 32 - Conversion back to uint64 correct
> -    ok 33 - Conversion of 18785037157 to decimal and back to int64 successful
> -    ok 34 - Conversion back to int64 correct
> -    ok 35 - Conversion of -18785037157 to decimal and back to int64 successful
> -    ok 36 - Conversion back to int64 correct
> -    ok 37 - Conversion of 274234119 to decimal and back to uint64 successful
> -    ok 38 - Conversion back to uint64 correct
> -    ok 39 - Conversion of 137996015 to decimal and back to int64 successful
> -    ok 40 - Conversion back to int64 correct
> -    ok 41 - Conversion of -137996015 to decimal and back to int64 successful
> -    ok 42 - Conversion back to int64 correct
> -    ok 43 - Conversion of 4294967295 to decimal and back to uint64 successful
> -    ok 44 - Conversion back to uint64 correct
> -    ok 45 - Conversion of 2147483647 to decimal and back to int64 successful
> -    ok 46 - Conversion back to int64 correct
> -    ok 47 - Conversion of -2147483648 to decimal and back to int64 successful
> -    ok 48 - Conversion back to int64 correct
> -    ok 49 - Conversion of 27356479 to decimal and back to uint64 successful
> -    ok 50 - Conversion back to uint64 correct
> -    ok 51 - Conversion of 13678239 to decimal and back to int64 successful
> -    ok 52 - Conversion back to int64 correct
> -    ok 53 - Conversion of -13678239 to decimal and back to int64 successful
> -    ok 54 - Conversion back to int64 correct
> -    ok 55 - Conversion of 181168 to decimal and back to uint64 successful
> -    ok 56 - Conversion back to uint64 correct
> -    ok 57 - Conversion of 90584 to decimal and back to int64 successful
> -    ok 58 - Conversion back to int64 correct
> -    ok 59 - Conversion of -90584 to decimal and back to int64 successful
> -    ok 60 - Conversion back to int64 correct
> -    ok 61 - Conversion of 1215 to decimal and back to uint64 successful
> -    ok 62 - Conversion back to uint64 correct
> -    ok 63 - Conversion of 607 to decimal and back to int64 successful
> -    ok 64 - Conversion back to int64 correct
> -    ok 65 - Conversion of -607 to decimal and back to int64 successful
> -    ok 66 - Conversion back to int64 correct
> -ok 279 - subtests
> -    1..151
> -    ok 1 - decimal_len(0)
> -    ok 2 - decimal_len(0) == len(decimal_pack(0)
> -    ok 3 - decimal_unpack(decimal_pack(0))
> -    ok 4 - decimal_unpack(decimal_pack(0)) len
> -    ok 5 - decimal_unpack(decimal_pack(0)) value
> -    ok 6 - decimal_unpack(decimal_pack(0)) scale
> -    ok 7 - decimal_unpack(decimal_pack(0)) precision
> -    ok 8 - str(decimal_unpack(decimal_pack(0)) == 0
> -    ok 9 - decimal_len(-0)
> -    ok 10 - decimal_len(-0) == len(decimal_pack(-0)
> -    ok 11 - decimal_unpack(decimal_pack(-0))
> -    ok 12 - decimal_unpack(decimal_pack(-0)) len
> -    ok 13 - decimal_unpack(decimal_pack(-0)) value
> -    ok 14 - decimal_unpack(decimal_pack(-0)) scale
> -    ok 15 - decimal_unpack(decimal_pack(-0)) precision
> -    ok 16 - str(decimal_unpack(decimal_pack(-0)) == -0
> -    ok 17 - decimal_len(1)
> -    ok 18 - decimal_len(1) == len(decimal_pack(1)
> -    ok 19 - decimal_unpack(decimal_pack(1))
> -    ok 20 - decimal_unpack(decimal_pack(1)) len
> -    ok 21 - decimal_unpack(decimal_pack(1)) value
> -    ok 22 - decimal_unpack(decimal_pack(1)) scale
> -    ok 23 - decimal_unpack(decimal_pack(1)) precision
> -    ok 24 - str(decimal_unpack(decimal_pack(1)) == 1
> -    ok 25 - decimal_len(-1)
> -    ok 26 - decimal_len(-1) == len(decimal_pack(-1)
> -    ok 27 - decimal_unpack(decimal_pack(-1))
> -    ok 28 - decimal_unpack(decimal_pack(-1)) len
> -    ok 29 - decimal_unpack(decimal_pack(-1)) value
> -    ok 30 - decimal_unpack(decimal_pack(-1)) scale
> -    ok 31 - decimal_unpack(decimal_pack(-1)) precision
> -    ok 32 - str(decimal_unpack(decimal_pack(-1)) == -1
> -    ok 33 - decimal_len(0.1)
> -    ok 34 - decimal_len(0.1) == len(decimal_pack(0.1)
> -    ok 35 - decimal_unpack(decimal_pack(0.1))
> -    ok 36 - decimal_unpack(decimal_pack(0.1)) len
> -    ok 37 - decimal_unpack(decimal_pack(0.1)) value
> -    ok 38 - decimal_unpack(decimal_pack(0.1)) scale
> -    ok 39 - decimal_unpack(decimal_pack(0.1)) precision
> -    ok 40 - str(decimal_unpack(decimal_pack(0.1)) == 0.1
> -    ok 41 - decimal_len(-0.1)
> -    ok 42 - decimal_len(-0.1) == len(decimal_pack(-0.1)
> -    ok 43 - decimal_unpack(decimal_pack(-0.1))
> -    ok 44 - decimal_unpack(decimal_pack(-0.1)) len
> -    ok 45 - decimal_unpack(decimal_pack(-0.1)) value
> -    ok 46 - decimal_unpack(decimal_pack(-0.1)) scale
> -    ok 47 - decimal_unpack(decimal_pack(-0.1)) precision
> -    ok 48 - str(decimal_unpack(decimal_pack(-0.1)) == -0.1
> -    ok 49 - decimal_len(2.718281828459045)
> -    ok 50 - decimal_len(2.718281828459045) == len(decimal_pack(2.718281828459045)
> -    ok 51 - decimal_unpack(decimal_pack(2.718281828459045))
> -    ok 52 - decimal_unpack(decimal_pack(2.718281828459045)) len
> -    ok 53 - decimal_unpack(decimal_pack(2.718281828459045)) value
> -    ok 54 - decimal_unpack(decimal_pack(2.718281828459045)) scale
> -    ok 55 - decimal_unpack(decimal_pack(2.718281828459045)) precision
> -    ok 56 - str(decimal_unpack(decimal_pack(2.718281828459045)) == 2.718281828459045
> -    ok 57 - decimal_len(-2.718281828459045)
> -    ok 58 - decimal_len(-2.718281828459045) == len(decimal_pack(-2.718281828459045)
> -    ok 59 - decimal_unpack(decimal_pack(-2.718281828459045))
> -    ok 60 - decimal_unpack(decimal_pack(-2.718281828459045)) len
> -    ok 61 - decimal_unpack(decimal_pack(-2.718281828459045)) value
> -    ok 62 - decimal_unpack(decimal_pack(-2.718281828459045)) scale
> -    ok 63 - decimal_unpack(decimal_pack(-2.718281828459045)) precision
> -    ok 64 - str(decimal_unpack(decimal_pack(-2.718281828459045)) == -2.718281828459045
> -    ok 65 - decimal_len(3.141592653589793)
> -    ok 66 - decimal_len(3.141592653589793) == len(decimal_pack(3.141592653589793)
> -    ok 67 - decimal_unpack(decimal_pack(3.141592653589793))
> -    ok 68 - decimal_unpack(decimal_pack(3.141592653589793)) len
> -    ok 69 - decimal_unpack(decimal_pack(3.141592653589793)) value
> -    ok 70 - decimal_unpack(decimal_pack(3.141592653589793)) scale
> -    ok 71 - decimal_unpack(decimal_pack(3.141592653589793)) precision
> -    ok 72 - str(decimal_unpack(decimal_pack(3.141592653589793)) == 3.141592653589793
> -    ok 73 - decimal_len(-3.141592653589793)
> -    ok 74 - decimal_len(-3.141592653589793) == len(decimal_pack(-3.141592653589793)
> -    ok 75 - decimal_unpack(decimal_pack(-3.141592653589793))
> -    ok 76 - decimal_unpack(decimal_pack(-3.141592653589793)) len
> -    ok 77 - decimal_unpack(decimal_pack(-3.141592653589793)) value
> -    ok 78 - decimal_unpack(decimal_pack(-3.141592653589793)) scale
> -    ok 79 - decimal_unpack(decimal_pack(-3.141592653589793)) precision
> -    ok 80 - str(decimal_unpack(decimal_pack(-3.141592653589793)) == -3.141592653589793
> -    ok 81 - decimal_len(1234567891234567890.0987654321987654321)
> -    ok 82 - decimal_len(1234567891234567890.0987654321987654321) == len(decimal_pack(1234567891234567890.0987654321987654321)
> -    ok 83 - decimal_unpack(decimal_pack(1234567891234567890.0987654321987654321))
> -    ok 84 - decimal_unpack(decimal_pack(1234567891234567890.0987654321987654321)) len
> -    ok 85 - decimal_unpack(decimal_pack(1234567891234567890.0987654321987654321)) value
> -    ok 86 - decimal_unpack(decimal_pack(1234567891234567890.0987654321987654321)) scale
> -    ok 87 - decimal_unpack(decimal_pack(1234567891234567890.0987654321987654321)) precision
> -    ok 88 - str(decimal_unpack(decimal_pack(1234567891234567890.0987654321987654321)) == 1234567891234567890.0987654321987654321
> -    ok 89 - decimal_len(-1234567891234567890.0987654321987654321)
> -    ok 90 - decimal_len(-1234567891234567890.0987654321987654321) == len(decimal_pack(-1234567891234567890.0987654321987654321)
> -    ok 91 - decimal_unpack(decimal_pack(-1234567891234567890.0987654321987654321))
> -    ok 92 - decimal_unpack(decimal_pack(-1234567891234567890.0987654321987654321)) len
> -    ok 93 - decimal_unpack(decimal_pack(-1234567891234567890.0987654321987654321)) value
> -    ok 94 - decimal_unpack(decimal_pack(-1234567891234567890.0987654321987654321)) scale
> -    ok 95 - decimal_unpack(decimal_pack(-1234567891234567890.0987654321987654321)) precision
> -    ok 96 - str(decimal_unpack(decimal_pack(-1234567891234567890.0987654321987654321)) == -1234567891234567890.0987654321987654321
> -    ok 97 - decimal_len(0.0000000000000000000000000000000000001)
> -    ok 98 - decimal_len(0.0000000000000000000000000000000000001) == len(decimal_pack(0.0000000000000000000000000000000000001)
> -    ok 99 - decimal_unpack(decimal_pack(0.0000000000000000000000000000000000001))
> -    ok 100 - decimal_unpack(decimal_pack(0.0000000000000000000000000000000000001)) len
> -    ok 101 - decimal_unpack(decimal_pack(0.0000000000000000000000000000000000001)) value
> -    ok 102 - decimal_unpack(decimal_pack(0.0000000000000000000000000000000000001)) scale
> -    ok 103 - decimal_unpack(decimal_pack(0.0000000000000000000000000000000000001)) precision
> -    ok 104 - str(decimal_unpack(decimal_pack(0.0000000000000000000000000000000000001)) == 0.0000000000000000000000000000000000001
> -    ok 105 - decimal_len(-0.0000000000000000000000000000000000001)
> -    ok 106 - decimal_len(-0.0000000000000000000000000000000000001) == len(decimal_pack(-0.0000000000000000000000000000000000001)
> -    ok 107 - decimal_unpack(decimal_pack(-0.0000000000000000000000000000000000001))
> -    ok 108 - decimal_unpack(decimal_pack(-0.0000000000000000000000000000000000001)) len
> -    ok 109 - decimal_unpack(decimal_pack(-0.0000000000000000000000000000000000001)) value
> -    ok 110 - decimal_unpack(decimal_pack(-0.0000000000000000000000000000000000001)) scale
> -    ok 111 - decimal_unpack(decimal_pack(-0.0000000000000000000000000000000000001)) precision
> -    ok 112 - str(decimal_unpack(decimal_pack(-0.0000000000000000000000000000000000001)) == -0.0000000000000000000000000000000000001
> -    ok 113 - decimal_len(0.00000000000000000000000000000000000001)
> -    ok 114 - decimal_len(0.00000000000000000000000000000000000001) == len(decimal_pack(0.00000000000000000000000000000000000001)
> -    ok 115 - decimal_unpack(decimal_pack(0.00000000000000000000000000000000000001))
> -    ok 116 - decimal_unpack(decimal_pack(0.00000000000000000000000000000000000001)) len
> -    ok 117 - decimal_unpack(decimal_pack(0.00000000000000000000000000000000000001)) value
> -    ok 118 - decimal_unpack(decimal_pack(0.00000000000000000000000000000000000001)) scale
> -    ok 119 - decimal_unpack(decimal_pack(0.00000000000000000000000000000000000001)) precision
> -    ok 120 - str(decimal_unpack(decimal_pack(0.00000000000000000000000000000000000001)) == 0.00000000000000000000000000000000000001
> -    ok 121 - decimal_len(-0.00000000000000000000000000000000000001)
> -    ok 122 - decimal_len(-0.00000000000000000000000000000000000001) == len(decimal_pack(-0.00000000000000000000000000000000000001)
> -    ok 123 - decimal_unpack(decimal_pack(-0.00000000000000000000000000000000000001))
> -    ok 124 - decimal_unpack(decimal_pack(-0.00000000000000000000000000000000000001)) len
> -    ok 125 - decimal_unpack(decimal_pack(-0.00000000000000000000000000000000000001)) value
> -    ok 126 - decimal_unpack(decimal_pack(-0.00000000000000000000000000000000000001)) scale
> -    ok 127 - decimal_unpack(decimal_pack(-0.00000000000000000000000000000000000001)) precision
> -    ok 128 - str(decimal_unpack(decimal_pack(-0.00000000000000000000000000000000000001)) == -0.00000000000000000000000000000000000001
> -    ok 129 - decimal_len(99999999999999999999999999999999999999)
> -    ok 130 - decimal_len(99999999999999999999999999999999999999) == len(decimal_pack(99999999999999999999999999999999999999)
> -    ok 131 - decimal_unpack(decimal_pack(99999999999999999999999999999999999999))
> -    ok 132 - decimal_unpack(decimal_pack(99999999999999999999999999999999999999)) len
> -    ok 133 - decimal_unpack(decimal_pack(99999999999999999999999999999999999999)) value
> -    ok 134 - decimal_unpack(decimal_pack(99999999999999999999999999999999999999)) scale
> -    ok 135 - decimal_unpack(decimal_pack(99999999999999999999999999999999999999)) precision
> -    ok 136 - str(decimal_unpack(decimal_pack(99999999999999999999999999999999999999)) == 99999999999999999999999999999999999999
> -    ok 137 - decimal_len(-99999999999999999999999999999999999999)
> -    ok 138 - decimal_len(-99999999999999999999999999999999999999) == len(decimal_pack(-99999999999999999999999999999999999999)
> -    ok 139 - decimal_unpack(decimal_pack(-99999999999999999999999999999999999999))
> -    ok 140 - decimal_unpack(decimal_pack(-99999999999999999999999999999999999999)) len
> -    ok 141 - decimal_unpack(decimal_pack(-99999999999999999999999999999999999999)) value
> -    ok 142 - decimal_unpack(decimal_pack(-99999999999999999999999999999999999999)) scale
> -    ok 143 - decimal_unpack(decimal_pack(-99999999999999999999999999999999999999)) precision
> -    ok 144 - str(decimal_unpack(decimal_pack(-99999999999999999999999999999999999999)) == -99999999999999999999999999999999999999
> -    ok 145 - decimal_len() is small for positive exponent decimal
> -    ok 146 - positive exponent decimal length
> -    ok 147 - decimal_unpack() of a positive exponent decimal
> -    ok 148 - decimal_unpack uses every byte packed by decimal_pack
> -    ok 149 - positive exponent number is packed/unpacked correctly
> -    ok 150 - unpack malformed decimal fails
> -    ok 151 - decode malformed decimal preserves buffer position
> -ok 280 - subtests
> -    1..198
> -    ok 1 - mp_sizeof_decimal(0)
> -    ok 2 - mp_sizeof_decimal(0) == len(mp_encode_decimal(0))
> -    ok 3 - mp_next(mp_encode(0))
> -    ok 4 - mp_decode(mp_encode(0) len
> -    ok 5 - mp_decode(mp_encode(0)) value
> -    ok 6 - mp_decode(mp_encode(0)) scale
> -    ok 7 - str(mp_decode(mp_encode(0))) == 0
> -    ok 8 - mp_ext_type is MP_DECIMAL
> -    ok 9 - decimal_unpack() after mp_decode_extl()
> -    ok 10 - decimal_unpack() after mp_decode_extl() value
> -    ok 11 - decimal_unpack() after mp_decode_extl() len
> -    ok 12 - mp_sizeof_decimal(-0)
> -    ok 13 - mp_sizeof_decimal(-0) == len(mp_encode_decimal(-0))
> -    ok 14 - mp_next(mp_encode(-0))
> -    ok 15 - mp_decode(mp_encode(-0) len
> -    ok 16 - mp_decode(mp_encode(-0)) value
> -    ok 17 - mp_decode(mp_encode(-0)) scale
> -    ok 18 - str(mp_decode(mp_encode(-0))) == -0
> -    ok 19 - mp_ext_type is MP_DECIMAL
> -    ok 20 - decimal_unpack() after mp_decode_extl()
> -    ok 21 - decimal_unpack() after mp_decode_extl() value
> -    ok 22 - decimal_unpack() after mp_decode_extl() len
> -    ok 23 - mp_sizeof_decimal(1)
> -    ok 24 - mp_sizeof_decimal(1) == len(mp_encode_decimal(1))
> -    ok 25 - mp_next(mp_encode(1))
> -    ok 26 - mp_decode(mp_encode(1) len
> -    ok 27 - mp_decode(mp_encode(1)) value
> -    ok 28 - mp_decode(mp_encode(1)) scale
> -    ok 29 - str(mp_decode(mp_encode(1))) == 1
> -    ok 30 - mp_ext_type is MP_DECIMAL
> -    ok 31 - decimal_unpack() after mp_decode_extl()
> -    ok 32 - decimal_unpack() after mp_decode_extl() value
> -    ok 33 - decimal_unpack() after mp_decode_extl() len
> -    ok 34 - mp_sizeof_decimal(-1)
> -    ok 35 - mp_sizeof_decimal(-1) == len(mp_encode_decimal(-1))
> -    ok 36 - mp_next(mp_encode(-1))
> -    ok 37 - mp_decode(mp_encode(-1) len
> -    ok 38 - mp_decode(mp_encode(-1)) value
> -    ok 39 - mp_decode(mp_encode(-1)) scale
> -    ok 40 - str(mp_decode(mp_encode(-1))) == -1
> -    ok 41 - mp_ext_type is MP_DECIMAL
> -    ok 42 - decimal_unpack() after mp_decode_extl()
> -    ok 43 - decimal_unpack() after mp_decode_extl() value
> -    ok 44 - decimal_unpack() after mp_decode_extl() len
> -    ok 45 - mp_sizeof_decimal(0.1)
> -    ok 46 - mp_sizeof_decimal(0.1) == len(mp_encode_decimal(0.1))
> -    ok 47 - mp_next(mp_encode(0.1))
> -    ok 48 - mp_decode(mp_encode(0.1) len
> -    ok 49 - mp_decode(mp_encode(0.1)) value
> -    ok 50 - mp_decode(mp_encode(0.1)) scale
> -    ok 51 - str(mp_decode(mp_encode(0.1))) == 0.1
> -    ok 52 - mp_ext_type is MP_DECIMAL
> -    ok 53 - decimal_unpack() after mp_decode_extl()
> -    ok 54 - decimal_unpack() after mp_decode_extl() value
> -    ok 55 - decimal_unpack() after mp_decode_extl() len
> -    ok 56 - mp_sizeof_decimal(-0.1)
> -    ok 57 - mp_sizeof_decimal(-0.1) == len(mp_encode_decimal(-0.1))
> -    ok 58 - mp_next(mp_encode(-0.1))
> -    ok 59 - mp_decode(mp_encode(-0.1) len
> -    ok 60 - mp_decode(mp_encode(-0.1)) value
> -    ok 61 - mp_decode(mp_encode(-0.1)) scale
> -    ok 62 - str(mp_decode(mp_encode(-0.1))) == -0.1
> -    ok 63 - mp_ext_type is MP_DECIMAL
> -    ok 64 - decimal_unpack() after mp_decode_extl()
> -    ok 65 - decimal_unpack() after mp_decode_extl() value
> -    ok 66 - decimal_unpack() after mp_decode_extl() len
> -    ok 67 - mp_sizeof_decimal(2.718281828459045)
> -    ok 68 - mp_sizeof_decimal(2.718281828459045) == len(mp_encode_decimal(2.718281828459045))
> -    ok 69 - mp_next(mp_encode(2.718281828459045))
> -    ok 70 - mp_decode(mp_encode(2.718281828459045) len
> -    ok 71 - mp_decode(mp_encode(2.718281828459045)) value
> -    ok 72 - mp_decode(mp_encode(2.718281828459045)) scale
> -    ok 73 - str(mp_decode(mp_encode(2.718281828459045))) == 2.718281828459045
> -    ok 74 - mp_ext_type is MP_DECIMAL
> -    ok 75 - decimal_unpack() after mp_decode_extl()
> -    ok 76 - decimal_unpack() after mp_decode_extl() value
> -    ok 77 - decimal_unpack() after mp_decode_extl() len
> -    ok 78 - mp_sizeof_decimal(-2.718281828459045)
> -    ok 79 - mp_sizeof_decimal(-2.718281828459045) == len(mp_encode_decimal(-2.718281828459045))
> -    ok 80 - mp_next(mp_encode(-2.718281828459045))
> -    ok 81 - mp_decode(mp_encode(-2.718281828459045) len
> -    ok 82 - mp_decode(mp_encode(-2.718281828459045)) value
> -    ok 83 - mp_decode(mp_encode(-2.718281828459045)) scale
> -    ok 84 - str(mp_decode(mp_encode(-2.718281828459045))) == -2.718281828459045
> -    ok 85 - mp_ext_type is MP_DECIMAL
> -    ok 86 - decimal_unpack() after mp_decode_extl()
> -    ok 87 - decimal_unpack() after mp_decode_extl() value
> -    ok 88 - decimal_unpack() after mp_decode_extl() len
> -    ok 89 - mp_sizeof_decimal(3.141592653589793)
> -    ok 90 - mp_sizeof_decimal(3.141592653589793) == len(mp_encode_decimal(3.141592653589793))
> -    ok 91 - mp_next(mp_encode(3.141592653589793))
> -    ok 92 - mp_decode(mp_encode(3.141592653589793) len
> -    ok 93 - mp_decode(mp_encode(3.141592653589793)) value
> -    ok 94 - mp_decode(mp_encode(3.141592653589793)) scale
> -    ok 95 - str(mp_decode(mp_encode(3.141592653589793))) == 3.141592653589793
> -    ok 96 - mp_ext_type is MP_DECIMAL
> -    ok 97 - decimal_unpack() after mp_decode_extl()
> -    ok 98 - decimal_unpack() after mp_decode_extl() value
> -    ok 99 - decimal_unpack() after mp_decode_extl() len
> -    ok 100 - mp_sizeof_decimal(-3.141592653589793)
> -    ok 101 - mp_sizeof_decimal(-3.141592653589793) == len(mp_encode_decimal(-3.141592653589793))
> -    ok 102 - mp_next(mp_encode(-3.141592653589793))
> -    ok 103 - mp_decode(mp_encode(-3.141592653589793) len
> -    ok 104 - mp_decode(mp_encode(-3.141592653589793)) value
> -    ok 105 - mp_decode(mp_encode(-3.141592653589793)) scale
> -    ok 106 - str(mp_decode(mp_encode(-3.141592653589793))) == -3.141592653589793
> -    ok 107 - mp_ext_type is MP_DECIMAL
> -    ok 108 - decimal_unpack() after mp_decode_extl()
> -    ok 109 - decimal_unpack() after mp_decode_extl() value
> -    ok 110 - decimal_unpack() after mp_decode_extl() len
> -    ok 111 - mp_sizeof_decimal(1234567891234567890.0987654321987654321)
> -    ok 112 - mp_sizeof_decimal(1234567891234567890.0987654321987654321) == len(mp_encode_decimal(1234567891234567890.0987654321987654321))
> -    ok 113 - mp_next(mp_encode(1234567891234567890.0987654321987654321))
> -    ok 114 - mp_decode(mp_encode(1234567891234567890.0987654321987654321) len
> -    ok 115 - mp_decode(mp_encode(1234567891234567890.0987654321987654321)) value
> -    ok 116 - mp_decode(mp_encode(1234567891234567890.0987654321987654321)) scale
> -    ok 117 - str(mp_decode(mp_encode(1234567891234567890.0987654321987654321))) == 1234567891234567890.0987654321987654321
> -    ok 118 - mp_ext_type is MP_DECIMAL
> -    ok 119 - decimal_unpack() after mp_decode_extl()
> -    ok 120 - decimal_unpack() after mp_decode_extl() value
> -    ok 121 - decimal_unpack() after mp_decode_extl() len
> -    ok 122 - mp_sizeof_decimal(-1234567891234567890.0987654321987654321)
> -    ok 123 - mp_sizeof_decimal(-1234567891234567890.0987654321987654321) == len(mp_encode_decimal(-1234567891234567890.0987654321987654321))
> -    ok 124 - mp_next(mp_encode(-1234567891234567890.0987654321987654321))
> -    ok 125 - mp_decode(mp_encode(-1234567891234567890.0987654321987654321) len
> -    ok 126 - mp_decode(mp_encode(-1234567891234567890.0987654321987654321)) value
> -    ok 127 - mp_decode(mp_encode(-1234567891234567890.0987654321987654321)) scale
> -    ok 128 - str(mp_decode(mp_encode(-1234567891234567890.0987654321987654321))) == -1234567891234567890.0987654321987654321
> -    ok 129 - mp_ext_type is MP_DECIMAL
> -    ok 130 - decimal_unpack() after mp_decode_extl()
> -    ok 131 - decimal_unpack() after mp_decode_extl() value
> -    ok 132 - decimal_unpack() after mp_decode_extl() len
> -    ok 133 - mp_sizeof_decimal(0.0000000000000000000000000000000000001)
> -    ok 134 - mp_sizeof_decimal(0.0000000000000000000000000000000000001) == len(mp_encode_decimal(0.0000000000000000000000000000000000001))
> -    ok 135 - mp_next(mp_encode(0.0000000000000000000000000000000000001))
> -    ok 136 - mp_decode(mp_encode(0.0000000000000000000000000000000000001) len
> -    ok 137 - mp_decode(mp_encode(0.0000000000000000000000000000000000001)) value
> -    ok 138 - mp_decode(mp_encode(0.0000000000000000000000000000000000001)) scale
> -    ok 139 - str(mp_decode(mp_encode(0.0000000000000000000000000000000000001))) == 0.0000000000000000000000000000000000001
> -    ok 140 - mp_ext_type is MP_DECIMAL
> -    ok 141 - decimal_unpack() after mp_decode_extl()
> -    ok 142 - decimal_unpack() after mp_decode_extl() value
> -    ok 143 - decimal_unpack() after mp_decode_extl() len
> -    ok 144 - mp_sizeof_decimal(-0.0000000000000000000000000000000000001)
> -    ok 145 - mp_sizeof_decimal(-0.0000000000000000000000000000000000001) == len(mp_encode_decimal(-0.0000000000000000000000000000000000001))
> -    ok 146 - mp_next(mp_encode(-0.0000000000000000000000000000000000001))
> -    ok 147 - mp_decode(mp_encode(-0.0000000000000000000000000000000000001) len
> -    ok 148 - mp_decode(mp_encode(-0.0000000000000000000000000000000000001)) value
> -    ok 149 - mp_decode(mp_encode(-0.0000000000000000000000000000000000001)) scale
> -    ok 150 - str(mp_decode(mp_encode(-0.0000000000000000000000000000000000001))) == -0.0000000000000000000000000000000000001
> -    ok 151 - mp_ext_type is MP_DECIMAL
> -    ok 152 - decimal_unpack() after mp_decode_extl()
> -    ok 153 - decimal_unpack() after mp_decode_extl() value
> -    ok 154 - decimal_unpack() after mp_decode_extl() len
> -    ok 155 - mp_sizeof_decimal(0.00000000000000000000000000000000000001)
> -    ok 156 - mp_sizeof_decimal(0.00000000000000000000000000000000000001) == len(mp_encode_decimal(0.00000000000000000000000000000000000001))
> -    ok 157 - mp_next(mp_encode(0.00000000000000000000000000000000000001))
> -    ok 158 - mp_decode(mp_encode(0.00000000000000000000000000000000000001) len
> -    ok 159 - mp_decode(mp_encode(0.00000000000000000000000000000000000001)) value
> -    ok 160 - mp_decode(mp_encode(0.00000000000000000000000000000000000001)) scale
> -    ok 161 - str(mp_decode(mp_encode(0.00000000000000000000000000000000000001))) == 0.00000000000000000000000000000000000001
> -    ok 162 - mp_ext_type is MP_DECIMAL
> -    ok 163 - decimal_unpack() after mp_decode_extl()
> -    ok 164 - decimal_unpack() after mp_decode_extl() value
> -    ok 165 - decimal_unpack() after mp_decode_extl() len
> -    ok 166 - mp_sizeof_decimal(-0.00000000000000000000000000000000000001)
> -    ok 167 - mp_sizeof_decimal(-0.00000000000000000000000000000000000001) == len(mp_encode_decimal(-0.00000000000000000000000000000000000001))
> -    ok 168 - mp_next(mp_encode(-0.00000000000000000000000000000000000001))
> -    ok 169 - mp_decode(mp_encode(-0.00000000000000000000000000000000000001) len
> -    ok 170 - mp_decode(mp_encode(-0.00000000000000000000000000000000000001)) value
> -    ok 171 - mp_decode(mp_encode(-0.00000000000000000000000000000000000001)) scale
> -    ok 172 - str(mp_decode(mp_encode(-0.00000000000000000000000000000000000001))) == -0.00000000000000000000000000000000000001
> -    ok 173 - mp_ext_type is MP_DECIMAL
> -    ok 174 - decimal_unpack() after mp_decode_extl()
> -    ok 175 - decimal_unpack() after mp_decode_extl() value
> -    ok 176 - decimal_unpack() after mp_decode_extl() len
> -    ok 177 - mp_sizeof_decimal(99999999999999999999999999999999999999)
> -    ok 178 - mp_sizeof_decimal(99999999999999999999999999999999999999) == len(mp_encode_decimal(99999999999999999999999999999999999999))
> -    ok 179 - mp_next(mp_encode(99999999999999999999999999999999999999))
> -    ok 180 - mp_decode(mp_encode(99999999999999999999999999999999999999) len
> -    ok 181 - mp_decode(mp_encode(99999999999999999999999999999999999999)) value
> -    ok 182 - mp_decode(mp_encode(99999999999999999999999999999999999999)) scale
> -    ok 183 - str(mp_decode(mp_encode(99999999999999999999999999999999999999))) == 99999999999999999999999999999999999999
> -    ok 184 - mp_ext_type is MP_DECIMAL
> -    ok 185 - decimal_unpack() after mp_decode_extl()
> -    ok 186 - decimal_unpack() after mp_decode_extl() value
> -    ok 187 - decimal_unpack() after mp_decode_extl() len
> -    ok 188 - mp_sizeof_decimal(-99999999999999999999999999999999999999)
> -    ok 189 - mp_sizeof_decimal(-99999999999999999999999999999999999999) == len(mp_encode_decimal(-99999999999999999999999999999999999999))
> -    ok 190 - mp_next(mp_encode(-99999999999999999999999999999999999999))
> -    ok 191 - mp_decode(mp_encode(-99999999999999999999999999999999999999) len
> -    ok 192 - mp_decode(mp_encode(-99999999999999999999999999999999999999)) value
> -    ok 193 - mp_decode(mp_encode(-99999999999999999999999999999999999999)) scale
> -    ok 194 - str(mp_decode(mp_encode(-99999999999999999999999999999999999999))) == -99999999999999999999999999999999999999
> -    ok 195 - mp_ext_type is MP_DECIMAL
> -    ok 196 - decimal_unpack() after mp_decode_extl()
> -    ok 197 - decimal_unpack() after mp_decode_extl() value
> -    ok 198 - decimal_unpack() after mp_decode_extl() len
> -ok 281 - subtests
> diff --git a/test/unit/fiber.cc b/test/unit/fiber.cc
> index b0dfc9b14..e2c885009 100644
> --- a/test/unit/fiber.cc
> +++ b/test/unit/fiber.cc
> @@ -74,6 +74,7 @@ static void
>  fiber_join_test()
>  {
>  	header();
> +	plan(1);
>  
>  	struct fiber *fiber = fiber_new_xc("join", noop_f);
>  	fiber_set_joinable(fiber, true);
> @@ -98,7 +99,7 @@ fiber_join_test()
>  		note("exception propagated");
>  	}
>  
> -	fputs("#gh-1238: log uncaught errors\n", stderr);
> +	note("log uncaught errors (gh-1238)");
>  	fiber = fiber_new_xc("exception", exception_f);
>  	fiber_wakeup(fiber);
>  
> @@ -123,7 +124,9 @@ fiber_join_test()
>  	note("by this time the fiber should be dead already");
>  	fiber_cancel(fiber);
>  	fiber_join(fiber);
> -
> +	
> +	ok(1, "fiber join test");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -131,6 +134,7 @@ void
>  fiber_stack_test()
>  {
>  	header();
> +	plan(1);
>  
>  	struct fiber *fiber;
>  	struct fiber_attr *fiber_attr;
> @@ -158,6 +162,8 @@ fiber_stack_test()
>  	fiber_sleep(0);
>  	note("big-stack fiber not crashed");
>  
> +	ok(1, "fiber stack test");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -165,11 +171,12 @@ void
>  fiber_name_test()
>  {
>  	header();
> -	note("name of a new fiber: %s.\n", fiber_name(fiber()));
> +	plan(1);
> +	note("name of a new fiber: %s", fiber_name(fiber()));
>  
>  	fiber_set_name(fiber(), "Horace");
>  
> -	note("set new fiber name: %s.\n", fiber_name(fiber()));
> +	note("set new fiber name: %s", fiber_name(fiber()));
>  
>  	char long_name[FIBER_NAME_MAX + 30];
>  	memset(long_name, 'a', sizeof(long_name));
> @@ -177,17 +184,21 @@ fiber_name_test()
>  
>  	fiber_set_name(fiber(), long_name);
>  
> -	note("fiber name is truncated: %s.\n", fiber_name(fiber()));
> +	note("fiber name is truncated: %s", fiber_name(fiber()));
> +	ok(1, "fiber name test");
> +	check_plan();
>  	footer();
>  }
>  
>  static int
>  main_f(va_list ap)
>  {
> +	plan(3);
>  	fiber_name_test();
>  	fiber_join_test();
>  	fiber_stack_test();
>  	ev_break(loop(), EVBREAK_ALL);
> +	check_plan();
>  	return 0;
>  }
>  
> diff --git a/test/unit/fiber.result b/test/unit/fiber.result
> deleted file mode 100644
> index a61e0a2b8..000000000
> --- a/test/unit/fiber.result
> +++ /dev/null
> @@ -1,19 +0,0 @@
> -#gh-1238: log uncaught errors
> -SystemError Failed to allocate 42 bytes in allocator for exception: Cannot allocate memory
> -	*** fiber_name_test ***
> -# name of a new fiber: main.
> -
> -# set new fiber name: Horace.
> -
> -# fiber name is truncated: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.
> -
> -	*** fiber_name_test: done ***
> -	*** fiber_join_test ***
> -# exception propagated
> -# cancel dead has started
> -# by this time the fiber should be dead already
> -	*** fiber_join_test: done ***
> -	*** fiber_stack_test ***
> -# normal-stack fiber not crashed
> -# big-stack fiber not crashed
> -	*** fiber_stack_test: done ***
> diff --git a/test/unit/fiber_channel.cc b/test/unit/fiber_channel.cc
> index 90c73a581..3b403768a 100644
> --- a/test/unit/fiber_channel.cc
> +++ b/test/unit/fiber_channel.cc
> @@ -90,6 +90,7 @@ main_f(va_list ap)
>  
>  int main()
>  {
> +	plan(2);
>  	memory_init();
>  	fiber_init(fiber_c_invoke);
>  	struct fiber *main= fiber_new_xc("main", main_f);
> @@ -97,5 +98,6 @@ int main()
>  	ev_run(loop(), 0);
>  	fiber_free();
>  	memory_free();
> +	check_plan();
>  	return status;
>  }
> diff --git a/test/unit/fiber_channel.result b/test/unit/fiber_channel.result
> deleted file mode 100644
> index b03949d8c..000000000
> --- a/test/unit/fiber_channel.result
> +++ /dev/null
> @@ -1,23 +0,0 @@
> -	*** fiber_channel_basic ***
> -1..10
> -ok 1 - fiber_channel_new()
> -ok 2 - fiber_channel_size()
> -ok 3 - fiber_channel_count()
> -ok 4 - fiber_channel_is_full()
> -ok 5 - fiber_channel_is_empty()
> -ok 6 - fiber_channel_size(1)
> -ok 7 - fiber_channel_count(1)
> -ok 8 - fiber_channel_is_full(1)
> -ok 9 - fiber_channel_is_empty(1)
> -ok 10 - fiber_channel_get()
> -	*** fiber_channel_basic: done ***
> -	*** fiber_channel_get ***
> -1..7
> -ok 1 - fiber_channel_put(0)
> -ok 2 - fiber_channel_put_timeout(0)
> -ok 3 - fiber_channel_get(0)
> -ok 4 - fiber_channel_put_timeout(1)
> -ok 5 - fiber_channel_get(1)
> -ok 6 - fiber_channel_put(closed)
> -ok 7 - fiber_channel_get(closed)
> -	*** fiber_channel_get: done ***
> diff --git a/test/unit/fiber_channel_stress.cc b/test/unit/fiber_channel_stress.cc
> index 98aec697b..1ac1d8ae5 100644
> --- a/test/unit/fiber_channel_stress.cc
> +++ b/test/unit/fiber_channel_stress.cc
> @@ -50,6 +50,7 @@ main_f(va_list ap)
>  
>  int main()
>  {
> +	plan(1);
>  	memory_init();
>  	fiber_init(fiber_c_invoke);
>  	struct fiber *main= fiber_new_xc("main", main_f);
> @@ -57,5 +58,7 @@ int main()
>  	ev_run(loop(), 0);
>  	fiber_free();
>  	memory_free();
> +	ok(1, "fiber channel stress");
> +	check_plan();
>  	return 0;
>  }
> diff --git a/test/unit/fiber_channel_stress.result b/test/unit/fiber_channel_stress.result
> deleted file mode 100644
> index 7abdb54e0..000000000
> --- a/test/unit/fiber_channel_stress.result
> +++ /dev/null
> @@ -1,2 +0,0 @@
> -	*** main_f ***
> -	*** main_f: done ***
> diff --git a/test/unit/fiber_cond.result b/test/unit/fiber_cond.result
> deleted file mode 100644
> index 20539e2be..000000000
> --- a/test/unit/fiber_cond.result
> +++ /dev/null
> @@ -1,8 +0,0 @@
> -1..7
> -ok 1 - timeout
> -ok 2 - timeout
> -ok 3 - signal
> -ok 4 - signal
> -ok 5 - order
> -ok 6 - broadcast
> -ok 7 - broadcast
> diff --git a/test/unit/fiber_stack.c b/test/unit/fiber_stack.c
> index 41abe3764..3d1fce7ba 100644
> --- a/test/unit/fiber_stack.c
> +++ b/test/unit/fiber_stack.c
> @@ -97,6 +97,8 @@ main_f(va_list ap)
>  
>  int main()
>  {
> +	header();
> +	plan(1);
>  	memory_init();
>  	fiber_init(fiber_c_invoke);
>  	fiber_attr_create(&default_attr);
> @@ -105,5 +107,6 @@ int main()
>  	ev_run(loop(), 0);
>  	fiber_free();
>  	memory_free();
> +	check_plan();
>  	return 0;
>  }
> diff --git a/test/unit/fiber_stack.result b/test/unit/fiber_stack.result
> deleted file mode 100644
> index 7cae4e96c..000000000
> --- a/test/unit/fiber_stack.result
> +++ /dev/null
> @@ -1,11 +0,0 @@
> -SystemError fiber mprotect failed: Cannot allocate memory
> -fiber: Can't put guard page to slab. Leak 57344 bytes: Cannot allocate memory
> -	*** main_f ***
> -1..6
> -ok 1 - mprotect: failed to setup fiber guard page
> -ok 2 - mprotect: diag is armed after error
> -ok 3 - madvise: non critical error on madvise hint
> -ok 4 - madvise: diag is armed after error
> -ok 5 - fiber with custom stack
> -ok 6 - expected leak detected
> -	*** main_f: done ***
> diff --git a/test/unit/fiber_stress.cc b/test/unit/fiber_stress.cc
> index 44ab12487..a0baf5fbd 100644
> --- a/test/unit/fiber_stress.cc
> +++ b/test/unit/fiber_stress.cc
> @@ -1,5 +1,6 @@
>  #include "memory.h"
>  #include "fiber.h"
> +#include "unit.h"
>  
>  enum {
>  	ITERATIONS = 50000,
> @@ -35,6 +36,7 @@ benchmark_f(va_list ap)
>  
>  int main()
>  {
> +	plan(1);
>  	memory_init();
>  	fiber_init(fiber_cxx_invoke);
>  	struct fiber *benchmark = fiber_new_xc("benchmark", benchmark_f);
> @@ -42,5 +44,7 @@ int main()
>  	ev_run(loop(), 0);
>  	fiber_free();
>  	memory_free();
> +	ok(1, "fiber stress");
> +	check_plan();
>  	return 0;
>  }
> diff --git a/test/unit/fiber_stress.result b/test/unit/fiber_stress.result
> deleted file mode 100644
> index e69de29bb..000000000
> diff --git a/test/unit/find_path.c b/test/unit/find_path.c
> index 5c6c0a8b6..2d4eb29d7 100644
> --- a/test/unit/find_path.c
> +++ b/test/unit/find_path.c
> @@ -11,6 +11,9 @@ int
>  main(int argc, char *argv[])
>  {
>  	header();
> +	plan(1);
>  	fail_unless(open(find_path(argv[0]), O_RDONLY) >= 0);
> +	ok(1, "find_path");
> +	check_plan();
>  	footer();
>  }
> diff --git a/test/unit/find_path.result b/test/unit/find_path.result
> deleted file mode 100644
> index 8300f0550..000000000
> --- a/test/unit/find_path.result
> +++ /dev/null
> @@ -1,2 +0,0 @@
> -	*** main ***
> -	*** main: done ***
> diff --git a/test/unit/guard.cc b/test/unit/guard.cc
> index a2953b829..ddf2e0d87 100644
> --- a/test/unit/guard.cc
> +++ b/test/unit/guard.cc
> @@ -7,7 +7,7 @@ static struct fiber_attr default_attr;
>  static void
>  sigsegf_handler(int signo)
>  {
> -	note("signal handler called");
> +	ok(1, "signal handler called");
>  	exit(0);
>  }
>  
> @@ -53,6 +53,7 @@ main_f(va_list ap)
>  
>  int main()
>  {
> +	plan(1);
>  	memory_init();
>  	fiber_init(fiber_cxx_invoke);
>  	fiber_attr_create(&default_attr);
> diff --git a/test/unit/guard.result b/test/unit/guard.result
> deleted file mode 100644
> index bc9889d42..000000000
> --- a/test/unit/guard.result
> +++ /dev/null
> @@ -1 +0,0 @@
> -# signal handler called
> diff --git a/test/unit/guava.c b/test/unit/guava.c
> index 4e3ced76a..4100c6b61 100644
> --- a/test/unit/guava.c
> +++ b/test/unit/guava.c
> @@ -21,12 +21,15 @@ static void
>  correctness_check()
>  {
>  	header();
> +	plan(1);
>  	int64_t i_vals[] = {0, 1, 2};
>  	for (size_t i = 0; i < sizeof(i_vals) / sizeof(int64_t); ++i)
>  		check_guava_correctness(i_vals[i]);
>  	srand(time(NULL));
>  	for (size_t i = 0; i < 20; ++i)
>  		check_guava_correctness(rand() % 7);
> +	ok(1, "correctness check");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -34,7 +37,10 @@ static void
>  sameresult_check()
>  {
>  	header();
> +	plan(1);
>  	fail_if(guava(100, 20) != guava(100, 20));
> +	ok(1, "sameresult check");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -42,6 +48,7 @@ static void
>  lcg_compat_check()
>  {
>  	header();
> +	plan(1);
>  	int32_t golden100[] = {
>  		0, 55, 62, 8, 45, 59, 86, 97, 82, 59,
>  		73, 37, 17, 56, 86, 21, 90, 37, 38, 83
> @@ -55,13 +62,17 @@ lcg_compat_check()
>  	fail_if(80343 != guava(2, 100001));
>  	fail_if(22152 != guava(2201, 100001));
>  	fail_if(15018 != guava(2202, 100001));
> +	ok(1, "lcg compat check");
> +	check_plan();
>  	footer();
>  }
>  
>  int
>  main(void)
>  {
> +	plan(3);
>  	correctness_check();
>  	lcg_compat_check();
>  	sameresult_check();
> +	check_plan();
>  }
> diff --git a/test/unit/guava.result b/test/unit/guava.result
> deleted file mode 100644
> index afc3e890f..000000000
> --- a/test/unit/guava.result
> +++ /dev/null
> @@ -1,6 +0,0 @@
> -	*** correctness_check ***
> -	*** correctness_check: done ***
> -	*** lcg_compat_check ***
> -	*** lcg_compat_check: done ***
> -	*** sameresult_check ***
> -	*** sameresult_check: done ***
> diff --git a/test/unit/heap.c b/test/unit/heap.c
> index 89806c633..a2480b5d4 100644
> --- a/test/unit/heap.c
> +++ b/test/unit/heap.c
> @@ -51,6 +51,7 @@ static void
>  test_insert_1_to_3()
>  {
>  	header();
> +	plan(1);
>  	struct test_type *value, *root_value;
>  	heap_t heap;
>  	test_heap_create(&heap);
> @@ -73,7 +74,9 @@ test_insert_1_to_3()
>  
>  	free_all_nodes(&heap);
>  	test_heap_destroy(&heap);
> +	ok(1, "test insert 1 to 3");
>  
> +	check_plan();
>  	footer();
>  }
>  
> @@ -81,6 +84,7 @@ static void
>  test_insert_3_to_1()
>  {
>  	header();
> +	plan(1);
>  	struct test_type *value, *root_value;
>  	heap_t heap;
>  	test_heap_create(&heap);
> @@ -103,7 +107,9 @@ test_insert_3_to_1()
>  
>  	free_all_nodes(&heap);
>  	test_heap_destroy(&heap);
> +	ok(1, "test insert 3 to 1");
>  
> +	check_plan();
>  	footer();
>  }
>  
> @@ -111,6 +117,7 @@ static void
>  test_insert_50_to_150_mod_100()
>  {
>  	header();
> +	plan(1);
>  	struct test_type *value, *root_value;
>  	heap_t heap;
>  	test_heap_create(&heap);
> @@ -143,7 +150,9 @@ test_insert_50_to_150_mod_100()
>  		free(root_value);
>  	}
>  	test_heap_destroy(&heap);
> +	ok(1, "test insert 50 to 150 mod 100");
>  
> +	check_plan();
>  	footer();
>  }
>  
> @@ -151,6 +160,7 @@ static void
>  test_insert_many_random()
>  {
>  	header();
> +	plan(1);
>  	uint32_t ans = UINT_MAX;
>  	struct test_type *value, *root_value;
>  	heap_t heap;
> @@ -179,6 +189,8 @@ test_insert_many_random()
>  
>  	free_all_nodes(&heap);
>  	test_heap_destroy(&heap);
> +	ok(1, "test insert many random");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -186,6 +198,7 @@ static void
>  test_insert_10_to_1_pop()
>  {
>  	header();
> +	plan(1);
>  	struct test_type *value, *root_value;
>  	heap_t heap;
>  	test_heap_create(&heap);
> @@ -221,7 +234,9 @@ test_insert_10_to_1_pop()
>  		free(root_value);
>  	}
>  	test_heap_destroy(&heap);
> +	ok(1, "test insert 10 to 1 pop");
>  
> +	check_plan();
>  	footer();
>  }
>  
> @@ -243,6 +258,7 @@ static void
>  test_insert_many_pop_many_random()
>  {
>  	header();
> +	plan(1);
>  	uint32_t ans = UINT_MAX;
>  
>  	struct test_type *value, *root_value;
> @@ -309,8 +325,10 @@ test_insert_many_pop_many_random()
>  		free(root_value);
>  	}
>  	test_heap_destroy(&heap);
> +	ok(1, "test insert many pop many random");
>  
>  	free(keys);
> +	check_plan();
>  	footer();
>  }
>  
> @@ -318,6 +336,7 @@ static void
>  test_insert_pop_workload()
>  {
>  	header();
> +	plan(1);
>  	uint32_t ans = UINT_MAX;
>  
>  	struct test_type *value, *root_value;
> @@ -354,6 +373,8 @@ test_insert_pop_workload()
>  
>  	free_all_nodes(&heap);
>  	test_heap_destroy(&heap);
> +	ok(1, "test insert pop workload");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -361,6 +382,7 @@ static void
>  test_pop_last()
>  {
>  	header();
> +	plan(1);
>  	uint32_t ans = UINT_MAX;
>  
>  	struct test_type *value, *root_value;
> @@ -377,6 +399,8 @@ test_pop_last()
>  
>  	test_heap_destroy(&heap);
>  	free(value);
> +	ok(1, "test pop last");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -384,6 +408,7 @@ static void
>  test_insert_update_workload()
>  {
>  	header();
> +	plan(1);
>  	uint32_t nodes_it = 0;
>  	uint64_t current_size = 0;
>  	uint32_t ans = UINT_MAX;
> @@ -427,6 +452,8 @@ test_insert_update_workload()
>  	free_all_nodes(&heap);
>  	test_heap_destroy(&heap);
>  	free(nodes);
> +	ok(1, "test insert update workload");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -434,6 +461,7 @@ static void
>  test_random_delete_workload()
>  {
>  	header();
> +	plan(1);
>  	uint32_t nodes_it = 0;
>  	uint64_t current_size = 0;
>  	uint32_t ans = UINT_MAX;
> @@ -477,6 +505,8 @@ test_random_delete_workload()
>  	free_all_nodes(&heap);
>  	test_heap_destroy(&heap);
>  	free(nodes);
> +	ok(1, "test random delete workload")
> +	check_plan();
>  	footer();
>  }
>  
> @@ -484,6 +514,7 @@ static void
>  test_delete_last_node()
>  {
>  	header();
> +	plan(1);
>  	struct test_type *value, *root_value;
>  	heap_t heap;
>  	test_heap_create(&heap);
> @@ -500,6 +531,8 @@ test_delete_last_node()
>  		fail("check heap invariants failed", "test_heap_check(&heap)");
>  	}
>  	test_heap_destroy(&heap);
> +	ok(1, "test delete last node");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -507,6 +540,7 @@ static void
>  test_heapify()
>  {
>  	header();
> +	plan(1);
>  	heap_t heap;
>  	test_heap_create(&heap);
>  
> @@ -524,15 +558,18 @@ test_heapify()
>  		     "test_heap_check(&heap)");
>  	}
>  	order_by_val2 = false;
> +	ok(1, "test heapify");
>  
>  	free_all_nodes(&heap);
>  	test_heap_destroy(&heap);
> +	check_plan();
>  	footer();
>  }
>  
>  int
>  main(int argc, const char** argv)
>  {
> +	plan(12);
>  	srand(179);
>  	test_insert_1_to_3();
>  	test_insert_3_to_1();
> @@ -546,4 +583,5 @@ main(int argc, const char** argv)
>  	test_random_delete_workload();
>  	test_delete_last_node();
>  	test_heapify();
> +	check_plan();
>  }
> diff --git a/test/unit/heap.result b/test/unit/heap.result
> deleted file mode 100644
> index 7928983c1..000000000
> --- a/test/unit/heap.result
> +++ /dev/null
> @@ -1,24 +0,0 @@
> -	*** test_insert_1_to_3 ***
> -	*** test_insert_1_to_3: done ***
> -	*** test_insert_3_to_1 ***
> -	*** test_insert_3_to_1: done ***
> -	*** test_insert_50_to_150_mod_100 ***
> -	*** test_insert_50_to_150_mod_100: done ***
> -	*** test_insert_many_random ***
> -	*** test_insert_many_random: done ***
> -	*** test_insert_10_to_1_pop ***
> -	*** test_insert_10_to_1_pop: done ***
> -	*** test_insert_many_pop_many_random ***
> -	*** test_insert_many_pop_many_random: done ***
> -	*** test_insert_pop_workload ***
> -	*** test_insert_pop_workload: done ***
> -	*** test_pop_last ***
> -	*** test_pop_last: done ***
> -	*** test_insert_update_workload ***
> -	*** test_insert_update_workload: done ***
> -	*** test_random_delete_workload ***
> -	*** test_random_delete_workload: done ***
> -	*** test_delete_last_node ***
> -	*** test_delete_last_node: done ***
> -	*** test_heapify ***
> -	*** test_heapify: done ***
> diff --git a/test/unit/heap_iterator.c b/test/unit/heap_iterator.c
> index 4fde39dfe..6981bbc92 100644
> --- a/test/unit/heap_iterator.c
> +++ b/test/unit/heap_iterator.c
> @@ -43,6 +43,7 @@ static void
>  test_iterator_create()
>  {
>  	header();
> +	plan(1);
>  	struct test_type *value, *root_value;
>  	heap_t heap;
>  	test_heap_create(&heap);
> @@ -59,6 +60,8 @@ test_iterator_create()
>  
>  	free_all_nodes(&heap);
>  
> +	ok(1, "test iterator create");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -66,6 +69,7 @@ static void
>  test_iterator_empty()
>  {
>  	header();
> +	plan(1);
>  	heap_t heap;
>  	test_heap_create(&heap);
>  
> @@ -79,6 +83,8 @@ test_iterator_empty()
>  
>  	free_all_nodes(&heap);
>  
> +	ok(1, "test iterator empty");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -87,6 +93,7 @@ static void
>  test_iterator_small()
>  {
>  	header();
> +	plan(1);
>  	struct test_type *value;
>  	heap_t heap;
>  	test_heap_create(&heap);
> @@ -128,6 +135,8 @@ test_iterator_small()
>  		fail("after all iterator returns not NULL", "value != NULL");
>  
>  	free_all_nodes(&heap);
> +	ok(1, "test iterator small");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -135,6 +144,7 @@ static void
>  test_iterator_large()
>  {
>  	header();
> +	plan(1);
>  	uint32_t const TEST_CASE_SIZE = 1000;
>  	struct test_type *value;
>  	heap_t heap;
> @@ -180,6 +190,8 @@ test_iterator_large()
>  		     "value != NULL");
>  
>  	free_all_nodes(&heap);
> +	ok(1, "test iterator large");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -188,8 +200,10 @@ int
>  main(int argc, const char** argv)
>  {
>  	srand(179);
> +	plan(4);
>  	test_iterator_create();
>  	test_iterator_empty();
>  	test_iterator_small();
>  	test_iterator_large();
> +	check_plan();
>  }
> diff --git a/test/unit/heap_iterator.result b/test/unit/heap_iterator.result
> deleted file mode 100644
> index 66b99dcc6..000000000
> --- a/test/unit/heap_iterator.result
> +++ /dev/null
> @@ -1,8 +0,0 @@
> -	*** test_iterator_create ***
> -	*** test_iterator_create: done ***
> -	*** test_iterator_empty ***
> -	*** test_iterator_empty: done ***
> -	*** test_iterator_small ***
> -	*** test_iterator_small: done ***
> -	*** test_iterator_large ***
> -	*** test_iterator_large: done ***
> diff --git a/test/unit/histogram.c b/test/unit/histogram.c
> index 3056d20fe..462f93511 100644
> --- a/test/unit/histogram.c
> +++ b/test/unit/histogram.c
> @@ -57,6 +57,7 @@ static void
>  test_counts(void)
>  {
>  	header();
> +	plan(1);
>  
>  	size_t n_buckets;
>  	int64_t *buckets = gen_buckets(&n_buckets);
> @@ -83,14 +84,17 @@ test_counts(void)
>  	histogram_delete(hist);
>  	free(data);
>  	free(buckets);
> +	ok(1, "test counts");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static void
>  test_discard(void)
>  {
>  	header();
> +	plan(1);
>  
>  	size_t n_buckets;
>  	int64_t *buckets = gen_buckets(&n_buckets);
> @@ -124,14 +128,17 @@ test_discard(void)
>  	histogram_delete(hist);
>  	free(data);
>  	free(buckets);
> +	ok(1, "test discard");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static void
>  test_percentile(void)
>  {
>  	header();
> +	plan(1);
>  
>  	size_t n_buckets;
>  	int64_t *buckets = gen_buckets(&n_buckets);
> @@ -170,15 +177,19 @@ test_percentile(void)
>  	histogram_delete(hist);
>  	free(data);
>  	free(buckets);
> +	ok(1, "test percentile");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  int
>  main()
>  {
> +	plan(3);
>  	srand(time(NULL));
>  	test_counts();
>  	test_discard();
>  	test_percentile();
> +	check_plan();
>  }
> diff --git a/test/unit/histogram.result b/test/unit/histogram.result
> deleted file mode 100644
> index e393c194d..000000000
> --- a/test/unit/histogram.result
> +++ /dev/null
> @@ -1,6 +0,0 @@
> -	*** test_counts ***
> -	*** test_counts: done ***
> -	*** test_discard ***
> -	*** test_discard: done ***
> -	*** test_percentile ***
> -	*** test_percentile: done ***
> diff --git a/test/unit/int96.cc b/test/unit/int96.cc
> index 29dbbcbf5..c033b0aed 100644
> --- a/test/unit/int96.cc
> +++ b/test/unit/int96.cc
> @@ -2,12 +2,11 @@
>  
>  #include "unit.h"
>  
> -#define check(expr) if (!(expr)) printf("failed at %s:%d\n", __FILE__, __LINE__)
> -
>  static void
>  test()
>  {
>  	header();
> +	plan(15);
>  
>  	const uint64_t a = 0xFFFFFFFFFFFFFFFFull / 2;
>  	int96_num num, num1, num2;
> @@ -15,57 +14,61 @@ test()
>  	int96_set_unsigned(&num1, a);
>  	int96_set_unsigned(&num2, a);
>  	int96_invert(&num2);
> -	check(int96_is_neg_int64(&num2));
> -	check(int96_extract_neg_int64(&num2) == int64_t(-a));
> -	check(int96_is_uint64(&num));
> -	check(int96_extract_uint64(&num) == 0);
> +	is(int96_is_neg_int64(&num2), true, "int96_is_neg_int64()");
> +	is(int96_extract_neg_int64(&num2), int64_t(-a), "int96_extract_neg_int64()");
> +	is(int96_is_uint64(&num), true, "int96_is_uint64()");
> +	is(int96_extract_uint64(&num), 0, "int96_extract_uint64()");
>  	int96_add(&num, &num1);
> -	check(int96_is_uint64(&num));
> -	check(int96_extract_uint64(&num) == a);
> +	is(int96_is_uint64(&num), true, "int96_is_uint64()");
> +	is(int96_extract_uint64(&num), a, "int96_extract_uint64()");
>  	int96_add(&num, &num1);
> -	check(int96_is_uint64(&num));
> -	check(int96_extract_uint64(&num) == a * 2);
> +	is(int96_is_uint64(&num), true, "int96_is_uint64()");
> +	is(int96_extract_uint64(&num), a * 2, "int96_extract_uint64()");
>  	for (int i = 1; i < 1000; i++) {
>  		for(int j = 0; j < i; j++) {
>  			int96_add(&num, &num1);
> -			check(!int96_is_uint64(&num) && !int96_is_neg_int64(&num));
> +			fail_if(!(!int96_is_uint64(&num) && !int96_is_neg_int64(&num)));
>  		}
>  		for(int j = 0; j < i - 1; j++) {
>  			int96_add(&num, &num2);
> -			check(!int96_is_uint64(&num) && !int96_is_neg_int64(&num));
> +			fail_if(!(!int96_is_uint64(&num) && !int96_is_neg_int64(&num)));
>  		}
>  		int96_add(&num, &num2);
> -		check(int96_is_uint64(&num));
> -		check(int96_extract_uint64(&num) == a * 2);
> +		fail_if(!int96_is_uint64(&num));
> +		fail_if(int96_extract_uint64(&num) != a * 2);
>  	}
> +	ok(1, "int96_add() in loop");
>  	int96_add(&num, &num2);
> -	check(int96_is_uint64(&num));
> -	check(int96_extract_uint64(&num) == a);
> +	is(int96_is_uint64(&num), true, "int96_is_uint64()");
> +	is(int96_extract_uint64(&num), a, "int96_extract_uint64()");
>  	int96_add(&num, &num2);
> -	check(int96_is_uint64(&num));
> -	check(int96_extract_uint64(&num) == 0);
> +	is(int96_is_uint64(&num), true, "int96_is_uint64()");
> +	is(int96_extract_uint64(&num), 0, "int96_extract_uint64()");
>  	int96_add(&num, &num2);
> -	check(int96_is_neg_int64(&num));
> -	check(int96_extract_neg_int64(&num) == int64_t(-a));
> +	is(int96_is_neg_int64(&num), true, "int96_is_neg_int64()");
> +	is(int96_extract_neg_int64(&num), int64_t(-a), "int96_extract_neg_int64()");
>  	for (int i = 1; i < 1000; i++) {
>  		for(int j = 0; j < i; j++) {
>  			int96_add(&num, &num2);
> -			check(!int96_is_uint64(&num) && !int96_is_neg_int64(&num));
> +			fail_if(!(!int96_is_uint64(&num) && !int96_is_neg_int64(&num)));
>  		}
>  		for(int j = 0; j < i - 1; j++) {
>  			int96_add(&num, &num1);
> -			check(!int96_is_uint64(&num) && !int96_is_neg_int64(&num));
> +			fail_if(!(!int96_is_uint64(&num) && !int96_is_neg_int64(&num)));
>  		}
>  		int96_add(&num, &num1);
> -		check(int96_is_neg_int64(&num));
> -		check(int96_extract_neg_int64(&num) == int64_t(-a));
> +		fail_if(!(int96_is_neg_int64(&num)));
> +		fail_if(int96_extract_neg_int64(&num) != int64_t(-a));
>  	}
>  
> +	check_plan();
>  	footer();
>  }
>  
>  int
>  main(int, const char **)
>  {
> +	plan(1);
>  	test();
> +	check_plan();
>  }
> diff --git a/test/unit/int96.result b/test/unit/int96.result
> deleted file mode 100644
> index 4a0b26f56..000000000
> --- a/test/unit/int96.result
> +++ /dev/null
> @@ -1,2 +0,0 @@
> -	*** test ***
> -	*** test: done ***
> diff --git a/test/unit/json.result b/test/unit/json.result
> deleted file mode 100644
> index fb9d1490f..000000000
> --- a/test/unit/json.result
> +++ /dev/null
> @@ -1,208 +0,0 @@
> -	*** main ***
> -1..6
> -	*** test_basic ***
> -    1..71
> -    ok 1 - parse <[1]>
> -    ok 2 - <[1]> is num
> -    ok 3 - <[1]> is 0
> -    ok 4 - parse <field1>
> -    ok 5 - <field1> is str
> -    ok 6 - len is 6
> -    ok 7 - str is field1
> -    ok 8 - parse <field2>
> -    ok 9 - <field2> is str
> -    ok 10 - len is 6
> -    ok 11 - str is field2
> -    ok 12 - parse <field3>
> -    ok 13 - <field3> is str
> -    ok 14 - len is 6
> -    ok 15 - str is field3
> -    ok 16 - parse <[5]>
> -    ok 17 - <[5]> is num
> -    ok 18 - <[5]> is 4
> -    ok 19 - parse <[3]>
> -    ok 20 - <[3]> is num
> -    ok 21 - <[3]> is 2
> -    ok 22 - parse <field>
> -    ok 23 - <field> is str
> -    ok 24 - len is 5
> -    ok 25 - str is field
> -    ok 26 - parse <[2]>
> -    ok 27 - <[2]> is num
> -    ok 28 - <[2]> is 1
> -    ok 29 - parse <field>
> -    ok 30 - <field> is str
> -    ok 31 - len is 5
> -    ok 32 - str is field
> -    ok 33 - parse <f1>
> -    ok 34 - <f1> is str
> -    ok 35 - len is 2
> -    ok 36 - str is f1
> -    ok 37 - parse <f2'3'>
> -    ok 38 - <f2'3'> is str
> -    ok 39 - len is 5
> -    ok 40 - str is f2'3'
> -    ok 41 - parse <field1>
> -    ok 42 - <field1> is str
> -    ok 43 - len is 6
> -    ok 44 - str is field1
> -    ok 45 - parse <field1>
> -    ok 46 - <field1> is str
> -    ok 47 - len is 6
> -    ok 48 - str is field1
> -    ok 49 - parse <[1234]>
> -    ok 50 - <[1234]> is num
> -    ok 51 - <[1234]> is 1233
> -    ok 52 - parse empty path
> -    ok 53 - is str
> -    ok 54 - parse <field1>
> -    ok 55 - <field1> is str
> -    ok 56 - len is 6
> -    ok 57 - str is field1
> -    ok 58 - parse <[2]>
> -    ok 59 - <[2]> is num
> -    ok 60 - <[2]> is 1
> -    ok 61 - parse <[6]>
> -    ok 62 - <[6]> is num
> -    ok 63 - <[6]> is 5
> -    ok 64 - parse <привет中国world>
> -    ok 65 - <привет中国world> is str
> -    ok 66 - len is 23
> -    ok 67 - str is привет中国world
> -    ok 68 - parse <中国a>
> -    ok 69 - <中国a> is str
> -    ok 70 - len is 7
> -    ok 71 - str is 中国a
> -ok 1 - subtests
> -	*** test_basic: done ***
> -	*** test_errors ***
> -    1..22
> -    ok 1 - error on position 2 for <[[>
> -    ok 2 - error on position 2 for <[field]>
> -    ok 3 - error on position 1 for <'field1'.field2>
> -    ok 4 - error on position 2 for <[]>
> -    ok 5 - error on position 1 for <''>
> -    ok 6 - error on position 1 for < field1>
> -    ok 7 - error on position 1 for <1field>
> -    ok 8 - error on position 2 for <.1field>
> -    ok 9 - error on position 8 for <['field>
> -    ok 10 - error on position 9 for <['field'>
> -    ok 11 - error on position 5 for <[123>
> -    ok 12 - error on position 3 for <['']>
> -    ok 13 - error on position 2 for <.[123]>
> -    ok 14 - error on position 2 for <[.]>
> -    ok 15 - error on position 6 for <['aaa??']>
> -    ok 16 - error on position 2 for <.??>
> -    ok 17 - can not write <field.[index]>
> -    ok 18 - can not omit '.' before not a first key out of []
> -    ok 19 - error in leading <.>
> -    ok 20 - space inside identifier
> -    ok 21 - tab inside identifier
> -    ok 22 - invalid token for index_base 1
> -ok 2 - subtests
> -	*** test_errors: done ***
> -	*** test_tree ***
> -    1..65
> -    ok 1 - add path '[1][10]'
> -    ok 2 - add path '[1][20].file'
> -    ok 3 - add path '[1][20].file[2]'
> -    ok 4 - add path '[1][20].file[8]'
> -    ok 5 - add path '[1][20]["file"][8]'
> -    ok 6 - lookup path '[1][10]'
> -    ok 7 - lookup path '[1][20].file'
> -    ok 8 - lookup unregistered path '[1][3]'
> -    ok 9 - test foreach pre order 0: have 0 expected of 0
> -    ok 10 - test foreach pre order 1: have 1 expected of 1
> -    ok 11 - test foreach pre order 2: have 2 expected of 2
> -    ok 12 - test foreach pre order 3: have 3 expected of 3
> -    ok 13 - test foreach pre order 4: have 4 expected of 4
> -    ok 14 - test foreach pre order 5: have 5 expected of 5
> -    ok 15 - records iterated count 6 of 6
> -    ok 16 - test foreach post order 0: have 1 expected of 1
> -    ok 17 - test foreach post order 1: have 4 expected of 4
> -    ok 18 - test foreach post order 2: have 5 expected of 5
> -    ok 19 - test foreach post order 3: have 3 expected of 3
> -    ok 20 - test foreach post order 4: have 2 expected of 2
> -    ok 21 - test foreach post order 5: have 0 expected of 0
> -    ok 22 - records iterated count 6 of 6
> -    ok 23 - test foreach safe order 0: have 1 expected of 1
> -    ok 24 - test foreach safe order 1: have 4 expected of 4
> -    ok 25 - test foreach safe order 2: have 5 expected of 5
> -    ok 26 - test foreach safe order 3: have 3 expected of 3
> -    ok 27 - test foreach safe order 4: have 2 expected of 2
> -    ok 28 - test foreach safe order 5: have 0 expected of 0
> -    ok 29 - records iterated count 6 of 6
> -    ok 30 - test foreach entry pre order 0: have 0 expected of 0
> -    ok 31 - test foreach entry pre order 1: have 1 expected of 1
> -    ok 32 - test foreach entry pre order 2: have 2 expected of 2
> -    ok 33 - test foreach entry pre order 3: have 3 expected of 3
> -    ok 34 - test foreach entry pre order 4: have 4 expected of 4
> -    ok 35 - test foreach entry pre order 5: have 5 expected of 5
> -    ok 36 - records iterated count 6 of 6
> -    ok 37 - test foreach entry post order 0: have 1 expected of 1
> -    ok 38 - test foreach entry post order 1: have 4 expected of 4
> -    ok 39 - test foreach entry post order 2: have 5 expected of 5
> -    ok 40 - test foreach entry post order 3: have 3 expected of 3
> -    ok 41 - test foreach entry post order 4: have 2 expected of 2
> -    ok 42 - test foreach entry post order 5: have 0 expected of 0
> -    ok 43 - records iterated count 6 of 6
> -    ok 44 - max_child_index 7 expected of 7
> -    ok 45 - max_child_index 1 expected of 1
> -    ok 46 - max_child_index -1 expected of -1
> -    ok 47 - lookup removed path '[1][20].file[2]'
> -    ok 48 - lookup removed path '[1][20].file[8]'
> -    ok 49 - lookup path was not corrupted '[1][20].file'
> -    ok 50 - test foreach entry safe order 0: have 1 expected of 1
> -    ok 51 - test foreach entry safe order 1: have 3 expected of 3
> -    ok 52 - test foreach entry safe order 2: have 2 expected of 2
> -    ok 53 - test foreach entry safe order 3: have 0 expected of 0
> -    ok 54 - records iterated count 4 of 4
> -    ok 55 - interm node is not leaf
> -    ok 56 - last node is leaf
> -    ok 57 - last node became interm - it can't be leaf anymore
> -    ok 58 - last node is leaf
> -    ok 59 - add path '[1][10]'
> -    ok 60 - lookup any token in non-multikey node
> -    ok 61 - add path '[1][*]["data"]'
> -    ok 62 - lookup path '[1][*]["data"]'
> -    ok 63 - lookup numeric token in multikey node
> -    ok 64 - lookup any token in multikey node
> -    ok 65 - lookup string token in multikey node
> -ok 3 - subtests
> -	*** test_tree: done ***
> -	*** test_path_cmp ***
> -    1..8
> -    ok 1 - path cmp result "Data[1]["FIO"].fname" with "Data[1]["FIO"].fname": have 0, expected 0
> -    ok 2 - path cmp result "Data[1]["FIO"].fname" with "["Data"][1].FIO["fname"]": have 0, expected 0
> -    ok 3 - path cmp result "Data[1]["FIO"].fname" with "Data[1]": have 1, expected 1
> -    ok 4 - path cmp result "Data[1]["FIO"].fname" with "Data[1]["FIO"].fname[1]": have -1, expected -1
> -    ok 5 - path cmp result "Data[1]["FIO"].fname" with "Data[1]["Info"].fname[1]": have -1, expected -1
> -    ok 6 - path cmp result "Data[*]["FIO"].fname[*]" with "["Data"][*].FIO["fname"][*]": have 0, expected 0
> -    ok 7 - path Data[1]["FIO"].fname is valid
> -    ok 8 - path Data[[1]["FIO"].fname error pos 6 expected 6
> -ok 4 - subtests
> -	*** test_path_cmp: done ***
> -	*** test_path_snprint ***
> -    1..9
> -    ok 1 - full path - retval
> -    ok 2 - full path - terminating nul
> -    ok 3 - full path - output
> -    ok 4 - truncated path - retval
> -    ok 5 - truncated path - terminating nul
> -    ok 6 - truncated path - output
> -    ok 7 - 1-byte buffer - retval
> -    ok 8 - 1-byte buffer - terminating nul
> -    ok 9 - 0-byte buffer - retval
> -ok 5 - subtests
> -	*** test_path_snprint: done ***
> -	*** test_path_multikey ***
> -    1..6
> -    ok 1 - Test json_path_multikey_offset with : have 0 expected 0
> -    ok 2 - Test json_path_multikey_offset with [1].Data[1].extra[1]: have 20 expected 20
> -    ok 3 - Test json_path_multikey_offset with [*].Data[1].extra[1]: have 0 expected 0
> -    ok 4 - Test json_path_multikey_offset with [*].Data[*].extra[1]: have 0 expected 0
> -    ok 5 - Test json_path_multikey_offset with [1].Data[*].extra[1]: have 8 expected 8
> -    ok 6 - Test json_path_multikey_offset with [1].Data[1].extra[*]: have 17 expected 17
> -ok 6 - subtests
> -	*** test_path_multikey: done ***
> -	*** main: done ***
> diff --git a/test/unit/light.cc b/test/unit/light.cc
> index 6d89938b4..c1832654b 100644
> --- a/test/unit/light.cc
> +++ b/test/unit/light.cc
> @@ -62,6 +62,7 @@ static void
>  simple_test()
>  {
>  	header();
> +	plan(1);
>  
>  	struct light_core ht;
>  	light_create(&ht, light_extent_size,
> @@ -80,7 +81,6 @@ simple_test()
>  			hash_t fnd = light_find(&ht, h, val);
>  			bool has1 = fnd != light_end;
>  			bool has2 = vect[val];
> -			assert(has1 == has2);
>  			if (has1 != has2) {
>  				fail("find key failed!", "true");
>  				return;
> @@ -118,7 +118,9 @@ simple_test()
>  		}
>  	}
>  	light_destroy(&ht);
> +	ok(1, "Simple test")
>  
> +	check_plan();
>  	footer();
>  }
>  
> @@ -126,6 +128,7 @@ static void
>  collision_test()
>  {
>  	header();
> +	plan(1);
>  
>  	struct light_core ht;
>  	light_create(&ht, light_extent_size,
> @@ -144,7 +147,6 @@ collision_test()
>  			hash_t fnd = light_find(&ht, h * 1024, val);
>  			bool has1 = fnd != light_end;
>  			bool has2 = vect[val];
> -			assert(has1 == has2);
>  			if (has1 != has2) {
>  				fail("find key failed!", "true");
>  				return;
> @@ -182,7 +184,9 @@ collision_test()
>  		}
>  	}
>  	light_destroy(&ht);
> +	ok(1, "Collision test")
>  
> +	check_plan();
>  	footer();
>  }
>  
> @@ -190,6 +194,7 @@ static void
>  iterator_test()
>  {
>  	header();
> +	plan(1);
>  
>  	struct light_core ht;
>  	light_create(&ht, light_extent_size,
> @@ -239,14 +244,17 @@ iterator_test()
>  	if (strage_thing >> 20) {
>  		printf("impossible!\n"); // prevent strage_thing to be optimized out
>  	}
> +	ok(1, "Iterator test")
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static void
>  iterator_freeze_check()
>  {
>  	header();
> +	plan(1);
>  
>  	const int test_data_size = 1000;
>  	hash_value_t comp_buf[test_data_size];
> @@ -313,13 +321,16 @@ iterator_freeze_check()
>  
>  		light_destroy(&ht);
>  	}
> +	ok(1, "Iterator freeze test");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  int
>  main(int, const char**)
>  {
> +	plan(4);
>  	srand(time(0));
>  	simple_test();
>  	collision_test();
> @@ -327,4 +338,5 @@ main(int, const char**)
>  	iterator_freeze_check();
>  	if (extents_count != 0)
>  		fail("memory leak!", "true");
> +	check_plan();
>  }
> diff --git a/test/unit/light.result b/test/unit/light.result
> deleted file mode 100644
> index 39c4d7c53..000000000
> --- a/test/unit/light.result
> +++ /dev/null
> @@ -1,8 +0,0 @@
> -	*** simple_test ***
> -	*** simple_test: done ***
> -	*** collision_test ***
> -	*** collision_test: done ***
> -	*** iterator_test ***
> -	*** iterator_test: done ***
> -	*** iterator_freeze_check ***
> -	*** iterator_freeze_check: done ***
> diff --git a/test/unit/luaL_iterator.result b/test/unit/luaL_iterator.result
> deleted file mode 100644
> index 2472eedcf..000000000
> --- a/test/unit/luaL_iterator.result
> +++ /dev/null
> @@ -1,89 +0,0 @@
> -1..86
> -	*** main ***
> -ok 1 - pairs, zero idx: stack size
> -ok 2 - pairs, zero idx: iter 0: gen() retval count
> -ok 3 - pairs, zero idx: iter 0: gen() 1st retval
> -ok 4 - pairs, zero idx: iter 0: gen() 2nd retval
> -ok 5 - pairs, zero idx: iter: 0: stack size
> -ok 6 - pairs, zero idx: iterator ends
> -ok 7 - pairs, zero idx: stack size
> -ok 8 - pairs, zero idx: stack size
> -ok 9 - ipairs, zero idx: stack size
> -ok 10 - ipairs, zero idx: iter 0: gen() retval count
> -ok 11 - ipairs, zero idx: iter 0: gen() 1st retval
> -ok 12 - ipairs, zero idx: iter 0: gen() 2nd retval
> -ok 13 - ipairs, zero idx: iter: 0: stack size
> -ok 14 - ipairs, zero idx: iter 1: gen() retval count
> -ok 15 - ipairs, zero idx: iter 1: gen() 1st retval
> -ok 16 - ipairs, zero idx: iter 1: gen() 2nd retval
> -ok 17 - ipairs, zero idx: iter: 1: stack size
> -ok 18 - ipairs, zero idx: iter 2: gen() retval count
> -ok 19 - ipairs, zero idx: iter 2: gen() 1st retval
> -ok 20 - ipairs, zero idx: iter 2: gen() 2nd retval
> -ok 21 - ipairs, zero idx: iter: 2: stack size
> -ok 22 - ipairs, zero idx: iterator ends
> -ok 23 - ipairs, zero idx: stack size
> -ok 24 - ipairs, zero idx: stack size
> -ok 25 - luafun iterator, zero idx: stack size
> -ok 26 - luafun iterator, zero idx: iter 0: gen() retval count
> -ok 27 - luafun iterator, zero idx: iter 0: gen() 1st retval
> -ok 28 - luafun iterator, zero idx: iter 0: gen() 2nd retval
> -ok 29 - luafun iterator, zero idx: iter: 0: stack size
> -ok 30 - luafun iterator, zero idx: iter 1: gen() retval count
> -ok 31 - luafun iterator, zero idx: iter 1: gen() 1st retval
> -ok 32 - luafun iterator, zero idx: iter 1: gen() 2nd retval
> -ok 33 - luafun iterator, zero idx: iter: 1: stack size
> -ok 34 - luafun iterator, zero idx: iter 2: gen() retval count
> -ok 35 - luafun iterator, zero idx: iter 2: gen() 1st retval
> -ok 36 - luafun iterator, zero idx: iter 2: gen() 2nd retval
> -ok 37 - luafun iterator, zero idx: iter: 2: stack size
> -ok 38 - luafun iterator, zero idx: iterator ends
> -ok 39 - luafun iterator, zero idx: stack size
> -ok 40 - luafun iterator, zero idx: stack size
> -ok 41 - pairs, from table: stack size
> -ok 42 - pairs, from table: iter 0: gen() retval count
> -ok 43 - pairs, from table: iter 0: gen() 1st retval
> -ok 44 - pairs, from table: iter 0: gen() 2nd retval
> -ok 45 - pairs, from table: iter: 0: stack size
> -ok 46 - pairs, from table: iterator ends
> -ok 47 - pairs, from table: stack size
> -ok 48 - pairs, from table: stack size
> -ok 49 - ipairs, from table: stack size
> -ok 50 - ipairs, from table: iter 0: gen() retval count
> -ok 51 - ipairs, from table: iter 0: gen() 1st retval
> -ok 52 - ipairs, from table: iter 0: gen() 2nd retval
> -ok 53 - ipairs, from table: iter: 0: stack size
> -ok 54 - ipairs, from table: iter 1: gen() retval count
> -ok 55 - ipairs, from table: iter 1: gen() 1st retval
> -ok 56 - ipairs, from table: iter 1: gen() 2nd retval
> -ok 57 - ipairs, from table: iter: 1: stack size
> -ok 58 - ipairs, from table: iter 2: gen() retval count
> -ok 59 - ipairs, from table: iter 2: gen() 1st retval
> -ok 60 - ipairs, from table: iter 2: gen() 2nd retval
> -ok 61 - ipairs, from table: iter: 2: stack size
> -ok 62 - ipairs, from table: iterator ends
> -ok 63 - ipairs, from table: stack size
> -ok 64 - ipairs, from table: stack size
> -ok 65 - luafun iterator, from table: stack size
> -ok 66 - luafun iterator, from table: iter 0: gen() retval count
> -ok 67 - luafun iterator, from table: iter 0: gen() 1st retval
> -ok 68 - luafun iterator, from table: iter 0: gen() 2nd retval
> -ok 69 - luafun iterator, from table: iter: 0: stack size
> -ok 70 - luafun iterator, from table: iter 1: gen() retval count
> -ok 71 - luafun iterator, from table: iter 1: gen() 1st retval
> -ok 72 - luafun iterator, from table: iter 1: gen() 2nd retval
> -ok 73 - luafun iterator, from table: iter: 1: stack size
> -ok 74 - luafun iterator, from table: iter 2: gen() retval count
> -ok 75 - luafun iterator, from table: iter 2: gen() 1st retval
> -ok 76 - luafun iterator, from table: iter 2: gen() 2nd retval
> -ok 77 - luafun iterator, from table: iter: 2: stack size
> -ok 78 - luafun iterator, from table: iterator ends
> -ok 79 - luafun iterator, from table: stack size
> -ok 80 - luafun iterator, from table: stack size
> -ok 81 - lua error: stack size
> -ok 82 - lua error: iterator error
> -ok 83 - lua error: check error type
> -ok 84 - lua error: check error message
> -ok 85 - lua error: stack size
> -ok 86 - lua error: stack size
> -	*** main: done ***
> diff --git a/test/unit/luaT_tuple_new.result b/test/unit/luaT_tuple_new.result
> deleted file mode 100644
> index 110aa68c2..000000000
> --- a/test/unit/luaT_tuple_new.result
> +++ /dev/null
> @@ -1,22 +0,0 @@
> -1..19
> -	*** test_basic ***
> -ok 1 - table: tuple != NULL
> -ok 2 - table: check tuple format id
> -ok 3 - table: check tuple size
> -ok 4 - table: check tuple data
> -ok 5 - table: check retvals count
> -ok 6 - tuple: tuple != NULL
> -ok 7 - tuple: check tuple format id
> -ok 8 - tuple: check tuple size
> -ok 9 - tuple: check tuple data
> -ok 10 - tuple: check retvals count
> -ok 11 - objects: tuple != NULL
> -ok 12 - objects: check tuple format id
> -ok 13 - objects: check tuple size
> -ok 14 - objects: check tuple data
> -ok 15 - objects: check retvals count
> -ok 16 - unexpected type: tuple == NULL
> -ok 17 - unexpected type: check retvals count
> -ok 18 - unexpected type: check error type
> -ok 19 - unexpected type: check error message
> -	*** test_basic: done ***
> diff --git a/test/unit/merger.result b/test/unit/merger.result
> deleted file mode 100644
> index 766ebce63..000000000
> --- a/test/unit/merger.result
> +++ /dev/null
> @@ -1,71 +0,0 @@
> -1..4
> -	*** test_basic ***
> -    1..9
> -	*** test_array_source ***
> -    ok 1 - array source next() (any format): tuple != NULL
> -    ok 2 - array source next() (any format): skip tuple validation
> -    ok 3 - array source next() (any format): check tuple size
> -    ok 4 - array source next() (any format): check tuple data
> -    ok 5 - array source next() (any format): tuple != NULL
> -    ok 6 - array source next() (any format): skip tuple validation
> -    ok 7 - array source next() (any format): check tuple size
> -    ok 8 - array source next() (any format): check tuple data
> -    ok 9 - array source is empty (any format)
> -	*** test_array_source: done ***
> -ok 1 - subtests
> -    1..9
> -	*** test_array_source ***
> -    ok 1 - array source next() (user's format): tuple != NULL
> -    ok 2 - array source next() (user's format): validate tuple
> -    ok 3 - array source next() (user's format): check tuple size
> -    ok 4 - array source next() (user's format): check tuple data
> -    ok 5 - array source next() (user's format): tuple != NULL
> -    ok 6 - array source next() (user's format): validate tuple
> -    ok 7 - array source next() (user's format): check tuple size
> -    ok 8 - array source next() (user's format): check tuple data
> -    ok 9 - array source is empty (user's format)
> -	*** test_array_source: done ***
> -ok 2 - subtests
> -    1..17
> -	*** test_merger ***
> -    ok 1 - merger next() (any format): tuple != NULL
> -    ok 2 - merger next() (any format): skip tuple validation
> -    ok 3 - merger next() (any format): check tuple size
> -    ok 4 - merger next() (any format): check tuple data
> -    ok 5 - merger next() (any format): tuple != NULL
> -    ok 6 - merger next() (any format): skip tuple validation
> -    ok 7 - merger next() (any format): check tuple size
> -    ok 8 - merger next() (any format): check tuple data
> -    ok 9 - merger next() (any format): tuple != NULL
> -    ok 10 - merger next() (any format): skip tuple validation
> -    ok 11 - merger next() (any format): check tuple size
> -    ok 12 - merger next() (any format): check tuple data
> -    ok 13 - merger next() (any format): tuple != NULL
> -    ok 14 - merger next() (any format): skip tuple validation
> -    ok 15 - merger next() (any format): check tuple size
> -    ok 16 - merger next() (any format): check tuple data
> -    ok 17 - merger is empty (any format)
> -	*** test_merger: done ***
> -ok 3 - subtests
> -    1..17
> -	*** test_merger ***
> -    ok 1 - merger next() (user's format): tuple != NULL
> -    ok 2 - merger next() (user's format): validate tuple
> -    ok 3 - merger next() (user's format): check tuple size
> -    ok 4 - merger next() (user's format): check tuple data
> -    ok 5 - merger next() (user's format): tuple != NULL
> -    ok 6 - merger next() (user's format): validate tuple
> -    ok 7 - merger next() (user's format): check tuple size
> -    ok 8 - merger next() (user's format): check tuple data
> -    ok 9 - merger next() (user's format): tuple != NULL
> -    ok 10 - merger next() (user's format): validate tuple
> -    ok 11 - merger next() (user's format): check tuple size
> -    ok 12 - merger next() (user's format): check tuple data
> -    ok 13 - merger next() (user's format): tuple != NULL
> -    ok 14 - merger next() (user's format): validate tuple
> -    ok 15 - merger next() (user's format): check tuple size
> -    ok 16 - merger next() (user's format): check tuple data
> -    ok 17 - merger is empty (user's format)
> -	*** test_merger: done ***
> -ok 4 - subtests
> -	*** test_basic: done ***
> diff --git a/test/unit/mhash.result b/test/unit/mhash.result
> deleted file mode 100644
> index fc757fa35..000000000
> --- a/test/unit/mhash.result
> +++ /dev/null
> @@ -1,18 +0,0 @@
> -	*** main ***
> -1..3
> -	*** mhash_int32_id_test ***
> -    1..0
> -	*** mhash_int32_id_test: done ***
> -ok 1 - subtests
> -	*** mhash_int32_collision_test ***
> -    1..0
> -	*** mhash_int32_collision_test: done ***
> -ok 2 - subtests
> -	*** mhash_random_test ***
> -    1..3
> -    ok 1 - empty random is always 'end'
> -    ok 2 - one element is always found
> -    ok 3 - incremental random from mutable hash
> -ok 3 - subtests
> -	*** mhash_random_test: done ***
> -	*** main: done ***
> diff --git a/test/unit/mhash_bytemap.result b/test/unit/mhash_bytemap.result
> deleted file mode 100644
> index fc757fa35..000000000
> --- a/test/unit/mhash_bytemap.result
> +++ /dev/null
> @@ -1,18 +0,0 @@
> -	*** main ***
> -1..3
> -	*** mhash_int32_id_test ***
> -    1..0
> -	*** mhash_int32_id_test: done ***
> -ok 1 - subtests
> -	*** mhash_int32_collision_test ***
> -    1..0
> -	*** mhash_int32_collision_test: done ***
> -ok 2 - subtests
> -	*** mhash_random_test ***
> -    1..3
> -    ok 1 - empty random is always 'end'
> -    ok 2 - one element is always found
> -    ok 3 - incremental random from mutable hash
> -ok 3 - subtests
> -	*** mhash_random_test: done ***
> -	*** main: done ***
> diff --git a/test/unit/mp_error.result b/test/unit/mp_error.result
> deleted file mode 100644
> index 6ef37b4d5..000000000
> --- a/test/unit/mp_error.result
> +++ /dev/null
> @@ -1,44 +0,0 @@
> -	*** main ***
> -1..5
> -	*** test_stack_error_decode ***
> -    1..17
> -    ok 1 - check CustomError
> -    ok 2 - check AccessDeniedError
> -    ok 3 - check ClientError
> -    ok 4 - check XlogError
> -    ok 5 - check XlogGapError
> -    ok 6 - check SystemError
> -    ok 7 - check SocketError
> -    ok 8 - check OutOfMemory
> -    ok 9 - check TimedOut
> -    ok 10 - check ChannelIsClosed
> -    ok 11 - check FiberIsCancelled
> -    ok 12 - check LuajitError
> -    ok 13 - check IllegalParams
> -    ok 14 - check CollationError
> -    ok 15 - check SwimError
> -    ok 16 - check CryptoError
> -    ok 17 - stack size
> -ok 1 - subtests
> -	*** test_stack_error_decode: done ***
> -	*** test_decode_unknown_type ***
> -    1..1
> -    ok 1 - check SomeNewError
> -ok 2 - subtests
> -	*** test_decode_unknown_type: done ***
> -	*** test_fail_not_enough_fields ***
> -    1..2
> -    ok 1 - check not enough additional fields
> -    ok 2 - error about parsing problem is set
> -ok 3 - subtests
> -	*** test_fail_not_enough_fields: done ***
> -	*** test_unknown_fields ***
> -    1..1
> -    ok 1 - check unknown fields
> -ok 4 - subtests
> -	*** test_unknown_additional_fields ***
> -    1..1
> -    ok 1 - check unknown additional field
> -ok 5 - subtests
> -	*** test_unknown_additional_fields: done ***
> -	*** main: done ***
> diff --git a/test/unit/msgpack.result b/test/unit/msgpack.result
> deleted file mode 100644
> index 02c0b05fd..000000000
> --- a/test/unit/msgpack.result
> +++ /dev/null
> @@ -1,2282 +0,0 @@
> -1..22
> -    1..135
> -    # *** test_uints ***
> -    # uint 0U
> -    ok 1 - mp_check_uint(0U) == 0
> -    ok 2 - mp_decode(mp_encode(0U)) == 0U
> -    ok 3 - mp_check(0U)
> -    ok 4 - len(mp_encode_uint(0U)
> -    ok 5 - len(mp_decode_uint(0U))
> -    ok 6 - len(mp_next_uint(0U))
> -    ok 7 - len(mp_check_uint(0U))
> -    ok 8 - mp_sizeof_uint(0U)
> -    ok 9 - mp_encode(0U) == "\x00"
> -    # uint 1U
> -    ok 10 - mp_check_uint(1U) == 0
> -    ok 11 - mp_decode(mp_encode(1U)) == 1U
> -    ok 12 - mp_check(1U)
> -    ok 13 - len(mp_encode_uint(1U)
> -    ok 14 - len(mp_decode_uint(1U))
> -    ok 15 - len(mp_next_uint(1U))
> -    ok 16 - len(mp_check_uint(1U))
> -    ok 17 - mp_sizeof_uint(1U)
> -    ok 18 - mp_encode(1U) == "\x01"
> -    # uint 0x7eU
> -    ok 19 - mp_check_uint(0x7eU) == 0
> -    ok 20 - mp_decode(mp_encode(0x7eU)) == 0x7eU
> -    ok 21 - mp_check(0x7eU)
> -    ok 22 - len(mp_encode_uint(0x7eU)
> -    ok 23 - len(mp_decode_uint(0x7eU))
> -    ok 24 - len(mp_next_uint(0x7eU))
> -    ok 25 - len(mp_check_uint(0x7eU))
> -    ok 26 - mp_sizeof_uint(0x7eU)
> -    ok 27 - mp_encode(0x7eU) == "\x7e"
> -    # uint 0x7fU
> -    ok 28 - mp_check_uint(0x7fU) == 0
> -    ok 29 - mp_decode(mp_encode(0x7fU)) == 0x7fU
> -    ok 30 - mp_check(0x7fU)
> -    ok 31 - len(mp_encode_uint(0x7fU)
> -    ok 32 - len(mp_decode_uint(0x7fU))
> -    ok 33 - len(mp_next_uint(0x7fU))
> -    ok 34 - len(mp_check_uint(0x7fU))
> -    ok 35 - mp_sizeof_uint(0x7fU)
> -    ok 36 - mp_encode(0x7fU) == "\x7f"
> -    # uint 0x80U
> -    ok 37 - mp_check_uint(0x80U) == 0
> -    ok 38 - mp_decode(mp_encode(0x80U)) == 0x80U
> -    ok 39 - mp_check(0x80U)
> -    ok 40 - len(mp_encode_uint(0x80U)
> -    ok 41 - len(mp_decode_uint(0x80U))
> -    ok 42 - len(mp_next_uint(0x80U))
> -    ok 43 - len(mp_check_uint(0x80U))
> -    ok 44 - mp_sizeof_uint(0x80U)
> -    ok 45 - mp_encode(0x80U) == "\xcc\x80"
> -    # uint 0xfeU
> -    ok 46 - mp_check_uint(0xfeU) == 0
> -    ok 47 - mp_decode(mp_encode(0xfeU)) == 0xfeU
> -    ok 48 - mp_check(0xfeU)
> -    ok 49 - len(mp_encode_uint(0xfeU)
> -    ok 50 - len(mp_decode_uint(0xfeU))
> -    ok 51 - len(mp_next_uint(0xfeU))
> -    ok 52 - len(mp_check_uint(0xfeU))
> -    ok 53 - mp_sizeof_uint(0xfeU)
> -    ok 54 - mp_encode(0xfeU) == "\xcc\xfe"
> -    # uint 0xffU
> -    ok 55 - mp_check_uint(0xffU) == 0
> -    ok 56 - mp_decode(mp_encode(0xffU)) == 0xffU
> -    ok 57 - mp_check(0xffU)
> -    ok 58 - len(mp_encode_uint(0xffU)
> -    ok 59 - len(mp_decode_uint(0xffU))
> -    ok 60 - len(mp_next_uint(0xffU))
> -    ok 61 - len(mp_check_uint(0xffU))
> -    ok 62 - mp_sizeof_uint(0xffU)
> -    ok 63 - mp_encode(0xffU) == "\xcc\xff"
> -    # uint 0xfffeU
> -    ok 64 - mp_check_uint(0xfffeU) == 0
> -    ok 65 - mp_decode(mp_encode(0xfffeU)) == 0xfffeU
> -    ok 66 - mp_check(0xfffeU)
> -    ok 67 - len(mp_encode_uint(0xfffeU)
> -    ok 68 - len(mp_decode_uint(0xfffeU))
> -    ok 69 - len(mp_next_uint(0xfffeU))
> -    ok 70 - len(mp_check_uint(0xfffeU))
> -    ok 71 - mp_sizeof_uint(0xfffeU)
> -    ok 72 - mp_encode(0xfffeU) == "\xcd\xff\xfe"
> -    # uint 0xffffU
> -    ok 73 - mp_check_uint(0xffffU) == 0
> -    ok 74 - mp_decode(mp_encode(0xffffU)) == 0xffffU
> -    ok 75 - mp_check(0xffffU)
> -    ok 76 - len(mp_encode_uint(0xffffU)
> -    ok 77 - len(mp_decode_uint(0xffffU))
> -    ok 78 - len(mp_next_uint(0xffffU))
> -    ok 79 - len(mp_check_uint(0xffffU))
> -    ok 80 - mp_sizeof_uint(0xffffU)
> -    ok 81 - mp_encode(0xffffU) == "\xcd\xff\xff"
> -    # uint 0x10000U
> -    ok 82 - mp_check_uint(0x10000U) == 0
> -    ok 83 - mp_decode(mp_encode(0x10000U)) == 0x10000U
> -    ok 84 - mp_check(0x10000U)
> -    ok 85 - len(mp_encode_uint(0x10000U)
> -    ok 86 - len(mp_decode_uint(0x10000U))
> -    ok 87 - len(mp_next_uint(0x10000U))
> -    ok 88 - len(mp_check_uint(0x10000U))
> -    ok 89 - mp_sizeof_uint(0x10000U)
> -    ok 90 - mp_encode(0x10000U) == "\xce\x00\x01\x00\x00"
> -    # uint 0xfffffffeU
> -    ok 91 - mp_check_uint(0xfffffffeU) == 0
> -    ok 92 - mp_decode(mp_encode(0xfffffffeU)) == 0xfffffffeU
> -    ok 93 - mp_check(0xfffffffeU)
> -    ok 94 - len(mp_encode_uint(0xfffffffeU)
> -    ok 95 - len(mp_decode_uint(0xfffffffeU))
> -    ok 96 - len(mp_next_uint(0xfffffffeU))
> -    ok 97 - len(mp_check_uint(0xfffffffeU))
> -    ok 98 - mp_sizeof_uint(0xfffffffeU)
> -    ok 99 - mp_encode(0xfffffffeU) == "\xce\xff\xff\xff\xfe"
> -    # uint 0xffffffffU
> -    ok 100 - mp_check_uint(0xffffffffU) == 0
> -    ok 101 - mp_decode(mp_encode(0xffffffffU)) == 0xffffffffU
> -    ok 102 - mp_check(0xffffffffU)
> -    ok 103 - len(mp_encode_uint(0xffffffffU)
> -    ok 104 - len(mp_decode_uint(0xffffffffU))
> -    ok 105 - len(mp_next_uint(0xffffffffU))
> -    ok 106 - len(mp_check_uint(0xffffffffU))
> -    ok 107 - mp_sizeof_uint(0xffffffffU)
> -    ok 108 - mp_encode(0xffffffffU) == "\xce\xff\xff\xff\xff"
> -    # uint 0x100000000ULL
> -    ok 109 - mp_check_uint(0x100000000ULL) == 0
> -    ok 110 - mp_decode(mp_encode(0x100000000ULL)) == 0x100000000ULL
> -    ok 111 - mp_check(0x100000000ULL)
> -    ok 112 - len(mp_encode_uint(0x100000000ULL)
> -    ok 113 - len(mp_decode_uint(0x100000000ULL))
> -    ok 114 - len(mp_next_uint(0x100000000ULL))
> -    ok 115 - len(mp_check_uint(0x100000000ULL))
> -    ok 116 - mp_sizeof_uint(0x100000000ULL)
> -    ok 117 - mp_encode(0x100000000ULL) == "\xcf\x00\x00\x00\x01\x00\x00\x00\x00"
> -    # uint 0xfffffffffffffffeULL
> -    ok 118 - mp_check_uint(0xfffffffffffffffeULL) == 0
> -    ok 119 - mp_decode(mp_encode(0xfffffffffffffffeULL)) == 0xfffffffffffffffeULL
> -    ok 120 - mp_check(0xfffffffffffffffeULL)
> -    ok 121 - len(mp_encode_uint(0xfffffffffffffffeULL)
> -    ok 122 - len(mp_decode_uint(0xfffffffffffffffeULL))
> -    ok 123 - len(mp_next_uint(0xfffffffffffffffeULL))
> -    ok 124 - len(mp_check_uint(0xfffffffffffffffeULL))
> -    ok 125 - mp_sizeof_uint(0xfffffffffffffffeULL)
> -    ok 126 - mp_encode(0xfffffffffffffffeULL) == "\xcf\xff\xff\xff\xff\xff\xff\xff\xfe"
> -    # uint 0xffffffffffffffffULL
> -    ok 127 - mp_check_uint(0xffffffffffffffffULL) == 0
> -    ok 128 - mp_decode(mp_encode(0xffffffffffffffffULL)) == 0xffffffffffffffffULL
> -    ok 129 - mp_check(0xffffffffffffffffULL)
> -    ok 130 - len(mp_encode_uint(0xffffffffffffffffULL)
> -    ok 131 - len(mp_decode_uint(0xffffffffffffffffULL))
> -    ok 132 - len(mp_next_uint(0xffffffffffffffffULL))
> -    ok 133 - len(mp_check_uint(0xffffffffffffffffULL))
> -    ok 134 - mp_sizeof_uint(0xffffffffffffffffULL)
> -    ok 135 - mp_encode(0xffffffffffffffffULL) == "\xcf\xff\xff\xff\xff\xff\xff\xff\xff"
> -    # *** test_uints: done ***
> -ok 1 - subtests
> -    1..153
> -    # *** test_ints ***
> -    # int -0x01
> -    ok 1 - mp_check_int(-0x01) == 0
> -    ok 2 - mp_decode(mp_encode(-0x01)) == -0x01
> -    ok 3 - mp_check(-0x01)
> -    ok 4 - len(mp_encode_int(-0x01)
> -    ok 5 - len(mp_decode_int(-0x01))
> -    ok 6 - len(mp_next_int(-0x01))
> -    ok 7 - len(mp_check_int(-0x01))
> -    ok 8 - mp_sizeof_int(-0x01)
> -    ok 9 - mp_encode(-0x01) == "\xff"
> -    # int -0x1e
> -    ok 10 - mp_check_int(-0x1e) == 0
> -    ok 11 - mp_decode(mp_encode(-0x1e)) == -0x1e
> -    ok 12 - mp_check(-0x1e)
> -    ok 13 - len(mp_encode_int(-0x1e)
> -    ok 14 - len(mp_decode_int(-0x1e))
> -    ok 15 - len(mp_next_int(-0x1e))
> -    ok 16 - len(mp_check_int(-0x1e))
> -    ok 17 - mp_sizeof_int(-0x1e)
> -    ok 18 - mp_encode(-0x1e) == "\xe2"
> -    # int -0x1f
> -    ok 19 - mp_check_int(-0x1f) == 0
> -    ok 20 - mp_decode(mp_encode(-0x1f)) == -0x1f
> -    ok 21 - mp_check(-0x1f)
> -    ok 22 - len(mp_encode_int(-0x1f)
> -    ok 23 - len(mp_decode_int(-0x1f))
> -    ok 24 - len(mp_next_int(-0x1f))
> -    ok 25 - len(mp_check_int(-0x1f))
> -    ok 26 - mp_sizeof_int(-0x1f)
> -    ok 27 - mp_encode(-0x1f) == "\xe1"
> -    # int -0x20
> -    ok 28 - mp_check_int(-0x20) == 0
> -    ok 29 - mp_decode(mp_encode(-0x20)) == -0x20
> -    ok 30 - mp_check(-0x20)
> -    ok 31 - len(mp_encode_int(-0x20)
> -    ok 32 - len(mp_decode_int(-0x20))
> -    ok 33 - len(mp_next_int(-0x20))
> -    ok 34 - len(mp_check_int(-0x20))
> -    ok 35 - mp_sizeof_int(-0x20)
> -    ok 36 - mp_encode(-0x20) == "\xe0"
> -    # int -0x21
> -    ok 37 - mp_check_int(-0x21) == 0
> -    ok 38 - mp_decode(mp_encode(-0x21)) == -0x21
> -    ok 39 - mp_check(-0x21)
> -    ok 40 - len(mp_encode_int(-0x21)
> -    ok 41 - len(mp_decode_int(-0x21))
> -    ok 42 - len(mp_next_int(-0x21))
> -    ok 43 - len(mp_check_int(-0x21))
> -    ok 44 - mp_sizeof_int(-0x21)
> -    ok 45 - mp_encode(-0x21) == "\xd0\xdf"
> -    # int -0x7f
> -    ok 46 - mp_check_int(-0x7f) == 0
> -    ok 47 - mp_decode(mp_encode(-0x7f)) == -0x7f
> -    ok 48 - mp_check(-0x7f)
> -    ok 49 - len(mp_encode_int(-0x7f)
> -    ok 50 - len(mp_decode_int(-0x7f))
> -    ok 51 - len(mp_next_int(-0x7f))
> -    ok 52 - len(mp_check_int(-0x7f))
> -    ok 53 - mp_sizeof_int(-0x7f)
> -    ok 54 - mp_encode(-0x7f) == "\xd0\x81"
> -    # int -0x80
> -    ok 55 - mp_check_int(-0x80) == 0
> -    ok 56 - mp_decode(mp_encode(-0x80)) == -0x80
> -    ok 57 - mp_check(-0x80)
> -    ok 58 - len(mp_encode_int(-0x80)
> -    ok 59 - len(mp_decode_int(-0x80))
> -    ok 60 - len(mp_next_int(-0x80))
> -    ok 61 - len(mp_check_int(-0x80))
> -    ok 62 - mp_sizeof_int(-0x80)
> -    ok 63 - mp_encode(-0x80) == "\xd0\x80"
> -    # int -0x81
> -    ok 64 - mp_check_int(-0x81) == 0
> -    ok 65 - mp_decode(mp_encode(-0x81)) == -0x81
> -    ok 66 - mp_check(-0x81)
> -    ok 67 - len(mp_encode_int(-0x81)
> -    ok 68 - len(mp_decode_int(-0x81))
> -    ok 69 - len(mp_next_int(-0x81))
> -    ok 70 - len(mp_check_int(-0x81))
> -    ok 71 - mp_sizeof_int(-0x81)
> -    ok 72 - mp_encode(-0x81) == "\xd1\xff\x7f"
> -    # int -0x7fff
> -    ok 73 - mp_check_int(-0x7fff) == 0
> -    ok 74 - mp_decode(mp_encode(-0x7fff)) == -0x7fff
> -    ok 75 - mp_check(-0x7fff)
> -    ok 76 - len(mp_encode_int(-0x7fff)
> -    ok 77 - len(mp_decode_int(-0x7fff))
> -    ok 78 - len(mp_next_int(-0x7fff))
> -    ok 79 - len(mp_check_int(-0x7fff))
> -    ok 80 - mp_sizeof_int(-0x7fff)
> -    ok 81 - mp_encode(-0x7fff) == "\xd1\x80\x01"
> -    # int -0x8000
> -    ok 82 - mp_check_int(-0x8000) == 0
> -    ok 83 - mp_decode(mp_encode(-0x8000)) == -0x8000
> -    ok 84 - mp_check(-0x8000)
> -    ok 85 - len(mp_encode_int(-0x8000)
> -    ok 86 - len(mp_decode_int(-0x8000))
> -    ok 87 - len(mp_next_int(-0x8000))
> -    ok 88 - len(mp_check_int(-0x8000))
> -    ok 89 - mp_sizeof_int(-0x8000)
> -    ok 90 - mp_encode(-0x8000) == "\xd1\x80\x00"
> -    # int -0x8001
> -    ok 91 - mp_check_int(-0x8001) == 0
> -    ok 92 - mp_decode(mp_encode(-0x8001)) == -0x8001
> -    ok 93 - mp_check(-0x8001)
> -    ok 94 - len(mp_encode_int(-0x8001)
> -    ok 95 - len(mp_decode_int(-0x8001))
> -    ok 96 - len(mp_next_int(-0x8001))
> -    ok 97 - len(mp_check_int(-0x8001))
> -    ok 98 - mp_sizeof_int(-0x8001)
> -    ok 99 - mp_encode(-0x8001) == "\xd2\xff\xff\x7f\xff"
> -    # int -0x7fffffff
> -    ok 100 - mp_check_int(-0x7fffffff) == 0
> -    ok 101 - mp_decode(mp_encode(-0x7fffffff)) == -0x7fffffff
> -    ok 102 - mp_check(-0x7fffffff)
> -    ok 103 - len(mp_encode_int(-0x7fffffff)
> -    ok 104 - len(mp_decode_int(-0x7fffffff))
> -    ok 105 - len(mp_next_int(-0x7fffffff))
> -    ok 106 - len(mp_check_int(-0x7fffffff))
> -    ok 107 - mp_sizeof_int(-0x7fffffff)
> -    ok 108 - mp_encode(-0x7fffffff) == "\xd2\x80\x00\x00\x01"
> -    # int -0x80000000LL
> -    ok 109 - mp_check_int(-0x80000000LL) == 0
> -    ok 110 - mp_decode(mp_encode(-0x80000000LL)) == -0x80000000LL
> -    ok 111 - mp_check(-0x80000000LL)
> -    ok 112 - len(mp_encode_int(-0x80000000LL)
> -    ok 113 - len(mp_decode_int(-0x80000000LL))
> -    ok 114 - len(mp_next_int(-0x80000000LL))
> -    ok 115 - len(mp_check_int(-0x80000000LL))
> -    ok 116 - mp_sizeof_int(-0x80000000LL)
> -    ok 117 - mp_encode(-0x80000000LL) == "\xd2\x80\x00\x00\x00"
> -    # int -0x80000001LL
> -    ok 118 - mp_check_int(-0x80000001LL) == 0
> -    ok 119 - mp_decode(mp_encode(-0x80000001LL)) == -0x80000001LL
> -    ok 120 - mp_check(-0x80000001LL)
> -    ok 121 - len(mp_encode_int(-0x80000001LL)
> -    ok 122 - len(mp_decode_int(-0x80000001LL))
> -    ok 123 - len(mp_next_int(-0x80000001LL))
> -    ok 124 - len(mp_check_int(-0x80000001LL))
> -    ok 125 - mp_sizeof_int(-0x80000001LL)
> -    ok 126 - mp_encode(-0x80000001LL) == "\xd3\xff\xff\xff\xff\x7f\xff\xff\xff"
> -    # int -0x80000001LL
> -    ok 127 - mp_check_int(-0x80000001LL) == 0
> -    ok 128 - mp_decode(mp_encode(-0x80000001LL)) == -0x80000001LL
> -    ok 129 - mp_check(-0x80000001LL)
> -    ok 130 - len(mp_encode_int(-0x80000001LL)
> -    ok 131 - len(mp_decode_int(-0x80000001LL))
> -    ok 132 - len(mp_next_int(-0x80000001LL))
> -    ok 133 - len(mp_check_int(-0x80000001LL))
> -    ok 134 - mp_sizeof_int(-0x80000001LL)
> -    ok 135 - mp_encode(-0x80000001LL) == "\xd3\xff\xff\xff\xff\x7f\xff\xff\xff"
> -    # int -0x7fffffffffffffffLL
> -    ok 136 - mp_check_int(-0x7fffffffffffffffLL) == 0
> -    ok 137 - mp_decode(mp_encode(-0x7fffffffffffffffLL)) == -0x7fffffffffffffffLL
> -    ok 138 - mp_check(-0x7fffffffffffffffLL)
> -    ok 139 - len(mp_encode_int(-0x7fffffffffffffffLL)
> -    ok 140 - len(mp_decode_int(-0x7fffffffffffffffLL))
> -    ok 141 - len(mp_next_int(-0x7fffffffffffffffLL))
> -    ok 142 - len(mp_check_int(-0x7fffffffffffffffLL))
> -    ok 143 - mp_sizeof_int(-0x7fffffffffffffffLL)
> -    ok 144 - mp_encode(-0x7fffffffffffffffLL) == "\xd3\x80\x00\x00\x00\x00\x00\x00\x01"
> -    # int (int64_t)-0x8000000000000000LL
> -    ok 145 - mp_check_int((int64_t)-0x8000000000000000LL) == 0
> -    ok 146 - mp_decode(mp_encode((int64_t)-0x8000000000000000LL)) == (int64_t)-0x8000000000000000LL
> -    ok 147 - mp_check((int64_t)-0x8000000000000000LL)
> -    ok 148 - len(mp_encode_int((int64_t)-0x8000000000000000LL)
> -    ok 149 - len(mp_decode_int((int64_t)-0x8000000000000000LL))
> -    ok 150 - len(mp_next_int((int64_t)-0x8000000000000000LL))
> -    ok 151 - len(mp_check_int((int64_t)-0x8000000000000000LL))
> -    ok 152 - mp_sizeof_int((int64_t)-0x8000000000000000LL)
> -    ok 153 - mp_encode((int64_t)-0x8000000000000000LL) == "\xd3\x80\x00\x00\x00\x00\x00\x00\x00"
> -    # *** test_ints: done ***
> -ok 2 - subtests
> -    1..18
> -    # *** test_bools ***
> -    # bool 1
> -    ok 1 - mp_check_bool(1) == 0
> -    ok 2 - mp_decode(mp_encode(1)) == 1
> -    ok 3 - mp_check(1)
> -    ok 4 - len(mp_encode_bool(1)
> -    ok 5 - len(mp_decode_bool(1))
> -    ok 6 - len(mp_next_bool(1))
> -    ok 7 - len(mp_check_bool(1))
> -    ok 8 - mp_sizeof_bool(1)
> -    ok 9 - mp_encode(1) == "\xc3"
> -    # bool 0
> -    ok 10 - mp_check_bool(0) == 0
> -    ok 11 - mp_decode(mp_encode(0)) == 0
> -    ok 12 - mp_check(0)
> -    ok 13 - len(mp_encode_bool(0)
> -    ok 14 - len(mp_decode_bool(0))
> -    ok 15 - len(mp_next_bool(0))
> -    ok 16 - len(mp_check_bool(0))
> -    ok 17 - mp_sizeof_bool(0)
> -    ok 18 - mp_encode(0) == "\xc2"
> -    # *** test_bools: done ***
> -ok 3 - subtests
> -    1..27
> -    # *** test_floats ***
> -    # float (float) 1.0
> -    ok 1 - mp_check_float((float) 1.0) == 0
> -    ok 2 - mp_decode(mp_encode((float) 1.0)) == (float) 1.0
> -    ok 3 - mp_check((float) 1.0)
> -    ok 4 - len(mp_encode_float((float) 1.0)
> -    ok 5 - len(mp_decode_float((float) 1.0))
> -    ok 6 - len(mp_next_float((float) 1.0))
> -    ok 7 - len(mp_check_float((float) 1.0))
> -    ok 8 - mp_sizeof_float((float) 1.0)
> -    ok 9 - mp_encode((float) 1.0) == "\xca\x3f\x80\x00\x00"
> -    # float (float) 3.141593
> -    ok 10 - mp_check_float((float) 3.141593) == 0
> -    ok 11 - mp_decode(mp_encode((float) 3.141593)) == (float) 3.141593
> -    ok 12 - mp_check((float) 3.141593)
> -    ok 13 - len(mp_encode_float((float) 3.141593)
> -    ok 14 - len(mp_decode_float((float) 3.141593))
> -    ok 15 - len(mp_next_float((float) 3.141593))
> -    ok 16 - len(mp_check_float((float) 3.141593))
> -    ok 17 - mp_sizeof_float((float) 3.141593)
> -    ok 18 - mp_encode((float) 3.141593) == "\xca\x40\x49\x0f\xdc"
> -    # float (float) -1e38f
> -    ok 19 - mp_check_float((float) -1e38f) == 0
> -    ok 20 - mp_decode(mp_encode((float) -1e38f)) == (float) -1e38f
> -    ok 21 - mp_check((float) -1e38f)
> -    ok 22 - len(mp_encode_float((float) -1e38f)
> -    ok 23 - len(mp_decode_float((float) -1e38f))
> -    ok 24 - len(mp_next_float((float) -1e38f))
> -    ok 25 - len(mp_check_float((float) -1e38f))
> -    ok 26 - mp_sizeof_float((float) -1e38f)
> -    ok 27 - mp_encode((float) -1e38f) == "\xca\xfe\x96\x76\x99"
> -    # *** test_floats: done ***
> -ok 4 - subtests
> -    1..27
> -    # *** test_doubles ***
> -    # double (double) 1.0
> -    ok 1 - mp_check_double((double) 1.0) == 0
> -    ok 2 - mp_decode(mp_encode((double) 1.0)) == (double) 1.0
> -    ok 3 - mp_check((double) 1.0)
> -    ok 4 - len(mp_encode_double((double) 1.0)
> -    ok 5 - len(mp_decode_double((double) 1.0))
> -    ok 6 - len(mp_next_double((double) 1.0))
> -    ok 7 - len(mp_check_double((double) 1.0))
> -    ok 8 - mp_sizeof_double((double) 1.0)
> -    ok 9 - mp_encode((double) 1.0) == "\xcb\x3f\xf0\x00\x00\x00\x00\x00\x00"
> -    # double (double) 3.141592653589793
> -    ok 10 - mp_check_double((double) 3.141592653589793) == 0
> -    ok 11 - mp_decode(mp_encode((double) 3.141592653589793)) == (double) 3.141592653589793
> -    ok 12 - mp_check((double) 3.141592653589793)
> -    ok 13 - len(mp_encode_double((double) 3.141592653589793)
> -    ok 14 - len(mp_decode_double((double) 3.141592653589793))
> -    ok 15 - len(mp_next_double((double) 3.141592653589793))
> -    ok 16 - len(mp_check_double((double) 3.141592653589793))
> -    ok 17 - mp_sizeof_double((double) 3.141592653589793)
> -    ok 18 - mp_encode((double) 3.141592653589793) == "\xcb\x40\x09\x21\xfb\x54\x44\x2d\x18"
> -    # double (double) -1e99
> -    ok 19 - mp_check_double((double) -1e99) == 0
> -    ok 20 - mp_decode(mp_encode((double) -1e99)) == (double) -1e99
> -    ok 21 - mp_check((double) -1e99)
> -    ok 22 - len(mp_encode_double((double) -1e99)
> -    ok 23 - len(mp_decode_double((double) -1e99))
> -    ok 24 - len(mp_next_double((double) -1e99))
> -    ok 25 - len(mp_check_double((double) -1e99))
> -    ok 26 - mp_sizeof_double((double) -1e99)
> -    ok 27 - mp_encode((double) -1e99) == "\xcb\xd4\x7d\x42\xae\xa2\x87\x9f\x2e"
> -    # *** test_doubles: done ***
> -ok 5 - subtests
> -    1..6
> -    # *** test_nils ***
> -    # nil
> -    ok 1 - mp_check_nil()
> -    ok 2 - len(mp_encode_nil() == 1
> -    ok 3 - len(mp_decode_nil()) == 1
> -    ok 4 - len(mp_next_nil()) == 1
> -    ok 5 - len(mp_check_nil()) == 1
> -    ok 6 - mp_sizeof_nil() == 1
> -    # *** test_nils: done ***
> -ok 6 - subtests
> -    1..78
> -    # *** test_strls ***
> -    # strl 0x00U
> -    ok 1 - mp_check_strl(0x00U) == 0
> -    ok 2 - mp_decode(mp_encode(0x00U)) == 0x00U
> -    ok 3 - len(mp_encode_strl(0x00U)
> -    ok 4 - len(mp_decode_strl(0x00U))
> -    ok 5 - mp_sizeof_strl(0x00U)
> -    ok 6 - mp_encode(0x00U) == "\xa0"
> -    # strl 0x01U
> -    ok 7 - mp_check_strl(0x01U) == 0
> -    ok 8 - mp_decode(mp_encode(0x01U)) == 0x01U
> -    ok 9 - len(mp_encode_strl(0x01U)
> -    ok 10 - len(mp_decode_strl(0x01U))
> -    ok 11 - mp_sizeof_strl(0x01U)
> -    ok 12 - mp_encode(0x01U) == "\xa1"
> -    # strl 0x1eU
> -    ok 13 - mp_check_strl(0x1eU) == 0
> -    ok 14 - mp_decode(mp_encode(0x1eU)) == 0x1eU
> -    ok 15 - len(mp_encode_strl(0x1eU)
> -    ok 16 - len(mp_decode_strl(0x1eU))
> -    ok 17 - mp_sizeof_strl(0x1eU)
> -    ok 18 - mp_encode(0x1eU) == "\xbe"
> -    # strl 0x1fU
> -    ok 19 - mp_check_strl(0x1fU) == 0
> -    ok 20 - mp_decode(mp_encode(0x1fU)) == 0x1fU
> -    ok 21 - len(mp_encode_strl(0x1fU)
> -    ok 22 - len(mp_decode_strl(0x1fU))
> -    ok 23 - mp_sizeof_strl(0x1fU)
> -    ok 24 - mp_encode(0x1fU) == "\xbf"
> -    # strl 0x20U
> -    ok 25 - mp_check_strl(0x20U) == 0
> -    ok 26 - mp_decode(mp_encode(0x20U)) == 0x20U
> -    ok 27 - len(mp_encode_strl(0x20U)
> -    ok 28 - len(mp_decode_strl(0x20U))
> -    ok 29 - mp_sizeof_strl(0x20U)
> -    ok 30 - mp_encode(0x20U) == "\xd9\x20"
> -    # strl 0xfeU
> -    ok 31 - mp_check_strl(0xfeU) == 0
> -    ok 32 - mp_decode(mp_encode(0xfeU)) == 0xfeU
> -    ok 33 - len(mp_encode_strl(0xfeU)
> -    ok 34 - len(mp_decode_strl(0xfeU))
> -    ok 35 - mp_sizeof_strl(0xfeU)
> -    ok 36 - mp_encode(0xfeU) == "\xd9\xfe"
> -    # strl 0xffU
> -    ok 37 - mp_check_strl(0xffU) == 0
> -    ok 38 - mp_decode(mp_encode(0xffU)) == 0xffU
> -    ok 39 - len(mp_encode_strl(0xffU)
> -    ok 40 - len(mp_decode_strl(0xffU))
> -    ok 41 - mp_sizeof_strl(0xffU)
> -    ok 42 - mp_encode(0xffU) == "\xd9\xff"
> -    # strl 0x0100U
> -    ok 43 - mp_check_strl(0x0100U) == 0
> -    ok 44 - mp_decode(mp_encode(0x0100U)) == 0x0100U
> -    ok 45 - len(mp_encode_strl(0x0100U)
> -    ok 46 - len(mp_decode_strl(0x0100U))
> -    ok 47 - mp_sizeof_strl(0x0100U)
> -    ok 48 - mp_encode(0x0100U) == "\xda\x01\x00"
> -    # strl 0xfffeU
> -    ok 49 - mp_check_strl(0xfffeU) == 0
> -    ok 50 - mp_decode(mp_encode(0xfffeU)) == 0xfffeU
> -    ok 51 - len(mp_encode_strl(0xfffeU)
> -    ok 52 - len(mp_decode_strl(0xfffeU))
> -    ok 53 - mp_sizeof_strl(0xfffeU)
> -    ok 54 - mp_encode(0xfffeU) == "\xda\xff\xfe"
> -    # strl 0xffffU
> -    ok 55 - mp_check_strl(0xffffU) == 0
> -    ok 56 - mp_decode(mp_encode(0xffffU)) == 0xffffU
> -    ok 57 - len(mp_encode_strl(0xffffU)
> -    ok 58 - len(mp_decode_strl(0xffffU))
> -    ok 59 - mp_sizeof_strl(0xffffU)
> -    ok 60 - mp_encode(0xffffU) == "\xda\xff\xff"
> -    # strl 0x00010000U
> -    ok 61 - mp_check_strl(0x00010000U) == 0
> -    ok 62 - mp_decode(mp_encode(0x00010000U)) == 0x00010000U
> -    ok 63 - len(mp_encode_strl(0x00010000U)
> -    ok 64 - len(mp_decode_strl(0x00010000U))
> -    ok 65 - mp_sizeof_strl(0x00010000U)
> -    ok 66 - mp_encode(0x00010000U) == "\xdb\x00\x01\x00\x00"
> -    # strl 0xfffffffeU
> -    ok 67 - mp_check_strl(0xfffffffeU) == 0
> -    ok 68 - mp_decode(mp_encode(0xfffffffeU)) == 0xfffffffeU
> -    ok 69 - len(mp_encode_strl(0xfffffffeU)
> -    ok 70 - len(mp_decode_strl(0xfffffffeU))
> -    ok 71 - mp_sizeof_strl(0xfffffffeU)
> -    ok 72 - mp_encode(0xfffffffeU) == "\xdb\xff\xff\xff\xfe"
> -    # strl 0xffffffffU
> -    ok 73 - mp_check_strl(0xffffffffU) == 0
> -    ok 74 - mp_decode(mp_encode(0xffffffffU)) == 0xffffffffU
> -    ok 75 - len(mp_encode_strl(0xffffffffU)
> -    ok 76 - len(mp_decode_strl(0xffffffffU))
> -    ok 77 - mp_sizeof_strl(0xffffffffU)
> -    ok 78 - mp_encode(0xffffffffU) == "\xdb\xff\xff\xff\xff"
> -    # *** test_strls: done ***
> -ok 7 - subtests
> -    1..78
> -    # *** test_binls ***
> -    # binl 0x00U
> -    ok 1 - mp_check_binl(0x00U) == 0
> -    ok 2 - mp_decode(mp_encode(0x00U)) == 0x00U
> -    ok 3 - len(mp_encode_binl(0x00U)
> -    ok 4 - len(mp_decode_binl(0x00U))
> -    ok 5 - mp_sizeof_binl(0x00U)
> -    ok 6 - mp_encode(0x00U) == "\xc4\x00"
> -    # binl 0x01U
> -    ok 7 - mp_check_binl(0x01U) == 0
> -    ok 8 - mp_decode(mp_encode(0x01U)) == 0x01U
> -    ok 9 - len(mp_encode_binl(0x01U)
> -    ok 10 - len(mp_decode_binl(0x01U))
> -    ok 11 - mp_sizeof_binl(0x01U)
> -    ok 12 - mp_encode(0x01U) == "\xc4\x01"
> -    # binl 0x1eU
> -    ok 13 - mp_check_binl(0x1eU) == 0
> -    ok 14 - mp_decode(mp_encode(0x1eU)) == 0x1eU
> -    ok 15 - len(mp_encode_binl(0x1eU)
> -    ok 16 - len(mp_decode_binl(0x1eU))
> -    ok 17 - mp_sizeof_binl(0x1eU)
> -    ok 18 - mp_encode(0x1eU) == "\xc4\x1e"
> -    # binl 0x1fU
> -    ok 19 - mp_check_binl(0x1fU) == 0
> -    ok 20 - mp_decode(mp_encode(0x1fU)) == 0x1fU
> -    ok 21 - len(mp_encode_binl(0x1fU)
> -    ok 22 - len(mp_decode_binl(0x1fU))
> -    ok 23 - mp_sizeof_binl(0x1fU)
> -    ok 24 - mp_encode(0x1fU) == "\xc4\x1f"
> -    # binl 0x20U
> -    ok 25 - mp_check_binl(0x20U) == 0
> -    ok 26 - mp_decode(mp_encode(0x20U)) == 0x20U
> -    ok 27 - len(mp_encode_binl(0x20U)
> -    ok 28 - len(mp_decode_binl(0x20U))
> -    ok 29 - mp_sizeof_binl(0x20U)
> -    ok 30 - mp_encode(0x20U) == "\xc4\x20"
> -    # binl 0xfeU
> -    ok 31 - mp_check_binl(0xfeU) == 0
> -    ok 32 - mp_decode(mp_encode(0xfeU)) == 0xfeU
> -    ok 33 - len(mp_encode_binl(0xfeU)
> -    ok 34 - len(mp_decode_binl(0xfeU))
> -    ok 35 - mp_sizeof_binl(0xfeU)
> -    ok 36 - mp_encode(0xfeU) == "\xc4\xfe"
> -    # binl 0xffU
> -    ok 37 - mp_check_binl(0xffU) == 0
> -    ok 38 - mp_decode(mp_encode(0xffU)) == 0xffU
> -    ok 39 - len(mp_encode_binl(0xffU)
> -    ok 40 - len(mp_decode_binl(0xffU))
> -    ok 41 - mp_sizeof_binl(0xffU)
> -    ok 42 - mp_encode(0xffU) == "\xc4\xff"
> -    # binl 0x0100U
> -    ok 43 - mp_check_binl(0x0100U) == 0
> -    ok 44 - mp_decode(mp_encode(0x0100U)) == 0x0100U
> -    ok 45 - len(mp_encode_binl(0x0100U)
> -    ok 46 - len(mp_decode_binl(0x0100U))
> -    ok 47 - mp_sizeof_binl(0x0100U)
> -    ok 48 - mp_encode(0x0100U) == "\xc5\x01\x00"
> -    # binl 0xfffeU
> -    ok 49 - mp_check_binl(0xfffeU) == 0
> -    ok 50 - mp_decode(mp_encode(0xfffeU)) == 0xfffeU
> -    ok 51 - len(mp_encode_binl(0xfffeU)
> -    ok 52 - len(mp_decode_binl(0xfffeU))
> -    ok 53 - mp_sizeof_binl(0xfffeU)
> -    ok 54 - mp_encode(0xfffeU) == "\xc5\xff\xfe"
> -    # binl 0xffffU
> -    ok 55 - mp_check_binl(0xffffU) == 0
> -    ok 56 - mp_decode(mp_encode(0xffffU)) == 0xffffU
> -    ok 57 - len(mp_encode_binl(0xffffU)
> -    ok 58 - len(mp_decode_binl(0xffffU))
> -    ok 59 - mp_sizeof_binl(0xffffU)
> -    ok 60 - mp_encode(0xffffU) == "\xc5\xff\xff"
> -    # binl 0x00010000U
> -    ok 61 - mp_check_binl(0x00010000U) == 0
> -    ok 62 - mp_decode(mp_encode(0x00010000U)) == 0x00010000U
> -    ok 63 - len(mp_encode_binl(0x00010000U)
> -    ok 64 - len(mp_decode_binl(0x00010000U))
> -    ok 65 - mp_sizeof_binl(0x00010000U)
> -    ok 66 - mp_encode(0x00010000U) == "\xc6\x00\x01\x00\x00"
> -    # binl 0xfffffffeU
> -    ok 67 - mp_check_binl(0xfffffffeU) == 0
> -    ok 68 - mp_decode(mp_encode(0xfffffffeU)) == 0xfffffffeU
> -    ok 69 - len(mp_encode_binl(0xfffffffeU)
> -    ok 70 - len(mp_decode_binl(0xfffffffeU))
> -    ok 71 - mp_sizeof_binl(0xfffffffeU)
> -    ok 72 - mp_encode(0xfffffffeU) == "\xc6\xff\xff\xff\xfe"
> -    # binl 0xffffffffU
> -    ok 73 - mp_check_binl(0xffffffffU) == 0
> -    ok 74 - mp_decode(mp_encode(0xffffffffU)) == 0xffffffffU
> -    ok 75 - len(mp_encode_binl(0xffffffffU)
> -    ok 76 - len(mp_decode_binl(0xffffffffU))
> -    ok 77 - mp_sizeof_binl(0xffffffffU)
> -    ok 78 - mp_encode(0xffffffffU) == "\xc6\xff\xff\xff\xff"
> -    # *** test_binls: done ***
> -ok 8 - subtests
> -    1..168
> -    # *** test_extls ***
> -    # extl 0x01U
> -    ok 1 - mp_check_extl(0x01U) == 0
> -    ok 2 - mp_decode(mp_encode(0x01U)) == 0x01U
> -    ok 3 - len(mp_encode_extl(0x01U)
> -    ok 4 - len(mp_decode_extl(0x01U))
> -    ok 5 - mp_sizeof_extl(0x01U)
> -    ok 6 - mp_encode(0x01U) == "\xd4\x00"
> -    # extl 0x02U
> -    ok 7 - mp_check_extl(0x02U) == 0
> -    ok 8 - mp_decode(mp_encode(0x02U)) == 0x02U
> -    ok 9 - len(mp_encode_extl(0x02U)
> -    ok 10 - len(mp_decode_extl(0x02U))
> -    ok 11 - mp_sizeof_extl(0x02U)
> -    ok 12 - mp_encode(0x02U) == "\xd5\x00"
> -    # extl 0x04U
> -    ok 13 - mp_check_extl(0x04U) == 0
> -    ok 14 - mp_decode(mp_encode(0x04U)) == 0x04U
> -    ok 15 - len(mp_encode_extl(0x04U)
> -    ok 16 - len(mp_decode_extl(0x04U))
> -    ok 17 - mp_sizeof_extl(0x04U)
> -    ok 18 - mp_encode(0x04U) == "\xd6\x00"
> -    # extl 0x08U
> -    ok 19 - mp_check_extl(0x08U) == 0
> -    ok 20 - mp_decode(mp_encode(0x08U)) == 0x08U
> -    ok 21 - len(mp_encode_extl(0x08U)
> -    ok 22 - len(mp_decode_extl(0x08U))
> -    ok 23 - mp_sizeof_extl(0x08U)
> -    ok 24 - mp_encode(0x08U) == "\xd7\x00"
> -    # extl 0x10U
> -    ok 25 - mp_check_extl(0x10U) == 0
> -    ok 26 - mp_decode(mp_encode(0x10U)) == 0x10U
> -    ok 27 - len(mp_encode_extl(0x10U)
> -    ok 28 - len(mp_decode_extl(0x10U))
> -    ok 29 - mp_sizeof_extl(0x10U)
> -    ok 30 - mp_encode(0x10U) == "\xd8\x00"
> -    # extl 0x11U
> -    ok 31 - mp_check_extl(0x11U) == 0
> -    ok 32 - mp_decode(mp_encode(0x11U)) == 0x11U
> -    ok 33 - len(mp_encode_extl(0x11U)
> -    ok 34 - len(mp_decode_extl(0x11U))
> -    ok 35 - mp_sizeof_extl(0x11U)
> -    ok 36 - mp_encode(0x11U) == "\xc7\x11\x00"
> -    # extl 0xfeU
> -    ok 37 - mp_check_extl(0xfeU) == 0
> -    ok 38 - mp_decode(mp_encode(0xfeU)) == 0xfeU
> -    ok 39 - len(mp_encode_extl(0xfeU)
> -    ok 40 - len(mp_decode_extl(0xfeU))
> -    ok 41 - mp_sizeof_extl(0xfeU)
> -    ok 42 - mp_encode(0xfeU) == "\xc7\xfe\x00"
> -    # extl 0xffU
> -    ok 43 - mp_check_extl(0xffU) == 0
> -    ok 44 - mp_decode(mp_encode(0xffU)) == 0xffU
> -    ok 45 - len(mp_encode_extl(0xffU)
> -    ok 46 - len(mp_decode_extl(0xffU))
> -    ok 47 - mp_sizeof_extl(0xffU)
> -    ok 48 - mp_encode(0xffU) == "\xc7\xff\x00"
> -    # extl 0x00U
> -    ok 49 - mp_check_extl(0x00U) == 0
> -    ok 50 - mp_decode(mp_encode(0x00U)) == 0x00U
> -    ok 51 - len(mp_encode_extl(0x00U)
> -    ok 52 - len(mp_decode_extl(0x00U))
> -    ok 53 - mp_sizeof_extl(0x00U)
> -    ok 54 - mp_encode(0x00U) == "\xc7\x00\x00"
> -    # extl 0x03U
> -    ok 55 - mp_check_extl(0x03U) == 0
> -    ok 56 - mp_decode(mp_encode(0x03U)) == 0x03U
> -    ok 57 - len(mp_encode_extl(0x03U)
> -    ok 58 - len(mp_decode_extl(0x03U))
> -    ok 59 - mp_sizeof_extl(0x03U)
> -    ok 60 - mp_encode(0x03U) == "\xc7\x03\x00"
> -    # extl 0x05U
> -    ok 61 - mp_check_extl(0x05U) == 0
> -    ok 62 - mp_decode(mp_encode(0x05U)) == 0x05U
> -    ok 63 - len(mp_encode_extl(0x05U)
> -    ok 64 - len(mp_decode_extl(0x05U))
> -    ok 65 - mp_sizeof_extl(0x05U)
> -    ok 66 - mp_encode(0x05U) == "\xc7\x05\x00"
> -    # extl 0x06U
> -    ok 67 - mp_check_extl(0x06U) == 0
> -    ok 68 - mp_decode(mp_encode(0x06U)) == 0x06U
> -    ok 69 - len(mp_encode_extl(0x06U)
> -    ok 70 - len(mp_decode_extl(0x06U))
> -    ok 71 - mp_sizeof_extl(0x06U)
> -    ok 72 - mp_encode(0x06U) == "\xc7\x06\x00"
> -    # extl 0x07U
> -    ok 73 - mp_check_extl(0x07U) == 0
> -    ok 74 - mp_decode(mp_encode(0x07U)) == 0x07U
> -    ok 75 - len(mp_encode_extl(0x07U)
> -    ok 76 - len(mp_decode_extl(0x07U))
> -    ok 77 - mp_sizeof_extl(0x07U)
> -    ok 78 - mp_encode(0x07U) == "\xc7\x07\x00"
> -    # extl 0x09U
> -    ok 79 - mp_check_extl(0x09U) == 0
> -    ok 80 - mp_decode(mp_encode(0x09U)) == 0x09U
> -    ok 81 - len(mp_encode_extl(0x09U)
> -    ok 82 - len(mp_decode_extl(0x09U))
> -    ok 83 - mp_sizeof_extl(0x09U)
> -    ok 84 - mp_encode(0x09U) == "\xc7\x09\x00"
> -    # extl 0x0aU
> -    ok 85 - mp_check_extl(0x0aU) == 0
> -    ok 86 - mp_decode(mp_encode(0x0aU)) == 0x0aU
> -    ok 87 - len(mp_encode_extl(0x0aU)
> -    ok 88 - len(mp_decode_extl(0x0aU))
> -    ok 89 - mp_sizeof_extl(0x0aU)
> -    ok 90 - mp_encode(0x0aU) == "\xc7\x0a\x00"
> -    # extl 0x0bU
> -    ok 91 - mp_check_extl(0x0bU) == 0
> -    ok 92 - mp_decode(mp_encode(0x0bU)) == 0x0bU
> -    ok 93 - len(mp_encode_extl(0x0bU)
> -    ok 94 - len(mp_decode_extl(0x0bU))
> -    ok 95 - mp_sizeof_extl(0x0bU)
> -    ok 96 - mp_encode(0x0bU) == "\xc7\x0b\x00"
> -    # extl 0x0cU
> -    ok 97 - mp_check_extl(0x0cU) == 0
> -    ok 98 - mp_decode(mp_encode(0x0cU)) == 0x0cU
> -    ok 99 - len(mp_encode_extl(0x0cU)
> -    ok 100 - len(mp_decode_extl(0x0cU))
> -    ok 101 - mp_sizeof_extl(0x0cU)
> -    ok 102 - mp_encode(0x0cU) == "\xc7\x0c\x00"
> -    # extl 0x0dU
> -    ok 103 - mp_check_extl(0x0dU) == 0
> -    ok 104 - mp_decode(mp_encode(0x0dU)) == 0x0dU
> -    ok 105 - len(mp_encode_extl(0x0dU)
> -    ok 106 - len(mp_decode_extl(0x0dU))
> -    ok 107 - mp_sizeof_extl(0x0dU)
> -    ok 108 - mp_encode(0x0dU) == "\xc7\x0d\x00"
> -    # extl 0x0eU
> -    ok 109 - mp_check_extl(0x0eU) == 0
> -    ok 110 - mp_decode(mp_encode(0x0eU)) == 0x0eU
> -    ok 111 - len(mp_encode_extl(0x0eU)
> -    ok 112 - len(mp_decode_extl(0x0eU))
> -    ok 113 - mp_sizeof_extl(0x0eU)
> -    ok 114 - mp_encode(0x0eU) == "\xc7\x0e\x00"
> -    # extl 0x0fU
> -    ok 115 - mp_check_extl(0x0fU) == 0
> -    ok 116 - mp_decode(mp_encode(0x0fU)) == 0x0fU
> -    ok 117 - len(mp_encode_extl(0x0fU)
> -    ok 118 - len(mp_decode_extl(0x0fU))
> -    ok 119 - mp_sizeof_extl(0x0fU)
> -    ok 120 - mp_encode(0x0fU) == "\xc7\x0f\x00"
> -    # extl 0x0100U
> -    ok 121 - mp_check_extl(0x0100U) == 0
> -    ok 122 - mp_decode(mp_encode(0x0100U)) == 0x0100U
> -    ok 123 - len(mp_encode_extl(0x0100U)
> -    ok 124 - len(mp_decode_extl(0x0100U))
> -    ok 125 - mp_sizeof_extl(0x0100U)
> -    ok 126 - mp_encode(0x0100U) == "\xc8\x01\x00\x00"
> -    # extl 0x0101U
> -    ok 127 - mp_check_extl(0x0101U) == 0
> -    ok 128 - mp_decode(mp_encode(0x0101U)) == 0x0101U
> -    ok 129 - len(mp_encode_extl(0x0101U)
> -    ok 130 - len(mp_decode_extl(0x0101U))
> -    ok 131 - mp_sizeof_extl(0x0101U)
> -    ok 132 - mp_encode(0x0101U) == "\xc8\x01\x01\x00"
> -    # extl 0xfffeU
> -    ok 133 - mp_check_extl(0xfffeU) == 0
> -    ok 134 - mp_decode(mp_encode(0xfffeU)) == 0xfffeU
> -    ok 135 - len(mp_encode_extl(0xfffeU)
> -    ok 136 - len(mp_decode_extl(0xfffeU))
> -    ok 137 - mp_sizeof_extl(0xfffeU)
> -    ok 138 - mp_encode(0xfffeU) == "\xc8\xff\xfe\x00"
> -    # extl 0xffffU
> -    ok 139 - mp_check_extl(0xffffU) == 0
> -    ok 140 - mp_decode(mp_encode(0xffffU)) == 0xffffU
> -    ok 141 - len(mp_encode_extl(0xffffU)
> -    ok 142 - len(mp_decode_extl(0xffffU))
> -    ok 143 - mp_sizeof_extl(0xffffU)
> -    ok 144 - mp_encode(0xffffU) == "\xc8\xff\xff\x00"
> -    # extl 0x00010000U
> -    ok 145 - mp_check_extl(0x00010000U) == 0
> -    ok 146 - mp_decode(mp_encode(0x00010000U)) == 0x00010000U
> -    ok 147 - len(mp_encode_extl(0x00010000U)
> -    ok 148 - len(mp_decode_extl(0x00010000U))
> -    ok 149 - mp_sizeof_extl(0x00010000U)
> -    ok 150 - mp_encode(0x00010000U) == "\xc9\x00\x01\x00\x00\x00"
> -    # extl 0x00010001U
> -    ok 151 - mp_check_extl(0x00010001U) == 0
> -    ok 152 - mp_decode(mp_encode(0x00010001U)) == 0x00010001U
> -    ok 153 - len(mp_encode_extl(0x00010001U)
> -    ok 154 - len(mp_decode_extl(0x00010001U))
> -    ok 155 - mp_sizeof_extl(0x00010001U)
> -    ok 156 - mp_encode(0x00010001U) == "\xc9\x00\x01\x00\x01\x00"
> -    # extl 0xfffffffeU
> -    ok 157 - mp_check_extl(0xfffffffeU) == 0
> -    ok 158 - mp_decode(mp_encode(0xfffffffeU)) == 0xfffffffeU
> -    ok 159 - len(mp_encode_extl(0xfffffffeU)
> -    ok 160 - len(mp_decode_extl(0xfffffffeU))
> -    ok 161 - mp_sizeof_extl(0xfffffffeU)
> -    ok 162 - mp_encode(0xfffffffeU) == "\xc9\xff\xff\xff\xfe\x00"
> -    # extl 0xffffffffU
> -    ok 163 - mp_check_extl(0xffffffffU) == 0
> -    ok 164 - mp_decode(mp_encode(0xffffffffU)) == 0xffffffffU
> -    ok 165 - len(mp_encode_extl(0xffffffffU)
> -    ok 166 - len(mp_decode_extl(0xffffffffU))
> -    ok 167 - mp_sizeof_extl(0xffffffffU)
> -    ok 168 - mp_encode(0xffffffffU) == "\xc9\xff\xff\xff\xff\x00"
> -    # *** test_extls: done ***
> -ok 9 - subtests
> -    1..96
> -    # *** test_strs ***
> -    # str len=0x01
> -    ok 1 - len(mp_decode_str(x, 1))
> -    ok 2 - len(mp_decode_strbin(x, 1))
> -    ok 3 - mp_check_str(mp_encode_str(x, 0x01))
> -    ok 4 - len(mp_decode_str(x, 0x01)
> -    ok 5 - len(mp_next_str(x, 0x01)
> -    ok 6 - len(mp_check_str(x, 0x01)
> -    ok 7 - mp_sizeof_str(0x01)
> -    ok 8 - mp_encode_str(x, 0x01) == x
> -    # str len=0x1e
> -    ok 9 - len(mp_decode_str(x, 30))
> -    ok 10 - len(mp_decode_strbin(x, 30))
> -    ok 11 - mp_check_str(mp_encode_str(x, 0x1e))
> -    ok 12 - len(mp_decode_str(x, 0x1e)
> -    ok 13 - len(mp_next_str(x, 0x1e)
> -    ok 14 - len(mp_check_str(x, 0x1e)
> -    ok 15 - mp_sizeof_str(0x1e)
> -    ok 16 - mp_encode_str(x, 0x1e) == x
> -    # str len=0x1f
> -    ok 17 - len(mp_decode_str(x, 31))
> -    ok 18 - len(mp_decode_strbin(x, 31))
> -    ok 19 - mp_check_str(mp_encode_str(x, 0x1f))
> -    ok 20 - len(mp_decode_str(x, 0x1f)
> -    ok 21 - len(mp_next_str(x, 0x1f)
> -    ok 22 - len(mp_check_str(x, 0x1f)
> -    ok 23 - mp_sizeof_str(0x1f)
> -    ok 24 - mp_encode_str(x, 0x1f) == x
> -    # str len=0x20
> -    ok 25 - len(mp_decode_str(x, 32))
> -    ok 26 - len(mp_decode_strbin(x, 32))
> -    ok 27 - mp_check_str(mp_encode_str(x, 0x20))
> -    ok 28 - len(mp_decode_str(x, 0x20)
> -    ok 29 - len(mp_next_str(x, 0x20)
> -    ok 30 - len(mp_check_str(x, 0x20)
> -    ok 31 - mp_sizeof_str(0x20)
> -    ok 32 - mp_encode_str(x, 0x20) == x
> -    # str len=0xfe
> -    ok 33 - len(mp_decode_str(x, 254))
> -    ok 34 - len(mp_decode_strbin(x, 254))
> -    ok 35 - mp_check_str(mp_encode_str(x, 0xfe))
> -    ok 36 - len(mp_decode_str(x, 0xfe)
> -    ok 37 - len(mp_next_str(x, 0xfe)
> -    ok 38 - len(mp_check_str(x, 0xfe)
> -    ok 39 - mp_sizeof_str(0xfe)
> -    ok 40 - mp_encode_str(x, 0xfe) == x
> -    # str len=0xff
> -    ok 41 - len(mp_decode_str(x, 255))
> -    ok 42 - len(mp_decode_strbin(x, 255))
> -    ok 43 - mp_check_str(mp_encode_str(x, 0xff))
> -    ok 44 - len(mp_decode_str(x, 0xff)
> -    ok 45 - len(mp_next_str(x, 0xff)
> -    ok 46 - len(mp_check_str(x, 0xff)
> -    ok 47 - mp_sizeof_str(0xff)
> -    ok 48 - mp_encode_str(x, 0xff) == x
> -    # str len=0x100
> -    ok 49 - len(mp_decode_str(x, 256))
> -    ok 50 - len(mp_decode_strbin(x, 256))
> -    ok 51 - mp_check_str(mp_encode_str(x, 0x100))
> -    ok 52 - len(mp_decode_str(x, 0x100)
> -    ok 53 - len(mp_next_str(x, 0x100)
> -    ok 54 - len(mp_check_str(x, 0x100)
> -    ok 55 - mp_sizeof_str(0x100)
> -    ok 56 - mp_encode_str(x, 0x100) == x
> -    # str len=0x101
> -    ok 57 - len(mp_decode_str(x, 257))
> -    ok 58 - len(mp_decode_strbin(x, 257))
> -    ok 59 - mp_check_str(mp_encode_str(x, 0x101))
> -    ok 60 - len(mp_decode_str(x, 0x101)
> -    ok 61 - len(mp_next_str(x, 0x101)
> -    ok 62 - len(mp_check_str(x, 0x101)
> -    ok 63 - mp_sizeof_str(0x101)
> -    ok 64 - mp_encode_str(x, 0x101) == x
> -    # str len=0xfffe
> -    ok 65 - len(mp_decode_str(x, 65534))
> -    ok 66 - len(mp_decode_strbin(x, 65534))
> -    ok 67 - mp_check_str(mp_encode_str(x, 0xfffe))
> -    ok 68 - len(mp_decode_str(x, 0xfffe)
> -    ok 69 - len(mp_next_str(x, 0xfffe)
> -    ok 70 - len(mp_check_str(x, 0xfffe)
> -    ok 71 - mp_sizeof_str(0xfffe)
> -    ok 72 - mp_encode_str(x, 0xfffe) == x
> -    # str len=0xffff
> -    ok 73 - len(mp_decode_str(x, 65535))
> -    ok 74 - len(mp_decode_strbin(x, 65535))
> -    ok 75 - mp_check_str(mp_encode_str(x, 0xffff))
> -    ok 76 - len(mp_decode_str(x, 0xffff)
> -    ok 77 - len(mp_next_str(x, 0xffff)
> -    ok 78 - len(mp_check_str(x, 0xffff)
> -    ok 79 - mp_sizeof_str(0xffff)
> -    ok 80 - mp_encode_str(x, 0xffff) == x
> -    # str len=0x10000
> -    ok 81 - len(mp_decode_str(x, 65536))
> -    ok 82 - len(mp_decode_strbin(x, 65536))
> -    ok 83 - mp_check_str(mp_encode_str(x, 0x10000))
> -    ok 84 - len(mp_decode_str(x, 0x10000)
> -    ok 85 - len(mp_next_str(x, 0x10000)
> -    ok 86 - len(mp_check_str(x, 0x10000)
> -    ok 87 - mp_sizeof_str(0x10000)
> -    ok 88 - mp_encode_str(x, 0x10000) == x
> -    # str len=0x10001
> -    ok 89 - len(mp_decode_str(x, 65537))
> -    ok 90 - len(mp_decode_strbin(x, 65537))
> -    ok 91 - mp_check_str(mp_encode_str(x, 0x10001))
> -    ok 92 - len(mp_decode_str(x, 0x10001)
> -    ok 93 - len(mp_next_str(x, 0x10001)
> -    ok 94 - len(mp_check_str(x, 0x10001)
> -    ok 95 - mp_sizeof_str(0x10001)
> -    ok 96 - mp_encode_str(x, 0x10001) == x
> -    # *** test_strs: done ***
> -ok 10 - subtests
> -    1..96
> -    # *** test_bins ***
> -    # bin len=0x01
> -    ok 1 - len(mp_decode_bin(x, 1))
> -    ok 2 - len(mp_decode_strbin(x, 1))
> -    ok 3 - mp_check_bin(mp_encode_bin(x, 0x01))
> -    ok 4 - len(mp_decode_bin(x, 0x01)
> -    ok 5 - len(mp_next_bin(x, 0x01)
> -    ok 6 - len(mp_check_bin(x, 0x01)
> -    ok 7 - mp_sizeof_bin(0x01)
> -    ok 8 - mp_encode_bin(x, 0x01) == x
> -    # bin len=0x1e
> -    ok 9 - len(mp_decode_bin(x, 30))
> -    ok 10 - len(mp_decode_strbin(x, 30))
> -    ok 11 - mp_check_bin(mp_encode_bin(x, 0x1e))
> -    ok 12 - len(mp_decode_bin(x, 0x1e)
> -    ok 13 - len(mp_next_bin(x, 0x1e)
> -    ok 14 - len(mp_check_bin(x, 0x1e)
> -    ok 15 - mp_sizeof_bin(0x1e)
> -    ok 16 - mp_encode_bin(x, 0x1e) == x
> -    # bin len=0x1f
> -    ok 17 - len(mp_decode_bin(x, 31))
> -    ok 18 - len(mp_decode_strbin(x, 31))
> -    ok 19 - mp_check_bin(mp_encode_bin(x, 0x1f))
> -    ok 20 - len(mp_decode_bin(x, 0x1f)
> -    ok 21 - len(mp_next_bin(x, 0x1f)
> -    ok 22 - len(mp_check_bin(x, 0x1f)
> -    ok 23 - mp_sizeof_bin(0x1f)
> -    ok 24 - mp_encode_bin(x, 0x1f) == x
> -    # bin len=0x20
> -    ok 25 - len(mp_decode_bin(x, 32))
> -    ok 26 - len(mp_decode_strbin(x, 32))
> -    ok 27 - mp_check_bin(mp_encode_bin(x, 0x20))
> -    ok 28 - len(mp_decode_bin(x, 0x20)
> -    ok 29 - len(mp_next_bin(x, 0x20)
> -    ok 30 - len(mp_check_bin(x, 0x20)
> -    ok 31 - mp_sizeof_bin(0x20)
> -    ok 32 - mp_encode_bin(x, 0x20) == x
> -    # bin len=0xfe
> -    ok 33 - len(mp_decode_bin(x, 254))
> -    ok 34 - len(mp_decode_strbin(x, 254))
> -    ok 35 - mp_check_bin(mp_encode_bin(x, 0xfe))
> -    ok 36 - len(mp_decode_bin(x, 0xfe)
> -    ok 37 - len(mp_next_bin(x, 0xfe)
> -    ok 38 - len(mp_check_bin(x, 0xfe)
> -    ok 39 - mp_sizeof_bin(0xfe)
> -    ok 40 - mp_encode_bin(x, 0xfe) == x
> -    # bin len=0xff
> -    ok 41 - len(mp_decode_bin(x, 255))
> -    ok 42 - len(mp_decode_strbin(x, 255))
> -    ok 43 - mp_check_bin(mp_encode_bin(x, 0xff))
> -    ok 44 - len(mp_decode_bin(x, 0xff)
> -    ok 45 - len(mp_next_bin(x, 0xff)
> -    ok 46 - len(mp_check_bin(x, 0xff)
> -    ok 47 - mp_sizeof_bin(0xff)
> -    ok 48 - mp_encode_bin(x, 0xff) == x
> -    # bin len=0x100
> -    ok 49 - len(mp_decode_bin(x, 256))
> -    ok 50 - len(mp_decode_strbin(x, 256))
> -    ok 51 - mp_check_bin(mp_encode_bin(x, 0x100))
> -    ok 52 - len(mp_decode_bin(x, 0x100)
> -    ok 53 - len(mp_next_bin(x, 0x100)
> -    ok 54 - len(mp_check_bin(x, 0x100)
> -    ok 55 - mp_sizeof_bin(0x100)
> -    ok 56 - mp_encode_bin(x, 0x100) == x
> -    # bin len=0x101
> -    ok 57 - len(mp_decode_bin(x, 257))
> -    ok 58 - len(mp_decode_strbin(x, 257))
> -    ok 59 - mp_check_bin(mp_encode_bin(x, 0x101))
> -    ok 60 - len(mp_decode_bin(x, 0x101)
> -    ok 61 - len(mp_next_bin(x, 0x101)
> -    ok 62 - len(mp_check_bin(x, 0x101)
> -    ok 63 - mp_sizeof_bin(0x101)
> -    ok 64 - mp_encode_bin(x, 0x101) == x
> -    # bin len=0xfffe
> -    ok 65 - len(mp_decode_bin(x, 65534))
> -    ok 66 - len(mp_decode_strbin(x, 65534))
> -    ok 67 - mp_check_bin(mp_encode_bin(x, 0xfffe))
> -    ok 68 - len(mp_decode_bin(x, 0xfffe)
> -    ok 69 - len(mp_next_bin(x, 0xfffe)
> -    ok 70 - len(mp_check_bin(x, 0xfffe)
> -    ok 71 - mp_sizeof_bin(0xfffe)
> -    ok 72 - mp_encode_bin(x, 0xfffe) == x
> -    # bin len=0xffff
> -    ok 73 - len(mp_decode_bin(x, 65535))
> -    ok 74 - len(mp_decode_strbin(x, 65535))
> -    ok 75 - mp_check_bin(mp_encode_bin(x, 0xffff))
> -    ok 76 - len(mp_decode_bin(x, 0xffff)
> -    ok 77 - len(mp_next_bin(x, 0xffff)
> -    ok 78 - len(mp_check_bin(x, 0xffff)
> -    ok 79 - mp_sizeof_bin(0xffff)
> -    ok 80 - mp_encode_bin(x, 0xffff) == x
> -    # bin len=0x10000
> -    ok 81 - len(mp_decode_bin(x, 65536))
> -    ok 82 - len(mp_decode_strbin(x, 65536))
> -    ok 83 - mp_check_bin(mp_encode_bin(x, 0x10000))
> -    ok 84 - len(mp_decode_bin(x, 0x10000)
> -    ok 85 - len(mp_next_bin(x, 0x10000)
> -    ok 86 - len(mp_check_bin(x, 0x10000)
> -    ok 87 - mp_sizeof_bin(0x10000)
> -    ok 88 - mp_encode_bin(x, 0x10000) == x
> -    # bin len=0x10001
> -    ok 89 - len(mp_decode_bin(x, 65537))
> -    ok 90 - len(mp_decode_strbin(x, 65537))
> -    ok 91 - mp_check_bin(mp_encode_bin(x, 0x10001))
> -    ok 92 - len(mp_decode_bin(x, 0x10001)
> -    ok 93 - len(mp_next_bin(x, 0x10001)
> -    ok 94 - len(mp_check_bin(x, 0x10001)
> -    ok 95 - mp_sizeof_bin(0x10001)
> -    ok 96 - mp_encode_bin(x, 0x10001) == x
> -    # *** test_bins: done ***
> -ok 11 - subtests
> -    1..225
> -    # *** test_exts ***
> -    # ext len=0x01
> -    ok 1 - len(mp_decode_ext(x, 1))
> -    ok 2 - type(mp_decode_ext(x))
> -    ok 3 - len(mp_decode_strbin(x, 1))
> -    ok 4 - mp_check_ext(mp_encode_ext(x, 0x01))
> -    ok 5 - len(mp_decode_ext(x, 0x01)
> -    ok 6 - len(mp_next_ext(x, 0x01)
> -    ok 7 - len(mp_check_ext(x, 0x01)
> -    ok 8 - mp_sizeof_ext(0x01)
> -    ok 9 - mp_encode_ext(x, 0x01) == x
> -    # ext len=0x02
> -    ok 10 - len(mp_decode_ext(x, 2))
> -    ok 11 - type(mp_decode_ext(x))
> -    ok 12 - len(mp_decode_strbin(x, 2))
> -    ok 13 - mp_check_ext(mp_encode_ext(x, 0x02))
> -    ok 14 - len(mp_decode_ext(x, 0x02)
> -    ok 15 - len(mp_next_ext(x, 0x02)
> -    ok 16 - len(mp_check_ext(x, 0x02)
> -    ok 17 - mp_sizeof_ext(0x02)
> -    ok 18 - mp_encode_ext(x, 0x02) == x
> -    # ext len=0x03
> -    ok 19 - len(mp_decode_ext(x, 3))
> -    ok 20 - type(mp_decode_ext(x))
> -    ok 21 - len(mp_decode_strbin(x, 3))
> -    ok 22 - mp_check_ext(mp_encode_ext(x, 0x03))
> -    ok 23 - len(mp_decode_ext(x, 0x03)
> -    ok 24 - len(mp_next_ext(x, 0x03)
> -    ok 25 - len(mp_check_ext(x, 0x03)
> -    ok 26 - mp_sizeof_ext(0x03)
> -    ok 27 - mp_encode_ext(x, 0x03) == x
> -    # ext len=0x04
> -    ok 28 - len(mp_decode_ext(x, 4))
> -    ok 29 - type(mp_decode_ext(x))
> -    ok 30 - len(mp_decode_strbin(x, 4))
> -    ok 31 - mp_check_ext(mp_encode_ext(x, 0x04))
> -    ok 32 - len(mp_decode_ext(x, 0x04)
> -    ok 33 - len(mp_next_ext(x, 0x04)
> -    ok 34 - len(mp_check_ext(x, 0x04)
> -    ok 35 - mp_sizeof_ext(0x04)
> -    ok 36 - mp_encode_ext(x, 0x04) == x
> -    # ext len=0x05
> -    ok 37 - len(mp_decode_ext(x, 5))
> -    ok 38 - type(mp_decode_ext(x))
> -    ok 39 - len(mp_decode_strbin(x, 5))
> -    ok 40 - mp_check_ext(mp_encode_ext(x, 0x05))
> -    ok 41 - len(mp_decode_ext(x, 0x05)
> -    ok 42 - len(mp_next_ext(x, 0x05)
> -    ok 43 - len(mp_check_ext(x, 0x05)
> -    ok 44 - mp_sizeof_ext(0x05)
> -    ok 45 - mp_encode_ext(x, 0x05) == x
> -    # ext len=0x06
> -    ok 46 - len(mp_decode_ext(x, 6))
> -    ok 47 - type(mp_decode_ext(x))
> -    ok 48 - len(mp_decode_strbin(x, 6))
> -    ok 49 - mp_check_ext(mp_encode_ext(x, 0x06))
> -    ok 50 - len(mp_decode_ext(x, 0x06)
> -    ok 51 - len(mp_next_ext(x, 0x06)
> -    ok 52 - len(mp_check_ext(x, 0x06)
> -    ok 53 - mp_sizeof_ext(0x06)
> -    ok 54 - mp_encode_ext(x, 0x06) == x
> -    # ext len=0x07
> -    ok 55 - len(mp_decode_ext(x, 7))
> -    ok 56 - type(mp_decode_ext(x))
> -    ok 57 - len(mp_decode_strbin(x, 7))
> -    ok 58 - mp_check_ext(mp_encode_ext(x, 0x07))
> -    ok 59 - len(mp_decode_ext(x, 0x07)
> -    ok 60 - len(mp_next_ext(x, 0x07)
> -    ok 61 - len(mp_check_ext(x, 0x07)
> -    ok 62 - mp_sizeof_ext(0x07)
> -    ok 63 - mp_encode_ext(x, 0x07) == x
> -    # ext len=0x08
> -    ok 64 - len(mp_decode_ext(x, 8))
> -    ok 65 - type(mp_decode_ext(x))
> -    ok 66 - len(mp_decode_strbin(x, 8))
> -    ok 67 - mp_check_ext(mp_encode_ext(x, 0x08))
> -    ok 68 - len(mp_decode_ext(x, 0x08)
> -    ok 69 - len(mp_next_ext(x, 0x08)
> -    ok 70 - len(mp_check_ext(x, 0x08)
> -    ok 71 - mp_sizeof_ext(0x08)
> -    ok 72 - mp_encode_ext(x, 0x08) == x
> -    # ext len=0x09
> -    ok 73 - len(mp_decode_ext(x, 9))
> -    ok 74 - type(mp_decode_ext(x))
> -    ok 75 - len(mp_decode_strbin(x, 9))
> -    ok 76 - mp_check_ext(mp_encode_ext(x, 0x09))
> -    ok 77 - len(mp_decode_ext(x, 0x09)
> -    ok 78 - len(mp_next_ext(x, 0x09)
> -    ok 79 - len(mp_check_ext(x, 0x09)
> -    ok 80 - mp_sizeof_ext(0x09)
> -    ok 81 - mp_encode_ext(x, 0x09) == x
> -    # ext len=0x0a
> -    ok 82 - len(mp_decode_ext(x, 10))
> -    ok 83 - type(mp_decode_ext(x))
> -    ok 84 - len(mp_decode_strbin(x, 10))
> -    ok 85 - mp_check_ext(mp_encode_ext(x, 0x0a))
> -    ok 86 - len(mp_decode_ext(x, 0x0a)
> -    ok 87 - len(mp_next_ext(x, 0x0a)
> -    ok 88 - len(mp_check_ext(x, 0x0a)
> -    ok 89 - mp_sizeof_ext(0x0a)
> -    ok 90 - mp_encode_ext(x, 0x0a) == x
> -    # ext len=0x0b
> -    ok 91 - len(mp_decode_ext(x, 11))
> -    ok 92 - type(mp_decode_ext(x))
> -    ok 93 - len(mp_decode_strbin(x, 11))
> -    ok 94 - mp_check_ext(mp_encode_ext(x, 0x0b))
> -    ok 95 - len(mp_decode_ext(x, 0x0b)
> -    ok 96 - len(mp_next_ext(x, 0x0b)
> -    ok 97 - len(mp_check_ext(x, 0x0b)
> -    ok 98 - mp_sizeof_ext(0x0b)
> -    ok 99 - mp_encode_ext(x, 0x0b) == x
> -    # ext len=0x0c
> -    ok 100 - len(mp_decode_ext(x, 12))
> -    ok 101 - type(mp_decode_ext(x))
> -    ok 102 - len(mp_decode_strbin(x, 12))
> -    ok 103 - mp_check_ext(mp_encode_ext(x, 0x0c))
> -    ok 104 - len(mp_decode_ext(x, 0x0c)
> -    ok 105 - len(mp_next_ext(x, 0x0c)
> -    ok 106 - len(mp_check_ext(x, 0x0c)
> -    ok 107 - mp_sizeof_ext(0x0c)
> -    ok 108 - mp_encode_ext(x, 0x0c) == x
> -    # ext len=0x0d
> -    ok 109 - len(mp_decode_ext(x, 13))
> -    ok 110 - type(mp_decode_ext(x))
> -    ok 111 - len(mp_decode_strbin(x, 13))
> -    ok 112 - mp_check_ext(mp_encode_ext(x, 0x0d))
> -    ok 113 - len(mp_decode_ext(x, 0x0d)
> -    ok 114 - len(mp_next_ext(x, 0x0d)
> -    ok 115 - len(mp_check_ext(x, 0x0d)
> -    ok 116 - mp_sizeof_ext(0x0d)
> -    ok 117 - mp_encode_ext(x, 0x0d) == x
> -    # ext len=0x0e
> -    ok 118 - len(mp_decode_ext(x, 14))
> -    ok 119 - type(mp_decode_ext(x))
> -    ok 120 - len(mp_decode_strbin(x, 14))
> -    ok 121 - mp_check_ext(mp_encode_ext(x, 0x0e))
> -    ok 122 - len(mp_decode_ext(x, 0x0e)
> -    ok 123 - len(mp_next_ext(x, 0x0e)
> -    ok 124 - len(mp_check_ext(x, 0x0e)
> -    ok 125 - mp_sizeof_ext(0x0e)
> -    ok 126 - mp_encode_ext(x, 0x0e) == x
> -    # ext len=0x0f
> -    ok 127 - len(mp_decode_ext(x, 15))
> -    ok 128 - type(mp_decode_ext(x))
> -    ok 129 - len(mp_decode_strbin(x, 15))
> -    ok 130 - mp_check_ext(mp_encode_ext(x, 0x0f))
> -    ok 131 - len(mp_decode_ext(x, 0x0f)
> -    ok 132 - len(mp_next_ext(x, 0x0f)
> -    ok 133 - len(mp_check_ext(x, 0x0f)
> -    ok 134 - mp_sizeof_ext(0x0f)
> -    ok 135 - mp_encode_ext(x, 0x0f) == x
> -    # ext len=0x10
> -    ok 136 - len(mp_decode_ext(x, 16))
> -    ok 137 - type(mp_decode_ext(x))
> -    ok 138 - len(mp_decode_strbin(x, 16))
> -    ok 139 - mp_check_ext(mp_encode_ext(x, 0x10))
> -    ok 140 - len(mp_decode_ext(x, 0x10)
> -    ok 141 - len(mp_next_ext(x, 0x10)
> -    ok 142 - len(mp_check_ext(x, 0x10)
> -    ok 143 - mp_sizeof_ext(0x10)
> -    ok 144 - mp_encode_ext(x, 0x10) == x
> -    # ext len=0x11
> -    ok 145 - len(mp_decode_ext(x, 17))
> -    ok 146 - type(mp_decode_ext(x))
> -    ok 147 - len(mp_decode_strbin(x, 17))
> -    ok 148 - mp_check_ext(mp_encode_ext(x, 0x11))
> -    ok 149 - len(mp_decode_ext(x, 0x11)
> -    ok 150 - len(mp_next_ext(x, 0x11)
> -    ok 151 - len(mp_check_ext(x, 0x11)
> -    ok 152 - mp_sizeof_ext(0x11)
> -    ok 153 - mp_encode_ext(x, 0x11) == x
> -    # ext len=0xfe
> -    ok 154 - len(mp_decode_ext(x, 254))
> -    ok 155 - type(mp_decode_ext(x))
> -    ok 156 - len(mp_decode_strbin(x, 254))
> -    ok 157 - mp_check_ext(mp_encode_ext(x, 0xfe))
> -    ok 158 - len(mp_decode_ext(x, 0xfe)
> -    ok 159 - len(mp_next_ext(x, 0xfe)
> -    ok 160 - len(mp_check_ext(x, 0xfe)
> -    ok 161 - mp_sizeof_ext(0xfe)
> -    ok 162 - mp_encode_ext(x, 0xfe) == x
> -    # ext len=0xff
> -    ok 163 - len(mp_decode_ext(x, 255))
> -    ok 164 - type(mp_decode_ext(x))
> -    ok 165 - len(mp_decode_strbin(x, 255))
> -    ok 166 - mp_check_ext(mp_encode_ext(x, 0xff))
> -    ok 167 - len(mp_decode_ext(x, 0xff)
> -    ok 168 - len(mp_next_ext(x, 0xff)
> -    ok 169 - len(mp_check_ext(x, 0xff)
> -    ok 170 - mp_sizeof_ext(0xff)
> -    ok 171 - mp_encode_ext(x, 0xff) == x
> -    # ext len=0x0100
> -    ok 172 - len(mp_decode_ext(x, 256))
> -    ok 173 - type(mp_decode_ext(x))
> -    ok 174 - len(mp_decode_strbin(x, 256))
> -    ok 175 - mp_check_ext(mp_encode_ext(x, 0x0100))
> -    ok 176 - len(mp_decode_ext(x, 0x0100)
> -    ok 177 - len(mp_next_ext(x, 0x0100)
> -    ok 178 - len(mp_check_ext(x, 0x0100)
> -    ok 179 - mp_sizeof_ext(0x0100)
> -    ok 180 - mp_encode_ext(x, 0x0100) == x
> -    # ext len=0x0101
> -    ok 181 - len(mp_decode_ext(x, 257))
> -    ok 182 - type(mp_decode_ext(x))
> -    ok 183 - len(mp_decode_strbin(x, 257))
> -    ok 184 - mp_check_ext(mp_encode_ext(x, 0x0101))
> -    ok 185 - len(mp_decode_ext(x, 0x0101)
> -    ok 186 - len(mp_next_ext(x, 0x0101)
> -    ok 187 - len(mp_check_ext(x, 0x0101)
> -    ok 188 - mp_sizeof_ext(0x0101)
> -    ok 189 - mp_encode_ext(x, 0x0101) == x
> -    # ext len=0xfffe
> -    ok 190 - len(mp_decode_ext(x, 65534))
> -    ok 191 - type(mp_decode_ext(x))
> -    ok 192 - len(mp_decode_strbin(x, 65534))
> -    ok 193 - mp_check_ext(mp_encode_ext(x, 0xfffe))
> -    ok 194 - len(mp_decode_ext(x, 0xfffe)
> -    ok 195 - len(mp_next_ext(x, 0xfffe)
> -    ok 196 - len(mp_check_ext(x, 0xfffe)
> -    ok 197 - mp_sizeof_ext(0xfffe)
> -    ok 198 - mp_encode_ext(x, 0xfffe) == x
> -    # ext len=0xffff
> -    ok 199 - len(mp_decode_ext(x, 65535))
> -    ok 200 - type(mp_decode_ext(x))
> -    ok 201 - len(mp_decode_strbin(x, 65535))
> -    ok 202 - mp_check_ext(mp_encode_ext(x, 0xffff))
> -    ok 203 - len(mp_decode_ext(x, 0xffff)
> -    ok 204 - len(mp_next_ext(x, 0xffff)
> -    ok 205 - len(mp_check_ext(x, 0xffff)
> -    ok 206 - mp_sizeof_ext(0xffff)
> -    ok 207 - mp_encode_ext(x, 0xffff) == x
> -    # ext len=0x00010000
> -    ok 208 - len(mp_decode_ext(x, 65536))
> -    ok 209 - type(mp_decode_ext(x))
> -    ok 210 - len(mp_decode_strbin(x, 65536))
> -    ok 211 - mp_check_ext(mp_encode_ext(x, 0x00010000))
> -    ok 212 - len(mp_decode_ext(x, 0x00010000)
> -    ok 213 - len(mp_next_ext(x, 0x00010000)
> -    ok 214 - len(mp_check_ext(x, 0x00010000)
> -    ok 215 - mp_sizeof_ext(0x00010000)
> -    ok 216 - mp_encode_ext(x, 0x00010000) == x
> -    # ext len=0x00010001
> -    ok 217 - len(mp_decode_ext(x, 65537))
> -    ok 218 - type(mp_decode_ext(x))
> -    ok 219 - len(mp_decode_strbin(x, 65537))
> -    ok 220 - mp_check_ext(mp_encode_ext(x, 0x00010001))
> -    ok 221 - len(mp_decode_ext(x, 0x00010001)
> -    ok 222 - len(mp_next_ext(x, 0x00010001)
> -    ok 223 - len(mp_check_ext(x, 0x00010001)
> -    ok 224 - mp_sizeof_ext(0x00010001)
> -    ok 225 - mp_encode_ext(x, 0x00010001) == x
> -    # *** test_exts: done ***
> -ok 12 - subtests
> -    1..54
> -    # *** test_arrays ***
> -    # array 0
> -    ok 1 - mp_check_array(0) == 0
> -    ok 2 - mp_decode(mp_encode(0)) == 0
> -    ok 3 - len(mp_encode_array(0)
> -    ok 4 - len(mp_decode_array(0))
> -    ok 5 - mp_sizeof_array(0)
> -    ok 6 - mp_encode(0) == "\x90"
> -    # array 1
> -    ok 7 - mp_check_array(1) == 0
> -    ok 8 - mp_decode(mp_encode(1)) == 1
> -    ok 9 - len(mp_encode_array(1)
> -    ok 10 - len(mp_decode_array(1))
> -    ok 11 - mp_sizeof_array(1)
> -    ok 12 - mp_encode(1) == "\x91"
> -    # array 15
> -    ok 13 - mp_check_array(15) == 0
> -    ok 14 - mp_decode(mp_encode(15)) == 15
> -    ok 15 - len(mp_encode_array(15)
> -    ok 16 - len(mp_decode_array(15))
> -    ok 17 - mp_sizeof_array(15)
> -    ok 18 - mp_encode(15) == "\x9f"
> -    # array 16
> -    ok 19 - mp_check_array(16) == 0
> -    ok 20 - mp_decode(mp_encode(16)) == 16
> -    ok 21 - len(mp_encode_array(16)
> -    ok 22 - len(mp_decode_array(16))
> -    ok 23 - mp_sizeof_array(16)
> -    ok 24 - mp_encode(16) == "\xdc\x00\x10"
> -    # array 0xfffe
> -    ok 25 - mp_check_array(0xfffe) == 0
> -    ok 26 - mp_decode(mp_encode(0xfffe)) == 0xfffe
> -    ok 27 - len(mp_encode_array(0xfffe)
> -    ok 28 - len(mp_decode_array(0xfffe))
> -    ok 29 - mp_sizeof_array(0xfffe)
> -    ok 30 - mp_encode(0xfffe) == "\xdc\xff\xfe"
> -    # array 0xffff
> -    ok 31 - mp_check_array(0xffff) == 0
> -    ok 32 - mp_decode(mp_encode(0xffff)) == 0xffff
> -    ok 33 - len(mp_encode_array(0xffff)
> -    ok 34 - len(mp_decode_array(0xffff))
> -    ok 35 - mp_sizeof_array(0xffff)
> -    ok 36 - mp_encode(0xffff) == "\xdc\xff\xff"
> -    # array 0x10000
> -    ok 37 - mp_check_array(0x10000) == 0
> -    ok 38 - mp_decode(mp_encode(0x10000)) == 0x10000
> -    ok 39 - len(mp_encode_array(0x10000)
> -    ok 40 - len(mp_decode_array(0x10000))
> -    ok 41 - mp_sizeof_array(0x10000)
> -    ok 42 - mp_encode(0x10000) == "\xdd\x00\x01\x00\x00"
> -    # array 0xfffffffeU
> -    ok 43 - mp_check_array(0xfffffffeU) == 0
> -    ok 44 - mp_decode(mp_encode(0xfffffffeU)) == 0xfffffffeU
> -    ok 45 - len(mp_encode_array(0xfffffffeU)
> -    ok 46 - len(mp_decode_array(0xfffffffeU))
> -    ok 47 - mp_sizeof_array(0xfffffffeU)
> -    ok 48 - mp_encode(0xfffffffeU) == "\xdd\xff\xff\xff\xfe"
> -    # array 0xffffffffU
> -    ok 49 - mp_check_array(0xffffffffU) == 0
> -    ok 50 - mp_decode(mp_encode(0xffffffffU)) == 0xffffffffU
> -    ok 51 - len(mp_encode_array(0xffffffffU)
> -    ok 52 - len(mp_decode_array(0xffffffffU))
> -    ok 53 - mp_sizeof_array(0xffffffffU)
> -    ok 54 - mp_encode(0xffffffffU) == "\xdd\xff\xff\xff\xff"
> -    # *** test_arrays: done ***
> -ok 13 - subtests
> -    1..54
> -    # *** test_maps ***
> -    # map 0
> -    ok 1 - mp_check_map(0) == 0
> -    ok 2 - mp_decode(mp_encode(0)) == 0
> -    ok 3 - len(mp_encode_map(0)
> -    ok 4 - len(mp_decode_map(0))
> -    ok 5 - mp_sizeof_map(0)
> -    ok 6 - mp_encode(0) == "\x80"
> -    # map 1
> -    ok 7 - mp_check_map(1) == 0
> -    ok 8 - mp_decode(mp_encode(1)) == 1
> -    ok 9 - len(mp_encode_map(1)
> -    ok 10 - len(mp_decode_map(1))
> -    ok 11 - mp_sizeof_map(1)
> -    ok 12 - mp_encode(1) == "\x81"
> -    # map 15
> -    ok 13 - mp_check_map(15) == 0
> -    ok 14 - mp_decode(mp_encode(15)) == 15
> -    ok 15 - len(mp_encode_map(15)
> -    ok 16 - len(mp_decode_map(15))
> -    ok 17 - mp_sizeof_map(15)
> -    ok 18 - mp_encode(15) == "\x8f"
> -    # map 16
> -    ok 19 - mp_check_map(16) == 0
> -    ok 20 - mp_decode(mp_encode(16)) == 16
> -    ok 21 - len(mp_encode_map(16)
> -    ok 22 - len(mp_decode_map(16))
> -    ok 23 - mp_sizeof_map(16)
> -    ok 24 - mp_encode(16) == "\xde\x00\x10"
> -    # map 0xfffe
> -    ok 25 - mp_check_map(0xfffe) == 0
> -    ok 26 - mp_decode(mp_encode(0xfffe)) == 0xfffe
> -    ok 27 - len(mp_encode_map(0xfffe)
> -    ok 28 - len(mp_decode_map(0xfffe))
> -    ok 29 - mp_sizeof_map(0xfffe)
> -    ok 30 - mp_encode(0xfffe) == "\xde\xff\xfe"
> -    # map 0xffff
> -    ok 31 - mp_check_map(0xffff) == 0
> -    ok 32 - mp_decode(mp_encode(0xffff)) == 0xffff
> -    ok 33 - len(mp_encode_map(0xffff)
> -    ok 34 - len(mp_decode_map(0xffff))
> -    ok 35 - mp_sizeof_map(0xffff)
> -    ok 36 - mp_encode(0xffff) == "\xde\xff\xff"
> -    # map 0x10000
> -    ok 37 - mp_check_map(0x10000) == 0
> -    ok 38 - mp_decode(mp_encode(0x10000)) == 0x10000
> -    ok 39 - len(mp_encode_map(0x10000)
> -    ok 40 - len(mp_decode_map(0x10000))
> -    ok 41 - mp_sizeof_map(0x10000)
> -    ok 42 - mp_encode(0x10000) == "\xdf\x00\x01\x00\x00"
> -    # map 0xfffffffeU
> -    ok 43 - mp_check_map(0xfffffffeU) == 0
> -    ok 44 - mp_decode(mp_encode(0xfffffffeU)) == 0xfffffffeU
> -    ok 45 - len(mp_encode_map(0xfffffffeU)
> -    ok 46 - len(mp_decode_map(0xfffffffeU))
> -    ok 47 - mp_sizeof_map(0xfffffffeU)
> -    ok 48 - mp_encode(0xfffffffeU) == "\xdf\xff\xff\xff\xfe"
> -    # map 0xffffffffU
> -    ok 49 - mp_check_map(0xffffffffU) == 0
> -    ok 50 - mp_decode(mp_encode(0xffffffffU)) == 0xffffffffU
> -    ok 51 - len(mp_encode_map(0xffffffffU)
> -    ok 52 - len(mp_decode_map(0xffffffffU))
> -    ok 53 - mp_sizeof_map(0xffffffffU)
> -    ok 54 - mp_encode(0xffffffffU) == "\xdf\xff\xff\xff\xff"
> -    # *** test_maps: done ***
> -ok 14 - subtests
> -    1..52
> -    # *** test_next_on_arrays ***
> -    # next/check on array(0)
> -    ok 1 - mp_check(array 0))
> -    ok 2 - len(array 0) == 1
> -    ok 3 - len(mp_check(array 0)) == 1
> -    ok 4 - len(mp_next(array 0)) == 1
> -    # next/check on array(1)
> -    ok 5 - mp_check(array 1))
> -    ok 6 - len(array 1) == 2
> -    ok 7 - len(mp_check(array 1)) == 2
> -    ok 8 - len(mp_next(array 1)) == 2
> -    # next/check on array(15)
> -    ok 9 - mp_check(array 15))
> -    ok 10 - len(array 15) == 16
> -    ok 11 - len(mp_check(array 15)) == 16
> -    ok 12 - len(mp_next(array 15)) == 16
> -    # next/check on array(16)
> -    ok 13 - mp_check(array 16))
> -    ok 14 - len(array 16) == 19
> -    ok 15 - len(mp_check(array 16)) == 19
> -    ok 16 - len(mp_next(array 16)) == 19
> -    # next/check on array(17)
> -    ok 17 - mp_check(array 17))
> -    ok 18 - len(array 17) == 20
> -    ok 19 - len(mp_check(array 17)) == 20
> -    ok 20 - len(mp_next(array 17)) == 20
> -    # next/check on array(254)
> -    ok 21 - mp_check(array 254))
> -    ok 22 - len(array 254) == 257
> -    ok 23 - len(mp_check(array 254)) == 257
> -    ok 24 - len(mp_next(array 254)) == 257
> -    # next/check on array(255)
> -    ok 25 - mp_check(array 255))
> -    ok 26 - len(array 255) == 258
> -    ok 27 - len(mp_check(array 255)) == 258
> -    ok 28 - len(mp_next(array 255)) == 258
> -    # next/check on array(256)
> -    ok 29 - mp_check(array 256))
> -    ok 30 - len(array 256) == 259
> -    ok 31 - len(mp_check(array 256)) == 259
> -    ok 32 - len(mp_next(array 256)) == 259
> -    # next/check on array(257)
> -    ok 33 - mp_check(array 257))
> -    ok 34 - len(array 257) == 260
> -    ok 35 - len(mp_check(array 257)) == 260
> -    ok 36 - len(mp_next(array 257)) == 260
> -    # next/check on array(65534)
> -    ok 37 - mp_check(array 65534))
> -    ok 38 - len(array 65534) == 65537
> -    ok 39 - len(mp_check(array 65534)) == 65537
> -    ok 40 - len(mp_next(array 65534)) == 65537
> -    # next/check on array(65535)
> -    ok 41 - mp_check(array 65535))
> -    ok 42 - len(array 65535) == 65538
> -    ok 43 - len(mp_check(array 65535)) == 65538
> -    ok 44 - len(mp_next(array 65535)) == 65538
> -    # next/check on array(65536)
> -    ok 45 - mp_check(array 65536))
> -    ok 46 - len(array 65536) == 65541
> -    ok 47 - len(mp_check(array 65536)) == 65541
> -    ok 48 - len(mp_next(array 65536)) == 65541
> -    # next/check on array(65537)
> -    ok 49 - mp_check(array 65537))
> -    ok 50 - len(array 65537) == 65542
> -    ok 51 - len(mp_check(array 65537)) == 65542
> -    ok 52 - len(mp_next(array 65537)) == 65542
> -    # *** test_next_on_arrays: done ***
> -ok 15 - subtests
> -    1..52
> -    # *** test_next_on_maps ***
> -    # next/check on map(0)
> -    ok 1 - mp_check(map 0))
> -    ok 2 - len(map 0) == 1
> -    ok 3 - len(mp_check(map 0)) == 1
> -    ok 4 - len(mp_next(map 0)) == 1
> -    # next/check on map(1)
> -    ok 5 - mp_check(map 1))
> -    ok 6 - len(map 1) == 3
> -    ok 7 - len(mp_check(map 1)) == 3
> -    ok 8 - len(mp_next(map 1)) == 3
> -    # next/check on map(15)
> -    ok 9 - mp_check(map 15))
> -    ok 10 - len(map 15) == 31
> -    ok 11 - len(mp_check(map 15)) == 31
> -    ok 12 - len(mp_next(map 15)) == 31
> -    # next/check on map(16)
> -    ok 13 - mp_check(map 16))
> -    ok 14 - len(map 16) == 35
> -    ok 15 - len(mp_check(map 16)) == 35
> -    ok 16 - len(mp_next(map 16)) == 35
> -    # next/check on map(17)
> -    ok 17 - mp_check(map 17))
> -    ok 18 - len(map 17) == 37
> -    ok 19 - len(mp_check(map 17)) == 37
> -    ok 20 - len(mp_next(map 17)) == 37
> -    # next/check on map(254)
> -    ok 21 - mp_check(map 254))
> -    ok 22 - len(map 254) == 511
> -    ok 23 - len(mp_check(map 254)) == 511
> -    ok 24 - len(mp_next(map 254)) == 511
> -    # next/check on map(255)
> -    ok 25 - mp_check(map 255))
> -    ok 26 - len(map 255) == 513
> -    ok 27 - len(mp_check(map 255)) == 513
> -    ok 28 - len(mp_next(map 255)) == 513
> -    # next/check on map(256)
> -    ok 29 - mp_check(map 256))
> -    ok 30 - len(map 256) == 515
> -    ok 31 - len(mp_check(map 256)) == 515
> -    ok 32 - len(mp_next(map 256)) == 515
> -    # next/check on map(257)
> -    ok 33 - mp_check(map 257))
> -    ok 34 - len(map 257) == 517
> -    ok 35 - len(mp_check(map 257)) == 517
> -    ok 36 - len(mp_next(map 257)) == 517
> -    # next/check on map(65534)
> -    ok 37 - mp_check(map 65534))
> -    ok 38 - len(map 65534) == 131071
> -    ok 39 - len(mp_check(map 65534)) == 131071
> -    ok 40 - len(mp_next(map 65534)) == 131071
> -    # next/check on map(65535)
> -    ok 41 - mp_check(map 65535))
> -    ok 42 - len(map 65535) == 131073
> -    ok 43 - len(mp_check(map 65535)) == 131073
> -    ok 44 - len(mp_next(map 65535)) == 131073
> -    # next/check on map(65536)
> -    ok 45 - mp_check(map 65536))
> -    ok 46 - len(map 65536) == 131077
> -    ok 47 - len(mp_check(map 65536)) == 131077
> -    ok 48 - len(mp_next(map 65536)) == 131077
> -    # next/check on map(65537)
> -    ok 49 - mp_check(map 65537))
> -    ok 50 - len(map 65537) == 131079
> -    ok 51 - len(mp_check(map 65537)) == 131079
> -    ok 52 - len(mp_next(map 65537)) == 131079
> -    # *** test_next_on_maps: done ***
> -ok 16 - subtests
> -    1..227
> -    # *** test_compare_uints ***
> -    ok 1 - mp_compare_uint(0, 0) == 0
> -    ok 2 - mp_compare_uint(0, 0) == 0
> -    ok 3 - mp_compare_uint(0, 0) == 0
> -    ok 4 - mp_compare_uint(0, 1) < 0
> -    ok 5 - mp_compare_uint(0, 126) < 0
> -    ok 6 - mp_compare_uint(0, 127) < 0
> -    ok 7 - mp_compare_uint(0, 128) < 0
> -    ok 8 - mp_compare_uint(0, 254) < 0
> -    ok 9 - mp_compare_uint(0, 255) < 0
> -    ok 10 - mp_compare_uint(0, 65534) < 0
> -    ok 11 - mp_compare_uint(0, 65535) < 0
> -    ok 12 - mp_compare_uint(0, 65536) < 0
> -    ok 13 - mp_compare_uint(0, 4294967294) < 0
> -    ok 14 - mp_compare_uint(0, 4294967295) < 0
> -    ok 15 - mp_compare_uint(0, 4294967296) < 0
> -    ok 16 - mp_compare_uint(0, 18446744073709551614) < 0
> -    ok 17 - mp_compare_uint(0, 18446744073709551615) < 0
> -    ok 18 - mp_compare_uint(1, 0) > 0
> -    ok 19 - mp_compare_uint(1, 1) == 0
> -    ok 20 - mp_compare_uint(1, 126) < 0
> -    ok 21 - mp_compare_uint(1, 127) < 0
> -    ok 22 - mp_compare_uint(1, 128) < 0
> -    ok 23 - mp_compare_uint(1, 254) < 0
> -    ok 24 - mp_compare_uint(1, 255) < 0
> -    ok 25 - mp_compare_uint(1, 65534) < 0
> -    ok 26 - mp_compare_uint(1, 65535) < 0
> -    ok 27 - mp_compare_uint(1, 65536) < 0
> -    ok 28 - mp_compare_uint(1, 4294967294) < 0
> -    ok 29 - mp_compare_uint(1, 4294967295) < 0
> -    ok 30 - mp_compare_uint(1, 4294967296) < 0
> -    ok 31 - mp_compare_uint(1, 18446744073709551614) < 0
> -    ok 32 - mp_compare_uint(1, 18446744073709551615) < 0
> -    ok 33 - mp_compare_uint(126, 0) > 0
> -    ok 34 - mp_compare_uint(126, 1) > 0
> -    ok 35 - mp_compare_uint(126, 126) == 0
> -    ok 36 - mp_compare_uint(126, 127) < 0
> -    ok 37 - mp_compare_uint(126, 128) < 0
> -    ok 38 - mp_compare_uint(126, 254) < 0
> -    ok 39 - mp_compare_uint(126, 255) < 0
> -    ok 40 - mp_compare_uint(126, 65534) < 0
> -    ok 41 - mp_compare_uint(126, 65535) < 0
> -    ok 42 - mp_compare_uint(126, 65536) < 0
> -    ok 43 - mp_compare_uint(126, 4294967294) < 0
> -    ok 44 - mp_compare_uint(126, 4294967295) < 0
> -    ok 45 - mp_compare_uint(126, 4294967296) < 0
> -    ok 46 - mp_compare_uint(126, 18446744073709551614) < 0
> -    ok 47 - mp_compare_uint(126, 18446744073709551615) < 0
> -    ok 48 - mp_compare_uint(127, 0) > 0
> -    ok 49 - mp_compare_uint(127, 1) > 0
> -    ok 50 - mp_compare_uint(127, 126) > 0
> -    ok 51 - mp_compare_uint(127, 127) == 0
> -    ok 52 - mp_compare_uint(127, 128) < 0
> -    ok 53 - mp_compare_uint(127, 254) < 0
> -    ok 54 - mp_compare_uint(127, 255) < 0
> -    ok 55 - mp_compare_uint(127, 65534) < 0
> -    ok 56 - mp_compare_uint(127, 65535) < 0
> -    ok 57 - mp_compare_uint(127, 65536) < 0
> -    ok 58 - mp_compare_uint(127, 4294967294) < 0
> -    ok 59 - mp_compare_uint(127, 4294967295) < 0
> -    ok 60 - mp_compare_uint(127, 4294967296) < 0
> -    ok 61 - mp_compare_uint(127, 18446744073709551614) < 0
> -    ok 62 - mp_compare_uint(127, 18446744073709551615) < 0
> -    ok 63 - mp_compare_uint(128, 0) > 0
> -    ok 64 - mp_compare_uint(128, 1) > 0
> -    ok 65 - mp_compare_uint(128, 126) > 0
> -    ok 66 - mp_compare_uint(128, 127) > 0
> -    ok 67 - mp_compare_uint(128, 128) == 0
> -    ok 68 - mp_compare_uint(128, 254) < 0
> -    ok 69 - mp_compare_uint(128, 255) < 0
> -    ok 70 - mp_compare_uint(128, 65534) < 0
> -    ok 71 - mp_compare_uint(128, 65535) < 0
> -    ok 72 - mp_compare_uint(128, 65536) < 0
> -    ok 73 - mp_compare_uint(128, 4294967294) < 0
> -    ok 74 - mp_compare_uint(128, 4294967295) < 0
> -    ok 75 - mp_compare_uint(128, 4294967296) < 0
> -    ok 76 - mp_compare_uint(128, 18446744073709551614) < 0
> -    ok 77 - mp_compare_uint(128, 18446744073709551615) < 0
> -    ok 78 - mp_compare_uint(254, 0) > 0
> -    ok 79 - mp_compare_uint(254, 1) > 0
> -    ok 80 - mp_compare_uint(254, 126) > 0
> -    ok 81 - mp_compare_uint(254, 127) > 0
> -    ok 82 - mp_compare_uint(254, 128) > 0
> -    ok 83 - mp_compare_uint(254, 254) == 0
> -    ok 84 - mp_compare_uint(254, 255) < 0
> -    ok 85 - mp_compare_uint(254, 65534) < 0
> -    ok 86 - mp_compare_uint(254, 65535) < 0
> -    ok 87 - mp_compare_uint(254, 65536) < 0
> -    ok 88 - mp_compare_uint(254, 4294967294) < 0
> -    ok 89 - mp_compare_uint(254, 4294967295) < 0
> -    ok 90 - mp_compare_uint(254, 4294967296) < 0
> -    ok 91 - mp_compare_uint(254, 18446744073709551614) < 0
> -    ok 92 - mp_compare_uint(254, 18446744073709551615) < 0
> -    ok 93 - mp_compare_uint(255, 0) > 0
> -    ok 94 - mp_compare_uint(255, 1) > 0
> -    ok 95 - mp_compare_uint(255, 126) > 0
> -    ok 96 - mp_compare_uint(255, 127) > 0
> -    ok 97 - mp_compare_uint(255, 128) > 0
> -    ok 98 - mp_compare_uint(255, 254) > 0
> -    ok 99 - mp_compare_uint(255, 255) == 0
> -    ok 100 - mp_compare_uint(255, 65534) < 0
> -    ok 101 - mp_compare_uint(255, 65535) < 0
> -    ok 102 - mp_compare_uint(255, 65536) < 0
> -    ok 103 - mp_compare_uint(255, 4294967294) < 0
> -    ok 104 - mp_compare_uint(255, 4294967295) < 0
> -    ok 105 - mp_compare_uint(255, 4294967296) < 0
> -    ok 106 - mp_compare_uint(255, 18446744073709551614) < 0
> -    ok 107 - mp_compare_uint(255, 18446744073709551615) < 0
> -    ok 108 - mp_compare_uint(65534, 0) > 0
> -    ok 109 - mp_compare_uint(65534, 1) > 0
> -    ok 110 - mp_compare_uint(65534, 126) > 0
> -    ok 111 - mp_compare_uint(65534, 127) > 0
> -    ok 112 - mp_compare_uint(65534, 128) > 0
> -    ok 113 - mp_compare_uint(65534, 254) > 0
> -    ok 114 - mp_compare_uint(65534, 255) > 0
> -    ok 115 - mp_compare_uint(65534, 65534) == 0
> -    ok 116 - mp_compare_uint(65534, 65535) < 0
> -    ok 117 - mp_compare_uint(65534, 65536) < 0
> -    ok 118 - mp_compare_uint(65534, 4294967294) < 0
> -    ok 119 - mp_compare_uint(65534, 4294967295) < 0
> -    ok 120 - mp_compare_uint(65534, 4294967296) < 0
> -    ok 121 - mp_compare_uint(65534, 18446744073709551614) < 0
> -    ok 122 - mp_compare_uint(65534, 18446744073709551615) < 0
> -    ok 123 - mp_compare_uint(65535, 0) > 0
> -    ok 124 - mp_compare_uint(65535, 1) > 0
> -    ok 125 - mp_compare_uint(65535, 126) > 0
> -    ok 126 - mp_compare_uint(65535, 127) > 0
> -    ok 127 - mp_compare_uint(65535, 128) > 0
> -    ok 128 - mp_compare_uint(65535, 254) > 0
> -    ok 129 - mp_compare_uint(65535, 255) > 0
> -    ok 130 - mp_compare_uint(65535, 65534) > 0
> -    ok 131 - mp_compare_uint(65535, 65535) == 0
> -    ok 132 - mp_compare_uint(65535, 65536) < 0
> -    ok 133 - mp_compare_uint(65535, 4294967294) < 0
> -    ok 134 - mp_compare_uint(65535, 4294967295) < 0
> -    ok 135 - mp_compare_uint(65535, 4294967296) < 0
> -    ok 136 - mp_compare_uint(65535, 18446744073709551614) < 0
> -    ok 137 - mp_compare_uint(65535, 18446744073709551615) < 0
> -    ok 138 - mp_compare_uint(65536, 0) > 0
> -    ok 139 - mp_compare_uint(65536, 1) > 0
> -    ok 140 - mp_compare_uint(65536, 126) > 0
> -    ok 141 - mp_compare_uint(65536, 127) > 0
> -    ok 142 - mp_compare_uint(65536, 128) > 0
> -    ok 143 - mp_compare_uint(65536, 254) > 0
> -    ok 144 - mp_compare_uint(65536, 255) > 0
> -    ok 145 - mp_compare_uint(65536, 65534) > 0
> -    ok 146 - mp_compare_uint(65536, 65535) > 0
> -    ok 147 - mp_compare_uint(65536, 65536) == 0
> -    ok 148 - mp_compare_uint(65536, 4294967294) < 0
> -    ok 149 - mp_compare_uint(65536, 4294967295) < 0
> -    ok 150 - mp_compare_uint(65536, 4294967296) < 0
> -    ok 151 - mp_compare_uint(65536, 18446744073709551614) < 0
> -    ok 152 - mp_compare_uint(65536, 18446744073709551615) < 0
> -    ok 153 - mp_compare_uint(4294967294, 0) > 0
> -    ok 154 - mp_compare_uint(4294967294, 1) > 0
> -    ok 155 - mp_compare_uint(4294967294, 126) > 0
> -    ok 156 - mp_compare_uint(4294967294, 127) > 0
> -    ok 157 - mp_compare_uint(4294967294, 128) > 0
> -    ok 158 - mp_compare_uint(4294967294, 254) > 0
> -    ok 159 - mp_compare_uint(4294967294, 255) > 0
> -    ok 160 - mp_compare_uint(4294967294, 65534) > 0
> -    ok 161 - mp_compare_uint(4294967294, 65535) > 0
> -    ok 162 - mp_compare_uint(4294967294, 65536) > 0
> -    ok 163 - mp_compare_uint(4294967294, 4294967294) == 0
> -    ok 164 - mp_compare_uint(4294967294, 4294967295) < 0
> -    ok 165 - mp_compare_uint(4294967294, 4294967296) < 0
> -    ok 166 - mp_compare_uint(4294967294, 18446744073709551614) < 0
> -    ok 167 - mp_compare_uint(4294967294, 18446744073709551615) < 0
> -    ok 168 - mp_compare_uint(4294967295, 0) > 0
> -    ok 169 - mp_compare_uint(4294967295, 1) > 0
> -    ok 170 - mp_compare_uint(4294967295, 126) > 0
> -    ok 171 - mp_compare_uint(4294967295, 127) > 0
> -    ok 172 - mp_compare_uint(4294967295, 128) > 0
> -    ok 173 - mp_compare_uint(4294967295, 254) > 0
> -    ok 174 - mp_compare_uint(4294967295, 255) > 0
> -    ok 175 - mp_compare_uint(4294967295, 65534) > 0
> -    ok 176 - mp_compare_uint(4294967295, 65535) > 0
> -    ok 177 - mp_compare_uint(4294967295, 65536) > 0
> -    ok 178 - mp_compare_uint(4294967295, 4294967294) > 0
> -    ok 179 - mp_compare_uint(4294967295, 4294967295) == 0
> -    ok 180 - mp_compare_uint(4294967295, 4294967296) < 0
> -    ok 181 - mp_compare_uint(4294967295, 18446744073709551614) < 0
> -    ok 182 - mp_compare_uint(4294967295, 18446744073709551615) < 0
> -    ok 183 - mp_compare_uint(4294967296, 0) > 0
> -    ok 184 - mp_compare_uint(4294967296, 1) > 0
> -    ok 185 - mp_compare_uint(4294967296, 126) > 0
> -    ok 186 - mp_compare_uint(4294967296, 127) > 0
> -    ok 187 - mp_compare_uint(4294967296, 128) > 0
> -    ok 188 - mp_compare_uint(4294967296, 254) > 0
> -    ok 189 - mp_compare_uint(4294967296, 255) > 0
> -    ok 190 - mp_compare_uint(4294967296, 65534) > 0
> -    ok 191 - mp_compare_uint(4294967296, 65535) > 0
> -    ok 192 - mp_compare_uint(4294967296, 65536) > 0
> -    ok 193 - mp_compare_uint(4294967296, 4294967294) > 0
> -    ok 194 - mp_compare_uint(4294967296, 4294967295) > 0
> -    ok 195 - mp_compare_uint(4294967296, 4294967296) == 0
> -    ok 196 - mp_compare_uint(4294967296, 18446744073709551614) < 0
> -    ok 197 - mp_compare_uint(4294967296, 18446744073709551615) < 0
> -    ok 198 - mp_compare_uint(18446744073709551614, 0) > 0
> -    ok 199 - mp_compare_uint(18446744073709551614, 1) > 0
> -    ok 200 - mp_compare_uint(18446744073709551614, 126) > 0
> -    ok 201 - mp_compare_uint(18446744073709551614, 127) > 0
> -    ok 202 - mp_compare_uint(18446744073709551614, 128) > 0
> -    ok 203 - mp_compare_uint(18446744073709551614, 254) > 0
> -    ok 204 - mp_compare_uint(18446744073709551614, 255) > 0
> -    ok 205 - mp_compare_uint(18446744073709551614, 65534) > 0
> -    ok 206 - mp_compare_uint(18446744073709551614, 65535) > 0
> -    ok 207 - mp_compare_uint(18446744073709551614, 65536) > 0
> -    ok 208 - mp_compare_uint(18446744073709551614, 4294967294) > 0
> -    ok 209 - mp_compare_uint(18446744073709551614, 4294967295) > 0
> -    ok 210 - mp_compare_uint(18446744073709551614, 4294967296) > 0
> -    ok 211 - mp_compare_uint(18446744073709551614, 18446744073709551614) == 0
> -    ok 212 - mp_compare_uint(18446744073709551614, 18446744073709551615) < 0
> -    ok 213 - mp_compare_uint(18446744073709551615, 0) > 0
> -    ok 214 - mp_compare_uint(18446744073709551615, 1) > 0
> -    ok 215 - mp_compare_uint(18446744073709551615, 126) > 0
> -    ok 216 - mp_compare_uint(18446744073709551615, 127) > 0
> -    ok 217 - mp_compare_uint(18446744073709551615, 128) > 0
> -    ok 218 - mp_compare_uint(18446744073709551615, 254) > 0
> -    ok 219 - mp_compare_uint(18446744073709551615, 255) > 0
> -    ok 220 - mp_compare_uint(18446744073709551615, 65534) > 0
> -    ok 221 - mp_compare_uint(18446744073709551615, 65535) > 0
> -    ok 222 - mp_compare_uint(18446744073709551615, 65536) > 0
> -    ok 223 - mp_compare_uint(18446744073709551615, 4294967294) > 0
> -    ok 224 - mp_compare_uint(18446744073709551615, 4294967295) > 0
> -    ok 225 - mp_compare_uint(18446744073709551615, 4294967296) > 0
> -    ok 226 - mp_compare_uint(18446744073709551615, 18446744073709551614) > 0
> -    ok 227 - mp_compare_uint(18446744073709551615, 18446744073709551615) == 0
> -    # *** test_compare_uints: done ***
> -ok 17 - subtests
> -    1..282
> -    # *** test_format ***
> -    ok 1 - Test type on step 0
> -    ok 2 - Test value on step 0
> -    ok 3 - Test type on step 1
> -    ok 4 - Test value on step 1
> -    ok 5 - Test type on step 2
> -    ok 6 - Test value on step 2
> -    ok 7 - Test type on step 3
> -    ok 8 - Test value on step 3
> -    ok 9 - Test type on step 4
> -    ok 10 - Test value on step 4
> -    ok 11 - Test type on step 5
> -    ok 12 - Test value on step 5
> -    ok 13 - Test type on step 6
> -    ok 14 - Test value on step 6
> -    ok 15 - Test type on step 7
> -    ok 16 - Test value on step 7
> -    ok 17 - Test type on step 8
> -    ok 18 - Test value on step 8
> -    ok 19 - Test type on step 9
> -    ok 20 - Test value on step 9
> -    ok 21 - Test type on step 10
> -    ok 22 - Test value on step 10
> -    ok 23 - Test type on step 11
> -    ok 24 - Test value on step 11
> -    ok 25 - Test type on step 12
> -    ok 26 - Test value on step 12
> -    ok 27 - Test type on step 13
> -    ok 28 - Test value on step 13
> -    ok 29 - Test type on step 14
> -    ok 30 - Test value on step 14
> -    ok 31 - Test type on step 0
> -    ok 32 - Test value on step 0
> -    ok 33 - Test type on step 1
> -    ok 34 - Test value on step 1
> -    ok 35 - Test type on step 2
> -    ok 36 - Test value on step 2
> -    ok 37 - Test type on step 3
> -    ok 38 - Test value on step 3
> -    ok 39 - Test type on step 4
> -    ok 40 - Test value on step 4
> -    ok 41 - Test type on step 5
> -    ok 42 - Test value on step 5
> -    ok 43 - Test type on step 6
> -    ok 44 - Test value on step 6
> -    ok 45 - Test type on step 7
> -    ok 46 - Test value on step 7
> -    ok 47 - Test type on step 8
> -    ok 48 - Test value on step 8
> -    ok 49 - Test type on step 9
> -    ok 50 - Test value on step 9
> -    ok 51 - Test type on step 10
> -    ok 52 - Test value on step 10
> -    ok 53 - Test type on step 11
> -    ok 54 - Test value on step 11
> -    ok 55 - Test type on step 12
> -    ok 56 - Test value on step 12
> -    ok 57 - Test type on step 13
> -    ok 58 - Test value on step 13
> -    ok 59 - Test type on step 14
> -    ok 60 - Test value on step 14
> -    ok 61 - check
> -    ok 62 - type
> -    ok 63 - decode
> -    ok 64 - check
> -    ok 65 - type
> -    ok 66 - check
> -    ok 67 - type
> -    ok 68 - decode
> -    ok 69 - check
> -    ok 70 - type
> -    ok 71 - decode
> -    ok 72 - check
> -    ok 73 - type
> -    ok 74 - decode
> -    ok 75 - check
> -    ok 76 - type
> -    ok 77 - decode
> -    ok 78 - check
> -    ok 79 - type
> -    ok 80 - decode
> -    ok 81 - check
> -    ok 82 - type
> -    ok 83 - decode
> -    ok 84 - check
> -    ok 85 - type
> -    ok 86 - decode
> -    ok 87 - check
> -    ok 88 - type
> -    ok 89 - decode
> -    ok 90 - check
> -    ok 91 - type
> -    ok 92 - decode
> -    ok 93 - check
> -    ok 94 - type
> -    ok 95 - decode
> -    ok 96 - check
> -    ok 97 - type
> -    ok 98 - decode
> -    ok 99 - compare
> -    ok 100 - check
> -    ok 101 - type
> -    ok 102 - decode
> -    ok 103 - check
> -    ok 104 - type
> -    ok 105 - decode
> -    ok 106 - compare
> -    ok 107 - check
> -    ok 108 - type
> -    ok 109 - decode
> -    ok 110 - check
> -    ok 111 - type
> -    ok 112 - decode
> -    ok 113 - check
> -    ok 114 - type
> -    ok 115 - check
> -    ok 116 - compare
> -    ok 117 - check
> -    ok 118 - type
> -    ok 119 - decode
> -    ok 120 - check
> -    ok 121 - type
> -    ok 122 - decode
> -    ok 123 - check
> -    ok 124 - type
> -    ok 125 - decode
> -    ok 126 - compare
> -    ok 127 - check
> -    ok 128 - type
> -    ok 129 - decode
> -    ok 130 - check
> -    ok 131 - type
> -    ok 132 - decode
> -    ok 133 - check
> -    ok 134 - type
> -    ok 135 - decode
> -    ok 136 - check
> -    ok 137 - type
> -    ok 138 - decode
> -    ok 139 - nothing more
> -    ok 140 - no magic detected
> -    ok 141 - return value on step 0
> -    ok 142 - buffer overflow on step 0
> -    ok 143 - return value on step 1
> -    ok 144 - buffer overflow on step 1
> -    ok 145 - return value on step 2
> -    ok 146 - buffer overflow on step 2
> -    ok 147 - return value on step 3
> -    ok 148 - buffer overflow on step 3
> -    ok 149 - return value on step 4
> -    ok 150 - buffer overflow on step 4
> -    ok 151 - return value on step 5
> -    ok 152 - buffer overflow on step 5
> -    ok 153 - return value on step 6
> -    ok 154 - buffer overflow on step 6
> -    ok 155 - return value on step 7
> -    ok 156 - buffer overflow on step 7
> -    ok 157 - return value on step 8
> -    ok 158 - buffer overflow on step 8
> -    ok 159 - return value on step 9
> -    ok 160 - buffer overflow on step 9
> -    ok 161 - return value on step 10
> -    ok 162 - buffer overflow on step 10
> -    ok 163 - return value on step 11
> -    ok 164 - buffer overflow on step 11
> -    ok 165 - return value on step 12
> -    ok 166 - buffer overflow on step 12
> -    ok 167 - return value on step 13
> -    ok 168 - buffer overflow on step 13
> -    ok 169 - return value on step 14
> -    ok 170 - buffer overflow on step 14
> -    ok 171 - return value on step 15
> -    ok 172 - buffer overflow on step 15
> -    ok 173 - return value on step 16
> -    ok 174 - buffer overflow on step 16
> -    ok 175 - return value on step 17
> -    ok 176 - buffer overflow on step 17
> -    ok 177 - return value on step 18
> -    ok 178 - buffer overflow on step 18
> -    ok 179 - return value on step 19
> -    ok 180 - buffer overflow on step 19
> -    ok 181 - return value on step 20
> -    ok 182 - buffer overflow on step 20
> -    ok 183 - return value on step 21
> -    ok 184 - buffer overflow on step 21
> -    ok 185 - return value on step 22
> -    ok 186 - buffer overflow on step 22
> -    ok 187 - return value on step 23
> -    ok 188 - buffer overflow on step 23
> -    ok 189 - return value on step 24
> -    ok 190 - buffer overflow on step 24
> -    ok 191 - return value on step 25
> -    ok 192 - buffer overflow on step 25
> -    ok 193 - return value on step 26
> -    ok 194 - buffer overflow on step 26
> -    ok 195 - return value on step 27
> -    ok 196 - buffer overflow on step 27
> -    ok 197 - return value on step 28
> -    ok 198 - buffer overflow on step 28
> -    ok 199 - return value on step 29
> -    ok 200 - buffer overflow on step 29
> -    ok 201 - return value on step 30
> -    ok 202 - buffer overflow on step 30
> -    ok 203 - return value on step 31
> -    ok 204 - buffer overflow on step 31
> -    ok 205 - return value on step 32
> -    ok 206 - buffer overflow on step 32
> -    ok 207 - return value on step 33
> -    ok 208 - buffer overflow on step 33
> -    ok 209 - return value on step 34
> -    ok 210 - buffer overflow on step 34
> -    ok 211 - return value on step 35
> -    ok 212 - buffer overflow on step 35
> -    ok 213 - return value on step 36
> -    ok 214 - buffer overflow on step 36
> -    ok 215 - return value on step 37
> -    ok 216 - buffer overflow on step 37
> -    ok 217 - return value on step 38
> -    ok 218 - buffer overflow on step 38
> -    ok 219 - return value on step 39
> -    ok 220 - buffer overflow on step 39
> -    ok 221 - return value on step 40
> -    ok 222 - buffer overflow on step 40
> -    ok 223 - return value on step 41
> -    ok 224 - buffer overflow on step 41
> -    ok 225 - return value on step 42
> -    ok 226 - buffer overflow on step 42
> -    ok 227 - return value on step 43
> -    ok 228 - buffer overflow on step 43
> -    ok 229 - return value on step 44
> -    ok 230 - buffer overflow on step 44
> -    ok 231 - return value on step 45
> -    ok 232 - buffer overflow on step 45
> -    ok 233 - return value on step 46
> -    ok 234 - buffer overflow on step 46
> -    ok 235 - return value on step 47
> -    ok 236 - buffer overflow on step 47
> -    ok 237 - return value on step 48
> -    ok 238 - buffer overflow on step 48
> -    ok 239 - return value on step 49
> -    ok 240 - buffer overflow on step 49
> -    ok 241 - return value on step 50
> -    ok 242 - buffer overflow on step 50
> -    ok 243 - return value on step 51
> -    ok 244 - buffer overflow on step 51
> -    ok 245 - return value on step 52
> -    ok 246 - buffer overflow on step 52
> -    ok 247 - return value on step 53
> -    ok 248 - buffer overflow on step 53
> -    ok 249 - return value on step 54
> -    ok 250 - buffer overflow on step 54
> -    ok 251 - return value on step 55
> -    ok 252 - buffer overflow on step 55
> -    ok 253 - return value on step 56
> -    ok 254 - buffer overflow on step 56
> -    ok 255 - return value on step 57
> -    ok 256 - buffer overflow on step 57
> -    ok 257 - return value on step 58
> -    ok 258 - buffer overflow on step 58
> -    ok 259 - return value on step 59
> -    ok 260 - buffer overflow on step 59
> -    ok 261 - return value on step 60
> -    ok 262 - buffer overflow on step 60
> -    ok 263 - return value on step 61
> -    ok 264 - buffer overflow on step 61
> -    ok 265 - return value on step 62
> -    ok 266 - buffer overflow on step 62
> -    ok 267 - return value on step 63
> -    ok 268 - buffer overflow on step 63
> -    ok 269 - return value on step 64
> -    ok 270 - buffer overflow on step 64
> -    ok 271 - return value on step 65
> -    ok 272 - buffer overflow on step 65
> -    ok 273 - return value on step 66
> -    ok 274 - buffer overflow on step 66
> -    ok 275 - return value on step 67
> -    ok 276 - buffer overflow on step 67
> -    ok 277 - return value on step 68
> -    ok 278 - buffer overflow on step 68
> -    ok 279 - return value on step 69
> -    ok 280 - buffer overflow on step 69
> -    ok 281 - return value on step 70
> -    ok 282 - buffer overflow on step 70
> -    # *** test_format: done ***
> -ok 18 - subtests
> -    1..12
> -    # *** test_mp_print ***
> -    ok 1 - mp_snprint return value
> -    ok 2 - mp_snprint result
> -    ok 3 - mp_snprint limit = 0
> -    ok 4 - mp_snprint limit = 1
> -    ok 5 - mp_snprint limit = 2
> -    ok 6 - mp_snprint limit = expected
> -    ok 7 - mp_snprint limit = expected + 1
> -    ok 8 - mp_fprint return value
> -    ok 9 - mp_fprint result
> -    ok 10 - mp_fprint I/O error
> -    ok 11 - mp_snprint max nesting depth return value
> -    ok 12 - mp_snprint max nesting depth result
> -    # *** test_mp_print: done ***
> -ok 19 - subtests
> -    1..65
> -    # *** test_mp_check ***
> -    ok 1 - invalid fixmap 1
> -    ok 2 - invalid fixmap 2
> -    ok 3 - invalid fixmap 3
> -    ok 4 - invalid fixarray 1
> -    ok 5 - invalid fixarray 2
> -    ok 6 - invalid fixarray 3
> -    ok 7 - invalid fixstr 1
> -    ok 8 - invalid fixstr 2
> -    ok 9 - invalid fixstr 3
> -    ok 10 - invalid bin8 1
> -    ok 11 - invalid bin8 2
> -    ok 12 - invalid bin16 1
> -    ok 13 - invalid bin16 2
> -    ok 14 - invalid bin32 1
> -    ok 15 - invalid bin32 2
> -    ok 16 - invalid ext8 1
> -    ok 17 - invalid ext8 2
> -    ok 18 - invalid ext8 3
> -    ok 19 - invalid ext8 4
> -    ok 20 - invalid ext16 1
> -    ok 21 - invalid ext16 2
> -    ok 22 - invalid ext16 3
> -    ok 23 - invalid ext16 4
> -    ok 24 - invalid ext32 1
> -    ok 25 - invalid ext32 2
> -    ok 26 - invalid ext32 3
> -    ok 27 - invalid ext32 4
> -    ok 28 - invalid float32 1
> -    ok 29 - invalid float32 2
> -    ok 30 - invalid float64 1
> -    ok 31 - invalid float64 2
> -    ok 32 - invalid uint8 1
> -    ok 33 - invalid uint16 1
> -    ok 34 - invalid uint32 1
> -    ok 35 - invalid uint64 1
> -    ok 36 - invalid int8 1
> -    ok 37 - invalid int16 1
> -    ok 38 - invalid int32 1
> -    ok 39 - invalid int64 1
> -    ok 40 - invalid fixext8 1
> -    ok 41 - invalid fixext8 2
> -    ok 42 - invalid fixext16 1
> -    ok 43 - invalid fixext16 2
> -    ok 44 - invalid fixext32 1
> -    ok 45 - invalid fixext32 2
> -    ok 46 - invalid fixext64 1
> -    ok 47 - invalid fixext64 2
> -    ok 48 - invalid fixext128 1
> -    ok 49 - invalid fixext128 2
> -    ok 50 - invalid str8 1
> -    ok 51 - invalid str8 2
> -    ok 52 - invalid str16 1
> -    ok 53 - invalid str16 2
> -    ok 54 - invalid str32 1
> -    ok 55 - invalid str32 2
> -    ok 56 - invalid array16 1
> -    ok 57 - invalid array16 2
> -    ok 58 - invalid array32 1
> -    ok 59 - invalid array32 2
> -    ok 60 - invalid map16 1
> -    ok 61 - invalid map16 2
> -    ok 62 - invalid map16 2
> -    ok 63 - invalid map32 1
> -    ok 64 - invalid map32 2
> -    ok 65 - invalid map32 3
> -    # *** test_mp_check: done ***
> -ok 20 - subtests
> -    1..96
> -    # *** test_numbers ***
> -    ok 1 - mp_read_int32(mp_encode_uint(123)) check success
> -    ok 2 - mp_read_int32(mp_encode_uint(123)) check pos advanced
> -    ok 3 - mp_read_int32(mp_encode_uint(123)) check result
> -    ok 4 - mp_read_int32(mp_encode_uint(12345)) check success
> -    ok 5 - mp_read_int32(mp_encode_uint(12345)) check pos advanced
> -    ok 6 - mp_read_int32(mp_encode_uint(12345)) check result
> -    ok 7 - mp_read_int32(mp_encode_uint(2147483647)) check success
> -    ok 8 - mp_read_int32(mp_encode_uint(2147483647)) check pos advanced
> -    ok 9 - mp_read_int32(mp_encode_uint(2147483647)) check result
> -    ok 10 - mp_read_int32(mp_encode_uint(2147483648)) check fail
> -    ok 11 - mp_read_int32(mp_encode_uint(2147483648)) check pos unchanged
> -    ok 12 - mp_read_int32(mp_encode_int(-123)) check success
> -    ok 13 - mp_read_int32(mp_encode_int(-123)) check pos advanced
> -    ok 14 - mp_read_int32(mp_encode_int(-123)) check result
> -    ok 15 - mp_read_int32(mp_encode_int(-12345)) check success
> -    ok 16 - mp_read_int32(mp_encode_int(-12345)) check pos advanced
> -    ok 17 - mp_read_int32(mp_encode_int(-12345)) check result
> -    ok 18 - mp_read_int32(mp_encode_int(-2147483648)) check success
> -    ok 19 - mp_read_int32(mp_encode_int(-2147483648)) check pos advanced
> -    ok 20 - mp_read_int32(mp_encode_int(-2147483648)) check result
> -    ok 21 - mp_read_int32(mp_encode_int(-2147483649LL)) check fail
> -    ok 22 - mp_read_int32(mp_encode_int(-2147483649LL)) check pos unchanged
> -    ok 23 - mp_read_int32(mp_encode_float(-1e2)) check fail
> -    ok 24 - mp_read_int32(mp_encode_float(-1e2)) check pos unchanged
> -    ok 25 - mp_read_int32(mp_encode_double(1.2345)) check fail
> -    ok 26 - mp_read_int32(mp_encode_double(1.2345)) check pos unchanged
> -    ok 27 - mp_read_int32(mp_encode_map(5)) check fail
> -    ok 28 - mp_read_int32(mp_encode_map(5)) check pos unchanged
> -    ok 29 - mp_read_int64(mp_encode_uint(123)) check success
> -    ok 30 - mp_read_int64(mp_encode_uint(123)) check pos advanced
> -    ok 31 - mp_read_int64(mp_encode_uint(123)) check result
> -    ok 32 - mp_read_int64(mp_encode_uint(12345)) check success
> -    ok 33 - mp_read_int64(mp_encode_uint(12345)) check pos advanced
> -    ok 34 - mp_read_int64(mp_encode_uint(12345)) check result
> -    ok 35 - mp_read_int64(mp_encode_uint(123456789)) check success
> -    ok 36 - mp_read_int64(mp_encode_uint(123456789)) check pos advanced
> -    ok 37 - mp_read_int64(mp_encode_uint(123456789)) check result
> -    ok 38 - mp_read_int64(mp_encode_uint(9223372036854775807ULL)) check success
> -    ok 39 - mp_read_int64(mp_encode_uint(9223372036854775807ULL)) check pos advanced
> -    ok 40 - mp_read_int64(mp_encode_uint(9223372036854775807ULL)) check result
> -    ok 41 - mp_read_int64(mp_encode_uint(9223372036854775808ULL)) check fail
> -    ok 42 - mp_read_int64(mp_encode_uint(9223372036854775808ULL)) check pos unchanged
> -    ok 43 - mp_read_int64(mp_encode_int(-123)) check success
> -    ok 44 - mp_read_int64(mp_encode_int(-123)) check pos advanced
> -    ok 45 - mp_read_int64(mp_encode_int(-123)) check result
> -    ok 46 - mp_read_int64(mp_encode_int(-12345)) check success
> -    ok 47 - mp_read_int64(mp_encode_int(-12345)) check pos advanced
> -    ok 48 - mp_read_int64(mp_encode_int(-12345)) check result
> -    ok 49 - mp_read_int64(mp_encode_int(-123456789)) check success
> -    ok 50 - mp_read_int64(mp_encode_int(-123456789)) check pos advanced
> -    ok 51 - mp_read_int64(mp_encode_int(-123456789)) check result
> -    ok 52 - mp_read_int64(mp_encode_int(-9223372036854775807LL)) check success
> -    ok 53 - mp_read_int64(mp_encode_int(-9223372036854775807LL)) check pos advanced
> -    ok 54 - mp_read_int64(mp_encode_int(-9223372036854775807LL)) check result
> -    ok 55 - mp_read_int64(mp_encode_float(100)) check fail
> -    ok 56 - mp_read_int64(mp_encode_float(100)) check pos unchanged
> -    ok 57 - mp_read_int64(mp_encode_double(-5.4321)) check fail
> -    ok 58 - mp_read_int64(mp_encode_double(-5.4321)) check pos unchanged
> -    ok 59 - mp_read_int64(mp_encode_array(10)) check fail
> -    ok 60 - mp_read_int64(mp_encode_array(10)) check pos unchanged
> -    ok 61 - mp_read_double(mp_encode_uint(123)) check success
> -    ok 62 - mp_read_double(mp_encode_uint(123)) check pos advanced
> -    ok 63 - mp_read_double(mp_encode_uint(123)) check result
> -    ok 64 - mp_read_double(mp_encode_uint(12345)) check success
> -    ok 65 - mp_read_double(mp_encode_uint(12345)) check pos advanced
> -    ok 66 - mp_read_double(mp_encode_uint(12345)) check result
> -    ok 67 - mp_read_double(mp_encode_uint(123456789)) check success
> -    ok 68 - mp_read_double(mp_encode_uint(123456789)) check pos advanced
> -    ok 69 - mp_read_double(mp_encode_uint(123456789)) check result
> -    ok 70 - mp_read_double(mp_encode_uint(1234567890000ULL)) check success
> -    ok 71 - mp_read_double(mp_encode_uint(1234567890000ULL)) check pos advanced
> -    ok 72 - mp_read_double(mp_encode_uint(1234567890000ULL)) check result
> -    ok 73 - mp_read_double(mp_encode_uint(123456789123456789ULL)) check fail
> -    ok 74 - mp_read_double(mp_encode_uint(123456789123456789ULL)) check pos unchanged
> -    ok 75 - mp_read_double(mp_encode_int(-123)) check success
> -    ok 76 - mp_read_double(mp_encode_int(-123)) check pos advanced
> -    ok 77 - mp_read_double(mp_encode_int(-123)) check result
> -    ok 78 - mp_read_double(mp_encode_int(-12345)) check success
> -    ok 79 - mp_read_double(mp_encode_int(-12345)) check pos advanced
> -    ok 80 - mp_read_double(mp_encode_int(-12345)) check result
> -    ok 81 - mp_read_double(mp_encode_int(-123456789)) check success
> -    ok 82 - mp_read_double(mp_encode_int(-123456789)) check pos advanced
> -    ok 83 - mp_read_double(mp_encode_int(-123456789)) check result
> -    ok 84 - mp_read_double(mp_encode_int(-1234567890000LL)) check success
> -    ok 85 - mp_read_double(mp_encode_int(-1234567890000LL)) check pos advanced
> -    ok 86 - mp_read_double(mp_encode_int(-1234567890000LL)) check result
> -    ok 87 - mp_read_double(mp_encode_int(-123456789123456789LL)) check fail
> -    ok 88 - mp_read_double(mp_encode_int(-123456789123456789LL)) check pos unchanged
> -    ok 89 - mp_read_double(mp_encode_float(6.565e6)) check success
> -    ok 90 - mp_read_double(mp_encode_float(6.565e6)) check pos advanced
> -    ok 91 - mp_read_double(mp_encode_float(6.565e6)) check result
> -    ok 92 - mp_read_double(mp_encode_double(-5.555)) check success
> -    ok 93 - mp_read_double(mp_encode_double(-5.555)) check pos advanced
> -    ok 94 - mp_read_double(mp_encode_double(-5.555)) check result
> -    ok 95 - mp_read_double(mp_encode_strl(100)) check fail
> -    ok 96 - mp_read_double(mp_encode_strl(100)) check pos unchanged
> -    # *** test_numbers: done ***
> -ok 21 - subtests
> -    1..4
> -    # *** test_overflow ***
> -    ok 1 - mp_check array overflow
> -    ok 2 - mp_check map overflow
> -    ok 3 - mp_check str overflow
> -    ok 4 - mp_check bin overflow
> -    # *** test_overflow: done ***
> -ok 22 - subtests
> diff --git a/test/unit/popen.result b/test/unit/popen.result
> deleted file mode 100644
> index f5e6bc2ca..000000000
> --- a/test/unit/popen.result
> +++ /dev/null
> @@ -1,30 +0,0 @@
> -1..3
> -	*** main_f ***
> -    1..6
> -	*** popen_write_exit ***
> -    ok 1 - popen_new
> -    ok 2 - state alive
> -    ok 3 - write flag check
> -    ok 4 - write to pipe
> -    ok 5 - child exited
> -    ok 6 - popen_delete
> -	*** popen_write_exit: done ***
> -ok 1 - subtests
> -    1..5
> -	*** popen_read_exit ***
> -    ok 1 - popen_new
> -    ok 2 - child exited
> -    ok 3 - read flag check
> -    ok 4 - read from pipe
> -    ok 5 - popen_delete
> -	*** popen_read_exit: done ***
> -ok 2 - subtests
> -    1..4
> -	*** popen_kill ***
> -    ok 1 - popen_new
> -    ok 2 - popen_send_signal
> -    ok 3 - child terminated
> -    ok 4 - popen_delete
> -	*** popen_kill: done ***
> -ok 3 - subtests
> -	*** main_f: done ***
> diff --git a/test/unit/queue.c b/test/unit/queue.c
> index 3caec1a41..d8bea5f78 100644
> --- a/test/unit/queue.c
> +++ b/test/unit/queue.c
> @@ -31,7 +31,6 @@
>  #include "third_party/queue.h"
>  #include "unit.h"
>  #include <stdio.h>
> -#include <assert.h>
>  
>  struct elem
>  {
> @@ -58,12 +57,15 @@ queue2str(struct elem_queue *queue)
>  void test0()
>  {
>  	header();
> +	plan(1);
>  	struct elem_queue queue = STAILQ_HEAD_INITIALIZER(queue);
> -	printf("Initialized: %s\n", queue2str(&queue));
> +	note("Initialized: %s", queue2str(&queue));
>  	STAILQ_INIT(&queue);
> -	printf("STAILQ_INIT: %s\n", queue2str(&queue));
> +	note("STAILQ_INIT: %s", queue2str(&queue));
>  	STAILQ_REVERSE(&queue, elem, entry);
> -	printf("STAILQ_REVERSE: %s\n", queue2str(&queue));
> +	note("STAILQ_REVERSE: %s", queue2str(&queue));
> +	ok(1, "test 0");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -71,13 +73,16 @@ void test0()
>  void test1()
>  {
>  	header();
> +	plan(1);
>  	struct elem el1;
>  	struct elem_queue queue = STAILQ_HEAD_INITIALIZER(queue);
>  	el1.val = 1;
>  	STAILQ_INSERT_TAIL(&queue, &el1, entry);
> -	printf("STAILQ_INIT: %s\n", queue2str(&queue));
> +	note("STAILQ_INIT: %s", queue2str(&queue));
>  	STAILQ_REVERSE(&queue, elem, entry);
> -	printf("STAILQ_REVERSE: %s\n", queue2str(&queue));
> +	note("STAILQ_REVERSE: %s", queue2str(&queue));
> +	ok(1, "test 1");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -85,21 +90,25 @@ void test1()
>  void test2()
>  {
>  	header();
> +	plan(1);
>  	struct elem el1, el2;
>  	struct elem_queue queue = STAILQ_HEAD_INITIALIZER(queue);
>  	el1.val = 1;
>  	el2.val = 2;
>  	STAILQ_INSERT_TAIL(&queue, &el1, entry);
>  	STAILQ_INSERT_TAIL(&queue, &el2, entry);
> -	printf("STAILQ_INIT: %s\n", queue2str(&queue));
> +	note("STAILQ_INIT: %s", queue2str(&queue));
>  	STAILQ_REVERSE(&queue, elem, entry);
> -	printf("STAILQ_REVERSE: %s\n", queue2str(&queue));
> +	note("STAILQ_REVERSE: %s", queue2str(&queue));
> +	ok(1, "test 2");
> +	check_plan();
>  	footer();
>  }
>  
>  void test3()
>  {
>  	header();
> +	plan(1);
>  	struct elem el1, el2, el3;
>  	struct elem_queue queue = STAILQ_HEAD_INITIALIZER(queue);
>  	el1.val = 1;
> @@ -108,9 +117,11 @@ void test3()
>  	STAILQ_INSERT_TAIL(&queue, &el1, entry);
>  	STAILQ_INSERT_TAIL(&queue, &el2, entry);
>  	STAILQ_INSERT_TAIL(&queue, &el3, entry);
> -	printf("STAILQ_INIT: %s\n", queue2str(&queue));
> +	note("STAILQ_INIT: %s", queue2str(&queue));
>  	STAILQ_REVERSE(&queue, elem, entry);
> -	printf("STAILQ_REVERSE: %s\n", queue2str(&queue));
> +	note("STAILQ_REVERSE: %s", queue2str(&queue));
> +	ok(1, "test 3");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -118,48 +129,52 @@ void test3()
>  void test_splice()
>  {
>  	header();
> +	plan(1);
>  	struct elem el1, el2, el3;
>  	struct elem_queue queue1 = STAILQ_HEAD_INITIALIZER(queue1);
>  	struct elem_queue queue2 = STAILQ_HEAD_INITIALIZER(queue2);
>  	STAILQ_SPLICE(&queue1, STAILQ_FIRST(&queue1), entry, &queue2);
> -	printf("q1: %s\n", queue2str(&queue1));
> -	printf("q2: %s\n", queue2str(&queue2));
> +	note("q1: %s", queue2str(&queue1));
> +	note("q2: %s", queue2str(&queue2));
>  	STAILQ_SPLICE(&queue2, STAILQ_FIRST(&queue2), entry, &queue1);
> -	printf("q1: %s\n", queue2str(&queue1));
> -	printf("q2: %s\n", queue2str(&queue2));
> +	note("q1: %s", queue2str(&queue1));
> +	note("q2: %s", queue2str(&queue2));
>  	el1.val = 1;
>  	el2.val = 2;
>  	el3.val = 3;
>  	STAILQ_INSERT_TAIL(&queue1, &el1, entry);
>  	STAILQ_INSERT_TAIL(&queue1, &el2, entry);
>  	STAILQ_INSERT_TAIL(&queue1, &el3, entry);
> -	printf("STAILQ_INIT: %s\n", queue2str(&queue1));
> +	note("STAILQ_INIT: %s", queue2str(&queue1));
>  	STAILQ_SPLICE(&queue1, STAILQ_FIRST(&queue1), entry, &queue2);
> -	printf("q1: %s\n", queue2str(&queue1));
> -	printf("q2: %s\n", queue2str(&queue2));
> +	note("q1: %s", queue2str(&queue1));
> +	note("q2: %s", queue2str(&queue2));
>  	STAILQ_SPLICE(&queue2, STAILQ_FIRST(&queue2), entry, &queue1);
> -	printf("q1: %s\n", queue2str(&queue1));
> -	printf("q2: %s\n", queue2str(&queue2));
> +	note("q1: %s", queue2str(&queue1));
> +	note("q2: %s", queue2str(&queue2));
>  	STAILQ_SPLICE(&queue1, STAILQ_NEXT(STAILQ_FIRST(&queue1), entry),
>  					   entry, &queue2);
> -	printf("q1: %s\n", queue2str(&queue1));
> -	printf("q2: %s\n", queue2str(&queue2));
> +	note("q1: %s", queue2str(&queue1));
> +	note("q2: %s", queue2str(&queue2));
>  	STAILQ_SPLICE(&queue2, STAILQ_NEXT(STAILQ_FIRST(&queue2), entry),
>  		      entry, &queue1);
> -	printf("q1: %s\n", queue2str(&queue1));
> -	printf("q2: %s\n", queue2str(&queue2));
> +	note("q1: %s", queue2str(&queue1));
> +	note("q2: %s", queue2str(&queue2));
>  	STAILQ_SPLICE(&queue2, STAILQ_FIRST(&queue2), entry, &queue1);
> -	printf("q1: %s\n", queue2str(&queue1));
> -	printf("q2: %s\n", queue2str(&queue2));
> +	note("q1: %s", queue2str(&queue1));
> +	note("q2: %s", queue2str(&queue2));
> +	ok(1, "test splice");
>  	footer();
>  }
>  
>  int main()
>  {
> +	plan(5);
>  	test0();
>  	test1();
>  	test2();
>  	test3();
>  	test_splice();
> +	check_plan();
>  	return 0;
>  }
> diff --git a/test/unit/queue.result b/test/unit/queue.result
> deleted file mode 100644
> index 18b0c0758..000000000
> --- a/test/unit/queue.result
> +++ /dev/null
> @@ -1,34 +0,0 @@
> -	*** test0 ***
> -Initialized: 
> -STAILQ_INIT: 
> -STAILQ_REVERSE: 
> -	*** test0: done ***
> -	*** test1 ***
> -STAILQ_INIT: 1 
> -STAILQ_REVERSE: 1 
> -	*** test1: done ***
> -	*** test2 ***
> -STAILQ_INIT: 1 2 
> -STAILQ_REVERSE: 2 1 
> -	*** test2: done ***
> -	*** test3 ***
> -STAILQ_INIT: 1 2 3 
> -STAILQ_REVERSE: 3 2 1 
> -	*** test3: done ***
> -	*** test_splice ***
> -q1: 
> -q2: 
> -q1: 
> -q2: 
> -STAILQ_INIT: 1 2 3 
> -q1: 
> -q2: 1 2 3 
> -q1: 1 2 3 
> -q2: 
> -q1: 1 
> -q2: 2 3 
> -q1: 1 3 
> -q2: 2 
> -q1: 1 3 2 
> -q2: 
> -	*** test_splice: done ***
> diff --git a/test/unit/ratelimit.result b/test/unit/ratelimit.result
> deleted file mode 100644
> index 8a755c64d..000000000
> --- a/test/unit/ratelimit.result
> +++ /dev/null
> @@ -1,13 +0,0 @@
> -	*** main ***
> -1..10
> -ok 1 - emitted 10 expected 10
> -ok 2 - suppressed 0 expected 0
> -ok 3 - emitted 0 expected 0
> -ok 4 - suppressed 0 expected 0
> -ok 5 - emitted 1 expected 1
> -ok 6 - suppressed 10 expected 10
> -ok 7 - emitted 1 expected 1
> -ok 8 - suppressed 0 expected 0
> -ok 9 - emitted 1000 expected 1000
> -ok 10 - suppressed 3000 expected 3000
> -	*** main: done ***
> diff --git a/test/unit/reflection_c.result b/test/unit/reflection_c.result
> deleted file mode 100644
> index 294fa9799..000000000
> --- a/test/unit/reflection_c.result
> +++ /dev/null
> @@ -1,5 +0,0 @@
> -1..4
> -ok 1 - assignable
> -ok 2 - assignable
> -ok 3 - assignable
> -ok 4 - assignable
> diff --git a/test/unit/reflection_cxx.result b/test/unit/reflection_cxx.result
> deleted file mode 100644
> index 0f4f51eb4..000000000
> --- a/test/unit/reflection_cxx.result
> +++ /dev/null
> @@ -1,31 +0,0 @@
> -1..30
> -ok 1 - type.name
> -ok 2 - type.parent
> -ok 3 - type.parent
> -ok 4 - is_instance
> -ok 5 - is_instance
> -ok 6 - is_instance
> -ok 7 - is_instance
> -ok 8 - methods order
> -ok 9 - methods order
> -ok 10 - methods order
> -ok 11 - methods order
> -ok 12 - methods order
> -ok 13 - method.owner
> -ok 14 - method.name
> -ok 15 - method.rtype (non void)
> -ok 16 - method.rtype (void)
> -ok 17 - method.nargs (zero)
> -ok 18 - method.nargs (non-zero)
> -ok 19 - method.atype
> -ok 20 - method.isconst
> -ok 21 - !method.isconst
> -ok 22 - !invokable<invalid args>
> -ok 23 - !invokable<extra args>
> -ok 24 - !invokable<>(invalid object)
> -ok 25 - invokable<const char *>
> -ok 26 - invokable<void, const char *>
> -ok 27 - invoke (int)
> -ok 28 - invoke (const char *)
> -ok 29 - invoke (void)
> -ok 30 - !invokable<>() on const method with non-const object
> diff --git a/test/unit/rmean.cc b/test/unit/rmean.cc
> index 50db96f6d..6f8667284 100644
> --- a/test/unit/rmean.cc
> +++ b/test/unit/rmean.cc
> @@ -5,7 +5,7 @@
>  
>  int print_stat(const char *name, int rps, int64_t total, void* ctx)
>  {
> -	printf("%s: rps %d, total %d%c", name, rps, (int)total,
> +	note("%s: rps %d, total %d%c", name, rps, (int)total,
>  	       name[2] == '2' ? '\n' : '\t');
>  	return 0;
>  }
> @@ -13,8 +13,9 @@ int print_stat(const char *name, int rps, int64_t total, void* ctx)
>  void test_100rps(rmean *st)
>  {
>  	header();
> -	printf("Send 100 requests every second for 10 seconds\n");
> -	printf("Calc rps at third and last second\n");
> +	plan(1);
> +	note("Send 100 requests every second for 10 seconds");
> +	note("Calc rps at third and last second");
>  	for(int i = 0; i < 10; i++) { /* 10 seconds */
>  		rmean_collect(st, 0, 100); /* send 100 requests */
>  		rmean_roll(st->stats[0].value, 1);
> @@ -29,13 +30,16 @@ void test_100rps(rmean *st)
>  		}
>  	}
>  	/* 10 seconds, 1000 in EV1, 100 rps */
> +	ok(1, "test 100rps");
> +	check_plan();
>  	footer();
>  }
>  
>  void test_mean15rps(rmean *st)
>  {
>  	header();
> -	printf("Send 15 rps on the average, and 3 rps to EV2\n");
> +	plan(1);
> +	note("Send 15 rps on the average, and 3 rps to EV2");
>  	for(int i = 0; i < 10; i++) { /* 10 seconds */
>  		for(int j = 0; j < 15; j++) {
>  			rmean_collect(st, 0, 1); /* send 15 requests */
> @@ -53,12 +57,15 @@ void test_mean15rps(rmean *st)
>  		   rmean_mean(st, 1),
>  		   rmean_total(st, 1), NULL);
>  	/* 10 seconds, 1000 + 150 in EV1, 15 rps. 30 in EV2, 3 rps*/
> +	ok(1, "test mean15rps");
>  	footer();
> +	check_plan();
>  }
>  
>  int main()
>  {
> -	printf("Stat. 2 names, timer simulation\n");
> +	plan(2);
> +	note("Stat. 2 names, timer simulation");
>  
>  	memory_init();
>  	fiber_init(fiber_cxx_invoke);
> @@ -74,5 +81,7 @@ int main()
>  
>  	fiber_free();
>  	memory_free();
> +	check_plan();
> +
>  	return 0;
>  }
> diff --git a/test/unit/rmean.result b/test/unit/rmean.result
> deleted file mode 100644
> index ce050f050..000000000
> --- a/test/unit/rmean.result
> +++ /dev/null
> @@ -1,11 +0,0 @@
> -Stat. 2 names, timer simulation
> -	*** test_100rps ***
> -Send 100 requests every second for 10 seconds
> -Calc rps at third and last second
> -EV1: rps 60, total 300	EV2: rps 0, total 0
> -EV1: rps 100, total 1000	EV2: rps 0, total 0
> -	*** test_100rps: done ***
> -	*** test_mean15rps ***
> -Send 15 rps on the average, and 3 rps to EV2
> -EV1: rps 15, total 1150	EV2: rps 3, total 30
> -	*** test_mean15rps: done ***
> diff --git a/test/unit/rope.c b/test/unit/rope.c
> index 5ab4c51f7..e86c94155 100644
> --- a/test/unit/rope.c
> +++ b/test/unit/rope.c
> @@ -4,7 +4,7 @@
>  static void
>  test_rope_extract(struct rope *rope, rope_size_t pos)
>  {
> -	printf("extract pos = %zu: ", (size_t) pos);
> +	printf("# extract pos = %zu: ", (size_t) pos);
>  	struct rope_node *node = rope_extract_node(rope, pos);
>  	rope_check(rope);
>  	str_print(node->data, node->leaf_size);
> @@ -14,10 +14,10 @@ test_rope_extract(struct rope *rope, rope_size_t pos)
>  static inline void
>  test_rope_cut(struct rope *rope, rope_size_t offset, rope_size_t size)
>  {
> -	printf("erase offset = %zu, size = %zu \n", (size_t) offset, (size_t) size);
> +	note("erase offset = %zu, size = %zu", (size_t) offset, (size_t) size);
>  	while (size-- > 0)
>  		rope_erase(rope, offset);
> -	rope_pretty_print(rope, str_print);
> +	/* rope_pretty_print(rope, str_print); */
>  	rope_check(rope);
>  }
>  
> @@ -58,11 +58,15 @@ test_rope()
>  	test_rope_extract(rope, 124);
>  
>  	rope_delete(rope);
> +	ok(1, "test rope");
> +	check_plan();
>  }
>  
>  int
>  main()
>  {
> +	plan(1);
>  	test_rope();
> +	check_plan();
>  	return 0;
>  }
> diff --git a/test/unit/rope.result b/test/unit/rope.result
> deleted file mode 100644
> index 996063800..000000000
> --- a/test/unit/rope.result
> +++ /dev/null
> @@ -1,299 +0,0 @@
> -insert offset = 0, str = 'who's gonna be'
> -size = 14
> -string = 'who's gonna be'
> -└──{ len = 14, height = 1, data = 'who's gonna be'}
> -
> -insert offset = 14, str = '<Mr.X>'
> -size = 20
> -string = 'who's gonna be<Mr.X>'
> -│  ┌──nil
> -└──{ len = 14, height = 2, data = 'who's gonna be'}
> -   └──{ len = 6, height = 1, data = '<Mr.X>'}
> -
> -insert offset = 20, str = ', Mr. <black!?!>Black'
> -size = 41
> -string = 'who's gonna be<Mr.X>, Mr. <black!?!>Black'
> -│  ┌──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 6, height = 2, data = '<Mr.X>'}
> -   └──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
> -
> -insert offset = 41, str = ', but they <know-something-'
> -size = 68
> -string = 'who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-'
> -│  ┌──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 6, height = 3, data = '<Mr.X>'}
> -   │  ┌──nil
> -   └──{ len = 21, height = 2, data = ', Mr. <black!?!>Black'}
> -      └──{ len = 27, height = 1, data = ', but they <know-something-'}
> -
> -insert offset = 0, str = 'guys all '
> -size = 77
> -string = 'guys all who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-'
> -│     ┌──{ len = 9, height = 1, data = 'guys all '}
> -│  ┌──{ len = 14, height = 2, data = 'who's gonna be'}
> -│  │  └──nil
> -└──{ len = 6, height = 3, data = '<Mr.X>'}
> -   │  ┌──nil
> -   └──{ len = 21, height = 2, data = ', Mr. <black!?!>Black'}
> -      └──{ len = 27, height = 1, data = ', but they <know-something-'}
> -
> -insert offset = 9, str = 'five fighting over '
> -size = 96
> -string = 'guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-'
> -│     ┌──{ len = 9, height = 1, data = 'guys all '}
> -│  ┌──{ len = 19, height = 2, data = 'five fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 6, height = 3, data = '<Mr.X>'}
> -   │  ┌──nil
> -   └──{ len = 21, height = 2, data = ', Mr. <black!?!>Black'}
> -      └──{ len = 27, height = 1, data = ', but they <know-something-'}
> -
> -insert offset = 0, str = '<yes, got got>You got four of '
> -size = 126
> -string = '<yes, got got>You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-'
> -│        ┌──{ len = 30, height = 1, data = '<yes, got got>You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 6, height = 4, data = '<Mr.X>'}
> -   │  ┌──nil
> -   └──{ len = 21, height = 2, data = ', Mr. <black!?!>Black'}
> -      └──{ len = 27, height = 1, data = ', but they <know-something-'}
> -
> -insert offset = 126, str = 'special> don't know each other'
> -size = 156
> -string = '<yes, got got>You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other'
> -│        ┌──{ len = 30, height = 1, data = '<yes, got got>You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 6, height = 4, data = '<Mr.X>'}
> -   │  ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
> -   └──{ len = 27, height = 2, data = ', but they <know-something-'}
> -      └──{ len = 30, height = 1, data = 'special> don't know each other'}
> -
> -insert offset = 4294967295, str = ', so nobody wants to back.'
> -size = 182
> -string = '<yes, got got>You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back.'
> -│        ┌──{ len = 30, height = 1, data = '<yes, got got>You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 6, height = 4, data = '<Mr.X>'}
> -   │  ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
> -   └──{ len = 27, height = 3, data = ', but they <know-something-'}
> -      │  ┌──nil
> -      └──{ len = 30, height = 2, data = 'special> don't know each other'}
> -         └──{ len = 26, height = 1, data = ', so nobody wants to back.'}
> -
> -insert offset = 181, str = ' down'
> -size = 187
> -string = '<yes, got got>You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.'
> -│        ┌──{ len = 30, height = 1, data = '<yes, got got>You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 6, height = 4, data = '<Mr.X>'}
> -   │     ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
> -   │  ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
> -   │  │  └──nil
> -   └──{ len = 30, height = 3, data = 'special> don't know each other'}
> -      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
> -      └──{ len = 5, height = 2, data = ' down'}
> -         └──{ len = 1, height = 1, data = '.'}
> -
> -insert offset = 4294967295, str = '<point-point>'
> -size = 200
> -string = '<yes, got got>You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.<point-point>'
> -│        ┌──{ len = 30, height = 1, data = '<yes, got got>You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 6, height = 5, data = '<Mr.X>'}
> -   │     ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
> -   │  ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
> -   │  │  └──nil
> -   └──{ len = 30, height = 4, data = 'special> don't know each other'}
> -      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
> -      └──{ len = 5, height = 3, data = ' down'}
> -         │  ┌──nil
> -         └──{ len = 1, height = 2, data = '.'}
> -            └──{ len = 13, height = 1, data = '<point-point>'}
> -
> -erase offset = 0, size = 5 
> -size = 195
> -string = ' got got>You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.<point-point>'
> -│        ┌──{ len = 25, height = 1, data = ' got got>You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 6, height = 5, data = '<Mr.X>'}
> -   │     ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
> -   │  ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
> -   │  │  └──nil
> -   └──{ len = 30, height = 4, data = 'special> don't know each other'}
> -      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
> -      └──{ len = 5, height = 3, data = ' down'}
> -         │  ┌──nil
> -         └──{ len = 1, height = 2, data = '.'}
> -            └──{ len = 13, height = 1, data = '<point-point>'}
> -
> -erase offset = 0, size = 9 
> -size = 186
> -string = 'You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.<point-point>'
> -│        ┌──{ len = 16, height = 1, data = 'You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 6, height = 5, data = '<Mr.X>'}
> -   │     ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
> -   │  ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
> -   │  │  └──nil
> -   └──{ len = 30, height = 4, data = 'special> don't know each other'}
> -      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
> -      └──{ len = 5, height = 3, data = ' down'}
> -         │  ┌──nil
> -         └──{ len = 1, height = 2, data = '.'}
> -            └──{ len = 13, height = 1, data = '<point-point>'}
> -
> -erase offset = 179, size = 7 
> -size = 179
> -string = 'You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.<point'
> -│        ┌──{ len = 16, height = 1, data = 'You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 6, height = 5, data = '<Mr.X>'}
> -   │     ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
> -   │  ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
> -   │  │  └──nil
> -   └──{ len = 30, height = 4, data = 'special> don't know each other'}
> -      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
> -      └──{ len = 5, height = 3, data = ' down'}
> -         │  ┌──{ len = 1, height = 1, data = '.'}
> -         └──{ len = 6, height = 2, data = '<point'}
> -            └──nil
> -
> -erase offset = 173, size = 1 
> -size = 178
> -string = 'You got four of guys all five fighting over who's gonna be<Mr.X>, Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.point'
> -│        ┌──{ len = 16, height = 1, data = 'You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 6, height = 5, data = '<Mr.X>'}
> -   │     ┌──{ len = 21, height = 1, data = ', Mr. <black!?!>Black'}
> -   │  ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
> -   │  │  └──nil
> -   └──{ len = 30, height = 4, data = 'special> don't know each other'}
> -      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
> -      └──{ len = 5, height = 3, data = ' down'}
> -         │  ┌──{ len = 1, height = 1, data = '.'}
> -         └──{ len = 5, height = 2, data = 'point'}
> -            └──nil
> -
> -erase offset = 58, size = 7 
> -size = 171
> -string = 'You got four of guys all five fighting over who's gonna be Mr. <black!?!>Black, but they <know-something-special> don't know each other, so nobody wants to back down.point'
> -│        ┌──{ len = 16, height = 1, data = 'You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 20, height = 4, data = ' Mr. <black!?!>Black'}
> -   │     ┌──{ len = 27, height = 1, data = ', but they <know-something-'}
> -   │  ┌──{ len = 30, height = 2, data = 'special> don't know each other'}
> -   │  │  └──{ len = 25, height = 1, data = ', so nobody wants to back'}
> -   └──{ len = 5, height = 3, data = ' down'}
> -      │  ┌──{ len = 1, height = 1, data = '.'}
> -      └──{ len = 5, height = 2, data = 'point'}
> -         └──nil
> -
> -erase offset = 63, size = 10 
> -size = 161
> -string = 'You got four of guys all five fighting over who's gonna be Mr. Black, but they <know-something-special> don't know each other, so nobody wants to back down.point'
> -│        ┌──{ len = 16, height = 1, data = 'You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 5, height = 5, data = ' Mr. '}
> -   │        ┌──{ len = 5, height = 1, data = 'Black'}
> -   │     ┌──{ len = 27, height = 2, data = ', but they <know-something-'}
> -   │     │  └──nil
> -   │  ┌──{ len = 30, height = 3, data = 'special> don't know each other'}
> -   │  │  └──{ len = 25, height = 1, data = ', so nobody wants to back'}
> -   └──{ len = 5, height = 4, data = ' down'}
> -      │  ┌──{ len = 1, height = 1, data = '.'}
> -      └──{ len = 5, height = 2, data = 'point'}
> -         └──nil
> -
> -erase offset = 79, size = 25 
> -size = 136
> -string = 'You got four of guys all five fighting over who's gonna be Mr. Black, but they don't know each other, so nobody wants to back down.point'
> -│        ┌──{ len = 16, height = 1, data = 'You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 19, height = 3, data = 'five fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 5, height = 5, data = ' Mr. '}
> -   │        ┌──{ len = 5, height = 1, data = 'Black'}
> -   │     ┌──{ len = 11, height = 2, data = ', but they '}
> -   │     │  └──nil
> -   │  ┌──{ len = 21, height = 3, data = 'don't know each other'}
> -   │  │  └──{ len = 25, height = 1, data = ', so nobody wants to back'}
> -   └──{ len = 5, height = 4, data = ' down'}
> -      │  ┌──{ len = 1, height = 1, data = '.'}
> -      └──{ len = 5, height = 2, data = 'point'}
> -         └──nil
> -
> -erase offset = 25, size = 5 
> -size = 131
> -string = 'You got four of guys all fighting over who's gonna be Mr. Black, but they don't know each other, so nobody wants to back down.point'
> -│        ┌──{ len = 16, height = 1, data = 'You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 14, height = 3, data = 'fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 5, height = 5, data = ' Mr. '}
> -   │        ┌──{ len = 5, height = 1, data = 'Black'}
> -   │     ┌──{ len = 11, height = 2, data = ', but they '}
> -   │     │  └──nil
> -   │  ┌──{ len = 21, height = 3, data = 'don't know each other'}
> -   │  │  └──{ len = 25, height = 1, data = ', so nobody wants to back'}
> -   └──{ len = 5, height = 4, data = ' down'}
> -      │  ┌──{ len = 1, height = 1, data = '.'}
> -      └──{ len = 5, height = 2, data = 'point'}
> -         └──nil
> -
> -erase offset = 126, size = 5 
> -size = 126
> -string = 'You got four of guys all fighting over who's gonna be Mr. Black, but they don't know each other, so nobody wants to back down.'
> -│        ┌──{ len = 16, height = 1, data = 'You got four of '}
> -│     ┌──{ len = 9, height = 2, data = 'guys all '}
> -│     │  └──nil
> -│  ┌──{ len = 14, height = 3, data = 'fighting over '}
> -│  │  └──{ len = 14, height = 1, data = 'who's gonna be'}
> -└──{ len = 5, height = 4, data = ' Mr. '}
> -   │     ┌──{ len = 5, height = 1, data = 'Black'}
> -   │  ┌──{ len = 11, height = 2, data = ', but they '}
> -   │  │  └──nil
> -   └──{ len = 21, height = 3, data = 'don't know each other'}
> -      │  ┌──{ len = 25, height = 1, data = ', so nobody wants to back'}
> -      └──{ len = 5, height = 2, data = ' down'}
> -         └──{ len = 1, height = 1, data = '.'}
> -
> -extract pos = 0: You got four of 
> -extract pos = 5: ot four of 
> -extract pos = 19: s all 
> -extract pos = 59: lack
> -extract pos = 124: n
> diff --git a/test/unit/rope_avl.c b/test/unit/rope_avl.c
> index b095fb1a6..cfefd2e48 100644
> --- a/test/unit/rope_avl.c
> +++ b/test/unit/rope_avl.c
> @@ -7,6 +7,7 @@ static void
>  test_avl_rotations()
>  {
>  	header();
> +	plan(1);
>  
>  	struct rope *rope = test_rope_new();
>  
> @@ -29,6 +30,8 @@ test_avl_rotations()
>  	test_rope_insert(rope, 3, "*");
>  
>  	rope_delete(rope);
> +	ok(1, "test avl rotations");
> +	check_plan();
>  
>  	footer();
>  }
> @@ -36,6 +39,8 @@ test_avl_rotations()
>  int
>  main()
>  {
> +	plan(1);
>  	test_avl_rotations();
> +	check_plan();
>  	return 0;
>  }
> diff --git a/test/unit/rope_avl.result b/test/unit/rope_avl.result
> deleted file mode 100644
> index 141ffe967..000000000
> --- a/test/unit/rope_avl.result
> +++ /dev/null
> @@ -1,123 +0,0 @@
> -	*** test_avl_rotations ***
> -insert offset = 0, str = '1'
> -size = 1
> -string = '1'
> -└──{ len = 1, height = 1, data = '1'}
> -
> -insert offset = 1, str = '2'
> -size = 2
> -string = '12'
> -│  ┌──nil
> -└──{ len = 1, height = 2, data = '1'}
> -   └──{ len = 1, height = 1, data = '2'}
> -
> -insert offset = 2, str = '<'
> -size = 3
> -string = '12<'
> -│  ┌──{ len = 1, height = 1, data = '1'}
> -└──{ len = 1, height = 2, data = '2'}
> -   └──{ len = 1, height = 1, data = '<'}
> -
> -insert offset = 0, str = '0'
> -size = 4
> -string = '012<'
> -│     ┌──{ len = 1, height = 1, data = '0'}
> -│  ┌──{ len = 1, height = 2, data = '1'}
> -│  │  └──nil
> -└──{ len = 1, height = 3, data = '2'}
> -   └──{ len = 1, height = 1, data = '<'}
> -
> -insert offset = 0, str = '>'
> -size = 5
> -string = '>012<'
> -│     ┌──{ len = 1, height = 1, data = '>'}
> -│  ┌──{ len = 1, height = 2, data = '0'}
> -│  │  └──{ len = 1, height = 1, data = '1'}
> -└──{ len = 1, height = 3, data = '2'}
> -   └──{ len = 1, height = 1, data = '<'}
> -
> -insert offset = 1, str = '*'
> -size = 6
> -string = '>*012<'
> -│     ┌──nil
> -│  ┌──{ len = 1, height = 2, data = '>'}
> -│  │  └──{ len = 1, height = 1, data = '*'}
> -└──{ len = 1, height = 3, data = '0'}
> -   │  ┌──{ len = 1, height = 1, data = '1'}
> -   └──{ len = 1, height = 2, data = '2'}
> -      └──{ len = 1, height = 1, data = '<'}
> -
> -insert offset = 3, str = 'p'
> -size = 7
> -string = '>*0p12<'
> -│     ┌──nil
> -│  ┌──{ len = 1, height = 2, data = '>'}
> -│  │  └──{ len = 1, height = 1, data = '*'}
> -└──{ len = 1, height = 4, data = '0'}
> -   │     ┌──{ len = 1, height = 1, data = 'p'}
> -   │  ┌──{ len = 1, height = 2, data = '1'}
> -   │  │  └──nil
> -   └──{ len = 1, height = 3, data = '2'}
> -      └──{ len = 1, height = 1, data = '<'}
> -
> -insert offset = 3, str = 'p'
> -size = 8
> -string = '>*0pp12<'
> -│     ┌──nil
> -│  ┌──{ len = 1, height = 2, data = '>'}
> -│  │  └──{ len = 1, height = 1, data = '*'}
> -└──{ len = 1, height = 4, data = '0'}
> -   │     ┌──{ len = 1, height = 1, data = 'p'}
> -   │  ┌──{ len = 1, height = 2, data = 'p'}
> -   │  │  └──{ len = 1, height = 1, data = '1'}
> -   └──{ len = 1, height = 3, data = '2'}
> -      └──{ len = 1, height = 1, data = '<'}
> -
> -insert offset = 3, str = 'p'
> -size = 9
> -string = '>*0ppp12<'
> -│     ┌──nil
> -│  ┌──{ len = 1, height = 2, data = '>'}
> -│  │  └──{ len = 1, height = 1, data = '*'}
> -└──{ len = 1, height = 4, data = '0'}
> -   │     ┌──{ len = 1, height = 1, data = 'p'}
> -   │  ┌──{ len = 1, height = 2, data = 'p'}
> -   │  │  └──nil
> -   └──{ len = 1, height = 3, data = 'p'}
> -      │  ┌──{ len = 1, height = 1, data = '1'}
> -      └──{ len = 1, height = 2, data = '2'}
> -         └──{ len = 1, height = 1, data = '<'}
> -
> -insert offset = 3, str = 'p'
> -size = 10
> -string = '>*0pppp12<'
> -│     ┌──nil
> -│  ┌──{ len = 1, height = 2, data = '>'}
> -│  │  └──{ len = 1, height = 1, data = '*'}
> -└──{ len = 1, height = 4, data = '0'}
> -   │     ┌──{ len = 1, height = 1, data = 'p'}
> -   │  ┌──{ len = 1, height = 2, data = 'p'}
> -   │  │  └──{ len = 1, height = 1, data = 'p'}
> -   └──{ len = 1, height = 3, data = 'p'}
> -      │  ┌──{ len = 1, height = 1, data = '1'}
> -      └──{ len = 1, height = 2, data = '2'}
> -         └──{ len = 1, height = 1, data = '<'}
> -
> -insert offset = 3, str = '*'
> -size = 11
> -string = '>*0*pppp12<'
> -│        ┌──nil
> -│     ┌──{ len = 1, height = 2, data = '>'}
> -│     │  └──{ len = 1, height = 1, data = '*'}
> -│  ┌──{ len = 1, height = 3, data = '0'}
> -│  │  │  ┌──{ len = 1, height = 1, data = '*'}
> -│  │  └──{ len = 1, height = 2, data = 'p'}
> -│  │     └──nil
> -└──{ len = 1, height = 4, data = 'p'}
> -   │  ┌──{ len = 1, height = 1, data = 'p'}
> -   └──{ len = 1, height = 3, data = 'p'}
> -      │  ┌──{ len = 1, height = 1, data = '1'}
> -      └──{ len = 1, height = 2, data = '2'}
> -         └──{ len = 1, height = 1, data = '<'}
> -
> -	*** test_avl_rotations: done ***
> diff --git a/test/unit/rope_basic.c b/test/unit/rope_basic.c
> index d9e116292..5ef49cb8d 100644
> --- a/test/unit/rope_basic.c
> +++ b/test/unit/rope_basic.c
> @@ -7,6 +7,7 @@ static void
>  test_empty_rope()
>  {
>  	header();
> +	plan(1);
>  
>  	struct rope *rope = test_rope_new();
>  
> @@ -19,13 +20,15 @@ test_empty_rope()
>  
>  	rope_traverse(rope, str_print);
>  	rope_check(rope);
> -	rope_pretty_print(rope, str_print);
> +	/* rope_pretty_print(rope, str_print); */
>  
>  	/* rope_erase(), rope_extract() expect a non-empty rope */
>  
>  	rope_iter_delete(iter);
>  	rope_delete(rope);
> +	ok(1, "test empty rope");
>  
> +	check_plan();
>  	footer();
>  }
>  
> @@ -33,13 +36,16 @@ static void
>  test_prepend()
>  {
>  	header();
> +	plan(1);
>  
>  	struct rope *rope = test_rope_new();
>  	test_rope_insert(rope, 0, " c ");
>  	test_rope_insert(rope, 0, " b ");
>  	test_rope_insert(rope, 0, " a ");
>  	rope_delete(rope);
> +	ok(1, "test prepend");
>  
> +	check_plan();
>  	footer();
>  }
>  
> @@ -47,13 +53,16 @@ static void
>  test_append()
>  {
>  	header();
> +	plan(1);
>  
>  	struct rope *rope = test_rope_new();
>  	test_rope_insert(rope, rope_size(rope), " a ");
>  	test_rope_insert(rope, rope_size(rope), " b ");
>  	test_rope_insert(rope, rope_size(rope), " c ");
>  	rope_delete(rope);
> +	ok(1, "test append");
>  
> +	check_plan();
>  	footer();
>  }
>  
> @@ -61,6 +70,7 @@ static void
>  test_insert()
>  {
>  	header();
> +	plan(1);
>  
>  	struct rope *rope = test_rope_new();
>  
> @@ -73,6 +83,8 @@ test_insert()
>  	test_rope_insert(rope, 8, "*");
>  
>  	rope_delete(rope);
> +	ok(1, "test insert");
> +	check_plan();
>  
>  	footer();
>  }
> @@ -81,6 +93,7 @@ static void
>  test_erase()
>  {
>  	header();
> +	plan(1);
>  
>  	struct rope *rope = test_rope_new();
>  	rope_insert(rope, rope_size(rope), "a", 1);
> @@ -90,6 +103,8 @@ test_erase()
>  	test_rope_erase(rope, 0);
>  
>  	rope_delete(rope);
> +	ok(1, "test erase")
> +	check_plan();
>  
>  	footer();
>  }
> @@ -97,10 +112,12 @@ test_erase()
>  int
>  main()
>  {
> +	plan(5);
>  	test_empty_rope();
>  	test_append();
>  	test_prepend();
>  	test_insert();
>  	test_erase();
> +	check_plan();
>  	return 0;
>  }
> diff --git a/test/unit/rope_basic.result b/test/unit/rope_basic.result
> deleted file mode 100644
> index fd8ef015e..000000000
> --- a/test/unit/rope_basic.result
> +++ /dev/null
> @@ -1,139 +0,0 @@
> -	*** test_empty_rope ***
> -size = 0
> -string = ''
> -└──nil
> -
> -	*** test_empty_rope: done ***
> -	*** test_append ***
> -insert offset = 0, str = ' a '
> -size = 3
> -string = ' a '
> -└──{ len = 3, height = 1, data = ' a '}
> -
> -insert offset = 3, str = ' b '
> -size = 6
> -string = ' a  b '
> -│  ┌──nil
> -└──{ len = 3, height = 2, data = ' a '}
> -   └──{ len = 3, height = 1, data = ' b '}
> -
> -insert offset = 6, str = ' c '
> -size = 9
> -string = ' a  b  c '
> -│  ┌──{ len = 3, height = 1, data = ' a '}
> -└──{ len = 3, height = 2, data = ' b '}
> -   └──{ len = 3, height = 1, data = ' c '}
> -
> -	*** test_append: done ***
> -	*** test_prepend ***
> -insert offset = 0, str = ' c '
> -size = 3
> -string = ' c '
> -└──{ len = 3, height = 1, data = ' c '}
> -
> -insert offset = 0, str = ' b '
> -size = 6
> -string = ' b  c '
> -│  ┌──{ len = 3, height = 1, data = ' b '}
> -└──{ len = 3, height = 2, data = ' c '}
> -   └──nil
> -
> -insert offset = 0, str = ' a '
> -size = 9
> -string = ' a  b  c '
> -│  ┌──{ len = 3, height = 1, data = ' a '}
> -└──{ len = 3, height = 2, data = ' b '}
> -   └──{ len = 3, height = 1, data = ' c '}
> -
> -	*** test_prepend: done ***
> -	*** test_insert ***
> -insert offset = 0, str = '   a '
> -size = 5
> -string = '   a '
> -└──{ len = 5, height = 1, data = '   a '}
> -
> -insert offset = 4, str = 'b '
> -size = 7
> -string = '   ab  '
> -│  ┌──{ len = 4, height = 1, data = '   a'}
> -└──{ len = 2, height = 2, data = 'b '}
> -   └──{ len = 1, height = 1, data = ' '}
> -
> -insert offset = 5, str = 'c '
> -size = 9
> -string = '   abc   '
> -│  ┌──{ len = 4, height = 1, data = '   a'}
> -└──{ len = 1, height = 3, data = 'b'}
> -   │  ┌──{ len = 2, height = 1, data = 'c '}
> -   └──{ len = 1, height = 2, data = ' '}
> -      └──{ len = 1, height = 1, data = ' '}
> -
> -insert offset = 1, str = ' '
> -size = 10
> -string = '    abc   '
> -│     ┌──{ len = 1, height = 1, data = ' '}
> -│  ┌──{ len = 1, height = 2, data = ' '}
> -│  │  └──{ len = 3, height = 1, data = '  a'}
> -└──{ len = 1, height = 3, data = 'b'}
> -   │  ┌──{ len = 2, height = 1, data = 'c '}
> -   └──{ len = 1, height = 2, data = ' '}
> -      └──{ len = 1, height = 1, data = ' '}
> -
> -insert offset = 9, str = ' '
> -size = 11
> -string = '    abc    '
> -│     ┌──{ len = 1, height = 1, data = ' '}
> -│  ┌──{ len = 1, height = 2, data = ' '}
> -│  │  └──{ len = 3, height = 1, data = '  a'}
> -└──{ len = 1, height = 4, data = 'b'}
> -   │  ┌──{ len = 2, height = 1, data = 'c '}
> -   └──{ len = 1, height = 3, data = ' '}
> -      │  ┌──{ len = 1, height = 1, data = ' '}
> -      └──{ len = 1, height = 2, data = ' '}
> -         └──nil
> -
> -insert offset = 4, str = '*'
> -size = 12
> -string = '    *abc    '
> -│     ┌──{ len = 1, height = 1, data = ' '}
> -│  ┌──{ len = 1, height = 3, data = ' '}
> -│  │  │  ┌──{ len = 2, height = 1, data = '  '}
> -│  │  └──{ len = 1, height = 2, data = '*'}
> -│  │     └──{ len = 1, height = 1, data = 'a'}
> -└──{ len = 1, height = 4, data = 'b'}
> -   │  ┌──{ len = 2, height = 1, data = 'c '}
> -   └──{ len = 1, height = 3, data = ' '}
> -      │  ┌──{ len = 1, height = 1, data = ' '}
> -      └──{ len = 1, height = 2, data = ' '}
> -         └──nil
> -
> -insert offset = 8, str = '*'
> -size = 13
> -string = '    *abc*    '
> -│     ┌──{ len = 1, height = 1, data = ' '}
> -│  ┌──{ len = 1, height = 3, data = ' '}
> -│  │  │  ┌──{ len = 2, height = 1, data = '  '}
> -│  │  └──{ len = 1, height = 2, data = '*'}
> -│  │     └──{ len = 1, height = 1, data = 'a'}
> -└──{ len = 1, height = 4, data = 'b'}
> -   │     ┌──{ len = 1, height = 1, data = 'c'}
> -   │  ┌──{ len = 1, height = 2, data = '*'}
> -   │  │  └──{ len = 1, height = 1, data = ' '}
> -   └──{ len = 1, height = 3, data = ' '}
> -      │  ┌──{ len = 1, height = 1, data = ' '}
> -      └──{ len = 1, height = 2, data = ' '}
> -         └──nil
> -
> -	*** test_insert: done ***
> -	*** test_erase ***
> -erase offset = 0
> -size = 0
> -string = ''
> -└──nil
> -
> -erase offset = 0
> -size = 1
> -string = 'b'
> -└──{ len = 1, height = 1, data = 'b'}
> -
> -	*** test_erase: done ***
> diff --git a/test/unit/rope_common.h b/test/unit/rope_common.h
> index 3392e87e3..67e2dbc2b 100644
> --- a/test/unit/rope_common.h
> +++ b/test/unit/rope_common.h
> @@ -3,6 +3,9 @@
>  #include <stdio.h>
>  #include <stdlib.h>
>  #include <string.h>
> +
> +#include "unit.h"
> +
>  static inline char *
>  str_getn(void *ctx, char *data, size_t size, size_t offset)
>  {
> @@ -68,18 +71,18 @@ test_rope_new()
>  static inline void
>  test_rope_insert(struct rope *rope, rope_size_t offset, char *str)
>  {
> -	printf("insert offset = %zu, str = '%s'\n", (size_t) offset, str);
> +	note("insert offset = %zu, str = '%s'", (size_t) offset, str);
>  	rope_insert(rope, offset, str, strlen(str));
> -	rope_pretty_print(rope, str_print);
> +	/* rope_pretty_print(rope, str_print); */
>  	rope_check(rope);
>  }
>  
>  static inline void
>  test_rope_erase(struct rope *rope, rope_size_t offset)
>  {
> -	printf("erase offset = %zu\n", (size_t) offset);
> +	note("erase offset = %zu", (size_t) offset);
>  	rope_erase(rope, offset);
> -	rope_pretty_print(rope, str_print);
> +	/* rope_pretty_print(rope, str_print); */
>  	rope_check(rope);
>  }
>  
> diff --git a/test/unit/rope_stress.c b/test/unit/rope_stress.c
> index bc312d7c0..4d17ef6ef 100644
> --- a/test/unit/rope_stress.c
> +++ b/test/unit/rope_stress.c
> @@ -8,6 +8,7 @@ static void
>  test_rope_stress_small()
>  {
>  	header();
> +	plan(1);
>  
>  	struct rope *rope = test_rope_new();
>  	const int iterations = 500;
> @@ -29,7 +30,9 @@ test_rope_stress_small()
>  		rope_check(rope);
>  	}
>  	rope_delete(rope);
> +	ok(1, "test rope stress small");
>  
> +	check_plan();
>  	footer();
>  }
>  
> @@ -37,6 +40,7 @@ static void
>  test_rope_stress_large()
>  {
>  	header();
> +	plan(1);
>  
>  	struct rope *rope = test_rope_new();
>  	const int iterations = 50000;
> @@ -58,14 +62,18 @@ test_rope_stress_large()
>  			rope_check(rope);
>  	}
>  	rope_delete(rope);
> +	ok(1, "test rope stress large");
>  
> +	check_plan();
>  	footer();
>  }
>  int
>  main()
>  {
> +	plan(2);
>  	srand(time(NULL));
>  	test_rope_stress_small();
>  	test_rope_stress_large();
> +	check_plan();
>  	return 0;
>  }
> diff --git a/test/unit/rope_stress.result b/test/unit/rope_stress.result
> deleted file mode 100644
> index bd2e45b75..000000000
> --- a/test/unit/rope_stress.result
> +++ /dev/null
> @@ -1,4 +0,0 @@
> -	*** test_rope_stress_small ***
> -	*** test_rope_stress_small: done ***
> -	*** test_rope_stress_large ***
> -	*** test_rope_stress_large: done ***
> diff --git a/test/unit/rtree.cc b/test/unit/rtree.cc
> index 02ca9cdd6..d623d0178 100644
> --- a/test/unit/rtree.cc
> +++ b/test/unit/rtree.cc
> @@ -31,19 +31,20 @@ extent_free(void *ctx, void *page)
>  static void
>  simple_check()
>  {
> +	header();
> +	plan(1);
> +
>  	struct rtree_rect rect;
>  	struct rtree_iterator iterator;
>  	rtree_iterator_init(&iterator);
>  	const size_t rounds = 2000;
>  
> -	header();
> -
>  	struct rtree tree;
>  	rtree_init(&tree, 2, extent_size,
>  		   extent_alloc, extent_free, &page_count,
>  		   RTREE_EUCLID);
>  
> -	printf("Insert 1..X, remove 1..X\n");
> +	note("Insert 1..X, remove 1..X");
>  	for (size_t i = 1; i <= rounds; i++) {
>  		record_t rec = (record_t)i;
>  
> @@ -82,7 +83,7 @@ simple_check()
>  		fail("Tree count mismatch (1)", "true");
>  	}
>  
> -	printf("Insert 1..X, remove X..1\n");
> +	note("Insert 1..X, remove X..1");
>  	for (size_t i = 1; i <= rounds; i++) {
>  		record_t rec = (record_t)i;
>  
> @@ -122,7 +123,7 @@ simple_check()
>  	}
>  
>  
> -	printf("Insert X..1, remove 1..X\n");
> +	note("Insert X..1, remove 1..X");
>  	for (size_t i = rounds; i != 0; i--) {
>  		record_t rec = (record_t)i;
>  
> @@ -162,7 +163,7 @@ simple_check()
>  	}
>  
>  
> -	printf("Insert X..1, remove X..1\n");
> +	note("Insert X..1, remove X..1");
>  	for (size_t i = rounds; i != 0; i--) {
>  		record_t rec = (record_t)i;
>  
> @@ -205,8 +206,10 @@ simple_check()
>  	rtree_destroy(&tree);
>  
>  	rtree_iterator_destroy(&iterator);
> +	ok(1, "simple test");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  static void
> @@ -222,6 +225,7 @@ static void
>  neighbor_test()
>  {
>  	header();
> +	plan(1);
>  
>  	const unsigned int test_count = 1000;
>  	struct rtree_rect arr[test_count];
> @@ -271,17 +275,21 @@ neighbor_test()
>  		fail("something found from empty iterator ", "true");
>  	}
>  	rtree_iterator_destroy(&iterator);
> +	ok(1, "neighbor test");
>  
>  	footer();
> +	check_plan();
>  }
>  
>  
>  int
>  main(void)
>  {
> +	plan(2);
>  	simple_check();
>  	neighbor_test();
>  	if (page_count != 0) {
>  		fail("memory leak!", "true");
>  	}
> +	check_plan();
>  }
> diff --git a/test/unit/rtree.result b/test/unit/rtree.result
> deleted file mode 100644
> index 6efa93438..000000000
> --- a/test/unit/rtree.result
> +++ /dev/null
> @@ -1,8 +0,0 @@
> -	*** simple_check ***
> -Insert 1..X, remove 1..X
> -Insert 1..X, remove X..1
> -Insert X..1, remove 1..X
> -Insert X..1, remove X..1
> -	*** simple_check: done ***
> -	*** neighbor_test ***
> -	*** neighbor_test: done ***
> diff --git a/test/unit/rtree_iterator.cc b/test/unit/rtree_iterator.cc
> index b3c8695e9..ee1bcc131 100644
> --- a/test/unit/rtree_iterator.cc
> +++ b/test/unit/rtree_iterator.cc
> @@ -31,6 +31,7 @@ static void
>  iterator_check()
>  {
>  	header();
> +	plan(1);
>  
>  	struct rtree tree;
>  	rtree_init(&tree, 2, extent_size,
> @@ -53,7 +54,7 @@ iterator_check()
>  			rtree_insert(&tree, &rect, record_t(++count));
>  		}
>  	}
> -	printf("Test tree size: %d\n", (int)rtree_number_of_records(&tree));
> +	note("Test tree size: %d", (int)rtree_number_of_records(&tree));
>  
>  	/* Test that tree filled ok */
>  	for (size_t i = 0; i < count1; i++) {
> @@ -81,8 +82,8 @@ iterator_check()
>  
>  	/* Print 7 elems closest to coordinate basis */
>  	{
> +		fprintf(stderr, "--> ");
>  		static struct rtree_rect basis;
> -		printf("--> ");
>  		if (!rtree_search(&tree, &basis, SOP_NEIGHBOR, &iterator)) {
>  			fail("Integrity check failed (5)", "false");
>  		}
> @@ -91,13 +92,13 @@ iterator_check()
>  			if (rec == 0) {
>  				fail("Integrity check failed (6)", "false");
>  			}
> -			printf("%p ", rec);
> +			fprintf(stderr, "%p ", rec);
>  		}
> -		printf("\n");
> +		fprintf(stderr, "\n");
>  	}
>  	/* Print 7 elems closest to the point [(count1-1)*count2*2, (count1-1)*count2*2] */
>  	{
> -		printf("<-- ");
> +		fprintf(stderr, "<-- ");
>  		coord_t coord = (count1 - 1) * count2 * 2;
>  		rtree_set2d(&rect, coord, coord, coord, coord);
>  		if (!rtree_search(&tree, &rect, SOP_NEIGHBOR, &iterator)) {
> @@ -108,9 +109,9 @@ iterator_check()
>  			if (rec == 0) {
>  				fail("Integrity check failed (6)", "false");
>  			}
> -			printf("%p ", rec);
> +			fprintf(stderr, "%p ", rec);
>  		}
> -		printf("\n");
> +		fprintf(stderr, "\n");
>  	}
>  
>  	/* Test strict belongs */
> @@ -192,6 +193,8 @@ iterator_check()
>  	rtree_iterator_destroy(&iterator);
>  	rtree_destroy(&tree);
>  
> +	ok(1, "iterator check");
> +	check_plan();
>  	footer();
>  }
>  
> @@ -199,6 +202,7 @@ static void
>  iterator_invalidate_check()
>  {
>  	header();
> +	plan(1);
>  
>  	const size_t test_size = 300;
>  	const size_t max_delete_count = 100;
> @@ -299,15 +303,21 @@ iterator_invalidate_check()
>  		rtree_destroy(&tree);
>  	}
>  
> +	ok(1, "iterator invalidate check");
> +	check_plan();
>  	footer();
>  }
>  
>  int
>  main(void)
>  {
> +	header();
> +	plan(2);
>  	iterator_check();
>  	iterator_invalidate_check();
>  	if (extent_count != 0) {
>  		fail("memory leak!", "false");
>  	}
> +	check_plan();
> +	footer();
>  }
> diff --git a/test/unit/rtree_iterator.result b/test/unit/rtree_iterator.result
> deleted file mode 100644
> index 5eac9f090..000000000
> --- a/test/unit/rtree_iterator.result
> +++ /dev/null
> @@ -1,7 +0,0 @@
> -	*** iterator_check ***
> -Test tree size: 50000
> ---> 0x1 0x2 0x3 0x4 0x5 0x6 0x7 
> -<-- 0xc34c 0xc34d 0xc34e 0xc34f 0xc350 0xc34b 0xc34a 
> -	*** iterator_check: done ***
> -	*** iterator_invalidate_check ***
> -	*** iterator_invalidate_check: done ***
> diff --git a/test/unit/rtree_multidim.cc b/test/unit/rtree_multidim.cc
> index e09f6190b..8fa44e6a9 100644
> --- a/test/unit/rtree_multidim.cc
> +++ b/test/unit/rtree_multidim.cc
> @@ -348,14 +348,14 @@ test_select_neigh(const CBoxSet<DIMENSION> &set, const struct rtree *tree)
>  		}
>  	}
>  	if (res1.size() != res2.size()) {
> -		printf("%s result size differ %d %d\n", __func__,
> +		diag("%s result size differ %d %d\n", __func__,
>  		       (int)res1.size(), (int)res2.size());
>  	} else {
>  		for (size_t i = 0; i < res1.size(); i++)
>  			if (res1[i].id != res2[i].id &&
>  			    res1[i].box.Distance2(box) !=
>  			    res2[i].box.Distance2(box))
> -				printf("%s result differ!\n", __func__);
> +				diag("%s result differ!\n", __func__);
>  	}
>  	rtree_iterator_destroy(&iterator);
>  
> @@ -388,14 +388,14 @@ test_select_neigh_man(const CBoxSet<DIMENSION> &set, struct rtree *tree)
>  		}
>  	}
>  	if (res1.size() != res2.size()) {
> -		printf("%s result size differ %d %d\n", __func__,
> +		diag("%s result size differ %d %d\n", __func__,
>  		       (int)res1.size(), (int)res2.size());
>  	} else {
>  		for (size_t i = 0; i < res1.size(); i++)
>  			if (res1[i].id != res2[i].id &&
>  			    res1[i].box.DistanceMan(box) !=
>  			    res2[i].box.DistanceMan(box))
> -				printf("%s result differ!\n", __func__);
> +				diag("%s result differ!\n", __func__);
>  	}
>  	tree->distance_type = RTREE_EUCLID; /* dirty hack */
>  	rtree_iterator_destroy(&iterator);
> @@ -428,12 +428,12 @@ test_select_in(const CBoxSet<DIMENSION> &set, const struct rtree *tree)
>  	sort(res1.begin(), res1.end());
>  	sort(res2.begin(), res2.end());
>  	if (res1.size() != res2.size()) {
> -		printf("%s result size differ %d %d\n", __func__,
> +		diag("%s result size differ %d %d\n", __func__,
>  		       (int)res1.size(), (int)res2.size());
>  	} else {
>  		for (size_t i = 0; i < res1.size(); i++)
>  			if (res1[i].id != res2[i].id)
> -				printf("%s result differ!\n", __func__);
> +				diag("%s result differ!\n", __func__);
>  	}
>  	rtree_iterator_destroy(&iterator);
>  
> @@ -465,12 +465,12 @@ test_select_strict_in(const CBoxSet<DIMENSION> &set, const struct rtree *tree)
>  	sort(res1.begin(), res1.end());
>  	sort(res2.begin(), res2.end());
>  	if (res1.size() != res2.size()) {
> -		printf("%s result size differ %d %d\n", __func__,
> +		diag("%s result size differ %d %d\n", __func__,
>  		       (int)res1.size(), (int)res2.size());
>  	} else {
>  		for (size_t i = 0; i < res1.size(); i++)
>  			if (res1[i].id != res2[i].id)
> -				printf("%s result differ!\n", __func__);
> +				diag("%s result differ!\n", __func__);
>  	}
>  	rtree_iterator_destroy(&iterator);
>  
> @@ -481,6 +481,7 @@ static void
>  rand_test()
>  {
>  	header();
> +	plan(1);
>  
>  	CBoxSet<DIMENSION> set;
>  
> @@ -489,7 +490,7 @@ rand_test()
>  		   extent_alloc, extent_free, &page_count,
>  		   RTREE_EUCLID);
>  
> -	printf("\tDIMENSION: %u, page size: %u, max fill good: %d\n",
> +	note("\tDIMENSION: %u, page size: %u, max fill good: %d\n",
>  	       DIMENSION, tree.page_size, tree.page_max_fill >= 10);
>  
>  	for (unsigned i = 0; i < TEST_ROUNDS; i++) {
> @@ -513,7 +514,7 @@ rand_test()
>  			struct rtree_rect rt;
>  			set.entries[id].box.FillRTreeRect(&rt);
>  			if (!rtree_remove(&tree, &rt, (void *)(id + 1))) {
> -				printf("Error in remove\n");
> +				diag("Error in remove\n");
>  			}
>  			set.DeleteBox(id);
>  		}
> @@ -525,13 +526,21 @@ rand_test()
>  	}
>  
>  	rtree_destroy(&tree);
> +	ok(1, "rand_test %u", DIMENSION);
> +
> +	/*
> +	note("\tDIMENSION: %u, page size: %u, max fill good: %d\n",
> +	       DIMENSION, tree.page_size, tree.page_max_fill >= 10);
> +	*/
>  
>  	footer();
> +	check_plan();
>  }
>  
>  int
>  main(void)
>  {
> +	plan(5);
>  	srand(time(0));
>  	rand_test<1>();
>  	rand_test<2>();
> @@ -541,4 +550,5 @@ main(void)
>  	if (page_count != 0) {
>  		fail("memory leak!", "true");
>  	}
> +	check_plan();
>  }
> diff --git a/test/unit/rtree_multidim.result b/test/unit/rtree_multidim.result
> deleted file mode 100644
> index 9370ecc3a..000000000
> --- a/test/unit/rtree_multidim.result
> +++ /dev/null
> @@ -1,15 +0,0 @@
> -	*** rand_test ***
> -	DIMENSION: 1, page size: 512, max fill good: 1
> -	*** rand_test: done ***
> -	*** rand_test ***
> -	DIMENSION: 2, page size: 1024, max fill good: 1
> -	*** rand_test: done ***
> -	*** rand_test ***
> -	DIMENSION: 3, page size: 1024, max fill good: 1
> -	*** rand_test: done ***
> -	*** rand_test ***
> -	DIMENSION: 8, page size: 4096, max fill good: 1
> -	*** rand_test: done ***
> -	*** rand_test ***
> -	DIMENSION: 16, page size: 8192, max fill good: 1
> -	*** rand_test: done ***
> diff --git a/test/unit/say.result b/test/unit/say.result
> deleted file mode 100644
> index 8dfed7b61..000000000
> --- a/test/unit/say.result
> +++ /dev/null
> @@ -1,67 +0,0 @@
> -1..33
> -# type: file
> -# next: 
> -ok 1 - 
> -# type: file
> -# next: /dev/null
> -ok 2 - /dev/null
> -# type: pipe
> -# next: 
> -ok 3 - |
> -# type: pipe
> -# next: /usr/bin/cronolog
> -ok 4 - |/usr/bin/cronolog
> -# type: file
> -# next: 
> -ok 5 - file:
> -# type: file
> -# next: instance.log
> -ok 6 - file:instance.log
> -# type: pipe
> -# next: 
> -ok 7 - pipe:
> -# type: pipe
> -# next: gzip > instance.log.gz
> -ok 8 - pipe:gzip > instance.log.gz
> -# type: syslog
> -# next: 
> -ok 9 - syslog:
> -# type: syslog
> -# next: identity=
> -ok 10 - syslog:identity=
> -# next: unknown:
> -ok 11 - unknown:
> -# next: unknown:example.org
> -ok 12 - unknown:example.org
> -# facility: 24
> -ok 13 - 
> -# identity: tarantool
> -# facility: 24
> -ok 14 - identity=tarantool
> -# facility: 1
> -ok 15 - facility=user
> -# identity: xtarantoolx
> -# facility: 17
> -ok 16 - identity=xtarantoolx,facility=local1
> -# identity: xtarantoolx
> -ok 17 - identity=xtarantoolx,facility=kern
> -# identity: xtarantoolx
> -# facility: 8
> -ok 18 - identity=xtarantoolx,facility=uucp
> -ok 19 - identity=xtarantoolx,facility=foo
> -# identity: bar
> -# facility: 10
> -ok 20 - facility=authpriv,identity=bar
> -ok 21 - invalid=
> -ok 22 - facility=local1,facility=local2
> -ok 23 - identity=foo,identity=bar
> -ok 24 - plain
> -ok 25 - json
> -ok 26 - custom
> -ok 27 - freopen
> -ok 28 - parsed identity
> -ok 29 - parsed facility
> -ok 30 - ftell
> -ok 31 - log_say
> -ok 32 - fseek
> -ok 33 - syslog line
> diff --git a/test/unit/scramble.c b/test/unit/scramble.c
> index 8f1ee55af..d4f684efb 100644
> --- a/test/unit/scramble.c
> +++ b/test/unit/scramble.c
> @@ -9,6 +9,9 @@
>  void
>  test_scramble()
>  {
> +	header();
> +	plan(1);
> +
>  	int salt[SCRAMBLE_SIZE/sizeof(int)];
>  	for (unsigned i = 0; i < sizeof(salt)/sizeof(int); i++)
>  		salt[i] = rand();
> @@ -30,7 +33,7 @@ test_scramble()
>  
>  	scramble_prepare(scramble, salt, password, strlen(password));
>  
> -	printf("%d\n", scramble_check(scramble, salt, hash2));
> +	note("%d", scramble_check(scramble, salt, hash2));
>  
>  	int remote_salt[SCRAMBLE_SIZE/sizeof(int)];
>  	for(size_t i = 0; i < sizeof(salt)/sizeof(int); ++i)
> @@ -40,21 +43,26 @@ test_scramble()
>  
>  	scramble_reencode(new_scramble, scramble, salt, remote_salt, hash2);
>  
> -	printf("%d\n", scramble_check(new_scramble, remote_salt, hash2));
> +	note("%d", scramble_check(new_scramble, remote_salt, hash2));
>  
>  	password = "wrongpass";
>  	scramble_prepare(scramble, salt, password, strlen(password));
>  
> -	printf("%d\n", scramble_check(scramble, salt, hash2) != 0);
> +	note("%d", scramble_check(scramble, salt, hash2) != 0);
>  
>  	scramble_prepare(scramble, salt, password, 0);
>  
> -	printf("%d\n", scramble_check(scramble, salt, hash2) != 0);
> +	note("%d", scramble_check(scramble, salt, hash2) != 0);
> +
> +	ok(1, "test scramble");
> +	check_plan();	
>  }
>  
>  void
>  test_password_prepare()
>  {
> +	header();
> +	plan(1);
>  	char buf[SCRAMBLE_BASE64_SIZE * 2];
>  	int password[5];
>  	for (unsigned i = 0; i < sizeof(password)/sizeof(int); i++)
> @@ -62,14 +70,19 @@ test_password_prepare()
>  	password_prepare((char *) password, sizeof(password),
>  			 buf, sizeof(buf));
>  	fail_unless(strlen(buf) == SCRAMBLE_BASE64_SIZE);
> +
> +	ok(1, "test password prepare");
> +	check_plan();
>  }
>  
>  int main()
>  {
>  	random_init();
>  
> +	plan(2);
>  	test_scramble();
>  	test_password_prepare();
> +	check_plan();
>  
>  	return 0;
>  }
> diff --git a/test/unit/scramble.result b/test/unit/scramble.result
> deleted file mode 100644
> index 0463db267..000000000
> --- a/test/unit/scramble.result
> +++ /dev/null
> @@ -1,4 +0,0 @@
> -0
> -0
> -1
> -1
> diff --git a/test/unit/sio.result b/test/unit/sio.result
> deleted file mode 100644
> index 896736bf9..000000000
> --- a/test/unit/sio.result
> +++ /dev/null
> @@ -1,36 +0,0 @@
> -	*** main ***
> -1..2
> -	*** check_uri_to_addr ***
> -    1..22
> -    ok 1 - invalid uri is detected
> -    ok 2 - too long UNIX path
> -    ok 3 - UNIX
> -    ok 4 - UNIX path
> -    ok 5 - UNIX family
> -    ok 6 - unix host is not empty
> -    ok 7 - localhost
> -    ok 8 - localhost family
> -    ok 9 - localhost address
> -    ok 10 - localhost port
> -    ok 11 - 'localhost' host is not empty
> -    ok 12 - 'any'
> -    ok 13 - 'any' family
> -    ok 14 - 'any' address
> -    ok 15 - 'any' port
> -    ok 16 - only port specified - host is empty
> -    ok 17 - IP
> -    ok 18 - IP family
> -    ok 19 - IP address
> -    ok 20 - IP port
> -    ok 21 - IPv4 host is not empty
> -    ok 22 - invalid IP
> -ok 1 - subtests
> -	*** check_uri_to_addr: done ***
> -	*** check_auto_bind ***
> -    1..3
> -    ok 1 - bind to 0 works
> -    ok 2 - getsockname works on 0 bind
> -    ok 3 - a real port is returned
> -ok 2 - subtests
> -	*** check_auto_bind: done ***
> -	*** main: done ***
> diff --git a/test/unit/stailq.result b/test/unit/stailq.result
> deleted file mode 100644
> index 041545008..000000000
> --- a/test/unit/stailq.result
> +++ /dev/null
> @@ -1,76 +0,0 @@
> -1..75
> -ok 1 - list is empty
> -ok 2 - list is empty after reverse
> -ok 3 - first item
> -ok 4 - last item
> -ok 5 - element (foreach) 0
> -ok 6 - element (foreach) 1
> -ok 7 - element (foreach) 2
> -ok 8 - element (foreach) 3
> -ok 9 - element (foreach) 4
> -ok 10 - element (foreach) 5
> -ok 11 - element (foreach) 6
> -ok 12 - first item
> -ok 13 - head is not empty
> -ok 14 - first entry
> -ok 15 - shift item 0
> -ok 16 - shift item 1
> -ok 17 - shift item 2
> -ok 18 - shift item 3
> -ok 19 - shift item 4
> -ok 20 - shift item 5
> -ok 21 - shift item 6
> -ok 22 - list is empty after shift
> -ok 23 - next is empty
> -ok 24 - element (foreach_entry) 6
> -ok 25 - element (foreach_entry) 5
> -ok 26 - element (foreach_entry) 4
> -ok 27 - element (foreach_entry) 3
> -ok 28 - element (foreach_entry) 2
> -ok 29 - element (foreach_entry) 1
> -ok 30 - element (foreach_entry) 0
> -ok 31 - element (foreach_entry) 0
> -ok 32 - element (foreach_entry) 1
> -ok 33 - element (foreach_entry) 2
> -ok 34 - element (foreach_entry) 3
> -ok 35 - element (foreach_entry) 4
> -ok 36 - element (foreach_entry) 5
> -ok 37 - element (foreach_entry) 6
> -ok 38 - head is empty after cut at first
> -ok 39 - tail element after cut at first 0
> -ok 40 - tail element after cut at first 1
> -ok 41 - tail element after cut at first 2
> -ok 42 - tail element after cut at first 3
> -ok 43 - tail element after cut at first 4
> -ok 44 - tail element after cut at first 5
> -ok 45 - tail element after cut at first 6
> -ok 46 - tail is empty after cut at last
> -ok 47 - head element after cut at last 0
> -ok 48 - head element after cut at last 1
> -ok 49 - head element after cut at last 2
> -ok 50 - head element after cut at last 3
> -ok 51 - head element after cut at last 4
> -ok 52 - head element after cut at last 5
> -ok 53 - head element after cut at last 6
> -ok 54 - head element after cut at middle 0
> -ok 55 - head element after cut at middle 1
> -ok 56 - head element after cut at middle 2
> -ok 57 - head element after cut at middle 3
> -ok 58 - tail element after cut at middle 4
> -ok 59 - tail element after cut at middle 5
> -ok 60 - tail element after cut at middle 6
> -ok 61 - tail is empty after concat
> -ok 62 - head element after concat 0
> -ok 63 - head element after concat 1
> -ok 64 - head element after concat 2
> -ok 65 - head element after concat 3
> -ok 66 - head element after concat 4
> -ok 67 - head element after concat 5
> -ok 68 - head element after concat 6
> -ok 69 - element 0 (insert)
> -ok 70 - element 1 (insert)
> -ok 71 - element 2 (insert)
> -ok 72 - element 3 (insert)
> -ok 73 - element 4 (insert)
> -ok 74 - first item (insert)
> -ok 75 - last item (insert)
> diff --git a/test/unit/swim.result b/test/unit/swim.result
> deleted file mode 100644
> index 07ea6a1a0..000000000
> --- a/test/unit/swim.result
> +++ /dev/null
> @@ -1,234 +0,0 @@
> -	*** main_f ***
> -1..23
> -	*** swim_test_one_link ***
> -    1..6
> -    ok 1 - no rounds - no fullmesh
> -    ok 2 - one link
> -    ok 3 - self 0 is alive
> -    ok 4 - self 1 is alive
> -    ok 5 - 0 sees 1 as alive
> -    ok 6 - 1 sees 0 as alive
> -ok 1 - subtests
> -	*** swim_test_one_link: done ***
> -	*** swim_test_sequence ***
> -    1..1
> -    ok 1 - sequence
> -ok 2 - subtests
> -	*** swim_test_sequence: done ***
> -	*** swim_test_uuid_update ***
> -    1..7
> -    ok 1 - UUID update
> -    ok 2 - old UUID is marked as 'left'
> -    ok 3 - old UUID is dropped after a while
> -    ok 4 - dropped everywhere
> -    ok 5 - two members in each
> -    ok 6 - can not update to an existing UUID - swim_cfg fails
> -    ok 7 - diag says 'exists'
> -ok 3 - subtests
> -	*** swim_test_uuid_update: done ***
> -	*** swim_test_cfg ***
> -    1..16
> -    ok 1 - first cfg failed - no URI
> -    ok 2 - diag says 'mandatory'
> -    ok 3 - first cfg failed - no UUID
> -    ok 4 - diag says 'mandatory'
> -    ok 5 - configured first time
> -    ok 6 - second time can omit URI, UUID
> -    ok 7 - hearbeat is dynamic
> -    ok 8 - URI is unchanged after recfg with NULL URI
> -    ok 9 - can not use invalid URI
> -    ok 10 - diag says 'invalid uri'
> -    ok 11 - can not use domain names
> -    ok 12 - diag says 'invalid uri'
> -    ok 13 - UNIX sockets are not supported
> -    ok 14 - diag says 'only IP'
> -    ok 15 - can not bind to an occupied port
> -    ok 16 - diag says 'bind'
> -ok 4 - subtests
> -	*** swim_test_cfg: done ***
> -	*** swim_test_add_remove ***
> -    1..14
> -    ok 1 - can not add an existing member
> -    ok 2 - diag says 'already exists'
> -    ok 3 - can not add a invalid uri
> -    ok 4 - diag says 'invalid uri'
> -    ok 5 - can not remove self
> -    ok 6 - diag says the same
> -    ok 7 - find by UUID works
> -    ok 8 - now remove one element
> -    ok 9 - and it can not be found anymore
> -    ok 10 - remove of a not existing member
> -    ok 11 - after removal the cluster is not in fullmesh
> -    ok 12 - but it is back in 1 step
> -    ok 13 - back in fullmesh after a member removal in the middle of a step
> -    ok 14 - if a referenced member is dropped, it can be detected from the public API
> -ok 5 - subtests
> -	*** swim_test_add_remove: done ***
> -	*** swim_test_basic_failure_detection ***
> -    1..9
> -    ok 1 - node is added as alive
> -    ok 2 - member still is not suspected after 1 noack
> -    ok 3 - but it is suspected after one more
> -    ok 4 - it is not dead after 2 more noacks
> -    ok 5 - but it is dead after one more
> -    ok 6 - after 2 more unacks the member still is not deleted - dissemination TTD keeps it
> -    ok 7 - but it is dropped after 2 rounds when TTD gets 0
> -    ok 8 - fullmesh is restored
> -    ok 9 - a member is added back on an ACK
> -ok 6 - subtests
> -	*** swim_test_basic_failure_detection: done ***
> -	*** swim_test_probe ***
> -    1..3
> -    ok 1 - probe validates URI
> -    ok 2 - send probe
> -    ok 3 - receive ACK on probe and get fullmesh
> -ok 7 - subtests
> -	*** swim_test_probe: done ***
> -	*** swim_test_refute ***
> -    1..6
> -    ok 1 - S2 increments its own incarnation to refute its suspicion
> -    ok 2 - new incarnation has reached S1 with a next round message
> -    ok 3 - after restart S2's version is 0 again
> -    ok 4 - but generation is new
> -    ok 5 - S2 disseminates new incarnation, S1 learns it
> -    ok 6 - and considers S2 alive
> -ok 8 - subtests
> -	*** swim_test_refute: done ***
> -	*** swim_test_basic_gossip ***
> -    1..4
> -    ok 1 - S1 still thinks that S2 is alive
> -    ok 2 - but one more second, and a second ack timed out - S1 sees S2 as suspected
> -    ok 3 - S3 still thinks that S2 is alive
> -    ok 4 - S3 learns about suspected S2 from S1
> -ok 9 - subtests
> -	*** swim_test_basic_gossip: done ***
> -	*** swim_test_too_big_packet ***
> -    1..3
> -    ok 1 - despite S1 can not send all the 50 members in a one packet, fullmesh is eventually reached
> -    ok 2 - a dead member is detected in time not depending on cluster size
> -    ok 3 - S26 death is eventually learned by everyone
> -ok 10 - subtests
> -	*** swim_test_too_big_packet: done ***
> -	*** swim_test_undead ***
> -    1..2
> -    ok 1 - member S2 is dead
> -    ok 2 - but it is never deleted due to the cfg option
> -ok 11 - subtests
> -	*** swim_test_undead: done ***
> -	*** swim_test_packet_loss ***
> -    1..5
> -    ok 1 - drop rate = 5.00, but the failure is disseminated
> -    ok 2 - drop rate = 10.00, but the failure is disseminated
> -    ok 3 - drop rate = 20.00, but the failure is disseminated
> -    ok 4 - drop rate = 50.00, but the failure is disseminated
> -    ok 5 - drop rate = 90.00, but the failure is disseminated
> -ok 12 - subtests
> -	*** swim_test_packet_loss: done ***
> -	*** swim_test_quit ***
> -    1..10
> -    ok 1 - 'self' is 'left' immediately after quit
> -    ok 2 - 'quit' is sent to all the members without delays between dispatches
> -    ok 3 - quited member S1 has returned and refuted the old status
> -    ok 4 - another member S2 has taken the quited UUID
> -    ok 5 - S3 did not add S1 back when received its 'quit'
> -    ok 6 - S2 finally got 'quit' message from S1, but with its 'own' UUID - refute it
> -    ok 7 - S3 sees S1 as left
> -    ok 8 - S2 does not see S1 at all
> -    ok 9 - after more time S1 is dropped from S3
> -    ok 10 - and still is not added to S2 - left members can not be added
> -ok 13 - subtests
> -	*** swim_test_quit: done ***
> -	*** swim_test_uri_update ***
> -    1..2
> -    ok 1 - S1 updated its URI and S2 sees that
> -    ok 2 - S2 still keeps new S1's URI, even received the old one from S3
> -ok 14 - subtests
> -	*** swim_test_uri_update: done ***
> -	*** swim_test_broadcast ***
> -    1..6
> -    ok 1 - S1 chooses to broadcast with port 2
> -    ok 2 - S2 receives the broadcast from S1
> -    ok 3 - others don't
> -    ok 4 - S1 broadcasts ping without port
> -    ok 5 - now everyone sees S1
> -    ok 6 - fullmesh is reached, and no one link was added explicitly
> -ok 15 - subtests
> -	*** swim_test_broadcast: done ***
> -	*** swim_test_payload_basic ***
> -    1..11
> -    ok 1 - no payload by default
> -    ok 2 - can not set too big payload
> -    ok 3 - diag says too big
> -    ok 4 - payload is set
> -    ok 5 - version is incremented on each payload update
> -    ok 6 - payload is successfully obtained back
> -    ok 7 - payload is disseminated
> -    ok 8 - payload is changed
> -    ok 9 - version is incremented on each payload update
> -    ok 10 - second payload is disseminated
> -    ok 11 - third payload is disseminated via anti-entropy
> -ok 16 - subtests
> -	*** swim_test_payload_basic: done ***
> -	*** swim_test_indirect_ping ***
> -    1..2
> -    ok 1 - S1 is still alive everywhere
> -    ok 2 - as well as S2 - they communicated via S3
> -ok 17 - subtests
> -	*** swim_test_indirect_ping: done ***
> -	*** swim_test_encryption ***
> -    1..3
> -    ok 1 - cluster works with encryption
> -    ok 2 - different encryption keys - can't interact
> -    ok 3 - cluster works after encryption has been disabled
> -ok 18 - subtests
> -	*** swim_test_encryption: done ***
> -	*** swim_test_slow_net ***
> -    1..0
> -    # slow network leads to idle round steps, they should not produce a new message
> -ok 19 - subtests
> -	*** swim_test_slow_net: done ***
> -	*** swim_test_triggers ***
> -    1..20
> -    ok 1 - trigger is fired
> -    ok 2 - is not deleted
> -    ok 3 - ctx.member is set
> -    ok 4 - ctx.events is set
> -    ok 5 - self payload is updated
> -    ok 6 - self is set as a member
> -    ok 7 - both version and payload events are presented
> -    ok 8 - suspicion fired a trigger
> -    ok 9 - status suspected
> -    ok 10 - death fired a trigger
> -    ok 11 - status dead
> -    ok 12 - drop fired a trigger
> -    ok 13 - status dropped
> -    ok 14 - dropped member is not presented in the member table
> -    ok 15 - but is in the event context
> -    ok 16 - yielding trigger is fired
> -    ok 17 - non-yielding still is not
> -    ok 18 - trigger is not deleted until all currently sleeping triggers are finished
> -    # now all the triggers are done and deleted
> -    ok 19 - local URI update warns about version update
> -    ok 20 - version is a part of incarnation, so the latter is updated too
> -ok 20 - subtests
> -	*** swim_test_triggers: done ***
> -	*** swim_test_generation ***
> -    1..3
> -    ok 1 - S1 disseminated its payload to S2
> -    ok 2 - S1 restarted and set another payload. Without generation it could lead to never disseminated new payload.
> -    ok 3 - S2 sees new generation of S1
> -ok 21 - subtests
> -	*** swim_test_generation: done ***
> -	*** swim_test_dissemination_speed ***
> -    1..2
> -    ok 1 - dissemination work in log time even at the very start of a cluster
> -    ok 2 - dissemination can withstand an event storm
> -ok 22 - subtests
> -	*** swim_test_dissemination_speed: done ***
> -	*** swim_test_suspect_new_members ***
> -    1..2
> -    ok 1 - S2 dropped S1 as dead
> -    ok 2 - S3 didn't add S1 from S2's messages, because S1 didn't answer on a ping
> -ok 23 - subtests
> -	*** swim_test_suspect_new_members: done ***
> -	*** main_f: done ***
> diff --git a/test/unit/swim_errinj.result b/test/unit/swim_errinj.result
> deleted file mode 100644
> index c60389d7f..000000000
> --- a/test/unit/swim_errinj.result
> +++ /dev/null
> @@ -1,18 +0,0 @@
> -	*** main_f ***
> -1..1
> -	*** swim_test_payload_refutation ***
> -    1..11
> -    ok 1 - S2 sees new version of S1
> -    ok 2 - S3 does the same
> -    ok 3 - but S2 does not known the new payload
> -    ok 4 - as well as S3
> -    ok 5 - S2 learned S1's payload via anti-entropy
> -    ok 6 - version still is the same
> -    ok 7 - S3 was blocked and does not know anything
> -    ok 8 - version still is the same
> -    ok 9 - S2 keeps the same new S1's payload, S3 did not rewrite it
> -    ok 10 - S3 still does not know anything
> -    ok 11 - S3 learns S1's payload from S2
> -ok 1 - subtests
> -	*** swim_test_payload_refutation: done ***
> -	*** main_f: done ***
> diff --git a/test/unit/swim_proto.result b/test/unit/swim_proto.result
> deleted file mode 100644
> index 8a41a5d40..000000000
> --- a/test/unit/swim_proto.result
> +++ /dev/null
> @@ -1,40 +0,0 @@
> -	*** main ***
> -1..3
> -	*** swim_test_member_def ***
> -    1..12
> -    ok 1 - not map header
> -    ok 2 - not uint member key
> -    ok 3 - too big member key
> -    ok 4 - STATUS is not uint
> -    ok 5 - invalid STATUS
> -    ok 6 - invalid address
> -    ok 7 - bad port
> -    ok 8 - unexpected buffer end
> -    ok 9 - unexpected buffer end
> -    ok 10 - uuid is nil/undefined
> -    ok 11 - port is 0/undefined
> -    ok 12 - normal member def
> -ok 1 - subtests
> -	*** swim_test_member_def: done ***
> -	*** swim_test_meta ***
> -    1..8
> -    ok 1 - not map header
> -    ok 2 - not uint meta key
> -    ok 3 - unknown meta key
> -    ok 4 - unexpected end
> -    ok 5 - invalid version
> -    ok 6 - port is 0/undefined
> -    ok 7 - version is 0/undefined
> -    ok 8 - normal meta
> -ok 2 - subtests
> -	*** swim_test_meta: done ***
> -	*** swim_test_route ***
> -    1..5
> -    ok 1 - route was expected, but map is too short
> -    ok 2 - no route map
> -    ok 3 - empty route map
> -    ok 4 - zero addresses
> -    ok 5 - normal route
> -ok 3 - subtests
> -	*** swim_test_route: done ***
> -	*** main: done ***
> diff --git a/test/unit/tuple_bigref.result b/test/unit/tuple_bigref.result
> deleted file mode 100644
> index 6e3f0cfa4..000000000
> --- a/test/unit/tuple_bigref.result
> +++ /dev/null
> @@ -1,17 +0,0 @@
> -	*** main ***
> -1..2
> -	*** test_bigrefs_overall ***
> -    1..3
> -    ok 1 - All tuples have refs == 1.
> -    ok 2 - All tuples have bigrefs.
> -    ok 3 - All tuples were deleted.
> -	*** test_bigrefs_overall: done ***
> -ok 1 - subtests
> -	*** test_bigrefs_non_consistent ***
> -    1..3
> -    ok 1 - All tuples have bigrefs.
> -    ok 2 - 11 tuples don't have bigrefs and all other tuples have
> -    ok 3 - All tuples have bigrefs and their indexes are in right order.
> -	*** test_bigrefs_non_consistent: done ***
> -ok 2 - subtests
> -	*** main: done ***
> diff --git a/test/unit/uri.result b/test/unit/uri.result
> deleted file mode 100644
> index 804560b69..000000000
> --- a/test/unit/uri.result
> +++ /dev/null
> @@ -1,1307 +0,0 @@
> -1..63
> -    1..19
> -    ok 1 - host: parse
> -    ok 2 - host: scheme
> -    ok 3 - host: login
> -    ok 4 - host: password
> -    ok 5 - host: host
> -    ok 6 - host: service
> -    ok 7 - host: path
> -    ok 8 - host: query
> -    ok 9 - host: fragment
> -    ok 10 - host: host_hint
> -    ok 11 - host: parse
> -    ok 12 - host: scheme
> -    ok 13 - host: login
> -    ok 14 - host: password
> -    ok 15 - host: host
> -    ok 16 - host: service
> -    ok 17 - host: path
> -    ok 18 - host: query
> -    ok 19 - host: fragment
> -ok 1 - subtests
> -    1..19
> -    ok 1 - host/: parse
> -    ok 2 - host/: scheme
> -    ok 3 - host/: login
> -    ok 4 - host/: password
> -    ok 5 - host/: host
> -    ok 6 - host/: service
> -    ok 7 - host/: path
> -    ok 8 - host/: query
> -    ok 9 - host/: fragment
> -    ok 10 - host/: host_hint
> -    ok 11 - host/: parse
> -    ok 12 - host/: scheme
> -    ok 13 - host/: login
> -    ok 14 - host/: password
> -    ok 15 - host/: host
> -    ok 16 - host/: service
> -    ok 17 - host/: path
> -    ok 18 - host/: query
> -    ok 19 - host/: fragment
> -ok 2 - subtests
> -    1..19
> -    ok 1 - host/path1/path2/path3: parse
> -    ok 2 - host/path1/path2/path3: scheme
> -    ok 3 - host/path1/path2/path3: login
> -    ok 4 - host/path1/path2/path3: password
> -    ok 5 - host/path1/path2/path3: host
> -    ok 6 - host/path1/path2/path3: service
> -    ok 7 - host/path1/path2/path3: path
> -    ok 8 - host/path1/path2/path3: query
> -    ok 9 - host/path1/path2/path3: fragment
> -    ok 10 - host/path1/path2/path3: host_hint
> -    ok 11 - host/path1/path2/path3: parse
> -    ok 12 - host/path1/path2/path3: scheme
> -    ok 13 - host/path1/path2/path3: login
> -    ok 14 - host/path1/path2/path3: password
> -    ok 15 - host/path1/path2/path3: host
> -    ok 16 - host/path1/path2/path3: service
> -    ok 17 - host/path1/path2/path3: path
> -    ok 18 - host/path1/path2/path3: query
> -    ok 19 - host/path1/path2/path3: fragment
> -ok 3 - subtests
> -    1..19
> -    ok 1 - host/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 2 - host/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 3 - host/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 4 - host/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 5 - host/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 6 - host/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 7 - host/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 8 - host/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 9 - host/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -    ok 10 - host/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
> -    ok 11 - host/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 12 - host/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 13 - host/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 14 - host/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 15 - host/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 16 - host/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 17 - host/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 18 - host/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 19 - host/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -ok 4 - subtests
> -    1..19
> -    ok 1 - host:service: parse
> -    ok 2 - host:service: scheme
> -    ok 3 - host:service: login
> -    ok 4 - host:service: password
> -    ok 5 - host:service: host
> -    ok 6 - host:service: service
> -    ok 7 - host:service: path
> -    ok 8 - host:service: query
> -    ok 9 - host:service: fragment
> -    ok 10 - host:service: host_hint
> -    ok 11 - host:service: parse
> -    ok 12 - host:service: scheme
> -    ok 13 - host:service: login
> -    ok 14 - host:service: password
> -    ok 15 - host:service: host
> -    ok 16 - host:service: service
> -    ok 17 - host:service: path
> -    ok 18 - host:service: query
> -    ok 19 - host:service: fragment
> -ok 5 - subtests
> -    1..19
> -    ok 1 - host:service/: parse
> -    ok 2 - host:service/: scheme
> -    ok 3 - host:service/: login
> -    ok 4 - host:service/: password
> -    ok 5 - host:service/: host
> -    ok 6 - host:service/: service
> -    ok 7 - host:service/: path
> -    ok 8 - host:service/: query
> -    ok 9 - host:service/: fragment
> -    ok 10 - host:service/: host_hint
> -    ok 11 - host:service/: parse
> -    ok 12 - host:service/: scheme
> -    ok 13 - host:service/: login
> -    ok 14 - host:service/: password
> -    ok 15 - host:service/: host
> -    ok 16 - host:service/: service
> -    ok 17 - host:service/: path
> -    ok 18 - host:service/: query
> -    ok 19 - host:service/: fragment
> -ok 6 - subtests
> -    1..19
> -    ok 1 - host:service/path1/path2/path3: parse
> -    ok 2 - host:service/path1/path2/path3: scheme
> -    ok 3 - host:service/path1/path2/path3: login
> -    ok 4 - host:service/path1/path2/path3: password
> -    ok 5 - host:service/path1/path2/path3: host
> -    ok 6 - host:service/path1/path2/path3: service
> -    ok 7 - host:service/path1/path2/path3: path
> -    ok 8 - host:service/path1/path2/path3: query
> -    ok 9 - host:service/path1/path2/path3: fragment
> -    ok 10 - host:service/path1/path2/path3: host_hint
> -    ok 11 - host:service/path1/path2/path3: parse
> -    ok 12 - host:service/path1/path2/path3: scheme
> -    ok 13 - host:service/path1/path2/path3: login
> -    ok 14 - host:service/path1/path2/path3: password
> -    ok 15 - host:service/path1/path2/path3: host
> -    ok 16 - host:service/path1/path2/path3: service
> -    ok 17 - host:service/path1/path2/path3: path
> -    ok 18 - host:service/path1/path2/path3: query
> -    ok 19 - host:service/path1/path2/path3: fragment
> -ok 7 - subtests
> -    1..19
> -    ok 1 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 2 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 3 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 4 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 5 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 6 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 7 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 8 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 9 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -    ok 10 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
> -    ok 11 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 12 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 13 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 14 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 15 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 16 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 17 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 18 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 19 - host:service/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -ok 8 - subtests
> -    1..19
> -    ok 1 - login@host: parse
> -    ok 2 - login@host: scheme
> -    ok 3 - login@host: login
> -    ok 4 - login@host: password
> -    ok 5 - login@host: host
> -    ok 6 - login@host: service
> -    ok 7 - login@host: path
> -    ok 8 - login@host: query
> -    ok 9 - login@host: fragment
> -    ok 10 - login@host: host_hint
> -    ok 11 - login@host: parse
> -    ok 12 - login@host: scheme
> -    ok 13 - login@host: login
> -    ok 14 - login@host: password
> -    ok 15 - login@host: host
> -    ok 16 - login@host: service
> -    ok 17 - login@host: path
> -    ok 18 - login@host: query
> -    ok 19 - login@host: fragment
> -ok 9 - subtests
> -    1..19
> -    ok 1 - login@host/: parse
> -    ok 2 - login@host/: scheme
> -    ok 3 - login@host/: login
> -    ok 4 - login@host/: password
> -    ok 5 - login@host/: host
> -    ok 6 - login@host/: service
> -    ok 7 - login@host/: path
> -    ok 8 - login@host/: query
> -    ok 9 - login@host/: fragment
> -    ok 10 - login@host/: host_hint
> -    ok 11 - login@host/: parse
> -    ok 12 - login@host/: scheme
> -    ok 13 - login@host/: login
> -    ok 14 - login@host/: password
> -    ok 15 - login@host/: host
> -    ok 16 - login@host/: service
> -    ok 17 - login@host/: path
> -    ok 18 - login@host/: query
> -    ok 19 - login@host/: fragment
> -ok 10 - subtests
> -    1..19
> -    ok 1 - login@host/path1/path2/path3: parse
> -    ok 2 - login@host/path1/path2/path3: scheme
> -    ok 3 - login@host/path1/path2/path3: login
> -    ok 4 - login@host/path1/path2/path3: password
> -    ok 5 - login@host/path1/path2/path3: host
> -    ok 6 - login@host/path1/path2/path3: service
> -    ok 7 - login@host/path1/path2/path3: path
> -    ok 8 - login@host/path1/path2/path3: query
> -    ok 9 - login@host/path1/path2/path3: fragment
> -    ok 10 - login@host/path1/path2/path3: host_hint
> -    ok 11 - login@host/path1/path2/path3: parse
> -    ok 12 - login@host/path1/path2/path3: scheme
> -    ok 13 - login@host/path1/path2/path3: login
> -    ok 14 - login@host/path1/path2/path3: password
> -    ok 15 - login@host/path1/path2/path3: host
> -    ok 16 - login@host/path1/path2/path3: service
> -    ok 17 - login@host/path1/path2/path3: path
> -    ok 18 - login@host/path1/path2/path3: query
> -    ok 19 - login@host/path1/path2/path3: fragment
> -ok 11 - subtests
> -    1..19
> -    ok 1 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 2 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 3 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 4 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 5 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 6 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 7 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 8 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 9 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -    ok 10 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
> -    ok 11 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 12 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 13 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 14 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 15 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 16 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 17 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 18 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 19 - login@host/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -ok 12 - subtests
> -    1..19
> -    ok 1 - login:password@host: parse
> -    ok 2 - login:password@host: scheme
> -    ok 3 - login:password@host: login
> -    ok 4 - login:password@host: password
> -    ok 5 - login:password@host: host
> -    ok 6 - login:password@host: service
> -    ok 7 - login:password@host: path
> -    ok 8 - login:password@host: query
> -    ok 9 - login:password@host: fragment
> -    ok 10 - login:password@host: host_hint
> -    ok 11 - login:password@host: parse
> -    ok 12 - login:password@host: scheme
> -    ok 13 - login:password@host: login
> -    ok 14 - login:password@host: password
> -    ok 15 - login:password@host: host
> -    ok 16 - login:password@host: service
> -    ok 17 - login:password@host: path
> -    ok 18 - login:password@host: query
> -    ok 19 - login:password@host: fragment
> -ok 13 - subtests
> -    1..19
> -    ok 1 - login:@host: parse
> -    ok 2 - login:@host: scheme
> -    ok 3 - login:@host: login
> -    ok 4 - login:@host: password
> -    ok 5 - login:@host: host
> -    ok 6 - login:@host: service
> -    ok 7 - login:@host: path
> -    ok 8 - login:@host: query
> -    ok 9 - login:@host: fragment
> -    ok 10 - login:@host: host_hint
> -    ok 11 - login:@host: parse
> -    ok 12 - login:@host: scheme
> -    ok 13 - login:@host: login
> -    ok 14 - login:@host: password
> -    ok 15 - login:@host: host
> -    ok 16 - login:@host: service
> -    ok 17 - login:@host: path
> -    ok 18 - login:@host: query
> -    ok 19 - login:@host: fragment
> -ok 14 - subtests
> -    1..19
> -    ok 1 - login:password@host/: parse
> -    ok 2 - login:password@host/: scheme
> -    ok 3 - login:password@host/: login
> -    ok 4 - login:password@host/: password
> -    ok 5 - login:password@host/: host
> -    ok 6 - login:password@host/: service
> -    ok 7 - login:password@host/: path
> -    ok 8 - login:password@host/: query
> -    ok 9 - login:password@host/: fragment
> -    ok 10 - login:password@host/: host_hint
> -    ok 11 - login:password@host/: parse
> -    ok 12 - login:password@host/: scheme
> -    ok 13 - login:password@host/: login
> -    ok 14 - login:password@host/: password
> -    ok 15 - login:password@host/: host
> -    ok 16 - login:password@host/: service
> -    ok 17 - login:password@host/: path
> -    ok 18 - login:password@host/: query
> -    ok 19 - login:password@host/: fragment
> -ok 15 - subtests
> -    1..19
> -    ok 1 - login:password@host/path1/path2/path3: parse
> -    ok 2 - login:password@host/path1/path2/path3: scheme
> -    ok 3 - login:password@host/path1/path2/path3: login
> -    ok 4 - login:password@host/path1/path2/path3: password
> -    ok 5 - login:password@host/path1/path2/path3: host
> -    ok 6 - login:password@host/path1/path2/path3: service
> -    ok 7 - login:password@host/path1/path2/path3: path
> -    ok 8 - login:password@host/path1/path2/path3: query
> -    ok 9 - login:password@host/path1/path2/path3: fragment
> -    ok 10 - login:password@host/path1/path2/path3: host_hint
> -    ok 11 - login:password@host/path1/path2/path3: parse
> -    ok 12 - login:password@host/path1/path2/path3: scheme
> -    ok 13 - login:password@host/path1/path2/path3: login
> -    ok 14 - login:password@host/path1/path2/path3: password
> -    ok 15 - login:password@host/path1/path2/path3: host
> -    ok 16 - login:password@host/path1/path2/path3: service
> -    ok 17 - login:password@host/path1/path2/path3: path
> -    ok 18 - login:password@host/path1/path2/path3: query
> -    ok 19 - login:password@host/path1/path2/path3: fragment
> -ok 16 - subtests
> -    1..19
> -    ok 1 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 2 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 3 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 4 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 5 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 6 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 7 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 8 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 9 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -    ok 10 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
> -    ok 11 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 12 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 13 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 14 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 15 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 16 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 17 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 18 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 19 - login:password@host/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -ok 17 - subtests
> -    1..19
> -    ok 1 - login:password@host:service: parse
> -    ok 2 - login:password@host:service: scheme
> -    ok 3 - login:password@host:service: login
> -    ok 4 - login:password@host:service: password
> -    ok 5 - login:password@host:service: host
> -    ok 6 - login:password@host:service: service
> -    ok 7 - login:password@host:service: path
> -    ok 8 - login:password@host:service: query
> -    ok 9 - login:password@host:service: fragment
> -    ok 10 - login:password@host:service: host_hint
> -    ok 11 - login:password@host:service: parse
> -    ok 12 - login:password@host:service: scheme
> -    ok 13 - login:password@host:service: login
> -    ok 14 - login:password@host:service: password
> -    ok 15 - login:password@host:service: host
> -    ok 16 - login:password@host:service: service
> -    ok 17 - login:password@host:service: path
> -    ok 18 - login:password@host:service: query
> -    ok 19 - login:password@host:service: fragment
> -ok 18 - subtests
> -    1..19
> -    ok 1 - login:password@host:service/: parse
> -    ok 2 - login:password@host:service/: scheme
> -    ok 3 - login:password@host:service/: login
> -    ok 4 - login:password@host:service/: password
> -    ok 5 - login:password@host:service/: host
> -    ok 6 - login:password@host:service/: service
> -    ok 7 - login:password@host:service/: path
> -    ok 8 - login:password@host:service/: query
> -    ok 9 - login:password@host:service/: fragment
> -    ok 10 - login:password@host:service/: host_hint
> -    ok 11 - login:password@host:service/: parse
> -    ok 12 - login:password@host:service/: scheme
> -    ok 13 - login:password@host:service/: login
> -    ok 14 - login:password@host:service/: password
> -    ok 15 - login:password@host:service/: host
> -    ok 16 - login:password@host:service/: service
> -    ok 17 - login:password@host:service/: path
> -    ok 18 - login:password@host:service/: query
> -    ok 19 - login:password@host:service/: fragment
> -ok 19 - subtests
> -    1..19
> -    ok 1 - login:password@host:service/path1/path2/path3: parse
> -    ok 2 - login:password@host:service/path1/path2/path3: scheme
> -    ok 3 - login:password@host:service/path1/path2/path3: login
> -    ok 4 - login:password@host:service/path1/path2/path3: password
> -    ok 5 - login:password@host:service/path1/path2/path3: host
> -    ok 6 - login:password@host:service/path1/path2/path3: service
> -    ok 7 - login:password@host:service/path1/path2/path3: path
> -    ok 8 - login:password@host:service/path1/path2/path3: query
> -    ok 9 - login:password@host:service/path1/path2/path3: fragment
> -    ok 10 - login:password@host:service/path1/path2/path3: host_hint
> -    ok 11 - login:password@host:service/path1/path2/path3: parse
> -    ok 12 - login:password@host:service/path1/path2/path3: scheme
> -    ok 13 - login:password@host:service/path1/path2/path3: login
> -    ok 14 - login:password@host:service/path1/path2/path3: password
> -    ok 15 - login:password@host:service/path1/path2/path3: host
> -    ok 16 - login:password@host:service/path1/path2/path3: service
> -    ok 17 - login:password@host:service/path1/path2/path3: path
> -    ok 18 - login:password@host:service/path1/path2/path3: query
> -    ok 19 - login:password@host:service/path1/path2/path3: fragment
> -ok 20 - subtests
> -    1..19
> -    ok 1 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 2 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 3 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 4 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 5 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 6 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 7 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 8 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 9 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -    ok 10 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
> -    ok 11 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 12 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 13 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 14 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 15 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 16 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 17 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 18 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 19 - login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -ok 21 - subtests
> -    1..19
> -    ok 1 - scheme://login:password@host:service: parse
> -    ok 2 - scheme://login:password@host:service: scheme
> -    ok 3 - scheme://login:password@host:service: login
> -    ok 4 - scheme://login:password@host:service: password
> -    ok 5 - scheme://login:password@host:service: host
> -    ok 6 - scheme://login:password@host:service: service
> -    ok 7 - scheme://login:password@host:service: path
> -    ok 8 - scheme://login:password@host:service: query
> -    ok 9 - scheme://login:password@host:service: fragment
> -    ok 10 - scheme://login:password@host:service: host_hint
> -    ok 11 - scheme://login:password@host:service: parse
> -    ok 12 - scheme://login:password@host:service: scheme
> -    ok 13 - scheme://login:password@host:service: login
> -    ok 14 - scheme://login:password@host:service: password
> -    ok 15 - scheme://login:password@host:service: host
> -    ok 16 - scheme://login:password@host:service: service
> -    ok 17 - scheme://login:password@host:service: path
> -    ok 18 - scheme://login:password@host:service: query
> -    ok 19 - scheme://login:password@host:service: fragment
> -ok 22 - subtests
> -    1..19
> -    ok 1 - scheme://login:password@host:service/: parse
> -    ok 2 - scheme://login:password@host:service/: scheme
> -    ok 3 - scheme://login:password@host:service/: login
> -    ok 4 - scheme://login:password@host:service/: password
> -    ok 5 - scheme://login:password@host:service/: host
> -    ok 6 - scheme://login:password@host:service/: service
> -    ok 7 - scheme://login:password@host:service/: path
> -    ok 8 - scheme://login:password@host:service/: query
> -    ok 9 - scheme://login:password@host:service/: fragment
> -    ok 10 - scheme://login:password@host:service/: host_hint
> -    ok 11 - scheme://login:password@host:service/: parse
> -    ok 12 - scheme://login:password@host:service/: scheme
> -    ok 13 - scheme://login:password@host:service/: login
> -    ok 14 - scheme://login:password@host:service/: password
> -    ok 15 - scheme://login:password@host:service/: host
> -    ok 16 - scheme://login:password@host:service/: service
> -    ok 17 - scheme://login:password@host:service/: path
> -    ok 18 - scheme://login:password@host:service/: query
> -    ok 19 - scheme://login:password@host:service/: fragment
> -ok 23 - subtests
> -    1..19
> -    ok 1 - scheme://login:password@host:service/path1/path2/path3: parse
> -    ok 2 - scheme://login:password@host:service/path1/path2/path3: scheme
> -    ok 3 - scheme://login:password@host:service/path1/path2/path3: login
> -    ok 4 - scheme://login:password@host:service/path1/path2/path3: password
> -    ok 5 - scheme://login:password@host:service/path1/path2/path3: host
> -    ok 6 - scheme://login:password@host:service/path1/path2/path3: service
> -    ok 7 - scheme://login:password@host:service/path1/path2/path3: path
> -    ok 8 - scheme://login:password@host:service/path1/path2/path3: query
> -    ok 9 - scheme://login:password@host:service/path1/path2/path3: fragment
> -    ok 10 - scheme://login:password@host:service/path1/path2/path3: host_hint
> -    ok 11 - scheme://login:password@host:service/path1/path2/path3: parse
> -    ok 12 - scheme://login:password@host:service/path1/path2/path3: scheme
> -    ok 13 - scheme://login:password@host:service/path1/path2/path3: login
> -    ok 14 - scheme://login:password@host:service/path1/path2/path3: password
> -    ok 15 - scheme://login:password@host:service/path1/path2/path3: host
> -    ok 16 - scheme://login:password@host:service/path1/path2/path3: service
> -    ok 17 - scheme://login:password@host:service/path1/path2/path3: path
> -    ok 18 - scheme://login:password@host:service/path1/path2/path3: query
> -    ok 19 - scheme://login:password@host:service/path1/path2/path3: fragment
> -ok 24 - subtests
> -    1..19
> -    ok 1 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 2 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 3 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 4 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 5 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 6 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 7 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 8 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 9 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -    ok 10 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
> -    ok 11 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 12 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 13 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 14 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 15 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 16 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 17 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 18 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 19 - scheme://login:password@host:service/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -ok 25 - subtests
> -    1..19
> -    ok 1 - host/path: parse
> -    ok 2 - host/path: scheme
> -    ok 3 - host/path: login
> -    ok 4 - host/path: password
> -    ok 5 - host/path: host
> -    ok 6 - host/path: service
> -    ok 7 - host/path: path
> -    ok 8 - host/path: query
> -    ok 9 - host/path: fragment
> -    ok 10 - host/path: host_hint
> -    ok 11 - host/path: parse
> -    ok 12 - host/path: scheme
> -    ok 13 - host/path: login
> -    ok 14 - host/path: password
> -    ok 15 - host/path: host
> -    ok 16 - host/path: service
> -    ok 17 - host/path: path
> -    ok 18 - host/path: query
> -    ok 19 - host/path: fragment
> -ok 26 - subtests
> -    1..19
> -    ok 1 - host//: parse
> -    ok 2 - host//: scheme
> -    ok 3 - host//: login
> -    ok 4 - host//: password
> -    ok 5 - host//: host
> -    ok 6 - host//: service
> -    ok 7 - host//: path
> -    ok 8 - host//: query
> -    ok 9 - host//: fragment
> -    ok 10 - host//: host_hint
> -    ok 11 - host//: parse
> -    ok 12 - host//: scheme
> -    ok 13 - host//: login
> -    ok 14 - host//: password
> -    ok 15 - host//: host
> -    ok 16 - host//: service
> -    ok 17 - host//: path
> -    ok 18 - host//: query
> -    ok 19 - host//: fragment
> -ok 27 - subtests
> -    1..19
> -    ok 1 - host//path: parse
> -    ok 2 - host//path: scheme
> -    ok 3 - host//path: login
> -    ok 4 - host//path: password
> -    ok 5 - host//path: host
> -    ok 6 - host//path: service
> -    ok 7 - host//path: path
> -    ok 8 - host//path: query
> -    ok 9 - host//path: fragment
> -    ok 10 - host//path: host_hint
> -    ok 11 - host//path: parse
> -    ok 12 - host//path: scheme
> -    ok 13 - host//path: login
> -    ok 14 - host//path: password
> -    ok 15 - host//path: host
> -    ok 16 - host//path: service
> -    ok 17 - host//path: path
> -    ok 18 - host//path: query
> -    ok 19 - host//path: fragment
> -ok 28 - subtests
> -    1..19
> -    ok 1 - host/;abc?q: parse
> -    ok 2 - host/;abc?q: scheme
> -    ok 3 - host/;abc?q: login
> -    ok 4 - host/;abc?q: password
> -    ok 5 - host/;abc?q: host
> -    ok 6 - host/;abc?q: service
> -    ok 7 - host/;abc?q: path
> -    ok 8 - host/;abc?q: query
> -    ok 9 - host/;abc?q: fragment
> -    ok 10 - host/;abc?q: host_hint
> -    ok 11 - host/;abc?q: parse
> -    ok 12 - host/;abc?q: scheme
> -    ok 13 - host/;abc?q: login
> -    ok 14 - host/;abc?q: password
> -    ok 15 - host/;abc?q: host
> -    ok 16 - host/;abc?q: service
> -    ok 17 - host/;abc?q: path
> -    ok 18 - host/;abc?q: query
> -    ok 19 - host/;abc?q: fragment
> -ok 29 - subtests
> -    1..19
> -    ok 1 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: parse
> -    ok 2 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: scheme
> -    ok 3 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: login
> -    ok 4 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: password
> -    ok 5 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: host
> -    ok 6 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: service
> -    ok 7 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: path
> -    ok 8 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: query
> -    ok 9 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: fragment
> -    ok 10 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: host_hint
> -    ok 11 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: parse
> -    ok 12 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: scheme
> -    ok 13 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: login
> -    ok 14 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: password
> -    ok 15 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: host
> -    ok 16 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: service
> -    ok 17 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: path
> -    ok 18 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: query
> -    ok 19 - scheme://login:password@host:service/@path1/:path2?q1=v1&q2=v2#fragment: fragment
> -ok 30 - subtests
> -    1..19
> -    ok 1 - host/~user: parse
> -    ok 2 - host/~user: scheme
> -    ok 3 - host/~user: login
> -    ok 4 - host/~user: password
> -    ok 5 - host/~user: host
> -    ok 6 - host/~user: service
> -    ok 7 - host/~user: path
> -    ok 8 - host/~user: query
> -    ok 9 - host/~user: fragment
> -    ok 10 - host/~user: host_hint
> -    ok 11 - host/~user: parse
> -    ok 12 - host/~user: scheme
> -    ok 13 - host/~user: login
> -    ok 14 - host/~user: password
> -    ok 15 - host/~user: host
> -    ok 16 - host/~user: service
> -    ok 17 - host/~user: path
> -    ok 18 - host/~user: query
> -    ok 19 - host/~user: fragment
> -ok 31 - subtests
> -    1..19
> -    ok 1 - try.tarantool.org: parse
> -    ok 2 - try.tarantool.org: scheme
> -    ok 3 - try.tarantool.org: login
> -    ok 4 - try.tarantool.org: password
> -    ok 5 - try.tarantool.org: host
> -    ok 6 - try.tarantool.org: service
> -    ok 7 - try.tarantool.org: path
> -    ok 8 - try.tarantool.org: query
> -    ok 9 - try.tarantool.org: fragment
> -    ok 10 - try.tarantool.org: host_hint
> -    ok 11 - try.tarantool.org: parse
> -    ok 12 - try.tarantool.org: scheme
> -    ok 13 - try.tarantool.org: login
> -    ok 14 - try.tarantool.org: password
> -    ok 15 - try.tarantool.org: host
> -    ok 16 - try.tarantool.org: service
> -    ok 17 - try.tarantool.org: path
> -    ok 18 - try.tarantool.org: query
> -    ok 19 - try.tarantool.org: fragment
> -ok 32 - subtests
> -    1..19
> -    ok 1 - try.tarantool.org: parse
> -    ok 2 - try.tarantool.org: scheme
> -    ok 3 - try.tarantool.org: login
> -    ok 4 - try.tarantool.org: password
> -    ok 5 - try.tarantool.org: host
> -    ok 6 - try.tarantool.org: service
> -    ok 7 - try.tarantool.org: path
> -    ok 8 - try.tarantool.org: query
> -    ok 9 - try.tarantool.org: fragment
> -    ok 10 - try.tarantool.org: host_hint
> -    ok 11 - try.tarantool.org: parse
> -    ok 12 - try.tarantool.org: scheme
> -    ok 13 - try.tarantool.org: login
> -    ok 14 - try.tarantool.org: password
> -    ok 15 - try.tarantool.org: host
> -    ok 16 - try.tarantool.org: service
> -    ok 17 - try.tarantool.org: path
> -    ok 18 - try.tarantool.org: query
> -    ok 19 - try.tarantool.org: fragment
> -ok 33 - subtests
> -    1..19
> -    ok 1 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: parse
> -    ok 2 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: scheme
> -    ok 3 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: login
> -    ok 4 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: password
> -    ok 5 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: host
> -    ok 6 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: service
> -    ok 7 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: path
> -    ok 8 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: query
> -    ok 9 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: fragment
> -    ok 10 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: host_hint
> -    ok 11 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: parse
> -    ok 12 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: scheme
> -    ok 13 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: login
> -    ok 14 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: password
> -    ok 15 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: host
> -    ok 16 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: service
> -    ok 17 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: path
> -    ok 18 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: query
> -    ok 19 - www.llanfairpwllgwyngyllgogerychwyrndrobwyll-llantysiliogogogoch.com: fragment
> -ok 34 - subtests
> -    1..19
> -    ok 1 - 0.0.0.0: parse
> -    ok 2 - 0.0.0.0: scheme
> -    ok 3 - 0.0.0.0: login
> -    ok 4 - 0.0.0.0: password
> -    ok 5 - 0.0.0.0: host
> -    ok 6 - 0.0.0.0: service
> -    ok 7 - 0.0.0.0: path
> -    ok 8 - 0.0.0.0: query
> -    ok 9 - 0.0.0.0: fragment
> -    ok 10 - 0.0.0.0: host_hint
> -    ok 11 - 0.0.0.0: parse
> -    ok 12 - 0.0.0.0: scheme
> -    ok 13 - 0.0.0.0: login
> -    ok 14 - 0.0.0.0: password
> -    ok 15 - 0.0.0.0: host
> -    ok 16 - 0.0.0.0: service
> -    ok 17 - 0.0.0.0: path
> -    ok 18 - 0.0.0.0: query
> -    ok 19 - 0.0.0.0: fragment
> -ok 35 - subtests
> -    1..19
> -    ok 1 - 127.0.0.1: parse
> -    ok 2 - 127.0.0.1: scheme
> -    ok 3 - 127.0.0.1: login
> -    ok 4 - 127.0.0.1: password
> -    ok 5 - 127.0.0.1: host
> -    ok 6 - 127.0.0.1: service
> -    ok 7 - 127.0.0.1: path
> -    ok 8 - 127.0.0.1: query
> -    ok 9 - 127.0.0.1: fragment
> -    ok 10 - 127.0.0.1: host_hint
> -    ok 11 - 127.0.0.1: parse
> -    ok 12 - 127.0.0.1: scheme
> -    ok 13 - 127.0.0.1: login
> -    ok 14 - 127.0.0.1: password
> -    ok 15 - 127.0.0.1: host
> -    ok 16 - 127.0.0.1: service
> -    ok 17 - 127.0.0.1: path
> -    ok 18 - 127.0.0.1: query
> -    ok 19 - 127.0.0.1: fragment
> -ok 36 - subtests
> -    1..19
> -    ok 1 - 127.0.0.1:3313: parse
> -    ok 2 - 127.0.0.1:3313: scheme
> -    ok 3 - 127.0.0.1:3313: login
> -    ok 4 - 127.0.0.1:3313: password
> -    ok 5 - 127.0.0.1:3313: host
> -    ok 6 - 127.0.0.1:3313: service
> -    ok 7 - 127.0.0.1:3313: path
> -    ok 8 - 127.0.0.1:3313: query
> -    ok 9 - 127.0.0.1:3313: fragment
> -    ok 10 - 127.0.0.1:3313: host_hint
> -    ok 11 - 127.0.0.1:3313: parse
> -    ok 12 - 127.0.0.1:3313: scheme
> -    ok 13 - 127.0.0.1:3313: login
> -    ok 14 - 127.0.0.1:3313: password
> -    ok 15 - 127.0.0.1:3313: host
> -    ok 16 - 127.0.0.1:3313: service
> -    ok 17 - 127.0.0.1:3313: path
> -    ok 18 - 127.0.0.1:3313: query
> -    ok 19 - 127.0.0.1:3313: fragment
> -ok 37 - subtests
> -    1..19
> -    ok 1 - scheme://login:password@127.0.0.1:3313: parse
> -    ok 2 - scheme://login:password@127.0.0.1:3313: scheme
> -    ok 3 - scheme://login:password@127.0.0.1:3313: login
> -    ok 4 - scheme://login:password@127.0.0.1:3313: password
> -    ok 5 - scheme://login:password@127.0.0.1:3313: host
> -    ok 6 - scheme://login:password@127.0.0.1:3313: service
> -    ok 7 - scheme://login:password@127.0.0.1:3313: path
> -    ok 8 - scheme://login:password@127.0.0.1:3313: query
> -    ok 9 - scheme://login:password@127.0.0.1:3313: fragment
> -    ok 10 - scheme://login:password@127.0.0.1:3313: host_hint
> -    ok 11 - scheme://login:password@127.0.0.1:3313: parse
> -    ok 12 - scheme://login:password@127.0.0.1:3313: scheme
> -    ok 13 - scheme://login:password@127.0.0.1:3313: login
> -    ok 14 - scheme://login:password@127.0.0.1:3313: password
> -    ok 15 - scheme://login:password@127.0.0.1:3313: host
> -    ok 16 - scheme://login:password@127.0.0.1:3313: service
> -    ok 17 - scheme://login:password@127.0.0.1:3313: path
> -    ok 18 - scheme://login:password@127.0.0.1:3313: query
> -    ok 19 - scheme://login:password@127.0.0.1:3313: fragment
> -ok 38 - subtests
> -    1..19
> -    ok 1 - [2001::11a3:09d7::1]: parse
> -    ok 2 - [2001::11a3:09d7::1]: scheme
> -    ok 3 - [2001::11a3:09d7::1]: login
> -    ok 4 - [2001::11a3:09d7::1]: password
> -    ok 5 - [2001::11a3:09d7::1]: host
> -    ok 6 - [2001::11a3:09d7::1]: service
> -    ok 7 - [2001::11a3:09d7::1]: path
> -    ok 8 - [2001::11a3:09d7::1]: query
> -    ok 9 - [2001::11a3:09d7::1]: fragment
> -    ok 10 - [2001::11a3:09d7::1]: host_hint
> -    ok 11 - [2001::11a3:09d7::1]: parse
> -    ok 12 - [2001::11a3:09d7::1]: scheme
> -    ok 13 - [2001::11a3:09d7::1]: login
> -    ok 14 - [2001::11a3:09d7::1]: password
> -    ok 15 - [2001::11a3:09d7::1]: host
> -    ok 16 - [2001::11a3:09d7::1]: service
> -    ok 17 - [2001::11a3:09d7::1]: path
> -    ok 18 - [2001::11a3:09d7::1]: query
> -    ok 19 - [2001::11a3:09d7::1]: fragment
> -ok 39 - subtests
> -    1..19
> -    ok 1 - scheme://login:password@[2001::11a3:09d7::1]:3313: parse
> -    ok 2 - scheme://login:password@[2001::11a3:09d7::1]:3313: scheme
> -    ok 3 - scheme://login:password@[2001::11a3:09d7::1]:3313: login
> -    ok 4 - scheme://login:password@[2001::11a3:09d7::1]:3313: password
> -    ok 5 - scheme://login:password@[2001::11a3:09d7::1]:3313: host
> -    ok 6 - scheme://login:password@[2001::11a3:09d7::1]:3313: service
> -    ok 7 - scheme://login:password@[2001::11a3:09d7::1]:3313: path
> -    ok 8 - scheme://login:password@[2001::11a3:09d7::1]:3313: query
> -    ok 9 - scheme://login:password@[2001::11a3:09d7::1]:3313: fragment
> -    ok 10 - scheme://login:password@[2001::11a3:09d7::1]:3313: host_hint
> -    ok 11 - scheme://login:password@[2001::11a3:09d7::1]:3313: parse
> -    ok 12 - scheme://login:password@[2001::11a3:09d7::1]:3313: scheme
> -    ok 13 - scheme://login:password@[2001::11a3:09d7::1]:3313: login
> -    ok 14 - scheme://login:password@[2001::11a3:09d7::1]:3313: password
> -    ok 15 - scheme://login:password@[2001::11a3:09d7::1]:3313: host
> -    ok 16 - scheme://login:password@[2001::11a3:09d7::1]:3313: service
> -    ok 17 - scheme://login:password@[2001::11a3:09d7::1]:3313: path
> -    ok 18 - scheme://login:password@[2001::11a3:09d7::1]:3313: query
> -    ok 19 - scheme://login:password@[2001::11a3:09d7::1]:3313: fragment
> -ok 40 - subtests
> -    1..19
> -    ok 1 - scheme://[2001:0db8:11a3:09d7::1]: parse
> -    ok 2 - scheme://[2001:0db8:11a3:09d7::1]: scheme
> -    ok 3 - scheme://[2001:0db8:11a3:09d7::1]: login
> -    ok 4 - scheme://[2001:0db8:11a3:09d7::1]: password
> -    ok 5 - scheme://[2001:0db8:11a3:09d7::1]: host
> -    ok 6 - scheme://[2001:0db8:11a3:09d7::1]: service
> -    ok 7 - scheme://[2001:0db8:11a3:09d7::1]: path
> -    ok 8 - scheme://[2001:0db8:11a3:09d7::1]: query
> -    ok 9 - scheme://[2001:0db8:11a3:09d7::1]: fragment
> -    ok 10 - scheme://[2001:0db8:11a3:09d7::1]: host_hint
> -    ok 11 - scheme://[2001:0db8:11a3:09d7::1]: parse
> -    ok 12 - scheme://[2001:0db8:11a3:09d7::1]: scheme
> -    ok 13 - scheme://[2001:0db8:11a3:09d7::1]: login
> -    ok 14 - scheme://[2001:0db8:11a3:09d7::1]: password
> -    ok 15 - scheme://[2001:0db8:11a3:09d7::1]: host
> -    ok 16 - scheme://[2001:0db8:11a3:09d7::1]: service
> -    ok 17 - scheme://[2001:0db8:11a3:09d7::1]: path
> -    ok 18 - scheme://[2001:0db8:11a3:09d7::1]: query
> -    ok 19 - scheme://[2001:0db8:11a3:09d7::1]: fragment
> -ok 41 - subtests
> -    1..19
> -    ok 1 - [::ffff:11.2.3.4]: parse
> -    ok 2 - [::ffff:11.2.3.4]: scheme
> -    ok 3 - [::ffff:11.2.3.4]: login
> -    ok 4 - [::ffff:11.2.3.4]: password
> -    ok 5 - [::ffff:11.2.3.4]: host
> -    ok 6 - [::ffff:11.2.3.4]: service
> -    ok 7 - [::ffff:11.2.3.4]: path
> -    ok 8 - [::ffff:11.2.3.4]: query
> -    ok 9 - [::ffff:11.2.3.4]: fragment
> -    ok 10 - [::ffff:11.2.3.4]: host_hint
> -    ok 11 - [::ffff:11.2.3.4]: parse
> -    ok 12 - [::ffff:11.2.3.4]: scheme
> -    ok 13 - [::ffff:11.2.3.4]: login
> -    ok 14 - [::ffff:11.2.3.4]: password
> -    ok 15 - [::ffff:11.2.3.4]: host
> -    ok 16 - [::ffff:11.2.3.4]: service
> -    ok 17 - [::ffff:11.2.3.4]: path
> -    ok 18 - [::ffff:11.2.3.4]: query
> -    ok 19 - [::ffff:11.2.3.4]: fragment
> -ok 42 - subtests
> -    1..19
> -    ok 1 - scheme://login:password@[::ffff:11.2.3.4]:3313: parse
> -    ok 2 - scheme://login:password@[::ffff:11.2.3.4]:3313: scheme
> -    ok 3 - scheme://login:password@[::ffff:11.2.3.4]:3313: login
> -    ok 4 - scheme://login:password@[::ffff:11.2.3.4]:3313: password
> -    ok 5 - scheme://login:password@[::ffff:11.2.3.4]:3313: host
> -    ok 6 - scheme://login:password@[::ffff:11.2.3.4]:3313: service
> -    ok 7 - scheme://login:password@[::ffff:11.2.3.4]:3313: path
> -    ok 8 - scheme://login:password@[::ffff:11.2.3.4]:3313: query
> -    ok 9 - scheme://login:password@[::ffff:11.2.3.4]:3313: fragment
> -    ok 10 - scheme://login:password@[::ffff:11.2.3.4]:3313: host_hint
> -    ok 11 - scheme://login:password@[::ffff:11.2.3.4]:3313: parse
> -    ok 12 - scheme://login:password@[::ffff:11.2.3.4]:3313: scheme
> -    ok 13 - scheme://login:password@[::ffff:11.2.3.4]:3313: login
> -    ok 14 - scheme://login:password@[::ffff:11.2.3.4]:3313: password
> -    ok 15 - scheme://login:password@[::ffff:11.2.3.4]:3313: host
> -    ok 16 - scheme://login:password@[::ffff:11.2.3.4]:3313: service
> -    ok 17 - scheme://login:password@[::ffff:11.2.3.4]:3313: path
> -    ok 18 - scheme://login:password@[::ffff:11.2.3.4]:3313: query
> -    ok 19 - scheme://login:password@[::ffff:11.2.3.4]:3313: fragment
> -ok 43 - subtests
> -    1..19
> -    ok 1 - 1: parse
> -    ok 2 - 1: scheme
> -    ok 3 - 1: login
> -    ok 4 - 1: password
> -    ok 5 - 1: host
> -    ok 6 - 1: service
> -    ok 7 - 1: path
> -    ok 8 - 1: query
> -    ok 9 - 1: fragment
> -    ok 10 - 1: host_hint
> -    ok 11 - 1: parse
> -    ok 12 - 1: scheme
> -    ok 13 - 1: login
> -    ok 14 - 1: password
> -    ok 15 - 1: host
> -    ok 16 - 1: service
> -    ok 17 - 1: path
> -    ok 18 - 1: query
> -    ok 19 - 1: fragment
> -ok 44 - subtests
> -    1..19
> -    ok 1 - 10: parse
> -    ok 2 - 10: scheme
> -    ok 3 - 10: login
> -    ok 4 - 10: password
> -    ok 5 - 10: host
> -    ok 6 - 10: service
> -    ok 7 - 10: path
> -    ok 8 - 10: query
> -    ok 9 - 10: fragment
> -    ok 10 - 10: host_hint
> -    ok 11 - 10: parse
> -    ok 12 - 10: scheme
> -    ok 13 - 10: login
> -    ok 14 - 10: password
> -    ok 15 - 10: host
> -    ok 16 - 10: service
> -    ok 17 - 10: path
> -    ok 18 - 10: query
> -    ok 19 - 10: fragment
> -ok 45 - subtests
> -    1..19
> -    ok 1 - 331: parse
> -    ok 2 - 331: scheme
> -    ok 3 - 331: login
> -    ok 4 - 331: password
> -    ok 5 - 331: host
> -    ok 6 - 331: service
> -    ok 7 - 331: path
> -    ok 8 - 331: query
> -    ok 9 - 331: fragment
> -    ok 10 - 331: host_hint
> -    ok 11 - 331: parse
> -    ok 12 - 331: scheme
> -    ok 13 - 331: login
> -    ok 14 - 331: password
> -    ok 15 - 331: host
> -    ok 16 - 331: service
> -    ok 17 - 331: path
> -    ok 18 - 331: query
> -    ok 19 - 331: fragment
> -ok 46 - subtests
> -    1..19
> -    ok 1 - 3313: parse
> -    ok 2 - 3313: scheme
> -    ok 3 - 3313: login
> -    ok 4 - 3313: password
> -    ok 5 - 3313: host
> -    ok 6 - 3313: service
> -    ok 7 - 3313: path
> -    ok 8 - 3313: query
> -    ok 9 - 3313: fragment
> -    ok 10 - 3313: host_hint
> -    ok 11 - 3313: parse
> -    ok 12 - 3313: scheme
> -    ok 13 - 3313: login
> -    ok 14 - 3313: password
> -    ok 15 - 3313: host
> -    ok 16 - 3313: service
> -    ok 17 - 3313: path
> -    ok 18 - 3313: query
> -    ok 19 - 3313: fragment
> -ok 47 - subtests
> -    1..19
> -    ok 1 - /: parse
> -    ok 2 - /: scheme
> -    ok 3 - /: login
> -    ok 4 - /: password
> -    ok 5 - /: host
> -    ok 6 - /: service
> -    ok 7 - /: path
> -    ok 8 - /: query
> -    ok 9 - /: fragment
> -    ok 10 - /: host_hint
> -    ok 11 - /: parse
> -    ok 12 - /: scheme
> -    ok 13 - /: login
> -    ok 14 - /: password
> -    ok 15 - /: host
> -    ok 16 - /: service
> -    ok 17 - /: path
> -    ok 18 - /: query
> -    ok 19 - /: fragment
> -ok 48 - subtests
> -    1..19
> -    ok 1 - /path1/path2/path3: parse
> -    ok 2 - /path1/path2/path3: scheme
> -    ok 3 - /path1/path2/path3: login
> -    ok 4 - /path1/path2/path3: password
> -    ok 5 - /path1/path2/path3: host
> -    ok 6 - /path1/path2/path3: service
> -    ok 7 - /path1/path2/path3: path
> -    ok 8 - /path1/path2/path3: query
> -    ok 9 - /path1/path2/path3: fragment
> -    ok 10 - /path1/path2/path3: host_hint
> -    ok 11 - /path1/path2/path3: parse
> -    ok 12 - /path1/path2/path3: scheme
> -    ok 13 - /path1/path2/path3: login
> -    ok 14 - /path1/path2/path3: password
> -    ok 15 - /path1/path2/path3: host
> -    ok 16 - /path1/path2/path3: service
> -    ok 17 - /path1/path2/path3: path
> -    ok 18 - /path1/path2/path3: query
> -    ok 19 - /path1/path2/path3: fragment
> -ok 49 - subtests
> -    1..19
> -    ok 1 - login:password@/path1/path2/path3: parse
> -    ok 2 - login:password@/path1/path2/path3: scheme
> -    ok 3 - login:password@/path1/path2/path3: login
> -    ok 4 - login:password@/path1/path2/path3: password
> -    ok 5 - login:password@/path1/path2/path3: host
> -    ok 6 - login:password@/path1/path2/path3: service
> -    ok 7 - login:password@/path1/path2/path3: path
> -    ok 8 - login:password@/path1/path2/path3: query
> -    ok 9 - login:password@/path1/path2/path3: fragment
> -    ok 10 - login:password@/path1/path2/path3: host_hint
> -    ok 11 - login:password@/path1/path2/path3: parse
> -    ok 12 - login:password@/path1/path2/path3: scheme
> -    ok 13 - login:password@/path1/path2/path3: login
> -    ok 14 - login:password@/path1/path2/path3: password
> -    ok 15 - login:password@/path1/path2/path3: host
> -    ok 16 - login:password@/path1/path2/path3: service
> -    ok 17 - login:password@/path1/path2/path3: path
> -    ok 18 - login:password@/path1/path2/path3: query
> -    ok 19 - login:password@/path1/path2/path3: fragment
> -ok 50 - subtests
> -    1..19
> -    ok 1 - unix/:/path1/path2/path3: parse
> -    ok 2 - unix/:/path1/path2/path3: scheme
> -    ok 3 - unix/:/path1/path2/path3: login
> -    ok 4 - unix/:/path1/path2/path3: password
> -    ok 5 - unix/:/path1/path2/path3: host
> -    ok 6 - unix/:/path1/path2/path3: service
> -    ok 7 - unix/:/path1/path2/path3: path
> -    ok 8 - unix/:/path1/path2/path3: query
> -    ok 9 - unix/:/path1/path2/path3: fragment
> -    ok 10 - unix/:/path1/path2/path3: host_hint
> -    ok 11 - unix/:/path1/path2/path3: parse
> -    ok 12 - unix/:/path1/path2/path3: scheme
> -    ok 13 - unix/:/path1/path2/path3: login
> -    ok 14 - unix/:/path1/path2/path3: password
> -    ok 15 - unix/:/path1/path2/path3: host
> -    ok 16 - unix/:/path1/path2/path3: service
> -    ok 17 - unix/:/path1/path2/path3: path
> -    ok 18 - unix/:/path1/path2/path3: query
> -    ok 19 - unix/:/path1/path2/path3: fragment
> -ok 51 - subtests
> -    1..19
> -    ok 1 - unix/:/path1/path2/path3:: parse
> -    ok 2 - unix/:/path1/path2/path3:: scheme
> -    ok 3 - unix/:/path1/path2/path3:: login
> -    ok 4 - unix/:/path1/path2/path3:: password
> -    ok 5 - unix/:/path1/path2/path3:: host
> -    ok 6 - unix/:/path1/path2/path3:: service
> -    ok 7 - unix/:/path1/path2/path3:: path
> -    ok 8 - unix/:/path1/path2/path3:: query
> -    ok 9 - unix/:/path1/path2/path3:: fragment
> -    ok 10 - unix/:/path1/path2/path3:: host_hint
> -    ok 11 - unix/:/path1/path2/path3:: parse
> -    ok 12 - unix/:/path1/path2/path3:: scheme
> -    ok 13 - unix/:/path1/path2/path3:: login
> -    ok 14 - unix/:/path1/path2/path3:: password
> -    ok 15 - unix/:/path1/path2/path3:: host
> -    ok 16 - unix/:/path1/path2/path3:: service
> -    ok 17 - unix/:/path1/path2/path3:: path
> -    ok 18 - unix/:/path1/path2/path3:: query
> -    ok 19 - unix/:/path1/path2/path3:: fragment
> -ok 52 - subtests
> -    1..19
> -    ok 1 - unix/:/path1/path2/path3:/: parse
> -    ok 2 - unix/:/path1/path2/path3:/: scheme
> -    ok 3 - unix/:/path1/path2/path3:/: login
> -    ok 4 - unix/:/path1/path2/path3:/: password
> -    ok 5 - unix/:/path1/path2/path3:/: host
> -    ok 6 - unix/:/path1/path2/path3:/: service
> -    ok 7 - unix/:/path1/path2/path3:/: path
> -    ok 8 - unix/:/path1/path2/path3:/: query
> -    ok 9 - unix/:/path1/path2/path3:/: fragment
> -    ok 10 - unix/:/path1/path2/path3:/: host_hint
> -    ok 11 - unix/:/path1/path2/path3:/: parse
> -    ok 12 - unix/:/path1/path2/path3:/: scheme
> -    ok 13 - unix/:/path1/path2/path3:/: login
> -    ok 14 - unix/:/path1/path2/path3:/: password
> -    ok 15 - unix/:/path1/path2/path3:/: host
> -    ok 16 - unix/:/path1/path2/path3:/: service
> -    ok 17 - unix/:/path1/path2/path3:/: path
> -    ok 18 - unix/:/path1/path2/path3:/: query
> -    ok 19 - unix/:/path1/path2/path3:/: fragment
> -ok 53 - subtests
> -    1..19
> -    ok 1 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 2 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 3 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 4 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 5 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 6 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 7 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 8 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 9 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -    ok 10 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: host_hint
> -    ok 11 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: parse
> -    ok 12 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: scheme
> -    ok 13 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: login
> -    ok 14 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: password
> -    ok 15 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: host
> -    ok 16 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: service
> -    ok 17 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: path
> -    ok 18 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: query
> -    ok 19 - unix/:/path1/path2/path3?q1=v1&q2=v2#fragment: fragment
> -ok 54 - subtests
> -    1..19
> -    ok 1 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: parse
> -    ok 2 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: scheme
> -    ok 3 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: login
> -    ok 4 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: password
> -    ok 5 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: host
> -    ok 6 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: service
> -    ok 7 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: path
> -    ok 8 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: query
> -    ok 9 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: fragment
> -    ok 10 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: host_hint
> -    ok 11 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: parse
> -    ok 12 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: scheme
> -    ok 13 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: login
> -    ok 14 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: password
> -    ok 15 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: host
> -    ok 16 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: service
> -    ok 17 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: path
> -    ok 18 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: query
> -    ok 19 - unix/:/path1/path2/path3:/p1/p2?q1=v1&q2=v2#fragment: fragment
> -ok 55 - subtests
> -    1..19
> -    ok 1 - login:password@unix/:/path1/path2/path3: parse
> -    ok 2 - login:password@unix/:/path1/path2/path3: scheme
> -    ok 3 - login:password@unix/:/path1/path2/path3: login
> -    ok 4 - login:password@unix/:/path1/path2/path3: password
> -    ok 5 - login:password@unix/:/path1/path2/path3: host
> -    ok 6 - login:password@unix/:/path1/path2/path3: service
> -    ok 7 - login:password@unix/:/path1/path2/path3: path
> -    ok 8 - login:password@unix/:/path1/path2/path3: query
> -    ok 9 - login:password@unix/:/path1/path2/path3: fragment
> -    ok 10 - login:password@unix/:/path1/path2/path3: host_hint
> -    ok 11 - login:password@unix/:/path1/path2/path3: parse
> -    ok 12 - login:password@unix/:/path1/path2/path3: scheme
> -    ok 13 - login:password@unix/:/path1/path2/path3: login
> -    ok 14 - login:password@unix/:/path1/path2/path3: password
> -    ok 15 - login:password@unix/:/path1/path2/path3: host
> -    ok 16 - login:password@unix/:/path1/path2/path3: service
> -    ok 17 - login:password@unix/:/path1/path2/path3: path
> -    ok 18 - login:password@unix/:/path1/path2/path3: query
> -    ok 19 - login:password@unix/:/path1/path2/path3: fragment
> -ok 56 - subtests
> -    1..19
> -    ok 1 - login:password@unix/:/path1/path2/path3:: parse
> -    ok 2 - login:password@unix/:/path1/path2/path3:: scheme
> -    ok 3 - login:password@unix/:/path1/path2/path3:: login
> -    ok 4 - login:password@unix/:/path1/path2/path3:: password
> -    ok 5 - login:password@unix/:/path1/path2/path3:: host
> -    ok 6 - login:password@unix/:/path1/path2/path3:: service
> -    ok 7 - login:password@unix/:/path1/path2/path3:: path
> -    ok 8 - login:password@unix/:/path1/path2/path3:: query
> -    ok 9 - login:password@unix/:/path1/path2/path3:: fragment
> -    ok 10 - login:password@unix/:/path1/path2/path3:: host_hint
> -    ok 11 - login:password@unix/:/path1/path2/path3:: parse
> -    ok 12 - login:password@unix/:/path1/path2/path3:: scheme
> -    ok 13 - login:password@unix/:/path1/path2/path3:: login
> -    ok 14 - login:password@unix/:/path1/path2/path3:: password
> -    ok 15 - login:password@unix/:/path1/path2/path3:: host
> -    ok 16 - login:password@unix/:/path1/path2/path3:: service
> -    ok 17 - login:password@unix/:/path1/path2/path3:: path
> -    ok 18 - login:password@unix/:/path1/path2/path3:: query
> -    ok 19 - login:password@unix/:/path1/path2/path3:: fragment
> -ok 57 - subtests
> -    1..19
> -    ok 1 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: parse
> -    ok 2 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: scheme
> -    ok 3 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: login
> -    ok 4 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: password
> -    ok 5 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: host
> -    ok 6 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: service
> -    ok 7 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: path
> -    ok 8 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: query
> -    ok 9 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: fragment
> -    ok 10 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: host_hint
> -    ok 11 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: parse
> -    ok 12 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: scheme
> -    ok 13 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: login
> -    ok 14 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: password
> -    ok 15 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: host
> -    ok 16 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: service
> -    ok 17 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: path
> -    ok 18 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: query
> -    ok 19 - scheme://login:password@unix/:/tmp/unix.sock:/path1/path2/path3: fragment
> -ok 58 - subtests
> -    1..19
> -    ok 1 - unix/:./relative/path.sock:/test: parse
> -    ok 2 - unix/:./relative/path.sock:/test: scheme
> -    ok 3 - unix/:./relative/path.sock:/test: login
> -    ok 4 - unix/:./relative/path.sock:/test: password
> -    ok 5 - unix/:./relative/path.sock:/test: host
> -    ok 6 - unix/:./relative/path.sock:/test: service
> -    ok 7 - unix/:./relative/path.sock:/test: path
> -    ok 8 - unix/:./relative/path.sock:/test: query
> -    ok 9 - unix/:./relative/path.sock:/test: fragment
> -    ok 10 - unix/:./relative/path.sock:/test: host_hint
> -    ok 11 - unix/:./relative/path.sock:/test: parse
> -    ok 12 - unix/:./relative/path.sock:/test: scheme
> -    ok 13 - unix/:./relative/path.sock:/test: login
> -    ok 14 - unix/:./relative/path.sock:/test: password
> -    ok 15 - unix/:./relative/path.sock:/test: host
> -    ok 16 - unix/:./relative/path.sock:/test: service
> -    ok 17 - unix/:./relative/path.sock:/test: path
> -    ok 18 - unix/:./relative/path.sock:/test: query
> -    ok 19 - unix/:./relative/path.sock:/test: fragment
> -ok 59 - subtests
> -    1..19
> -    ok 1 - scheme://unix/:./relative/path.sock:/test: parse
> -    ok 2 - scheme://unix/:./relative/path.sock:/test: scheme
> -    ok 3 - scheme://unix/:./relative/path.sock:/test: login
> -    ok 4 - scheme://unix/:./relative/path.sock:/test: password
> -    ok 5 - scheme://unix/:./relative/path.sock:/test: host
> -    ok 6 - scheme://unix/:./relative/path.sock:/test: service
> -    ok 7 - scheme://unix/:./relative/path.sock:/test: path
> -    ok 8 - scheme://unix/:./relative/path.sock:/test: query
> -    ok 9 - scheme://unix/:./relative/path.sock:/test: fragment
> -    ok 10 - scheme://unix/:./relative/path.sock:/test: host_hint
> -    ok 11 - scheme://unix/:./relative/path.sock:/test: parse
> -    ok 12 - scheme://unix/:./relative/path.sock:/test: scheme
> -    ok 13 - scheme://unix/:./relative/path.sock:/test: login
> -    ok 14 - scheme://unix/:./relative/path.sock:/test: password
> -    ok 15 - scheme://unix/:./relative/path.sock:/test: host
> -    ok 16 - scheme://unix/:./relative/path.sock:/test: service
> -    ok 17 - scheme://unix/:./relative/path.sock:/test: path
> -    ok 18 - scheme://unix/:./relative/path.sock:/test: query
> -    ok 19 - scheme://unix/:./relative/path.sock:/test: fragment
> -ok 60 - subtests
> -    1..19
> -    ok 1 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: parse
> -    ok 2 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: scheme
> -    ok 3 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: login
> -    ok 4 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: password
> -    ok 5 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: host
> -    ok 6 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: service
> -    ok 7 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: path
> -    ok 8 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: query
> -    ok 9 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: fragment
> -    ok 10 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: host_hint
> -    ok 11 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: parse
> -    ok 12 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: scheme
> -    ok 13 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: login
> -    ok 14 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: password
> -    ok 15 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: host
> -    ok 16 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: service
> -    ok 17 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: path
> -    ok 18 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: query
> -    ok 19 - http://tarantool.org/dist/master/debian/pool/main/t/tarantool/tarantool_1.6.3+314+g91066ee+20140910+1434.orig.tar.gz: fragment
> -ok 61 - subtests
> -    1..19
> -    ok 1 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: parse
> -    ok 2 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: scheme
> -    ok 3 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: login
> -    ok 4 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: password
> -    ok 5 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: host
> -    ok 6 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: service
> -    ok 7 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: path
> -    ok 8 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: query
> -    ok 9 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: fragment
> -    ok 10 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: host_hint
> -    ok 11 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: parse
> -    ok 12 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: scheme
> -    ok 13 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: login
> -    ok 14 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: password
> -    ok 15 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: host
> -    ok 16 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: service
> -    ok 17 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: path
> -    ok 18 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: query
> -    ok 19 - https://www.google.com/search?safe=off&site=&tbm=isch&source=hp&biw=1918&bih=1109&q=Tarantool&oq=Tarantool&gs_l=img.3..0i24l3j0i10i24j0i24&gws_rd=ssl: fragment
> -ok 62 - subtests
> -    1..2
> -    ok 1 - empty is invalid
> -    ok 2 - :// is invalid
> -ok 63 - subtests
> diff --git a/test/unit/uuid.result b/test/unit/uuid.result
> deleted file mode 100644
> index 50a1140c5..000000000
> --- a/test/unit/uuid.result
> +++ /dev/null
> @@ -1,9 +0,0 @@
> -1..3
> -ok 1 - 6611265b-8852-4832-af8b-4164d52c62eb > 186ebbf7-cf97-4e2e-8b1b-76154f6f3949
> -ok 2 - 075b4148-8fb0-2e7f-af50-4164d52c62eb < 1fbc929f-5da8-28c5-8b36-76154f6f3949
> -    1..4
> -    ok 1 - mp_sizeof_uuid() == encoded length
> -    ok 2 - mp_decode_uuid() return code
> -    ok 3 - mp_sizeof_uuid() == decoded length
> -    ok 4 - mp_decode_uuid(mp_encode_uuid(uu)) == uu
> -ok 3 - subtests
> diff --git a/test/unit/vclock.result b/test/unit/vclock.result
> deleted file mode 100644
> index 2ca741bbd..000000000
> --- a/test/unit/vclock.result
> +++ /dev/null
> @@ -1,149 +0,0 @@
> -1..5
> -    1..40
> -	*** test_compare ***
> -    ok 1 - compare (), () => 0
> -    ok 2 - compare (), () => 0
> -    ok 3 - compare (), (10) => -1
> -    ok 4 - compare (10), () => 1
> -    ok 5 - compare (0), (0) => 0
> -    ok 6 - compare (0), (0) => 0
> -    ok 7 - compare (1), (1) => 0
> -    ok 8 - compare (1), (1) => 0
> -    ok 9 - compare (1), (2) => -1
> -    ok 10 - compare (2), (1) => 1
> -    ok 11 - compare (), (10, 1, 0) => -1
> -    ok 12 - compare (10, 1, 0), () => 1
> -    ok 13 - compare (5), (10, 1, 0) => -1
> -    ok 14 - compare (10, 1, 0), (5) => 1
> -    ok 15 - compare (10), (10, 1, 0) => -1
> -    ok 16 - compare (10, 1, 0), (10) => 1
> -    ok 17 - compare (15), (10, 1, 0) => 2147483647
> -    ok 18 - compare (10, 1, 0), (15) => 2147483647
> -    ok 19 - compare (10, 1, 0), (10, 1, 1) => -1
> -    ok 20 - compare (10, 1, 1), (10, 1, 0) => 1
> -    ok 21 - compare (10, 1, 0), (10, 2, 0) => -1
> -    ok 22 - compare (10, 2, 0), (10, 1, 0) => 1
> -    ok 23 - compare (10, 1, 0), (10, 1, 0) => 0
> -    ok 24 - compare (10, 1, 0), (10, 1, 0) => 0
> -    ok 25 - compare (10, 0, 1), (10, 1, 0) => 2147483647
> -    ok 26 - compare (10, 1, 0), (10, 0, 1) => 2147483647
> -    ok 27 - compare (10, 2, 1), (10, 1, 2) => 2147483647
> -    ok 28 - compare (10, 1, 2), (10, 2, 1) => 2147483647
> -    ok 29 - compare (10, 0, 1), (11, 0, 0) => 2147483647
> -    ok 30 - compare (11, 0, 0), (10, 0, 1) => 2147483647
> -    ok 31 - compare (10, 0, 5), (5, 0, 10) => 2147483647
> -    ok 32 - compare (5, 0, 10), (10, 0, 5) => 2147483647
> -    ok 33 - compare (10, 10, 10), (10, 10, 10) => 0
> -    ok 34 - compare (10, 10, 10), (10, 10, 10) => 0
> -    ok 35 - compare (10, 10, 10), (10, 10, 10, 1) => -1
> -    ok 36 - compare (10, 10, 10, 1), (10, 10, 10) => 1
> -    ok 37 - compare (10, 10, 10), (10, 10, 10, 1, 2, 3) => -1
> -    ok 38 - compare (10, 10, 10, 1, 2, 3), (10, 10, 10) => 1
> -    ok 39 - compare (0, 0, 0), (10, 0, 0, 0, 0) => -1
> -    ok 40 - compare (10, 0, 0, 0, 0), (0, 0, 0) => 1
> -	*** test_compare: done ***
> -ok 1 - subtests
> -    1..36
> -	*** test_isearch ***
> -    ok 1 - query #1
> -    ok 2 - query #2
> -    ok 3 - query #3
> -    ok 4 - query #4
> -    ok 5 - query #5
> -    ok 6 - query #6
> -    ok 7 - query #7
> -    ok 8 - query #8
> -    ok 9 - query #9
> -    ok 10 - query #10
> -    ok 11 - query #11
> -    ok 12 - query #12
> -    ok 13 - query #13
> -    ok 14 - query #14
> -    ok 15 - query #15
> -    ok 16 - query #16
> -    ok 17 - query #17
> -    ok 18 - query #18
> -    ok 19 - query #19
> -    ok 20 - query #20
> -    ok 21 - query #21
> -    ok 22 - query #22
> -    ok 23 - query #23
> -    ok 24 - query #24
> -    ok 25 - query #25
> -    ok 26 - query #26
> -    ok 27 - query #27
> -    ok 28 - query #28
> -    ok 29 - query #29
> -    ok 30 - query #30
> -    ok 31 - query #31
> -    ok 32 - query #32
> -    ok 33 - query #33
> -    ok 34 - query #34
> -    ok 35 - query #35
> -    ok 36 - query #36
> -	*** test_isearch: done ***
> -ok 2 - subtests
> -    1..8
> -	*** test_tostring ***
> -    ok 1 - tostring () => {}
> -    ok 2 - tostring (-1, -1, -1) => {}
> -    ok 3 - tostring (1) => {0: 1}
> -    ok 4 - tostring (1, 2) => {0: 1, 1: 2}
> -    ok 5 - tostring (10, 15, 20) => {0: 10, 1: 15, 2: 20}
> -    ok 6 - tostring (10, -1, 15, -1, 20) => {0: 10, 2: 15, 4: 20}
> -    ok 7 - tostring (0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15) => {1: 1, 2: 2, 3: 3, 4: 4, 5: 5, 6: 6, 7: 7, 8: 8, 9: 9, 10: 10, 11: 11, 12: 12, 13: 13, 14: 14, 15: 15}
> -    ok 8 - tostring (9223372036854775000, 9223372036854775001, 9223372036854775002, 9223372036854775003, 9223372036854775004, 9223372036854775005, 9223372036854775006, 9223372036854775007, 9223372036854775008, 9223372036854775009, 9223372036854775010, 9223372036854775011, 9223372036854775012, 9223372036854775013, 9223372036854775014, 9223372036854775015) => {0: 9223372036854775000, 1: 9223372036854775001, 2: 9223372036854775002, 3: 9223372036854775003, 4: 9223372036854775004, 5: 9223372036854775005, 6: 9223372036854775006, 7: 9223372036854775007, 8: 9223372036854775008, 9: 9223372036854775009, 10: 9223372036854775010, 11: 9223372036854775011, 12: 9223372036854775012, 13: 9223372036854775013, 14: 9223372036854775014, 15: 9223372036854775015}
> -	*** test_tostring: done ***
> -ok 3 - subtests
> -    1..12
> -	*** test_fromstring ***
> -    ok 1 - fromstring {} => ()
> -    ok 2 - fromstring  	 	 { 	 	 } 	 	  => ()
> -    ok 3 - fromstring {0: 10} => (10)
> -    ok 4 - fromstring {0: 10,} => (10)
> -    ok 5 - fromstring {	 0	 :	  10	 ,	 } => (10)
> -    ok 6 - fromstring {0: 10, 1: 15, 3: 20} => (10, 15, -1, 20)
> -    ok 7 - fromstring {2: 20, 0: 10, 4: 30} => (10, -1, 20, -1, 30)
> -    ok 8 - fromstring {4: 30, 2: 20} => (-1, -1, 20, -1, 30)
> -    ok 9 - fromstring {4: 30, 2: 20,} => (-1, -1, 20, -1, 30)
> -    ok 10 - fromstring {0: 4294967295} => (4294967295)
> -    ok 11 - fromstring {0: 4294967296} => (4294967296)
> -    ok 12 - fromstring {0: 9223372036854775807} => (9223372036854775807)
> -	*** test_fromstring: done ***
> -ok 4 - subtests
> -    1..32
> -	*** test_fromstring_invalid ***
> -    ok 1 - fromstring "" => 1
> -    ok 2 - fromstring " " => 2
> -    ok 3 - fromstring "	 	 	 " => 7
> -    ok 4 - fromstring "}" => 1
> -    ok 5 - fromstring "1: 10" => 1
> -    ok 6 - fromstring "abcde" => 1
> -    ok 7 - fromstring "12345" => 1
> -    ok 8 - fromstring "\x01\x02\x03\x04\x05\x06" => 1
> -    ok 9 - fromstring "{" => 2
> -    ok 10 - fromstring "{1	 " => 5
> -    ok 11 - fromstring "{1:	 " => 6
> -    ok 12 - fromstring "{1:10" => 6
> -    ok 13 - fromstring "{1:10	 " => 8
> -    ok 14 - fromstring "{1:10," => 7
> -    ok 15 - fromstring "{1:10,	 	 " => 11
> -    ok 16 - fromstring "{1:10 2:20" => 7
> -    ok 17 - fromstring "{1:10,," => 7
> -    ok 18 - fromstring "{1:10, 10,}" => 10
> -    ok 19 - fromstring "{1:-1}" => 4
> -    ok 20 - fromstring "{-1:1}" => 2
> -    ok 21 - fromstring "{128:1}" => 5
> -    ok 22 - fromstring "{1:abcde}" => 4
> -    ok 23 - fromstring "{abcde:1}" => 2
> -    ok 24 - fromstring "{1:1.1}" => 5
> -    ok 25 - fromstring "{1.1:1}" => 3
> -    ok 26 - fromstring "{4294967296:1}" => 12
> -    ok 27 - fromstring "{1:9223372036854775808}" => 23
> -    ok 28 - fromstring "{1:18446744073709551616}" => 24
> -    ok 29 - fromstring "{1:18446744073709551616}" => 24
> -    ok 30 - fromstring "{1:340282366920938463463374607431768211456}" => 43
> -    ok 31 - fromstring "{1:10, 1:20}" => 12
> -    ok 32 - fromstring "{1:20, 1:10}" => 12
> -	*** test_fromstring_invalid: done ***
> -ok 5 - subtests
> diff --git a/test/unit/vy_cache.result b/test/unit/vy_cache.result
> deleted file mode 100644
> index a67e8edb0..000000000
> --- a/test/unit/vy_cache.result
> +++ /dev/null
> @@ -1,9 +0,0 @@
> -	*** test_basic ***
> -1..6
> -ok 1 - cache is filled with 6 statements
> -ok 2 - cache is filled with 12 statements
> -ok 3 - cache is filled with 18 statements
> -ok 4 - next_key * 4
> -ok 5 - restore
> -ok 6 - restore on position after last
> -	*** test_basic: done ***
> diff --git a/test/unit/vy_mem.c b/test/unit/vy_mem.c
> index 2e461f312..4e136b72b 100644
> --- a/test/unit/vy_mem.c
> +++ b/test/unit/vy_mem.c
> @@ -9,7 +9,7 @@ test_basic(void)
>  {
>  	header();
>  
> -	plan(12);
> +	plan(9);
>  
>  	/* Create key_def */
>  	uint32_t fields[] = { 0 };
> @@ -334,11 +334,13 @@ test_iterator_restore_after_insertion()
>  int
>  main(int argc, char *argv[])
>  {
> +	plan(2);
>  	vy_iterator_C_test_init(0);
>  
>  	test_basic();
>  	test_iterator_restore_after_insertion();
>  
>  	vy_iterator_C_test_finish();
> +	check_plan();
>  	return 0;
>  }
> diff --git a/test/unit/vy_mem.result b/test/unit/vy_mem.result
> deleted file mode 100644
> index 5c9c7af58..000000000
> --- a/test/unit/vy_mem.result
> +++ /dev/null
> @@ -1,17 +0,0 @@
> -# Looks like you planned 12 tests but ran 9.
> -	*** test_basic ***
> -1..12
> -ok 1 - mem->dump_lsn on empty mem
> -ok 2 - mem->dump_lsn after prepare
> -ok 3 - mem->dump_lsn after commit
> -ok 4 - vy_mem_older_lsn 1
> -ok 5 - vy_mem_older_lsn 2
> -ok 6 - vy_mem_rollback 1
> -ok 7 - vy_mem_rollback 2
> -ok 8 - vy_mem->version
> -ok 9 - vy_mem->version
> -	*** test_basic: done ***
> -	*** test_iterator_restore_after_insertion ***
> -1..1
> -ok 1 - check wrong_output 0
> -	*** test_iterator_restore_after_insertion: done ***
> diff --git a/test/unit/vy_point_lookup.result b/test/unit/vy_point_lookup.result
> deleted file mode 100644
> index 4e68dda6d..000000000
> --- a/test/unit/vy_point_lookup.result
> +++ /dev/null
> @@ -1,20 +0,0 @@
> -1..1
> -	*** test_basic ***
> -    1..15
> -    ok 1 - vy_lsm_env_create
> -    ok 2 - key_def is not NULL
> -    ok 3 - tuple_format_new is not NULL
> -    ok 4 - lsm is not NULL
> -    ok 5 - range is not NULL
> -    ok 6 - temp dir name is not NULL
> -    ok 7 - temp dir create (2)
> -    ok 8 - temp dir create (3)
> -    ok 9 - vy_lsm_rotate_mem
> -    ok 10 - vy_run_new
> -    ok 11 - vy_run_write
> -    ok 12 - vy_run_new
> -    ok 13 - vy_run_write
> -    ok 14 - select results
> -    ok 15 - no errors happened
> -ok 1 - subtests
> -	*** test_basic: done ***
> diff --git a/test/unit/vy_write_iterator.result b/test/unit/vy_write_iterator.result
> deleted file mode 100644
> index a80116852..000000000
> --- a/test/unit/vy_write_iterator.result
> +++ /dev/null
> @@ -1,61 +0,0 @@
> -	*** test_basic ***
> -1..58
> -ok 1 - stmt 0 is correct
> -ok 2 - stmt 1 is correct
> -ok 3 - stmt 2 is correct
> -ok 4 - stmt 3 is correct
> -ok 5 - correct results count
> -ok 6 - stmt 0 is correct
> -ok 7 - stmt 1 is correct
> -ok 8 - stmt 2 is correct
> -ok 9 - stmt 3 is correct
> -ok 10 - correct results count
> -ok 11 - stmt 0 is correct
> -ok 12 - stmt 1 is correct
> -ok 13 - correct results count
> -ok 14 - stmt 0 is correct
> -ok 15 - stmt 1 is correct
> -ok 16 - correct results count
> -ok 17 - stmt 0 is correct
> -ok 18 - correct results count
> -ok 19 - stmt 0 is correct
> -ok 20 - stmt 1 is correct
> -ok 21 - correct results count
> -ok 22 - stmt 0 is correct
> -ok 23 - stmt 1 is correct
> -ok 24 - correct results count
> -ok 25 - stmt 0 is correct
> -ok 26 - stmt 1 is correct
> -ok 27 - stmt 2 is correct
> -ok 28 - correct results count
> -ok 29 - stmt 0 is correct
> -ok 30 - correct results count
> -ok 31 - stmt 0 is correct
> -ok 32 - stmt 1 is correct
> -ok 33 - stmt 2 is correct
> -ok 34 - correct results count
> -ok 35 - stmt 0 is correct
> -ok 36 - stmt 1 is correct
> -ok 37 - stmt 2 is correct
> -ok 38 - correct results count
> -ok 39 - stmt 0 is correct
> -ok 40 - stmt 1 is correct
> -ok 41 - stmt 2 is correct
> -ok 42 - correct results count
> -ok 43 - deferred stmt 0 is correct
> -ok 44 - deferred stmt 1 is correct
> -ok 45 - deferred stmt 2 is correct
> -ok 46 - deferred stmt 3 is correct
> -ok 47 - correct deferred stmt count
> -ok 48 - stmt 0 is correct
> -ok 49 - stmt 1 is correct
> -ok 50 - correct results count
> -ok 51 - correct deferred stmt count
> -ok 52 - stmt 0 is correct
> -ok 53 - stmt 1 is correct
> -ok 54 - correct results count
> -ok 55 - correct deferred stmt count
> -ok 56 - stmt 0 is correct
> -ok 57 - correct results count
> -ok 58 - correct deferred stmt count
> -	*** test_basic: done ***
> diff --git a/test/unit/xrow.result b/test/unit/xrow.result
> deleted file mode 100644
> index 5ee92ad7b..000000000
> --- a/test/unit/xrow.result
> +++ /dev/null
> @@ -1,58 +0,0 @@
> -1..3
> -    1..40
> -    ok 1 - round trip
> -    ok 2 - roundtrip.version_id
> -    ok 3 - roundtrip.protocol
> -    ok 4 - roundtrip.uuid
> -    ok 5 - roundtrip.salt_len
> -    ok 6 - roundtrip.salt
> -    ok 7 - decode iproto
> -    ok 8 - iproto.version_id
> -    ok 9 - iproto.protocol
> -    ok 10 - iproto.uuid
> -    ok 11 - iproto.salt_len
> -    ok 12 - iproto.salt
> -    ok 13 - decode lua
> -    ok 14 - lua.version_id
> -    ok 15 - lua.protocol
> -    ok 16 - lua.uuid
> -    ok 17 - lua.salt_len
> -    ok 18 - decode iproto166
> -    ok 19 - iproto166.version_id
> -    ok 20 - iproto166.protocol
> -    ok 21 - iproto166.uuid
> -    ok 22 - iproto166.salt_len
> -    ok 23 - iproto166.salt
> -    ok 24 - decode lua166
> -    ok 25 - lua166.version_id
> -    ok 26 - lua166.protocol
> -    ok 27 - lua166.uuid
> -    ok 28 - lua166.salt_len
> -    ok 29 - invalid 0
> -    ok 30 - invalid 1
> -    ok 31 - invalid 2
> -    ok 32 - invalid 3
> -    ok 33 - invalid 4
> -    ok 34 - invalid 5
> -    ok 35 - invalid 6
> -    ok 36 - invalid 7
> -    ok 37 - invalid 8
> -    ok 38 - invalid 9
> -    ok 39 - invalid 10
> -    ok 40 - invalid 11
> -ok 1 - subtests
> -    1..10
> -    ok 1 - bad msgpack end
> -    ok 2 - encode
> -    ok 3 - header map size
> -    ok 4 - header decode
> -    ok 5 - decoded type
> -    ok 6 - decoded replica_id
> -    ok 7 - decoded lsn
> -    ok 8 - decoded tm
> -    ok 9 - decoded sync
> -    ok 10 - decoded bodycnt
> -ok 2 - subtests
> -    1..1
> -    ok 1 - request_str
> -ok 3 - subtests
> -- 
> 2.23.0
> 

-- 
sergeyb@

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Tarantool-patches] [PATCH 0/2] Make unit tests TAP-compliant
  2020-05-21  9:59 [Tarantool-patches] [PATCH 0/2] Make unit tests TAP-compliant sergeyb
  2020-05-21  9:59 ` [Tarantool-patches] [PATCH 1/2] test: update unit test lib to produce TAP-compliant output sergeyb
  2020-05-21  9:59 ` [Tarantool-patches] [PATCH 2/2] test: update unit tests to make them TAP-compliant sergeyb
@ 2020-06-02  9:21 ` Sergey Bronnikov
  2020-06-03 22:52 ` Vladislav Shpilevoy
  3 siblings, 0 replies; 12+ messages in thread
From: Sergey Bronnikov @ 2020-06-02  9:21 UTC (permalink / raw)
  To: tarantool-patches, Vladislav Shpilevoy

Vladislav,

please review patches.

On 12:59 Thu 21 May , sergeyb@tarantool.org wrote:
> From: Sergey Bronnikov <sergeyb@tarantool.org>
> 
> Tarantool unit tests uses TAP framework but some tests haven't produce
> TAP-compliant output. This patch fixes such tests.
> 
> TAP framework contains primitives to check correctness of test functions
> behaviour and produced test output contains information about passed and failed
> testcases. This output processed by test-run.py on test execution. In this scheme
> separate artifacts like reference output files are useless and patch removes them.
> 
> GH branch: https://github.com/tarantool/tarantool/tree/ligurio/gh-5000-using-tap-output-in-unit-tests
> GH issue: https://github.com/tarantool/tarantool/issues/5000
> 
> Alexander Turenko (1):
>   test: update unit test lib to produce TAP-compliant output
> 
> Sergey Bronnikov (1):
>   test: update unit tests to make them TAP-compliant
> 
>  test/unit/CMakeLists.txt              |   49 +-
>  test/unit/base64.result               |  178 --
>  test/unit/bit.c                       |   75 +-
>  test/unit/bit.result                  |  895 ----------
>  test/unit/bitset_basic.c              |   38 +-
>  test/unit/bitset_basic.result         |   12 -
>  test/unit/bitset_index.c              |   42 +-
>  test/unit/bitset_index.result         |   21 -
>  test/unit/bitset_iterator.c           |   32 +
>  test/unit/bitset_iterator.result      |   22 -
>  test/unit/bloom.cc                    |   20 +-
>  test/unit/bloom.result                |    6 -
>  test/unit/bps_tree.cc                 |   80 +-
>  test/unit/bps_tree.result             |  284 ---
>  test/unit/bps_tree_iterator.cc        |   42 +-
>  test/unit/bps_tree_iterator.result    |   21 -
>  test/unit/cbus.c                      |   20 +-
>  test/unit/cbus.result                 |   24 -
>  test/unit/cbus_hang.c                 |    2 +-
>  test/unit/cbus_hang.result            |    4 -
>  test/unit/cbus_stress.c               |   53 +-
>  test/unit/cbus_stress.result          |    2 -
>  test/unit/checkpoint_schedule.result  |   41 -
>  test/unit/coio.result                 |   12 -
>  test/unit/coll.cpp                    |   51 +-
>  test/unit/coll.result                 |   90 -
>  test/unit/column_mask.result          |   36 -
>  test/unit/crypto.result               |  132 --
>  test/unit/csv.result                  |   80 +-
>  test/unit/decimal.result              |  700 --------
>  test/unit/fiber.cc                    |   21 +-
>  test/unit/fiber.result                |   19 -
>  test/unit/fiber_channel.cc            |    2 +
>  test/unit/fiber_channel.result        |   23 -
>  test/unit/fiber_channel_stress.cc     |    3 +
>  test/unit/fiber_channel_stress.result |    2 -
>  test/unit/fiber_cond.result           |    8 -
>  test/unit/fiber_stack.c               |    3 +
>  test/unit/fiber_stack.result          |   11 -
>  test/unit/fiber_stress.cc             |    4 +
>  test/unit/fiber_stress.result         |    0
>  test/unit/find_path.c                 |    3 +
>  test/unit/find_path.result            |    2 -
>  test/unit/guard.cc                    |    3 +-
>  test/unit/guard.result                |    1 -
>  test/unit/guava.c                     |   11 +
>  test/unit/guava.result                |    6 -
>  test/unit/heap.c                      |   38 +
>  test/unit/heap.result                 |   24 -
>  test/unit/heap_iterator.c             |   14 +
>  test/unit/heap_iterator.result        |    8 -
>  test/unit/histogram.c                 |   11 +
>  test/unit/histogram.result            |    6 -
>  test/unit/int96.cc                    |   51 +-
>  test/unit/int96.result                |    2 -
>  test/unit/json.result                 |  208 ---
>  test/unit/light.cc                    |   16 +-
>  test/unit/light.result                |    8 -
>  test/unit/luaL_iterator.result        |   89 -
>  test/unit/luaT_tuple_new.result       |   22 -
>  test/unit/merger.result               |   71 -
>  test/unit/mhash.result                |   18 -
>  test/unit/mhash_bytemap.result        |   18 -
>  test/unit/mp_error.result             |   44 -
>  test/unit/msgpack.result              | 2282 -------------------------
>  test/unit/popen.result                |   30 -
>  test/unit/queue.c                     |   65 +-
>  test/unit/queue.result                |   34 -
>  test/unit/ratelimit.result            |   13 -
>  test/unit/reflection_c.result         |    5 -
>  test/unit/reflection_cxx.result       |   31 -
>  test/unit/rmean.cc                    |   19 +-
>  test/unit/rmean.result                |   11 -
>  test/unit/rope.c                      |   10 +-
>  test/unit/rope.result                 |  299 ----
>  test/unit/rope_avl.c                  |    5 +
>  test/unit/rope_avl.result             |  123 --
>  test/unit/rope_basic.c                |   19 +-
>  test/unit/rope_basic.result           |  139 --
>  test/unit/rope_common.h               |   11 +-
>  test/unit/rope_stress.c               |    8 +
>  test/unit/rope_stress.result          |    4 -
>  test/unit/rtree.cc                    |   20 +-
>  test/unit/rtree.result                |    8 -
>  test/unit/rtree_iterator.cc           |   24 +-
>  test/unit/rtree_iterator.result       |    7 -
>  test/unit/rtree_multidim.cc           |   30 +-
>  test/unit/rtree_multidim.result       |   15 -
>  test/unit/say.result                  |   67 -
>  test/unit/scramble.c                  |   21 +-
>  test/unit/scramble.result             |    4 -
>  test/unit/sio.result                  |   36 -
>  test/unit/stailq.result               |   76 -
>  test/unit/swim.result                 |  234 ---
>  test/unit/swim_errinj.result          |   18 -
>  test/unit/swim_proto.result           |   40 -
>  test/unit/tuple_bigref.result         |   17 -
>  test/unit/unit.c                      |    3 +
>  test/unit/unit.h                      |   13 +-
>  test/unit/uri.result                  | 1307 --------------
>  test/unit/uuid.result                 |    9 -
>  test/unit/vclock.result               |  149 --
>  test/unit/vy_cache.result             |    9 -
>  test/unit/vy_mem.c                    |    4 +-
>  test/unit/vy_mem.result               |   17 -
>  test/unit/vy_point_lookup.result      |   20 -
>  test/unit/vy_write_iterator.result    |   61 -
>  test/unit/xrow.result                 |   58 -
>  108 files changed, 688 insertions(+), 8521 deletions(-)
>  delete mode 100644 test/unit/base64.result
>  delete mode 100644 test/unit/bit.result
>  delete mode 100644 test/unit/bitset_basic.result
>  delete mode 100644 test/unit/bitset_index.result
>  delete mode 100644 test/unit/bitset_iterator.result
>  delete mode 100644 test/unit/bloom.result
>  delete mode 100644 test/unit/bps_tree.result
>  delete mode 100644 test/unit/bps_tree_iterator.result
>  delete mode 100644 test/unit/cbus.result
>  delete mode 100644 test/unit/cbus_hang.result
>  delete mode 100644 test/unit/cbus_stress.result
>  delete mode 100644 test/unit/checkpoint_schedule.result
>  delete mode 100644 test/unit/coio.result
>  delete mode 100644 test/unit/coll.result
>  delete mode 100644 test/unit/column_mask.result
>  delete mode 100644 test/unit/crypto.result
>  delete mode 100644 test/unit/decimal.result
>  delete mode 100644 test/unit/fiber.result
>  delete mode 100644 test/unit/fiber_channel.result
>  delete mode 100644 test/unit/fiber_channel_stress.result
>  delete mode 100644 test/unit/fiber_cond.result
>  delete mode 100644 test/unit/fiber_stack.result
>  delete mode 100644 test/unit/fiber_stress.result
>  delete mode 100644 test/unit/find_path.result
>  delete mode 100644 test/unit/guard.result
>  delete mode 100644 test/unit/guava.result
>  delete mode 100644 test/unit/heap.result
>  delete mode 100644 test/unit/heap_iterator.result
>  delete mode 100644 test/unit/histogram.result
>  delete mode 100644 test/unit/int96.result
>  delete mode 100644 test/unit/json.result
>  delete mode 100644 test/unit/light.result
>  delete mode 100644 test/unit/luaL_iterator.result
>  delete mode 100644 test/unit/luaT_tuple_new.result
>  delete mode 100644 test/unit/merger.result
>  delete mode 100644 test/unit/mhash.result
>  delete mode 100644 test/unit/mhash_bytemap.result
>  delete mode 100644 test/unit/mp_error.result
>  delete mode 100644 test/unit/msgpack.result
>  delete mode 100644 test/unit/popen.result
>  delete mode 100644 test/unit/queue.result
>  delete mode 100644 test/unit/ratelimit.result
>  delete mode 100644 test/unit/reflection_c.result
>  delete mode 100644 test/unit/reflection_cxx.result
>  delete mode 100644 test/unit/rmean.result
>  delete mode 100644 test/unit/rope.result
>  delete mode 100644 test/unit/rope_avl.result
>  delete mode 100644 test/unit/rope_basic.result
>  delete mode 100644 test/unit/rope_stress.result
>  delete mode 100644 test/unit/rtree.result
>  delete mode 100644 test/unit/rtree_iterator.result
>  delete mode 100644 test/unit/rtree_multidim.result
>  delete mode 100644 test/unit/say.result
>  delete mode 100644 test/unit/scramble.result
>  delete mode 100644 test/unit/sio.result
>  delete mode 100644 test/unit/stailq.result
>  delete mode 100644 test/unit/swim.result
>  delete mode 100644 test/unit/swim_errinj.result
>  delete mode 100644 test/unit/swim_proto.result
>  delete mode 100644 test/unit/tuple_bigref.result
>  delete mode 100644 test/unit/uri.result
>  delete mode 100644 test/unit/uuid.result
>  delete mode 100644 test/unit/vclock.result
>  delete mode 100644 test/unit/vy_cache.result
>  delete mode 100644 test/unit/vy_mem.result
>  delete mode 100644 test/unit/vy_point_lookup.result
>  delete mode 100644 test/unit/vy_write_iterator.result
>  delete mode 100644 test/unit/xrow.result
> 
> -- 
> 2.23.0

-- 
sergeyb@

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Tarantool-patches] [PATCH 0/2] Make unit tests TAP-compliant
  2020-05-21  9:59 [Tarantool-patches] [PATCH 0/2] Make unit tests TAP-compliant sergeyb
                   ` (2 preceding siblings ...)
  2020-06-02  9:21 ` [Tarantool-patches] [PATCH 0/2] Make unit tests TAP-compliant Sergey Bronnikov
@ 2020-06-03 22:52 ` Vladislav Shpilevoy
  2020-06-08 15:35   ` Sergey Bronnikov
  3 siblings, 1 reply; 12+ messages in thread
From: Vladislav Shpilevoy @ 2020-06-03 22:52 UTC (permalink / raw)
  To: sergeyb, tarantool-patches; +Cc: o.piskunov, alexander.turenko

Hi! Thanks for the patchset!

I see both commits state they close the issue. But only one commit
can do that. According to the issue header, the second commit
looks like 'Closes'. And the first is 'Part of'.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Tarantool-patches] [PATCH 1/2] test: update unit test lib to produce TAP-compliant output
  2020-05-21  9:59 ` [Tarantool-patches] [PATCH 1/2] test: update unit test lib to produce TAP-compliant output sergeyb
  2020-06-02  9:20   ` Sergey Bronnikov
@ 2020-06-03 22:52   ` Vladislav Shpilevoy
  2020-06-08 15:37     ` Sergey Bronnikov
  1 sibling, 1 reply; 12+ messages in thread
From: Vladislav Shpilevoy @ 2020-06-03 22:52 UTC (permalink / raw)
  To: sergeyb, tarantool-patches; +Cc: o.piskunov, Alexander Turenko

Thanks for the patch!

> diff --git a/test/unit/unit.h b/test/unit/unit.h
> index 43c301b28..27879ea98 100644
> --- a/test/unit/unit.h
> +++ b/test/unit/unit.h
> @@ -129,6 +126,16 @@ int check_plan(void);
>  	}						\
>  }
>  
> +#define header() do {				\
> +	_space(stdout);				\
> +	printf("# *** %s ***\n", __func__);	\
> +} while(0)
> +
> +#define footer() do {					\
> +	_space(stdout);					\
> +	printf("# *** %s: done ***\n", __func__);	\

Since alignment is used, lets use it correctly. And align all
the slashes in the same way.

I mean footer and header slashes. Slightly screwed tabs inside
footer and inside header macros are git diff artifacts, no problem
here.

> +} while(0)
> +
>  #if defined(__cplusplus)
>  }
>  #endif /* defined(__cplusplus) */

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Tarantool-patches] [PATCH 2/2] test: update unit tests to make them TAP-compliant
  2020-05-21  9:59 ` [Tarantool-patches] [PATCH 2/2] test: update unit tests to make them TAP-compliant sergeyb
  2020-06-02  9:20   ` Sergey Bronnikov
@ 2020-06-03 22:52   ` Vladislav Shpilevoy
  2020-06-08 15:49     ` Sergey Bronnikov
  1 sibling, 1 reply; 12+ messages in thread
From: Vladislav Shpilevoy @ 2020-06-03 22:52 UTC (permalink / raw)
  To: sergeyb, tarantool-patches; +Cc: o.piskunov, alexander.turenko

Thanks for the patch!

There is still not deleted file unit/sql-bitvec.result.
Seems like its test file was removed some time ago, and
the result file was forgotten.

Also there is unit/csv.result. It has a test. Why didn't
you delete this file? Is the test output TAP compliant?

After I run the tests, unit/msgpack.result is generated
again. Test-run says

	[002] unit/msgpack.test                                               
	[002] TAP13 parse failed: Missing plan in the TAP source
	[002] [ new ]

See 8 comments below.

> diff --git a/test/unit/bit.c b/test/unit/bit.c
> index da514484d..d18aa5579 100644
> --- a/test/unit/bit.c
> +++ b/test/unit/bit.c
> @@ -29,20 +29,22 @@ test_ctz_clz(void)
>  		uint64_t val64 = vals[i];
>  		uint32_t val32 = (uint32_t) vals[i];
>  
> -		printf("bit_ctz_u64(%" PRIu64 ") => %d\n", val64,
> +		note("bit_ctz_u64(%" PRIu64 ") => %d", val64,
>  			bit_ctz_u64(val64));
> -		printf("bit_clz_u64(%" PRIu64 ") => %d\n", val64,
> +		note("bit_clz_u64(%" PRIu64 ") => %d", val64,
>  			bit_clz_u64(val64));

1. Previously the multiline expressions where aligned by the
parent expression printf(). Now they are not aligned. Please,
align. Multiline function call should be aligned by the column
after the opening parenthesis, not including it. Here and in all
other places, of this and other files.

>  
>  		if (vals[i] > UINT32_MAX)
>  			continue;
>  
> -		printf("bit_ctz_u32(%" PRIu32 ") => %d\n", val32,
> +		note("bit_ctz_u32(%" PRIu32 ") => %d", val32,
>  			bit_ctz_u32(val32));
> -		printf("bit_clz_u32(%" PRIu32 ") => %d\n", val32,
> +		note("bit_clz_u32(%" PRIu32 ") => %d", val32,
>  			bit_clz_u32(val32));
>  	}
>  
> +	ok(1, "test ctz clz");

2. Seems like plan(0) works perfectly fine, so you don't need
to add the dummy ok() calls. Moreover, you can delete plan()+check_plan(),
and it also works fine. Because header() and footer() are just comments.
They don't oblige you to have a plan. That should reduce diff size and
simplify the patch.

> +	check_plan();
>  	footer();
>  }
> @@ -107,36 +115,42 @@ static void
>  
>  static inline void
>  test_index_print(const int *start, const int *end)
>  {
> +	/*
>  	for (const int *cur = start; cur < end; cur++) {
>  		printf("%d ", *cur);
>  	}
> +	*/

3. WTF is that?

>  }
>  
>  static void
>  test_index(void)
>  {
>  	header();
> +	plan(1);
>  
>  	int indexes[sizeof(int64_t) * CHAR_BIT + 1];
>  
> @@ -144,18 +158,20 @@ test_index(void)
>  		uint64_t val64 = vals[i];
>  		uint32_t val32 = (uint32_t) vals[i];
>  
> -		printf("bit_index_u64(%" PRIu64 ", *, -1) => ", val64);
> +		//printf("bit_index_u64(%" PRIu64 ", *, -1) => ", val64);
>  		test_index_print(indexes, bit_index_u64(val64, indexes, -1));
> -		printf("\n");
> +		//printf("\n");
>  
>  		if (vals[i] > UINT32_MAX)
>  			continue;
>  
> -		printf("bit_index_u32(%" PRIu32 ", *, -1) => ", val32);
> +		//printf("bit_index_u32(%" PRIu32 ", *, -1) => ", val32);
>  		test_index_print(indexes, bit_index_u32(val32, indexes, -1));
> -		printf("\n");
> +		//printf("\n");

4. ???
Seems like the patch is really raw. Please, get rid of the commented
code. It should either work, or should not exist.

>  	}
>  
> +	ok(1, "test index");
> +	check_plan();
>  	footer();
>  }
> @@ -202,7 +222,9 @@ test_bit_iter_empty(void)
>  
>  	bit_iterator_init(&it, NULL, 0, false);
>  	fail_unless(bit_iterator_next(&it) == SIZE_MAX);
> -
> +	

5. Trailing tab symbol. It is highlighted in bright red
color in the console, when you do 'git diff/show'.

> +	ok(1, "test bit iter empty");
> +	check_plan();
>  	footer();
>  }
> @@ -217,12 +240,15 @@ test_bitmap_size(void)
>  	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT * 4) == sizeof(long) * 4);
>  	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT * 4 - 1) == sizeof(long) * 4);
>  	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT * 9 / 2) == sizeof(long) * 5);
> +	ok(1, "test bitmap size");
> +	check_plan();
>  	footer();
>  }
>  
>  int
>  main(void)
>  {
> +	plan(8);

6. I see that to some main() functions you added only plan() + check_plan().
To some you added header() + footer(). Lets be consistent and add all the
outputs: header(), plan(), check_plan(), and footer().

> diff --git a/test/unit/bloom.cc b/test/unit/bloom.cc
> index 2e5b99412..23a36487c 100644
> --- a/test/unit/bloom.cc
> +++ b/test/unit/bloom.cc
> @@ -45,14 +47,16 @@ simple_test()
>  		if (fp_rate > p + 0.001)
>  			fp_rate_too_big++;
>  	}
> -	cout << "error_count = " << error_count << endl;
> -	cout << "fp_rate_too_big = " << fp_rate_too_big << endl;
> +	note("error_count = %d", error_count);
> +	note("fp_rate_too_big = %d", fp_rate_too_big);
> +	ok(1, "%s", __func__);
> +	check_plan();

7. There is a header(), but no footer().

>  }
>  
>  void
>  store_load_test()
>  {
> -	cout << "*** " << __func__ << " ***" << endl;
> +	plan(1);

8. Why did you add header() to the previous test, and to this
one you didn't? Find and fix all the other similar inconsistencies
in the patch.

I will review the rest, when the comments above are done and expanded
to the whole patch.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Tarantool-patches] [PATCH 0/2] Make unit tests TAP-compliant
  2020-06-03 22:52 ` Vladislav Shpilevoy
@ 2020-06-08 15:35   ` Sergey Bronnikov
  0 siblings, 0 replies; 12+ messages in thread
From: Sergey Bronnikov @ 2020-06-08 15:35 UTC (permalink / raw)
  To: Vladislav Shpilevoy; +Cc: o.piskunov, tarantool-patches, alexander.turenko

Hi,

On 00:52 Thu 04 Jun , Vladislav Shpilevoy wrote:
> Hi! Thanks for the patchset!
> 
> I see both commits state they close the issue. But only one commit
> can do that. According to the issue header, the second commit
> looks like 'Closes'. And the first is 'Part of'.

Agree, fixed it in a new version of patches.

-- 
sergeyb@

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Tarantool-patches] [PATCH 1/2] test: update unit test lib to produce TAP-compliant output
  2020-06-03 22:52   ` Vladislav Shpilevoy
@ 2020-06-08 15:37     ` Sergey Bronnikov
  0 siblings, 0 replies; 12+ messages in thread
From: Sergey Bronnikov @ 2020-06-08 15:37 UTC (permalink / raw)
  To: Vladislav Shpilevoy; +Cc: o.piskunov, tarantool-patches, Alexander Turenko

Hi, Vladislav

thanks for spending time on review of my patches!

On 00:52 Thu 04 Jun , Vladislav Shpilevoy wrote:
> Thanks for the patch!
> 
> > diff --git a/test/unit/unit.h b/test/unit/unit.h
> > index 43c301b28..27879ea98 100644
> > --- a/test/unit/unit.h
> > +++ b/test/unit/unit.h
> > @@ -129,6 +126,16 @@ int check_plan(void);
> >  	}						\
> >  }
> >  
> > +#define header() do {				\
> > +	_space(stdout);				\
> > +	printf("# *** %s ***\n", __func__);	\
> > +} while(0)
> > +
> > +#define footer() do {					\
> > +	_space(stdout);					\
> > +	printf("# *** %s: done ***\n", __func__);	\
> 
> Since alignment is used, lets use it correctly. And align all
> the slashes in the same way.

Fixed.

> I mean footer and header slashes. Slightly screwed tabs inside
> footer and inside header macros are git diff artifacts, no problem
> here.
> 
> > +} while(0)
> > +
> >  #if defined(__cplusplus)
> >  }
> >  #endif /* defined(__cplusplus) */

-- 
sergeyb@

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [Tarantool-patches] [PATCH 2/2] test: update unit tests to make them TAP-compliant
  2020-06-03 22:52   ` Vladislav Shpilevoy
@ 2020-06-08 15:49     ` Sergey Bronnikov
  0 siblings, 0 replies; 12+ messages in thread
From: Sergey Bronnikov @ 2020-06-08 15:49 UTC (permalink / raw)
  To: Vladislav Shpilevoy; +Cc: o.piskunov, tarantool-patches, alexander.turenko

Hi, Vladislav

thanks for review!

On 00:52 Thu 04 Jun , Vladislav Shpilevoy wrote:
> Thanks for the patch!
> 
> There is still not deleted file unit/sql-bitvec.result.
> Seems like its test file was removed some time ago, and
> the result file was forgotten.

Removed in a branch and updated version of patches.

> Also there is unit/csv.result. It has a test. Why didn't
> you delete this file? Is the test output TAP compliant?

Actually the problem with this test that it uses complex output and I
thought it is better to keep it as is. Then I look on it again and fixed
TAP output, changes were small.

> After I run the tests, unit/msgpack.result is generated
> again. Test-run says
> 
> 	[002] unit/msgpack.test                                               
> 	[002] TAP13 parse failed: Missing plan in the TAP source
> 	[002] [ new ]

It was my bad. This test uses header from msgpuck library which required
small fix. But I forgot to mention it or at least update submodule with
msgpuck in a patchset. Fixed in a new version.

> See 8 comments below.
> 
> > diff --git a/test/unit/bit.c b/test/unit/bit.c
> > index da514484d..d18aa5579 100644
> > --- a/test/unit/bit.c
> > +++ b/test/unit/bit.c
> > @@ -29,20 +29,22 @@ test_ctz_clz(void)
> >  		uint64_t val64 = vals[i];
> >  		uint32_t val32 = (uint32_t) vals[i];
> >  
> > -		printf("bit_ctz_u64(%" PRIu64 ") => %d\n", val64,
> > +		note("bit_ctz_u64(%" PRIu64 ") => %d", val64,
> >  			bit_ctz_u64(val64));
> > -		printf("bit_clz_u64(%" PRIu64 ") => %d\n", val64,
> > +		note("bit_clz_u64(%" PRIu64 ") => %d", val64,
> >  			bit_clz_u64(val64));
> 
> 1. Previously the multiline expressions where aligned by the
> parent expression printf(). Now they are not aligned. Please,
> align. Multiline function call should be aligned by the column
> after the opening parenthesis, not including it. Here and in all
> other places, of this and other files.

Missed it, new version contains properly aligned lines.

> >  
> >  		if (vals[i] > UINT32_MAX)
> >  			continue;
> >  
> > -		printf("bit_ctz_u32(%" PRIu32 ") => %d\n", val32,
> > +		note("bit_ctz_u32(%" PRIu32 ") => %d", val32,
> >  			bit_ctz_u32(val32));
> > -		printf("bit_clz_u32(%" PRIu32 ") => %d\n", val32,
> > +		note("bit_clz_u32(%" PRIu32 ") => %d", val32,
> >  			bit_clz_u32(val32));
> >  	}
> >  
> > +	ok(1, "test ctz clz");
> 
> 2. Seems like plan(0) works perfectly fine, so you don't need
> to add the dummy ok() calls. Moreover, you can delete plan()+check_plan(),
> and it also works fine. Because header() and footer() are just comments.
> They don't oblige you to have a plan. That should reduce diff size and
> simplify the patch.

My main idea was to report function names and testcases in a TAP output.
However there is no other sense in these ok()'s. We discussed it again
with you separately and I have removed all dummy ok() calls.

> > +	check_plan();
> >  	footer();
> >  }
> > @@ -107,36 +115,42 @@ static void
> >  
> >  static inline void
> >  test_index_print(const int *start, const int *end)
> >  {
> > +	/*
> >  	for (const int *cur = start; cur < end; cur++) {
> >  		printf("%d ", *cur);
> >  	}
> > +	*/
> 
> 3. WTF is that?

Ah, missed it.

> >  }
> >  
> >  static void
> >  test_index(void)
> >  {
> >  	header();
> > +	plan(1);
> >  
> >  	int indexes[sizeof(int64_t) * CHAR_BIT + 1];
> >  
> > @@ -144,18 +158,20 @@ test_index(void)
> >  		uint64_t val64 = vals[i];
> >  		uint32_t val32 = (uint32_t) vals[i];
> >  
> > -		printf("bit_index_u64(%" PRIu64 ", *, -1) => ", val64);
> > +		//printf("bit_index_u64(%" PRIu64 ", *, -1) => ", val64);
> >  		test_index_print(indexes, bit_index_u64(val64, indexes, -1));
> > -		printf("\n");
> > +		//printf("\n");
> >  
> >  		if (vals[i] > UINT32_MAX)
> >  			continue;
> >  
> > -		printf("bit_index_u32(%" PRIu32 ", *, -1) => ", val32);
> > +		//printf("bit_index_u32(%" PRIu32 ", *, -1) => ", val32);
> >  		test_index_print(indexes, bit_index_u32(val32, indexes, -1));
> > -		printf("\n");
> > +		//printf("\n");
> 
> 4. ???
> Seems like the patch is really raw. Please, get rid of the commented
> code. It should either work, or should not exist.
> 
> >  	}
> >  
> > +	ok(1, "test index");
> > +	check_plan();
> >  	footer();
> >  }
> > @@ -202,7 +222,9 @@ test_bit_iter_empty(void)
> >  
> >  	bit_iterator_init(&it, NULL, 0, false);
> >  	fail_unless(bit_iterator_next(&it) == SIZE_MAX);
> > -
> > +	
> 
> 5. Trailing tab symbol. It is highlighted in bright red
> color in the console, when you do 'git diff/show'.

Removed extra tab.

> > +	ok(1, "test bit iter empty");
> > +	check_plan();
> >  	footer();
> >  }
> > @@ -217,12 +240,15 @@ test_bitmap_size(void)
> >  	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT * 4) == sizeof(long) * 4);
> >  	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT * 4 - 1) == sizeof(long) * 4);
> >  	fail_unless(bitmap_size(sizeof(long) * CHAR_BIT * 9 / 2) == sizeof(long) * 5);
> > +	ok(1, "test bitmap size");
> > +	check_plan();
> >  	footer();
> >  }
> >  
> >  int
> >  main(void)
> >  {
> > +	plan(8);
> 
> 6. I see that to some main() functions you added only plan() + check_plan().
> To some you added header() + footer(). Lets be consistent and add all the
> outputs: header(), plan(), check_plan(), and footer().

In a new version I kept only plan() and check_plan().

> > diff --git a/test/unit/bloom.cc b/test/unit/bloom.cc
> > index 2e5b99412..23a36487c 100644
> > --- a/test/unit/bloom.cc
> > +++ b/test/unit/bloom.cc
> > @@ -45,14 +47,16 @@ simple_test()
> >  		if (fp_rate > p + 0.001)
> >  			fp_rate_too_big++;
> >  	}
> > -	cout << "error_count = " << error_count << endl;
> > -	cout << "fp_rate_too_big = " << fp_rate_too_big << endl;
> > +	note("error_count = %d", error_count);
> > +	note("fp_rate_too_big = %d", fp_rate_too_big);
> > +	ok(1, "%s", __func__);
> > +	check_plan();
> 
> 7. There is a header(), but no footer().
> 
> >  }
> >  
> >  void
> >  store_load_test()
> >  {
> > -	cout << "*** " << __func__ << " ***" << endl;
> > +	plan(1);
> 
> 8. Why did you add header() to the previous test, and to this
> one you didn't? Find and fix all the other similar inconsistencies
> in the patch.
> 
> I will review the rest, when the comments above are done and expanded
> to the whole patch.

-- 
sergeyb@

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2020-06-08 15:51 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-21  9:59 [Tarantool-patches] [PATCH 0/2] Make unit tests TAP-compliant sergeyb
2020-05-21  9:59 ` [Tarantool-patches] [PATCH 1/2] test: update unit test lib to produce TAP-compliant output sergeyb
2020-06-02  9:20   ` Sergey Bronnikov
2020-06-03 22:52   ` Vladislav Shpilevoy
2020-06-08 15:37     ` Sergey Bronnikov
2020-05-21  9:59 ` [Tarantool-patches] [PATCH 2/2] test: update unit tests to make them TAP-compliant sergeyb
2020-06-02  9:20   ` Sergey Bronnikov
2020-06-03 22:52   ` Vladislav Shpilevoy
2020-06-08 15:49     ` Sergey Bronnikov
2020-06-02  9:21 ` [Tarantool-patches] [PATCH 0/2] Make unit tests TAP-compliant Sergey Bronnikov
2020-06-03 22:52 ` Vladislav Shpilevoy
2020-06-08 15:35   ` Sergey Bronnikov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox