Skip to content

Commit

Permalink
Add unit test for the added property "perConnectionBufferLimitBytes"
Browse files Browse the repository at this point in the history
  • Loading branch information
RusJaI committed Nov 21, 2023
1 parent e0c5666 commit 8b775a0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions adapter/internal/oasparser/envoyconf/listener_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ func TestCreateListenerWithRds(t *testing.T) {
assert.NotEmpty(t, securedListener.FilterChains, "Filter chain for listener should not be null.")
assert.NotNil(t, securedListener.FilterChains[0].GetTransportSocket(),
"Transport Socket should not be null for secured listener")
assert.Equal(t, 1048576, securedListener.PerConnectionBufferLimitBytes,
assert.Equal(t, uint32(1048576), securedListener.PerConnectionBufferLimitBytes.GetValue(),
"Buffered payload limit mismatch for secured Listener.")

nonSecuredListener := listeners[1]
Expand All @@ -60,7 +60,7 @@ func TestCreateListenerWithRds(t *testing.T) {
assert.NotEmpty(t, nonSecuredListener.FilterChains, "Filter chain for listener should not be null.")
assert.Nil(t, nonSecuredListener.FilterChains[0].GetTransportSocket(),
"Transport Socket should be null for non-secured listener")
assert.Equal(t, 1048576, nonSecuredListener.PerConnectionBufferLimitBytes,
assert.Equal(t, uint32(1048576), nonSecuredListener.PerConnectionBufferLimitBytes.GetValue(),
"Buffered payload limit mismatch for non-secured Listener.")
}

Expand Down

0 comments on commit 8b775a0

Please sign in to comment.