Skip to content

Commit

Permalink
Remove unused assignment
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinmcconnell committed Aug 4, 2024
1 parent 8a0e785 commit b9548f7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/server/router_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,14 +87,14 @@ func TestRouter_UpdatingOptions(t *testing.T) {
targetOptions.MaxRequestBodySize = 10
require.NoError(t, router.SetServiceTarget("service1", "dummy.example.com", target, serviceOptions, targetOptions, DefaultDeployTimeout, DefaultDrainTimeout))

statusCode, body := sendRequest(router, httptest.NewRequest(http.MethodPost, "http://dummy.example.com", strings.NewReader("Something longer than 10")))
statusCode, _ := sendRequest(router, httptest.NewRequest(http.MethodPost, "http://dummy.example.com", strings.NewReader("Something longer than 10")))
assert.Equal(t, http.StatusRequestEntityTooLarge, statusCode)

targetOptions.BufferRequests = false
targetOptions.MaxRequestBodySize = 0
require.NoError(t, router.SetServiceTarget("service1", "dummy.example.com", target, serviceOptions, targetOptions, DefaultDeployTimeout, DefaultDrainTimeout))

statusCode, body = sendRequest(router, httptest.NewRequest(http.MethodPost, "http://dummy.example.com", strings.NewReader("Something longer than 10")))
statusCode, body := sendRequest(router, httptest.NewRequest(http.MethodPost, "http://dummy.example.com", strings.NewReader("Something longer than 10")))
assert.Equal(t, http.StatusOK, statusCode)
assert.Equal(t, "first", body)

Expand Down

0 comments on commit b9548f7

Please sign in to comment.