Use main for the main provenance layer
This commit is contained in:
@@ -523,17 +523,17 @@ func TestLoadMetadataReflectsDefaultsInputAndDetachedRecords(t *testing.T) {
|
||||
t.Fatalf("kept = %#v, %v", kept, ok)
|
||||
}
|
||||
set, ok := metadata.Lookup(Keys("nested", "set"))
|
||||
if !ok || !set.Explicit || set.Origin.Layer != LayerBase || len(set.Origin.Locations) != 1 {
|
||||
if !ok || !set.Explicit || set.Origin.Layer != LayerMain || len(set.Origin.Locations) != 1 {
|
||||
t.Fatalf("set = %#v, %v", set, ok)
|
||||
}
|
||||
nullable, ok := metadata.Lookup(Keys("nullable"))
|
||||
if !ok || !nullable.Explicit || !nullable.Null || nullable.Origin.Layer != LayerBase {
|
||||
if !ok || !nullable.Explicit || !nullable.Null || nullable.Origin.Layer != LayerMain {
|
||||
t.Fatalf("nullable = %#v, %v", nullable, ok)
|
||||
}
|
||||
if metadata.IsExplicit(Keys("nested", "kept")) || !metadata.IsExplicit(Keys("nested", "set")) {
|
||||
t.Fatal("explicit presence disagrees with lookup")
|
||||
}
|
||||
if history := metadata.History(Keys("nested", "set")); len(history) != 2 || history[0].Origin.Layer != LayerDefault || history[1].Origin.Layer != LayerBase || len(history[1].Previous) != 1 {
|
||||
if history := metadata.History(Keys("nested", "set")); len(history) != 2 || history[0].Origin.Layer != LayerDefault || history[1].Origin.Layer != LayerMain || len(history[1].Previous) != 1 {
|
||||
t.Fatalf("history = %#v", history)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user