Skip to content

Commit 7f894fe

Browse files
JAVA-29164 | fixing failing test (#15401)
1 parent ec8fe08 commit 7f894fe

4 files changed

Lines changed: 6 additions & 6 deletions

File tree

apache-kafka/pom.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,7 @@
181181
</build>
182182

183183
<properties>
184+
<jackson.version>2.13.4</jackson.version>
184185
<kafka.version>3.4.0</kafka.version>
185186
<testcontainers-kafka.version>1.19.3</testcontainers-kafka.version>
186187
<testcontainers-jupiter.version>1.15.3</testcontainers-jupiter.version>

apache-kafka/src/test/java/com/baeldung/flink/BackupCreatorIntegrationTest.java renamed to apache-kafka/src/test/java/com/baeldung/flink/BackupCreatorUnitTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
import static org.junit.Assert.assertArrayEquals;
3030
import static org.junit.Assert.assertEquals;
3131

32-
public class BackupCreatorIntegrationTest {
32+
public class BackupCreatorUnitTest {
3333
public static ObjectMapper mapper;
3434

3535
@Before

apache-kafka/src/test/java/com/baeldung/flink/WordCapitalizerIntegrationTest.java renamed to apache-kafka/src/test/java/com/baeldung/flink/WordCapitalizerUnitTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
import java.util.List;
1111
import java.util.stream.Collectors;
1212

13-
public class WordCapitalizerIntegrationTest {
13+
public class WordCapitalizerUnitTest {
1414

1515
@Test
1616
public void givenDataSet_whenExecuteWordCapitalizer_thenReturnCapitalizedWords() throws Exception {

apache-kafka/src/test/java/com/baeldung/kafkastreams/KafkaStreamsLiveTest.java

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,7 @@
2121
import org.junit.Test;
2222

2323
public class KafkaStreamsLiveTest {
24-
private String bootstrapServers = "localhost:9092";
25-
private Path stateDirectory;
24+
private final String bootstrapServers = "localhost:9092";
2625

2726
@Test
2827
@Ignore("it needs to have kafka broker running on local")
@@ -44,8 +43,8 @@ public void shouldTestKafkaStreams() throws InterruptedException {
4443

4544
// Use a temporary directory for storing state, which will be automatically removed after the test.
4645
try {
47-
this.stateDirectory = Files.createTempDirectory("kafka-streams");
48-
streamsConfiguration.put(StreamsConfig.STATE_DIR_CONFIG, this.stateDirectory.toAbsolutePath()
46+
Path stateDirectory = Files.createTempDirectory("kafka-streams");
47+
streamsConfiguration.put(StreamsConfig.STATE_DIR_CONFIG, stateDirectory.toAbsolutePath()
4948
.toString());
5049
} catch (final IOException e) {
5150
throw new UncheckedIOException("Cannot create temporary directory", e);

0 commit comments

Comments
 (0)