Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
memoriav
Memobase 2020
services
Import Process
Mapper Service
Commits
d8530dab
Commit
d8530dab
authored
Oct 20, 2020
by
Jonas Waeber
Browse files
Update integration tests & remove unnecessary local variable
parent
df7388f6
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/main/kotlin/Service.kt
View file @
d8530dab
...
...
@@ -35,11 +35,8 @@ class Service(file: String = "app.yml") {
file
,
useStreamsConfig
=
true
)
private
val
builder
=
KafkaTopology
(
settings
).
prepare
()
fun
run
()
{
val
stream
=
KafkaStreams
(
builder
.
build
(),
settings
.
kafkaStreamsSettings
)
val
stream
=
KafkaStreams
(
KafkaTopology
(
settings
).
prepare
().
build
(),
settings
.
kafkaStreamsSettings
)
stream
.
use
{
it
.
start
()
while
(
stream
.
state
().
isRunning
)
{
...
...
src/test/kotlin/IntegrationTests.kt
View file @
d8530dab
...
...
@@ -27,7 +27,6 @@ import org.apache.kafka.common.serialization.StringDeserializer
import
org.apache.kafka.common.serialization.StringSerializer
import
org.apache.kafka.streams.TopologyTestDriver
import
org.apache.kafka.streams.test.ConsumerRecordFactory
import
org.apache.logging.log4j.LogManager
import
org.assertj.core.api.Assertions.assertThat
import
org.junit.jupiter.api.TestInstance
import
org.junit.jupiter.params.ParameterizedTest
...
...
@@ -41,7 +40,6 @@ import java.util.stream.Stream
@TestInstance
(
TestInstance
.
Lifecycle
.
PER_CLASS
)
class
IntegrationTests
{
private
val
log
=
LogManager
.
getLogger
(
"TestLogger"
)
private
val
resourcePath
=
"src/test/resources"
private
fun
readFile
(
fileName
:
String
):
String
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment