Browse Source

Remove ex.printStackTrace() in tests

Closes gh-13952
pull/14003/head
Johnny Lim 7 years ago committed by Stephane Nicoll
parent
commit
d4fba783fb
  1. 1
      spring-boot-project/spring-boot-devtools/src/test/java/org/springframework/boot/devtools/livereload/LiveReloadServerTests.java
  2. 1
      spring-boot-project/spring-boot-devtools/src/test/java/org/springframework/boot/devtools/tunnel/server/SocketTargetServerConnectionTests.java
  3. 2
      spring-boot-project/spring-boot/src/test/java/org/springframework/boot/context/properties/bind/CollectionBinderTests.java
  4. 1
      spring-boot-project/spring-boot/src/test/java/org/springframework/boot/diagnostics/analyzer/BeanCurrentlyInCreationFailureAnalyzerTests.java

1
spring-boot-project/spring-boot-devtools/src/test/java/org/springframework/boot/devtools/livereload/LiveReloadServerTests.java

@ -188,7 +188,6 @@ public class LiveReloadServerTests { @@ -188,7 +188,6 @@ public class LiveReloadServerTests {
super.run();
}
catch (ConnectionClosedException ex) {
ex.printStackTrace();
synchronized (MonitoredLiveReloadServer.this.monitor) {
MonitoredLiveReloadServer.this.closedExceptions.add(ex);
}

1
spring-boot-project/spring-boot-devtools/src/test/java/org/springframework/boot/devtools/tunnel/server/SocketTargetServerConnectionTests.java

@ -162,7 +162,6 @@ public class SocketTargetServerConnectionTests { @@ -162,7 +162,6 @@ public class SocketTargetServerConnectionTests {
channel.close();
}
catch (Exception ex) {
ex.printStackTrace();
fail();
}
}

2
spring-boot-project/spring-boot/src/test/java/org/springframework/boot/context/properties/bind/CollectionBinderTests.java

@ -124,7 +124,6 @@ public class CollectionBinderTests { @@ -124,7 +124,6 @@ public class CollectionBinderTests {
fail("No exception thrown");
}
catch (BindException ex) {
ex.printStackTrace();
Set<ConfigurationProperty> unbound = ((UnboundConfigurationPropertiesException) ex
.getCause()).getUnboundProperties();
assertThat(unbound).hasSize(1);
@ -147,7 +146,6 @@ public class CollectionBinderTests { @@ -147,7 +146,6 @@ public class CollectionBinderTests {
fail("No exception thrown");
}
catch (BindException ex) {
ex.printStackTrace();
Set<ConfigurationProperty> unbound = ((UnboundConfigurationPropertiesException) ex
.getCause()).getUnboundProperties();
assertThat(unbound).hasSize(1);

1
spring-boot-project/spring-boot/src/test/java/org/springframework/boot/diagnostics/analyzer/BeanCurrentlyInCreationFailureAnalyzerTests.java

@ -144,7 +144,6 @@ public class BeanCurrentlyInCreationFailureAnalyzerTests { @@ -144,7 +144,6 @@ public class BeanCurrentlyInCreationFailureAnalyzerTests {
return null;
}
catch (Exception ex) {
ex.printStackTrace();
return ex;
}
}

Loading…
Cancel
Save