Skip to content

Commit

Permalink
Use manual setup instead of change values for all tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
ran-su committed Oct 25, 2024
1 parent 2d3b4b3 commit 8ced5de
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions netty/src/test/java/io/grpc/netty/NettyClientHandlerTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,8 @@ public class NettyClientHandlerTest extends NettyHandlerTestBase<NettyClientHand
private NettyClientStream.TransportState streamTransportState;
private Http2Headers grpcHeaders;
private long nanoTime; // backs a ticker, for testing ping round-trip time measurement
private int maxHeaderListSize = 8000;
private int softLimitHeaderListSize = 2000;
private int maxHeaderListSize = Integer.MAX_VALUE;
private int softLimitHeaderListSize = Integer.MAX_VALUE;
private int streamId = STREAM_ID;
private ClientTransportLifecycleManager lifecycleManager;
private KeepAliveManager mockKeepAliveManager = null;
Expand Down Expand Up @@ -222,6 +222,10 @@ public Void answer(InvocationOnMock invocation) throws Throwable {
@Test
@SuppressWarnings("InlineMeInliner")
public void sendLargerThanSoftLimitHeaderMayFail() throws Exception {
maxHeaderListSize = 8000;
softLimitHeaderListSize = 2000;
manualSetUp();

createStream();
// total head size of 7999, soft limit = 2000 and max = 8000.
// This header has 5999/6000 chance to be rejected.
Expand Down

0 comments on commit 8ced5de

Please sign in to comment.