Use main for the main provenance layer
This commit is contained in:
@@ -29,7 +29,7 @@ func TestNestedCLIOverridePreservesRetainedInputPresence(t *testing.T) {
|
||||
definition := Definition[config]{Resolve: func(value *config, resolution *Resolution) error {
|
||||
for _, key := range []string{"count", "zero", "enabled"} {
|
||||
info, ok := resolution.InputInfo(Keys("settings", "nested", key))
|
||||
if !ok || !info.Explicit || info.Origin.Layer != LayerBase {
|
||||
if !ok || !info.Explicit || info.Origin.Layer != LayerMain {
|
||||
t.Errorf("retained %s input info = %#v, %v", key, info, ok)
|
||||
}
|
||||
}
|
||||
@@ -54,7 +54,7 @@ func TestNestedCLIOverridePreservesRetainedInputPresence(t *testing.T) {
|
||||
}
|
||||
for _, key := range []string{"count", "zero", "enabled"} {
|
||||
info, ok := result.Metadata().Lookup(Keys("settings", "nested", key))
|
||||
if !ok || !info.Explicit || info.Origin.Layer != LayerBase || len(info.Origin.Locations) != 1 || info.Origin.Locations[0].SourceID != "source-1" {
|
||||
if !ok || !info.Explicit || info.Origin.Layer != LayerMain || len(info.Origin.Locations) != 1 || info.Origin.Locations[0].SourceID != "source-1" {
|
||||
t.Errorf("retained %s metadata = %#v, %v", key, info, ok)
|
||||
}
|
||||
}
|
||||
@@ -112,7 +112,7 @@ func TestPostDecodeOverrideLifecycleMatchesOrdinaryAndLayeredLoads(t *testing.T)
|
||||
if result.Config.Count != 5 || result.Config.Derived != 8 {
|
||||
t.Errorf("%s resolved configuration = %#v", name, result.Config)
|
||||
}
|
||||
if got := historyLayers(result.Metadata().History(Keys("count"))); !reflect.DeepEqual(got, []Layer{LayerDefault, LayerBase, LayerCLI, LayerResolution}) {
|
||||
if got := historyLayers(result.Metadata().History(Keys("count"))); !reflect.DeepEqual(got, []Layer{LayerDefault, LayerMain, LayerCLI, LayerResolution}) {
|
||||
t.Errorf("%s count history layers = %#v", name, got)
|
||||
}
|
||||
info, ok := result.Metadata().Lookup(Keys("count"))
|
||||
|
||||
Reference in New Issue
Block a user