MCPcopy Create free account
hub / github.com/algolia/cli / TestApplicationPlanChangeAborted_WithReason

Function TestApplicationPlanChangeAborted_WithReason

pkg/telemetry/events_test.go:82–91  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

80}
81
82func TestApplicationPlanChangeAborted_WithReason(t *testing.T) {
83 tracker := NewFlowTracker()
84 tracker.SetStep(StepPlan)
85
86 event := ApplicationPlanChangeAborted(DirectionUpgrade, tracker, AbortReasonAlreadyOnPlan)
87 assert.Equal(t, EventApplicationPlanChangeAborted, event.Name)
88 assert.Equal(t, DirectionUpgrade, event.Properties["direction"])
89 assert.Equal(t, StepPlan, event.Properties["step"])
90 assert.Equal(t, AbortReasonAlreadyOnPlan, event.Properties["reason"])
91}
92
93func TestApplicationPlanChangeAborted_WithoutReason(t *testing.T) {
94 event := ApplicationPlanChangeAborted(DirectionDowngrade, NewFlowTracker(), "")

Callers

nothing calls this directly

Calls 3

SetStepMethod · 0.95
NewFlowTrackerFunction · 0.85

Tested by

no test coverage detected