Skip to content

Commit df06dcc

Browse files
updated message
1 parent 041261d commit df06dcc

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

tools/cli/internal/changelog/sunset.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,12 +44,13 @@ func (m *Changelog) newOasDiffEntriesFromSunsetEndpoints(
4444
}
4545

4646
// Avoid adding duplicates in the changelog.
47-
// Passing version="" to findChangelogEntry since the sunset date is the same for all the API versions
47+
// Passing version="" to findChangelogEntry since the sunset date of the endpoint with API version "version"
48+
// is the same in all the specs.
4849
if findChangelogEntry(m.BaseChangelog, config.Revision.Sunset, operationID, "", endpointRemovedCode) == nil {
4950
changes = append(changes, &outputfilter.OasDiffEntry{
5051
Date: config.Revision.Sunset,
5152
ID: endpointRemovedCode,
52-
Text: fmt.Sprintf("endpoint removed as it has reached its sunset date '%s'", config.Revision.Sunset),
53+
Text: fmt.Sprintf("endpoint with API Version '%s' was removed as it has reached its sunset date '%s'", version, config.Revision.Sunset),
5354
Level: int(checker.ERR),
5455
Operation: config.Revision.HTTPMethod,
5556
OperationID: operationID,

tools/cli/internal/changelog/sunset_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ func TestNewOasDiffEntriesFromSunsetEndpoints(t *testing.T) {
126126
Operation: "GET",
127127
OperationID: "listStreamInstances",
128128
Path: "/api/atlas/v2/groups/{id}/streams",
129-
Text: "endpoint removed as it has reached its sunset date '2023-07-12'",
129+
Text: "endpoint with API Version '2023-02-01' was removed as it has reached its sunset date '2023-07-12'",
130130
},
131131
}
132132

0 commit comments

Comments
 (0)