ProducerStateManager newProducerStateManager() throws IOException {
        return new ProducerStateManager(
            topicPartition,
            logDir,
            5 * 60 * 1000,
            new ProducerStateManagerConfig(TransactionLogConfigs.PRODUCER_ID_EXPIRATION_MS_DEFAULT, true),
            new MockTime()
        );
    }
This test was intended to check file size and positions after closing and reopening a segment.
Since there is no log file in ElasticLogSegment, we only test the segment size when reopening.
The method name is kept the same for compatibility.
core/src/test/java/kafka/log/streamaspect/ElasticLogSegmentTest.java