Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -469,8 +469,9 @@ public void testMethodAfterStepsInWhenClauseShouldFail() throws Exception {
</route>
</routes>
""";
ModelParser parser = new ModelParser(new StringReader(routesXml));
Exception e = assertThrows(Exception.class, () -> {
new ModelParser(new StringReader(routesXml)).parseRoutesDefinition();
parser.parseRoutesDefinition();
});
assertThat(e).hasStackTraceContaining("already has a predicate");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@

import org.junit.jupiter.api.Test;

import static org.junit.jupiter.api.Assertions.assertDoesNotThrow;
import static org.junit.jupiter.api.Assertions.assertFalse;
import static org.junit.jupiter.api.Assertions.assertNotNull;
import static org.junit.jupiter.api.Assertions.assertTrue;

class EnvironmentHelperTest {
Expand All @@ -28,20 +28,17 @@ class EnvironmentHelperTest {
void testIsColorEnabledReturnsBoolean() {
// Should not throw and should return a boolean value
// The actual result depends on the environment, but the method should work
boolean result = EnvironmentHelper.isColorEnabled();
assertNotNull(result);
assertDoesNotThrow(() -> EnvironmentHelper.isColorEnabled());
}

@Test
void testIsCIEnvironmentReturnsBoolean() {
boolean result = EnvironmentHelper.isCIEnvironment();
assertNotNull(result);
assertDoesNotThrow(() -> EnvironmentHelper.isCIEnvironment());
}

@Test
void testIsInteractiveTerminalReturnsBoolean() {
boolean result = EnvironmentHelper.isInteractiveTerminal();
assertNotNull(result);
assertDoesNotThrow(() -> EnvironmentHelper.isInteractiveTerminal());
}

@Test
Expand Down
Loading