Skip to content

Commit 827721c

Browse files
authored
test: tighten network error assertion in schema fetch test
1 parent d512d8b commit 827721c

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

internal/config/validation_schema_fetch_test.go

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -129,10 +129,7 @@ func TestFetchAndFixSchema_NetworkError(t *testing.T) {
129129

130130
assert.Error(t, err)
131131
assert.Nil(t, result)
132-
// Error message varies slightly depending on whether it is a network failure
133-
// ("failed to fetch schema from <url>: ...") or an HTTP error status
134-
// ("failed to fetch schema: HTTP NNN"), so check the common prefix.
135-
assert.ErrorContains(t, err, "failed to fetch schema")
132+
assert.ErrorContains(t, err, "failed to fetch schema from")
136133
}
137134

138135
// TestFetchAndFixSchema_Timeout tests handling of request timeouts

0 commit comments

Comments
 (0)