1 package de.juplo.kafka.chat.backend;
3 import org.junit.jupiter.api.DisplayName;
4 import org.junit.jupiter.api.Test;
5 import org.springframework.http.MediaType;
6 import org.testcontainers.shaded.org.awaitility.Awaitility;
8 import java.time.Duration;
11 public abstract class AbstractConfigurationWithShardingIT extends AbstractConfigurationIT
14 @DisplayName("A PUT-message for a not owned shard yields 404 - NOT FOUND")
15 void testNotFoundForPutMessageToAChatRoomInNotOwnedShard()
17 String otherChatRoomId = "4e7246a6-29ae-43ea-b56f-669c3481ac19";
21 .atMost(Duration.ofSeconds(15))
26 "http://localhost:{port}/{chatRoomId}/otto/66",
29 .contentType(MediaType.TEXT_PLAIN)
30 .accept(MediaType.APPLICATION_JSON)
31 .bodyValue("The devil rules route 66")
33 .expectStatus().isNotFound());