From ee1f55630f0637d88d170e7b52abbb7fca101002 Mon Sep 17 00:00:00 2001 From: Mike Farah Date: Mon, 15 Feb 2021 17:33:41 +1100 Subject: [PATCH] nicer reduce example --- pkg/yqlib/operator_reduce_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/yqlib/operator_reduce_test.go b/pkg/yqlib/operator_reduce_test.go index 87654b6..d96a1b2 100644 --- a/pkg/yqlib/operator_reduce_test.go +++ b/pkg/yqlib/operator_reduce_test.go @@ -26,7 +26,7 @@ var reduceOperatorScenarios = []expressionScenario{ subdescription: "The _$context_ variable set by reduce lets you access the data outside the reduce block.", document: `a: cat`, document2: `b: dog`, - expression: `fileIndex as $item ireduce ({}; . * ($context | select(fileIndex==$item)) )`, + expression: `fi as $item ireduce ({}; . * ($context | select(fileIndex==$item)) )`, expected: []string{ "D0, P[], (!!map)::a: cat\nb: dog\n", },