From fa14a973462de4e31d6c2821a6f45457ace2bfa3 Mon Sep 17 00:00:00 2001 From: Daniel Schmidt Date: Fri, 9 Jan 2026 14:09:11 +0100 Subject: [PATCH] stacks: ensure an empty plan sends an applied status for the component --- internal/rpcapi/stacks_test.go | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/internal/rpcapi/stacks_test.go b/internal/rpcapi/stacks_test.go index 1c08317cf6..0e2d7d4da8 100644 --- a/internal/rpcapi/stacks_test.go +++ b/internal/rpcapi/stacks_test.go @@ -1278,6 +1278,29 @@ func TestStackChangeProgressDuringApply(t *testing.T) { }, }, }, + "empty": { + mode: stacks.PlanMode_NORMAL, + source: "git::https://example.com/empty.git", + state: []stackstate.AppliedChange{ + &stackstate.AppliedChangeComponentInstance{ + ComponentAddr: mustAbsComponent(t, "component.self"), + ComponentInstanceAddr: mustAbsComponentInstance(t, "component.self"), + }, + }, + want: []*stacks.StackChangeProgress{ + { + Event: &stacks.StackChangeProgress_ComponentInstanceStatus_{ + ComponentInstanceStatus: &stacks.StackChangeProgress_ComponentInstanceStatus{ + Addr: &stacks.ComponentInstanceInStackAddr{ + ComponentAddr: "component.self", + ComponentInstanceAddr: "component.self", + }, + Status: stacks.StackChangeProgress_ComponentInstanceStatus_APPLIED, + }, + }, + }, + }, + }, } for name, tc := range tcs {