mirror of
https://github.com/mikefarah/yq.git
synced 2026-09-07 02:48:27 +08:00
Fixed self assigned issue #1107
This commit is contained in:
@@ -28,6 +28,15 @@ var assignOperatorScenarios = []expressionScenario{
|
||||
"D0, P[], (doc)::{a: null}\n",
|
||||
},
|
||||
},
|
||||
{
|
||||
skipDoc: true,
|
||||
description: "self reference",
|
||||
document: "a: cat",
|
||||
expression: `.a = [.a]`,
|
||||
expected: []string{
|
||||
"D0, P[], (doc)::a:\n - cat\n",
|
||||
},
|
||||
},
|
||||
{
|
||||
description: "Update node to be the child value",
|
||||
document: `{a: {b: {g: foof}}}`,
|
||||
|
||||
Reference in New Issue
Block a user