Two sub bugs fixed; two new gsub tests have been added.
./jq --run-tests < tests/onig.test
has been run successfully:
...
Testing 'gsub("a";"b")' at line number 70
Testing 'gsub( "(.*)"; ""; "x")' at line number 74
...
22 of 22 tests passed (0 malformed)
This commit is contained in:
1 parent
ec583deefa
commit
ad8d1a8cc8
2 files changed
+12
-4
No files matched your search
@@ -67,6 +67,14 @@ gsub("(?<d>\\d)"; ":\(.d);")
|
||||
"a1b2"
|
||||
"a:1;b:2;"
|
||||
|
||||
gsub("a";"b")
|
||||
"aaaaa"
|
||||
"bbbbb"
|
||||
|
||||
gsub( "(.*)"; ""; "x")
|
||||
""
|
||||
""
|
||||
|
||||
[.[] | scan(", ")]
|
||||
["a,b, c, d, e,f",", a,b, c, d, e,f, "]
|
||||
[", ",", ",", ",", ",", ",", ",", ",", "]
|
||||
|
||||
Reference in new issue
Block a user