tools/fix: add tests for value alias conversion when "self" is in scope
Test cases where "cue fix --exp=aliasv2" converts old-style value
aliases (X={...}) to "let X = self" in structs where "self" is already
defined as a field, let clause, or alias. The generated "let X = self"
binds to the wrong value in these cases.
For #4151.
Signed-off-by: Daniel Martí <mvdan@mvdan.cc>
Change-Id: Iaeabbd3fd53f94a3aab95843ee7e2196c14aa935
Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1231143
TryBot-Result: CUEcueckoo <cueckoo@cuelang.org>
Unity-Result: CUE porcuepine <cue.porcuepine@gmail.com>
Reviewed-by: Marcel van Lohuizen <mpvl@gmail.com>