Skip to content

Commit

Permalink
use assertHeaderMissing in assertInertiaNotVary func
Browse files Browse the repository at this point in the history
  • Loading branch information
Roman Sarvarov committed Sep 27, 2024
1 parent c615c79 commit 215492c
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions helpers_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -136,11 +136,7 @@ func assertInertiaVary(t *testing.T, w *httptest.ResponseRecorder) {
func assertInertiaNotVary(t *testing.T, w *httptest.ResponseRecorder) {
t.Helper()

gotVary := w.Header().Get("Vary")

if gotVary != "" {
t.Fatal("unexpected Vary header found")
}
assertHeaderMissing(t, w, "Vary")
}

func assertHandlerServed(t *testing.T, handlers ...http.HandlerFunc) http.HandlerFunc {
Expand Down

0 comments on commit 215492c

Please sign in to comment.