From 8ac12c99fc59b01da40c2939cb4a7b72d32d2153 Mon Sep 17 00:00:00 2001 From: Charlie Stanton Date: Sat, 27 Apr 2024 09:29:46 +0100 Subject: Add iterating destructures --- main/main_test.go | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'main') diff --git a/main/main_test.go b/main/main_test.go index b745202..8512b62 100644 --- a/main/main_test.go +++ b/main/main_test.go @@ -86,6 +86,13 @@ func TestMain(t *testing.T) { input: miscInput, expected: `["Charlie Johnson","Tom Johnson","Charlie Chaplin","John Johnson"]`, }, + { + name: "Get full names with merge full command", + program: "s/#(\"people\"$_ :(): )-/p M/#( \"people\" @( . #()# )@ )#/{ s/#( \"people\"$_ @( . #[ \"first_name\" \".{-0}$a\" | \"last_name\" \".{-0}$b\" | .. $_]- `\"$a $b\"` )@ )-/p }", + quiet: true, + input: miscInput, + expected: `["Charlie Johnson","Tom Johnson","Charlie Chaplin","John Johnson"]`, + }, { name: "Verbose concat array values", program: "as/#( \"array\"$_ :(): )-/{ :s N/#( .$_ . )-/{ es/.{-0}:():/be mbs } :em s/:( -( ~(.{-0}` `)-{-0} ~(.{-0})- )~ )-/p }", -- cgit v1.2.3