@@ -60,58 +60,4 @@ class CommandGatewayExtensionsTest {
6060
6161 verify { subjectGateway.send(exampleCommand, any<CommandCallback <ExampleCommand , Any >>()) }
6262 }
63-
64- @Test
65- fun `SendAndWaitWithResponse extension should invoke correct method on the gateway` () {
66- every { subjectGateway.sendAndWait<Any >(exampleCommand) } returns Unit
67-
68- subjectGateway.sendAndWaitWithResponse<Any >(exampleCommand)
69-
70- verify { subjectGateway.sendAndWait<Any >(exampleCommand) }
71- }
72-
73- @Test
74- fun `SendAndWaitWithResponse extension should invoke correct method on the gateway without explicit generic parameter` () {
75- every { subjectGateway.sendAndWait<Any >(exampleCommand) } returns Unit
76-
77- fun methodWithExplicitReturnValue (): Unit = subjectGateway.sendAndWaitWithResponse(exampleCommand)
78-
79- methodWithExplicitReturnValue()
80-
81- verify { subjectGateway.sendAndWait<Any >(exampleCommand) }
82- }
83-
84- @Test
85- fun `SendAndWaitWithResponse with timeout extension should invoke correct method on the gateway` () {
86- every { subjectGateway.sendAndWait<Any >(exampleCommand, timeoutInterval, TimeUnit .MICROSECONDS ) } returns Unit
87-
88- subjectGateway.sendAndWaitWithResponse<Any >(command = exampleCommand, timeout = timeoutInterval, unit = TimeUnit .MICROSECONDS )
89-
90- verify { subjectGateway.sendAndWait<Any >(exampleCommand, timeoutInterval, TimeUnit .MICROSECONDS ) }
91- }
92-
93- @Test
94- fun `SendAndWaitWithResponse with timeout extension should invoke correct method on the gateway without explicit generic parameter` () {
95- every { subjectGateway.sendAndWait<Any >(exampleCommand, timeoutInterval, TimeUnit .MICROSECONDS ) } returns Unit
96-
97- fun methodWithExplicitReturnValue (): Unit =
98- subjectGateway.sendAndWaitWithResponse(
99- command = exampleCommand,
100- timeout = timeoutInterval,
101- unit = TimeUnit .MICROSECONDS
102- )
103-
104- methodWithExplicitReturnValue()
105-
106- verify { subjectGateway.sendAndWait<Any >(exampleCommand, timeoutInterval, TimeUnit .MICROSECONDS ) }
107- }
108-
109- @Test
110- fun `SendAndWaitWithResponse with timeout extension should invoke correct method on the gateway with default Timeunit` () {
111- every { subjectGateway.sendAndWait<Any >(exampleCommand, timeoutInterval, defaultTimeUnit) } returns Unit
112-
113- subjectGateway.sendAndWaitWithResponse<Any >(command = exampleCommand, timeout = timeoutInterval)
114-
115- verify { subjectGateway.sendAndWait<Any >(exampleCommand, timeoutInterval, defaultTimeUnit) }
116- }
11763}
0 commit comments