File tree Expand file tree Collapse file tree 1 file changed +8
-9
lines changed
src/test/java/com/testingbot/tunnel Expand file tree Collapse file tree 1 file changed +8
-9
lines changed Original file line number Diff line number Diff line change @@ -44,16 +44,15 @@ void stop_shouldStopForwarder() {
4444 }
4545
4646 @ Test
47- void testForwarding_withRunningForwarder_shouldTestConnection () {
48- // Given
47+ void testForwarding_withRunningForwarder_shouldExecuteWithoutException () {
48+ // Given: HttpForwarder with running Jetty server
4949 httpForwarder = new HttpForwarder (app );
50-
51- // When
52- boolean result = httpForwarder .testForwarding ();
53-
54- // Then
55- assertThat (result ).isFalse (); // Expected in test environment
56-
50+
51+ // When: Testing if forwarder is responding
52+ // Then: Should not throw exception (result depends on SSH tunnel availability)
53+ assertThatCode (() -> httpForwarder .testForwarding ())
54+ .doesNotThrowAnyException ();
55+
5756 // Clean up
5857 httpForwarder .stop ();
5958 }
You can’t perform that action at this time.
0 commit comments