From 8b775a0f2b531b76ba3378faf14bd78bf7cff9e3 Mon Sep 17 00:00:00 2001 From: rusirijayodaillesinghe Date: Tue, 21 Nov 2023 11:43:26 +0530 Subject: [PATCH] Add unit test for the added property "perConnectionBufferLimitBytes" --- adapter/internal/oasparser/envoyconf/listener_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/adapter/internal/oasparser/envoyconf/listener_test.go b/adapter/internal/oasparser/envoyconf/listener_test.go index 81f424d007..ace96b173e 100644 --- a/adapter/internal/oasparser/envoyconf/listener_test.go +++ b/adapter/internal/oasparser/envoyconf/listener_test.go @@ -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] @@ -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.") }