You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
new TopologyTestDriver(topology) - does not pick these up instead I need to manually create the properties and pass them in:
@ConfigProperty(name="quarkus.kafka-streams.default.key.serde")
String keySerde;
@ConfigProperty(name="quarkus.kafka-streams.default.value.serde")
String valueSerde;
@ConfigProperty(name="schema.registry.url")
String schemaRegistry;
@Test
public void myTest() {
// using DSL
StreamsBuilder builder = new StreamsBuilder();
.... build thing to test
Topology topology = builder.build();
// create test driver
Properties p = new Properties();
p.setProperty(StreamsConfig.DEFAULT_KEY_SERDE_CLASS_CONFIG, keySerde);
p.setProperty(StreamsConfig.DEFAULT_VALUE_SERDE_CLASS_CONFIG, valueSerde);
p.setProperty("schema.registry.url", schemaRegistry);
try (TopologyTestDriver testDriver = new TopologyTestDriver(topology, p)) {
### Implementation ideas
It would be great if it could pick up the same properties I use to configure the app and I didn't have manually add in the right mappings.
i.e.
Description
In my application.properties I have:
in my application-test.properties I have:
new TopologyTestDriver(topology)
- does not pick these up instead I need to manually create the properties and pass them in:quarkus.kafka-streams.schema-registry-url
quarkus.kafka-streams.default.key.serde
quarkus.kafka-streams.default.value.serde
The text was updated successfully, but these errors were encountered: