strJoin() now supports linked list and added strJoin(sep, linked-list) test

This commit is contained in:
2026-08-02 17:03:35 +02:00
parent b080eaf49f
commit 5cd48bdc50
2 changed files with 44 additions and 6 deletions
+4 -2
View File
@@ -35,7 +35,9 @@ func TestExpr(t *testing.T) {
/* 19 */ {`a=2; ${a}`, int64(2), nil},
/* 20 */ {`$_=2; $_`, int64(2), nil},
/* 21 */ {`$$`, dict.NewDict(map[any]any{"vars": dict.NewDict(nil), "funcs": dict.NewDict(nil)}), nil},
/* 22 */ {`
/* 22 */ {`builtin "string"; strJoin("-", [<"a", "b", "c">])`, nil, `strJoin(): invalid value [<"a", "b", "c">] (linked-list) for parameter "item"`},
/* 22 */ {`builtin ""`, nil, `strJoin(): invalid value [<"a", "b", "c">] (linked-list) for parameter "item"`},
/* 23 */ {`
ds={
"init":func(@end){@current=0 but true},
//"current":func(){current},
@@ -50,6 +52,6 @@ func TestExpr(t *testing.T) {
}
// t.Setenv("EXPR_PATH", ".")
// RunTestSuiteSpec(t, section, inputs, 19)
// RunTestSuiteSpec(t, section, inputs, 22)
RunTestSuite(t, section, inputs)
}