|
|
|
|
@ -419,9 +419,10 @@ resource "ephem_write_only" "wo" {
|
|
|
|
|
t.Fatalf("Expected 1 resource change, got %d", len(plan.Changes.Resources))
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// if len(plan.Changes.Resources[0].AfterWriteOnlyPaths) != 1 {
|
|
|
|
|
// t.Fatalf("Expected 1 write-only attribute, got %d", len(plan.Changes.Resources[0].AfterWriteOnlyPaths))
|
|
|
|
|
// }
|
|
|
|
|
if len(plan.Changes.Resources[0].AfterWriteOnlyPaths) != 1 {
|
|
|
|
|
t.Fatalf("Expected 1 write-only attribute, got %d", len(plan.Changes.Resources[0].AfterWriteOnlyPaths))
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
schemas, schemaDiags := ctx.Schemas(m, plan.PriorState)
|
|
|
|
|
assertNoDiagnostics(t, schemaDiags)
|
|
|
|
|
planChanges, err := plan.Changes.Decode(schemas)
|
|
|
|
|
@ -468,11 +469,11 @@ resource "ephem_write_only" "wo" {
|
|
|
|
|
t.Fatalf("normal attribute not as expected")
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// if len(resourceInstance.Current.AttrWriteOnlyPaths) != 1 {
|
|
|
|
|
// t.Fatalf("Expected 1 write only attribute")
|
|
|
|
|
// }
|
|
|
|
|
if len(resourceInstance.Current.AttrWriteOnlyPaths) != 1 {
|
|
|
|
|
t.Fatalf("Expected 1 write only attribute")
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// if !resourceInstance.Current.AttrWriteOnlyPaths[0].Equals(cty.GetAttrPath("write_only")) {
|
|
|
|
|
// t.Fatalf("Expected write_only to be a write only attribute")
|
|
|
|
|
// }
|
|
|
|
|
if !resourceInstance.Current.AttrWriteOnlyPaths[0].Equals(cty.GetAttrPath("write_only")) {
|
|
|
|
|
t.Fatalf("Expected write_only to be a write only attribute")
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|