backend/local: adding some informative comments to commented-out tests

This commit is contained in:
Kristin Laemmert 2018-09-28 16:35:34 -07:00 committed by Martin Atkins
parent c661157999
commit 3da04ef9fc
2 changed files with 4 additions and 1 deletions

View File

@ -84,7 +84,6 @@ func (b *Local) opApply(
}
trivialPlan := plan.Changes.Empty()
hasUI := op.UIOut != nil && op.UIIn != nil
mustConfirm := hasUI && ((op.Destroy && (!op.DestroyForce && !op.AutoApprove)) || (!op.Destroy && !op.AutoApprove && !trivialPlan))
if mustConfirm {

View File

@ -189,6 +189,8 @@ func TestLocal_planDestroy(t *testing.T) {
}
plan := testReadPlan(t, planPath)
// This statement can be removed when the test is fixed and replaced with the
// commented-out test below.
if plan == nil {
t.Fatalf("plan is nil")
}
@ -223,6 +225,8 @@ func TestLocal_planOutPathNoChange(t *testing.T) {
}
plan := testReadPlan(t, planPath)
// This statement can be removed when the test is fixed and replaced with the
// commented-out test below.
if plan == nil {
t.Fatalf("plan is nil")
}