Migrate structural and inspection fixtures
This commit is contained in:
@@ -17,10 +17,10 @@ func TestLayeredSequenceProjectsNestedSourceDestinations(t *testing.T) {
|
||||
t.Run(fmt.Sprintf("%s/underlay=%t", mode, underlay), func(t *testing.T) {
|
||||
files := fstest.MapFS{}
|
||||
for _, id := range []string{"a", "b", "c"} {
|
||||
files[id+"/record.yml"] = &fstest.MapFile{Data: []byte("configkit: {imports: [{path: helper.yml}]}\nid: " + id + "\n")}
|
||||
files[id+"/record.yml"] = &fstest.MapFile{Data: []byte("config: {imports: [{path: helper.yml}]}\nid: " + id + "\n")}
|
||||
files[id+"/helper.yml"] = &fstest.MapFile{Data: []byte("value: " + id + "\n")}
|
||||
}
|
||||
files["main.yml"] = &fstest.MapFile{Data: []byte("configkit:\n sequences: [{destination: [items], key: id, mode: " + mode + "}]\n imports: [{glob: '*/record.yml', destination: [items], placement: sequence-item}]\n")}
|
||||
files["main.yml"] = &fstest.MapFile{Data: []byte("config:\n sequences: [{destination: [items], key: id, mode: " + mode + "}]\n imports: [{glob: '*/record.yml', destination: [items], placement: sequence-item}]\n")}
|
||||
lower := "items: [{id: b}, {id: a}, {id: keep}]\n"
|
||||
want := map[string]int{"a": 1, "b": 0, "c": 3}
|
||||
if mode == "append" {
|
||||
|
||||
Reference in New Issue
Block a user