@Test
  void shouldThrowExceptionWhenFillBlockStateCallsExceedsMaxBlockCallSize() {
    List<BlockStateCall> blockStateCalls = new ArrayList<>();
    blockStateCalls.add(createBlockStateCall(101L, 1609459212L));
    blockStateCalls.add(createBlockStateCall(257L, 1609459248L));
    blockStateCalls.add(createBlockStateCall(null, 1609459224L));

    IllegalArgumentException exception =
        assertThrows(
            IllegalArgumentException.class,
            () -> BlockStateCalls.fillBlockStateCalls(blockStateCalls, mockBlockHeader));
    assertEquals(
        "Block number 258 exceeds the limit of 257 (header: 1 + MAX_BLOCK_CALL_SIZE: 256)",
        exception.getMessage());
  }
Tests that an exception is thrown when the maximum number of BlockStateCalls is exceeded.
ethereum/core/src/test/java/org/hyperledger/besu/ethereum/transaction/BlockStateCallsTest.java