diff options
author | Jon Marius Venstad <venstad@gmail.com> | 2021-07-01 15:42:49 +0200 |
---|---|---|
committer | Jon Marius Venstad <venstad@gmail.com> | 2021-07-01 15:42:49 +0200 |
commit | d86cd94e2b2156875794dddb13d178983193cac6 (patch) | |
tree | 7c21da2ffce936a24eeaeadb9fb2f34557c3a90d /container-messagebus | |
parent | bccacd48ddeb391d9a644bbfb0b702c7a2bc6a3e (diff) |
Add new TestUtils file
Diffstat (limited to 'container-messagebus')
-rw-r--r-- | container-messagebus/src/main/java/com/yahoo/messagebus/jdisc/test/TestUtils.java | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/container-messagebus/src/main/java/com/yahoo/messagebus/jdisc/test/TestUtils.java b/container-messagebus/src/main/java/com/yahoo/messagebus/jdisc/test/TestUtils.java new file mode 100644 index 00000000000..85ad241259f --- /dev/null +++ b/container-messagebus/src/main/java/com/yahoo/messagebus/jdisc/test/TestUtils.java @@ -0,0 +1,21 @@ +// Copyright Verizon Media. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. +package com.yahoo.messagebus.jdisc.test; + +import com.yahoo.cloud.config.SlobroksConfig; +import com.yahoo.jrt.Spec; +import com.yahoo.jrt.slobrok.server.Slobrok; + +/** + * @author jonmv + */ +public class TestUtils { + + private TestUtils() { } + + public static SlobroksConfig configFor(Slobrok slobrok) { + return new SlobroksConfig.Builder().slobrok(new SlobroksConfig.Slobrok.Builder() + .connectionspec(new Spec("localhost", slobrok.port()).toString())) + .build(); + } + +} |