From d7bf31c6d259cd9a84ec805f9d19ef1bf84c2175 Mon Sep 17 00:00:00 2001 From: Francois Perrad Date: Sat, 5 Sep 2009 13:58:05 +0200 Subject: [PATCH] add messages --- t/pmc/boolean.t | 8 ++++---- t/pmc/boolean_hll.t | 8 ++++---- t/pmc/function.t | 12 ++++++------ t/pmc/function_hll.t | 14 +++++++------- t/pmc/nil.t | 12 ++++++------ t/pmc/nil_hll.t | 8 ++++---- t/pmc/number.t | 10 +++++----- t/pmc/number_hll.t | 14 +++++++------- t/pmc/string.t | 12 ++++++------ t/pmc/string_hll.t | 19 +++++++++---------- t/pmc/table.t | 20 ++++++++++---------- t/pmc/table_hll.t | 10 +++++----- t/pmc/thread.t | 12 ++++++------ t/pmc/thread_hll.t | 6 +++--- t/pmc/userdata.t | 12 ++++++------ t/pmc/userdata_hll.t | 6 +++--- 16 files changed, 91 insertions(+), 92 deletions(-) diff --git a/t/pmc/boolean.t b/t/pmc/boolean.t index 3245cc1..0f86da5 100644 --- a/t/pmc/boolean.t +++ b/t/pmc/boolean.t @@ -31,7 +31,7 @@ Tests C PMC .sub 'check_inheritance' $P0 = new 'LuaBoolean' $I0 = isa $P0, 'LuaAny' - is($I0, 1) + is($I0, 1, "check inheritance") $I0 = isa $P0, 'LuaBoolean' is($I0, 1) .end @@ -39,7 +39,7 @@ Tests C PMC .sub 'check_interface' $P0 = new 'LuaBoolean' $I0 = does $P0, 'scalar' - is($I0, 1) + is($I0, 1, "check interface") $I0 = does $P0, 'boolean' is($I0, 1) $I0 = does $P0, 'integer' @@ -51,14 +51,14 @@ Tests C PMC .sub 'check_name' $P0 = new 'LuaBoolean' $S0 = typeof $P0 - is($S0, 'boolean') + is($S0, 'boolean', "check name") .end .sub 'check_get_string' $P0 = new 'LuaBoolean' set $P0, 0 $S0 = $P0 - is($S0, 'false') + is($S0, 'false', "check get_string") set $P0, 1 $S0 = $P0 is($S0, 'true') diff --git a/t/pmc/boolean_hll.t b/t/pmc/boolean_hll.t index 4f9179a..bfd4f1d 100644 --- a/t/pmc/boolean_hll.t +++ b/t/pmc/boolean_hll.t @@ -33,7 +33,7 @@ Tests C PMC $P0 = new 'LuaBoolean' set $P0, 1 $S0 = $P0 - is($S0, 'true') + is($S0, 'true', "check HLL") $I0 = isa $P0, 'LuaBoolean' is($I0, 1) .end @@ -41,7 +41,7 @@ Tests C PMC .sub 'check_HLL_const' .const 'LuaBoolean' K = '1' $S0 = K - is($S0, 'true') + is($S0, 'true', "check HLL & .const") $I0 = isa K, 'LuaBoolean' is($I0, 1) .end @@ -50,7 +50,7 @@ Tests C PMC $P0 = new 'LuaBoolean' set $P0, 1 $S0 = $P0 - is($S0, 'true') + is($S0, 'true', "check tostring") $P1 = $P0.'tostring'() $S0 = $P1 is($S0, 'true') @@ -62,7 +62,7 @@ Tests C PMC $P0 = new 'LuaBoolean' set $P0, 1 $S0 = $P0 - is($S0, 'true') + is($S0, 'true', "check tonumber") $P1 = $P0.'tonumber'() $S0 = $P1 is($S0, 'nil') diff --git a/t/pmc/function.t b/t/pmc/function.t index 018b386..77b5fe1 100644 --- a/t/pmc/function.t +++ b/t/pmc/function.t @@ -33,7 +33,7 @@ Tests C PMC .sub 'check_inheritance' $P0 = new 'LuaFunction' $I0 = isa $P0, 'scalar' - is($I0, 0) + is($I0, 0, "check inheritance") $I0 = isa $P0, 'Sub' is($I0, 1) $I0 = isa $P0, 'Closure' @@ -47,7 +47,7 @@ Tests C PMC .sub 'check_interface' $P0 = new 'LuaFunction' $I0 = does $P0, 'scalar' - is($I0, 1) + is($I0, 1, "check interface") $I0 = does $P0, 'sub' is($I0, 1) $I0 = does $P0, 'no_interface' @@ -57,13 +57,13 @@ Tests C PMC .sub 'check_name' $P0 = new 'LuaFunction' $S0 = typeof $P0 - is($S0, 'function') + is($S0, 'function', "check name") .end .sub 'check_get_string' $P0 = new 'LuaFunction' $S0 = $P0 - like($S0, '^function: <[0..9A..Fa..f]>*') + like($S0, '^function: <[0..9A..Fa..f]>*', "check get_string") .end .sub 'check_get_bool' @@ -72,7 +72,7 @@ Tests C PMC is($I0, 1) .const 'Sub' F1 = 'f1' $I0 = istrue F1 - is($I0, 1) + is($I0, 1, "check get_bool") .end .sub f1 @@ -84,7 +84,7 @@ Tests C PMC $P0 = new 'LuaFunction' $P1 = not $P0 $S0 = $P1 - is($S0, 'false') + is($S0, 'false', "check logical_not") $S0 = typeof $P1 is($S0, 'boolean') .end diff --git a/t/pmc/function_hll.t b/t/pmc/function_hll.t index 3c189aa..40ddb15 100644 --- a/t/pmc/function_hll.t +++ b/t/pmc/function_hll.t @@ -36,7 +36,7 @@ Tests C PMC # .const 'LuaFunction' F1 = 'f1' .const 'Sub' F1 = 'f1' $I0 = isa F1, 'LuaFunction' - is($I0, 1) + is($I0, 1, "check HLL") $S0 = F1() is($S0, "f1()") .const 'Sub' F2 = 'f2' @@ -57,7 +57,7 @@ Tests C PMC .sub 'check_HLL_autoboxing' $P0 = fct1() $I0 = isa $P0, 'LuaFunction' - is($I0, 1) + is($I0, 1, "check HLL autoboxing") $P0 = fct2() $I0 = isa $P0, 'LuaFunction' is($I0, 1) @@ -76,7 +76,7 @@ Tests C PMC .sub 'check_tostring' $P0 = new 'LuaFunction' $S0 = $P0 - like($S0, '^function: <[0..9A..Fa..f]>*') + like($S0, '^function: <[0..9A..Fa..f]>*', "check tostring") $P1 = $P0.'tostring'() $S0 = $P1 like($S0, '^function: <[0..9A..Fa..f]>*') @@ -88,7 +88,7 @@ Tests C PMC $P0 = new 'LuaFunction' $P1 = $P0.'tonumber'() $S0 = $P1 - is($S0, 'nil') + is($S0, 'nil', "check tonumber") $S0 = typeof $P1 is($S0, 'nil') .end @@ -97,7 +97,7 @@ Tests C PMC .const 'Sub'F1 = 'f1' $P0 = new 'LuaFunction', F1 $I0 = isa $P0, 'LuaFunction' - is($I0, 1) + is($I0, 1, "check init_pmc") $S0 = $P0() is($S0, "f1()") .end @@ -111,7 +111,7 @@ Tests C PMC .const 'LuaString' k_print = 'print' $P2 = $P1[k_print] $I0 = isa $P2, 'LuaFunction' - is($I0, 1) + is($I0, 1, "load from pbc") # $P2($P2) .end @@ -122,7 +122,7 @@ Tests C PMC .const 'LuaString' k_print = 'print' $P2 = $P1[k_print] $I0 = isa $P2, 'LuaFunction' - is($I0, 1) + is($I0, 1, "load from pbc") # $P2($P2) .end diff --git a/t/pmc/nil.t b/t/pmc/nil.t index aadbbdc..47f1bf1 100644 --- a/t/pmc/nil.t +++ b/t/pmc/nil.t @@ -33,7 +33,7 @@ Tests C PMC .sub 'check_inheritance' $P0 = new 'LuaNil' $I0 = isa $P0, 'LuaAny' - is($I0, 1) + is($I0, 1, "check inheritance") $I0 = isa $P0, 'LuaNil' is($I0, 1) .end @@ -41,7 +41,7 @@ Tests C PMC .sub 'check_interface' $P0 = new 'LuaNil' $I0 = does $P0, 'scalar' - is($I0, 1) + is($I0, 1, "check interface") $I0 = does $P0, 'no_interface' is($I0, 0) .end @@ -49,26 +49,26 @@ Tests C PMC .sub 'check_name' $P0 = new 'LuaNil' $S0 = typeof $P0 - is($S0, 'nil') + is($S0, 'nil', "check name") .end .sub 'check_get_string' $P0 = new 'LuaNil' $S0 = $P0 - is($S0, 'nil') + is($S0, 'nil', "check get_string") .end .sub 'check_get_bool' $P0 = new 'LuaNil' $I0 = isfalse $P0 - is($I0, 1) + is($I0, 1, "check get_bool") .end .sub 'check_logical_not' $P0 = new 'LuaNil' $P1 = not $P0 $S0 = $P1 - is($S0, 'true') + is($S0, 'true', "check logical_not") $S0 = typeof $P1 is($S0, 'boolean') .end diff --git a/t/pmc/nil_hll.t b/t/pmc/nil_hll.t index 7e84733..d8a97ab 100644 --- a/t/pmc/nil_hll.t +++ b/t/pmc/nil_hll.t @@ -32,7 +32,7 @@ Tests C PMC .sub 'check_HLL' $P0 = new 'LuaNil' $S0 = $P0 - is($S0, 'nil') + is($S0, 'nil', "check HLL") $I0 = isa $P0, 'LuaNil' is($I0, 1) .end @@ -40,7 +40,7 @@ Tests C PMC .sub 'check_HLL_const' .const 'LuaNil' K = 'dummy' $S0 = K - is($S0, 'nil') + is($S0, 'nil', "check HLL & .const") $I0 = isa K, 'LuaNil' is($I0, 1) .end @@ -48,7 +48,7 @@ Tests C PMC .sub 'check_tostring' $P0 = new 'LuaNil' $S0 = $P0 - is($S0, 'nil') + is($S0, 'nil', "check tostring") $P1 = $P0.'tostring'() $S0 = $P1 is($S0, 'nil') @@ -59,7 +59,7 @@ Tests C PMC .sub 'check_tonumber' $P0 = new 'LuaNil' $S0 = $P0 - is($S0, 'nil') + is($S0, 'nil', "check tonumber") $P1 = $P0.'tonumber'() $S0 = $P1 is($S0, 'nil') diff --git a/t/pmc/number.t b/t/pmc/number.t index 472b2dc..4889e8c 100644 --- a/t/pmc/number.t +++ b/t/pmc/number.t @@ -32,7 +32,7 @@ Tests C PMC .sub 'check_inheritance' $P0 = new 'LuaNumber' $I0 = isa $P0, 'LuaAny' - is($I0, 1) + is($I0, 1, "check inheritance") $I0 = isa $P0, 'LuaNumber' is($I0, 1) .end @@ -40,7 +40,7 @@ Tests C PMC .sub 'check_interface' $P0 = new 'LuaNumber' $I0 = does $P0, 'scalar' - is($I0, 1) + is($I0, 1, "check interface") $I0 = does $P0, 'float' is($I0, 1) $I0 = does $P0, 'no_interface' @@ -50,14 +50,14 @@ Tests C PMC .sub 'check_name' $P0 = new 'LuaNumber' $S0 = typeof $P0 - is($S0, 'number') + is($S0, 'number', "check name") .end .sub 'check_set_integer_native' $P0 = new 'LuaNumber' set $P0, 3.14 $S0 = typeof $P0 - is($S0, 'number') + is($S0, 'number', "check set_integer_native") $S0 = $P0 is($S0, '3.14') set $P0, 2 @@ -72,7 +72,7 @@ Tests C PMC set $P0, 3.14 $P1 = not $P0 $S0 = $P1 - is($S0, 'false') + is($S0, 'false', "check logical_not") $S0 = typeof $P1 is($S0, 'boolean') .end diff --git a/t/pmc/number_hll.t b/t/pmc/number_hll.t index 005aa3f..678187c 100644 --- a/t/pmc/number_hll.t +++ b/t/pmc/number_hll.t @@ -36,7 +36,7 @@ Tests C PMC $P0 = new 'LuaNumber' set $P0, 3.14 $S0 = $P0 - is($S0, '3.14') + is($S0, '3.14', "check HLL") $I0 = isa $P0, 'LuaNumber' is($I0, 1) .end @@ -44,7 +44,7 @@ Tests C PMC .sub 'check_HLL_autoboxing' $P0 = fct() $S0 = $P0 - is($S0, '3.14') + is($S0, '3.14', "check HLL autoboxing") $I0 = isa $P0, 'LuaNumber' is($I0, 1) .end @@ -56,7 +56,7 @@ Tests C PMC .sub 'check_HLL_const' .const 'LuaNumber' K = '3.14' $S0 = K - is($S0, '3.14') + is($S0, '3.14', "check HLL & .const") $I0 = isa K, 'LuaNumber' is($I0, 1) .end @@ -64,7 +64,7 @@ Tests C PMC .sub 'check_box_float' $P0 = box 3.14 $S0 = $P0 - is($S0, '3.14') + is($S0, '3.14', "check box float") $I0 = isa $P0, 'LuaNumber' is($I0, 1) .end @@ -72,7 +72,7 @@ Tests C PMC .sub 'check_box_integer' $P0 = box -2 $S0 = $P0 - is($S0, '-2') + is($S0, '-2', "check box integer") $I0 = isa $P0, 'LuaNumber' is($I0, 1) .end @@ -81,7 +81,7 @@ Tests C PMC $P0 = new 'LuaNumber' set $P0, 3.14 $S0 = $P0 - is($S0, '3.14') + is($S0, '3.14', "check tostring") $P1 = $P0.'tostring'() $S0 = $P1 is($S0, '3.14') @@ -93,7 +93,7 @@ Tests C PMC $P0 = new 'LuaNumber' set $P0, 3.14 $S0 = $P0 - is($S0, '3.14') + is($S0, '3.14', "check tonumber") $P1 = $P0.'tonumber'() $S0 = $P1 is($S0, '3.14') diff --git a/t/pmc/string.t b/t/pmc/string.t index bddd780..7c32bf1 100644 --- a/t/pmc/string.t +++ b/t/pmc/string.t @@ -33,7 +33,7 @@ Tests C PMC .sub 'check_inheritance' $P0 = new 'LuaString' $I0 = isa $P0, 'LuaAny' - is($I0, 1) + is($I0, 1, "check inheritance") $I0 = isa $P0, 'LuaString' is($I0, 1) .end @@ -41,7 +41,7 @@ Tests C PMC .sub 'check_interface' $P0 = new 'LuaString' $I0 = does $P0, 'scalar' - is($I0, 1) + is($I0, 1, "check interface") $I0 = does $P0, 'string' is($I0, 1) $I0 = does $P0, 'no_interface' @@ -51,14 +51,14 @@ Tests C PMC .sub 'check_name' $P0 = new 'LuaString' $S0 = typeof $P0 - is($S0, 'string') + is($S0, 'string', "check name") .end .sub 'check_get_bool' $P0 = new 'LuaString' set $P0, 'str' $I0 = istrue $P0 - is($I0, 1) + is($I0, 1, "check get_bool") set $P0, '' $I0 = istrue $P0 is($I0, 1) @@ -69,7 +69,7 @@ Tests C PMC set $P0, 'str' $P1 = not $P0 $S0 = $P1 - is($S0, 'false') + is($S0, 'false', "check logical_not") $S0 = typeof $P1 is($S0, 'boolean') .end @@ -78,7 +78,7 @@ Tests C PMC $P0 = new 'LuaString' set $P0, "embe\0_dd\0_ed\0" $I0 = elements $P0 - is($I0, 13) + is($I0, 13, "check embedded zero") .end # Local Variables: diff --git a/t/pmc/string_hll.t b/t/pmc/string_hll.t index ed9fc04..edb91a2 100644 --- a/t/pmc/string_hll.t +++ b/t/pmc/string_hll.t @@ -38,7 +38,7 @@ Tests C PMC $P0 = new 'LuaString' set $P0, "simple string" $S0 = $P0 - is($S0, "simple string") + is($S0, "simple string", "check HLL") $I0 = isa $P0, 'LuaString' is($I0, 1) .end @@ -46,7 +46,7 @@ Tests C PMC .sub 'check_HLL_autoboxing' $P0 = fct() $S0 = $P0 - is($S0, "simple string") + is($S0, "simple string", "check HLL autoboxing") $I0 = isa $P0, 'LuaString' is($I0, 1) .end @@ -58,7 +58,7 @@ Tests C PMC .sub 'check_HLL_const' .const 'LuaString' K = "simple string" $S0 = K - is($S0, "simple string") + is($S0, "simple string", "check HLL & .const") $I0 = isa K, 'LuaString' is($I0, 1) .end @@ -66,7 +66,7 @@ Tests C PMC .sub 'check_empty_string' .const 'LuaString' K = '' $S0 = K - is($S0, '') + is($S0, '', "check empty string") $I0 = isa K, 'LuaString' is($I0, 1) .end @@ -74,26 +74,25 @@ Tests C PMC .sub 'check_box' $P0 = box "simple string" $S0 = $P0 - is($S0, "simple string") + is($S0, "simple string", "check box") $I0 = isa $P0, 'LuaString' is($I0, 1) .end .sub 'check_is_equal' - # RT #60292 $P1 = new 'LuaString' set $P1, 'str' $P2 = new 'LuaString' set $P2, 'str' $I0 = iseq $P1, $P2 - is($I0, 1) + is($I0, 1, "check is_equal (RT #60292)") .end .sub 'check_tostring' $P0 = new 'LuaString' set $P0, 'value' $S0 = $P0 - is($S0, 'value') + is($S0, 'value', "check tostring") $P1 = $P0.'tostring'() $S0 = $P1 is($S0, 'value') @@ -105,7 +104,7 @@ Tests C PMC $P0 = new 'LuaString' set $P0, '3.14' $S0 = $P0 - is($S0, '3.14') + is($S0, '3.14', "check tonumber") $P1 = $P0.'tonumber'() $S0 = $P1 is($S0, '3.14') @@ -117,7 +116,7 @@ Tests C PMC $P0 = new 'LuaString' set $P0, '111' $S0 = $P0 - is($S0, '111') + is($S0, '111', "check tobase") $P1 = $P0.'tobase'(2) $S0 = $P1 is($S0, '7') diff --git a/t/pmc/table.t b/t/pmc/table.t index 366d156..67f70a7 100644 --- a/t/pmc/table.t +++ b/t/pmc/table.t @@ -36,7 +36,7 @@ Tests C type .sub 'check_inheritance' $P0 = new 'LuaTable' $I0 = isa $P0, 'scalar' - is($I0, 0) + is($I0, 0, "check ingeritance") $I0 = isa $P0, 'LuaAny' is($I0, 1) $I0 = isa $P0, 'LuaTable' @@ -46,7 +46,7 @@ Tests C
type .sub 'check_interface' $P0 = new 'LuaTable' $I0 = does $P0, 'scalar' - is($I0, 0) + is($I0, 0, "check interface") $I0 = does $P0, 'no_interface' is($I0, 0) .end @@ -54,26 +54,26 @@ Tests C
type .sub 'check_name' $P0 = new 'LuaTable' $S0 = typeof $P0 - is($S0, 'table') + is($S0, 'table', "check name") .end .sub 'check_get_string' $P0 = new 'LuaTable' $S0 = $P0 - like($S0, '^table: <[0..9A..Fa..f]>*') + like($S0, '^table: <[0..9A..Fa..f]>*', "check get_string") .end .sub 'check_get_bool' $P0 = new 'LuaTable' $I0 = istrue $P0 - is($I0, 1) + is($I0, 1, "check get_bool") .end .sub 'check_logical_not' $P0 = new 'LuaTable' $P1 = not $P0 $S0 = $P1 - is($S0, 'false') + is($S0, 'false', "check logical_not") $S0 = typeof $P1 is($S0, 'boolean') .end @@ -90,7 +90,7 @@ Tests C
type $P0[val2] = val2 $P1 = $P0[val1] $S0 = $P1 - is($S0, "value1") + is($S0, "value1", "check key PMC") $P1 = $P0[val2] $S0 = $P1 is($S0, "value2") @@ -108,7 +108,7 @@ Tests C
type nil = new 'LuaNil' push_eh _handler $P0[nil] = val1 - ok(0) + ok(0, "check key nil") pop_eh end _handler: @@ -116,7 +116,7 @@ Tests C
type .get_results (ex) $S0 = ex # table index is nil - like($S0, '^table') + like($S0, '^table', "check key nil") .end .sub 'check_deletion' # by assignment of nil @@ -128,7 +128,7 @@ Tests C
type val2 = new 'LuaString' val2 = "value2" $I0 = elements $P0 - is($I0, 0) + is($I0, 0, "check deletion") $P0[val1] = val1 $I0 = elements $P0 is($I0, 1) diff --git a/t/pmc/table_hll.t b/t/pmc/table_hll.t index 863d030..693ef7c 100644 --- a/t/pmc/table_hll.t +++ b/t/pmc/table_hll.t @@ -33,7 +33,7 @@ Tests C
type .sub 'check_HLL' $P0 = new 'LuaTable' $I0 = isa $P0, 'LuaTable' - is($I0, 1) + is($I0, 1, "check HLL") .end .sub 'check_len' @@ -63,7 +63,7 @@ Tests C
type .local pmc len len = $P0.'len'() $I0 = len - is($I0, 4) + is($I0, 4, "check len") val3 = new 'LuaNil' dec key1 $P0[key1] = val3 @@ -99,7 +99,7 @@ Tests C
type key = $P0[0] pmc2 = $P0[1] $S0 = pmc2 - is($S0, "value1") + is($S0, "value1", "check next") $P0 = pmc1.'next'(key) key = $P0[0] pmc2 = $P0[1] @@ -118,7 +118,7 @@ Tests C
type .sub 'check_tostring' $P0 = new 'LuaTable' $S0 = $P0 - like($S0, '^table: <[0..9A..Fa..f]>*') + like($S0, '^table: <[0..9A..Fa..f]>*', "check tostring") $P1 = $P0.'tostring'() $S0 = $P1 like($S0, '^table: <[0..9A..Fa..f]>*') @@ -130,7 +130,7 @@ Tests C
type $P0 = new 'LuaTable' $P1 = $P0.'tonumber'() $S0 = $P1 - is($S0, 'nil') + is($S0, 'nil', "check tonumber") $S0 = typeof $P1 is($S0, 'nil') .end diff --git a/t/pmc/thread.t b/t/pmc/thread.t index ff9cc15..8f1dd4a 100644 --- a/t/pmc/thread.t +++ b/t/pmc/thread.t @@ -35,7 +35,7 @@ Tests Lua C type .const 'Sub' F1 = 'f1' $P0 = new 'LuaThread', F1 $I0 = isa $P0, 'scalar' - is($I0, 0) + is($I0, 0, "check inheritance") $I0 = isa $P0, 'LuaAny' is($I0, 1) $I0 = isa $P0, 'LuaThread' @@ -51,7 +51,7 @@ Tests Lua C type .const 'Sub' F1 = 'f1' $P0 = new 'LuaThread', F1 $I0 = does $P0, 'scalar' - is($I0, 1) + is($I0, 1, "check interface") $I0 = does $P0, 'no_interface' is($I0, 0) .end @@ -60,21 +60,21 @@ Tests Lua C type .const 'Sub' F1 = 'f1' $P0 = new 'LuaThread', F1 $S0 = typeof $P0 - is($S0, 'thread') + is($S0, 'thread', "check name") .end .sub 'check_get_string' .const 'Sub' F1 = 'f1' $P0 = new 'LuaThread', F1 $S0 = $P0 - like($S0, '^thread: <[0..9A..Fa..f]>*') + like($S0, '^thread: <[0..9A..Fa..f]>*', "check get_string") .end .sub 'check_get_bool' .const 'Sub' F1 = 'f1' $P0 = new 'LuaThread', F1 $I0 = istrue $P0 - is($I0, 1) + is($I0, 1, "check get_bool") .end .sub 'check_logical_not' @@ -82,7 +82,7 @@ Tests Lua C type $P0 = new 'LuaThread', F1 $P1 = not $P0 $S0 = $P1 - is($S0, 'false') + is($S0, 'false', "check logical_not") $S0 = typeof $P1 is($S0, 'boolean') .end diff --git a/t/pmc/thread_hll.t b/t/pmc/thread_hll.t index 60372cb..2414111 100644 --- a/t/pmc/thread_hll.t +++ b/t/pmc/thread_hll.t @@ -35,7 +35,7 @@ Tests Lua C type .const 'Sub' F1 = 'f1' $P0 = new 'LuaThread', F1 $I0 = isa $P0, 'LuaThread' - is($I0, 1) + is($I0, 1, "check HLL") .end .sub 'f1' @@ -47,7 +47,7 @@ Tests Lua C type .const 'Sub' F1 = 'f1' $P0 = new 'LuaThread', F1 $S0 = $P0 - like($S0, '^thread: <[0..9A..Fa..f]>*') + like($S0, '^thread: <[0..9A..Fa..f]>*', "check tostring") $P1 = $P0.'tostring'() $S0 = $P1 like($S0, '^thread: <[0..9A..Fa..f]>*') @@ -60,7 +60,7 @@ Tests Lua C type $P0 = new 'LuaThread', F1 $P1 = $P0.'tonumber'() $S0 = $P1 - is($S0, 'nil') + is($S0, 'nil', "check tonumber") $S0 = typeof $P1 is($S0, 'nil') .end diff --git a/t/pmc/userdata.t b/t/pmc/userdata.t index 03c5de7..ebe6396 100644 --- a/t/pmc/userdata.t +++ b/t/pmc/userdata.t @@ -33,7 +33,7 @@ Tests C type .sub 'check_inheritance' $P0 = new 'LuaUserdata' $I0 = isa $P0, 'scalar' - is($I0, 0) + is($I0, 0, "check inheritance") $I0 = isa $P0, 'LuaAny' is($I0, 1) $I0 = isa $P0, 'LuaUserdata' @@ -43,7 +43,7 @@ Tests C type .sub 'check_interface' $P0 = new 'LuaUserdata' $I0 = does $P0, 'scalar' - is($I0, 1) + is($I0, 1, "check interface") $I0 = does $P0, 'no_interface' is($I0, 0) .end @@ -51,13 +51,13 @@ Tests C type .sub 'check_name' $P0 = new 'LuaUserdata' $S0 = typeof $P0 - is($S0, 'userdata') + is($S0, 'userdata', "check name") .end .sub 'check_get_string' $P0 = new 'LuaUserdata' $S0 = $P0 - like($S0, '^userdata: <[0..9A..Fa..f]>*') + like($S0, '^userdata: <[0..9A..Fa..f]>*', "check get_string") .end .sub 'check_get_bool' @@ -65,7 +65,7 @@ Tests C type $P1 = new 'Array' setattribute $P0, 'data', $P1 $I0 = istrue $P0 - is($I0, 1) + is($I0, 1, "check get_bool") .end .sub 'check_logical_not' @@ -74,7 +74,7 @@ Tests C type setattribute $P0, 'data', $P1 $P2 = not $P0 $S0 = $P2 - is($S0, 'false') + is($S0, 'false', "check logical_not") $S0 = typeof $P2 is($S0, 'boolean') .end diff --git a/t/pmc/userdata_hll.t b/t/pmc/userdata_hll.t index fe79cda..07f7009 100644 --- a/t/pmc/userdata_hll.t +++ b/t/pmc/userdata_hll.t @@ -33,7 +33,7 @@ Tests C type $P1 = new 'Array' setattribute $P0, 'data', $P1 $I0 = isa $P0, 'LuaUserdata' - is($I0, 1) + is($I0, 1, "check HLL") .end .sub 'check_tostring' @@ -41,7 +41,7 @@ Tests C type $P1 = new 'Array' setattribute $P0, 'data', $P1 $S0 = $P0 - like($S0, '^userdata: <[0..9A..Fa..f]>*') + like($S0, '^userdata: <[0..9A..Fa..f]>*', "check tostring") $P2 = $P0.'tostring'() $S0 = $P2 like($S0, '^userdata: <[0..9A..Fa..f]>*') @@ -55,7 +55,7 @@ Tests C type setattribute $P0, 'data', $P1 $P2 = $P0.'tonumber'() $S0 = $P2 - is($S0, 'nil') + is($S0, 'nil', "check tonumber") $S0 = typeof $P2 is($S0, 'nil') .end