From e8846b85f036a366754070cc6551a4e452e8d51f Mon Sep 17 00:00:00 2001 From: Hussain Kara Fallah Date: Tue, 6 Aug 2024 13:30:30 +0300 Subject: [PATCH] test good --- .../transferwise/kafka/tkms/test/TestMessageDecorator.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tw-tkms-starter/src/test/java/com/transferwise/kafka/tkms/test/TestMessageDecorator.java b/tw-tkms-starter/src/test/java/com/transferwise/kafka/tkms/test/TestMessageDecorator.java index 10147e3..478af31 100644 --- a/tw-tkms-starter/src/test/java/com/transferwise/kafka/tkms/test/TestMessageDecorator.java +++ b/tw-tkms-starter/src/test/java/com/transferwise/kafka/tkms/test/TestMessageDecorator.java @@ -13,10 +13,10 @@ public class TestMessageDecorator implements ITkmsMessageDecorator { @Override public List
getHeaders(TkmsMessage message) { var h1 = new Header().setKey("tool").setValue("jambi".getBytes(StandardCharsets.UTF_8)); - if (message.getKey() == null) { - return List.of(); + if (message.getValue() != null && new String(message.getValue(), StandardCharsets.UTF_8).startsWith("Here from")) { + return List.of(h1); } - return List.of(h1); + return List.of(); } }