mirror of
https://github.com/mikefarah/yq.git
synced 2026-09-07 02:48:27 +08:00
Adding splat[] short hand to explode,collect,flatten,groupby,path,pivot,select and more
This commit is contained in:
@@ -188,6 +188,16 @@ var anchorOperatorScenarios = []expressionScenario{
|
||||
"D0, P[b], (!!str)::cat\n",
|
||||
},
|
||||
},
|
||||
{
|
||||
description: "Explode splat",
|
||||
skipDoc: true,
|
||||
document: `{a: &a cat, b: *a}`,
|
||||
expression: `explode(.)[]`,
|
||||
expected: []string{
|
||||
"D0, P[a], (!!str)::cat\n",
|
||||
"D0, P[b], (!!str)::cat\n",
|
||||
},
|
||||
},
|
||||
{
|
||||
description: "Explode alias and anchor - check original parent",
|
||||
skipDoc: true,
|
||||
|
||||
Reference in New Issue
Block a user