Polish sample package names
This commit is contained in:
@@ -23,7 +23,6 @@ import org.junit.Test;
|
||||
import org.springframework.boot.test.OutputCapture;
|
||||
import org.springframework.core.NestedCheckedException;
|
||||
|
||||
import com.mongodb.MongoServerSelectionException;
|
||||
import com.mongodb.MongoTimeoutException;
|
||||
|
||||
import static org.junit.Assert.assertTrue;
|
||||
@@ -61,8 +60,7 @@ public class SampleMongoApplicationTests {
|
||||
NestedCheckedException nested = new NestedCheckedException("failed", ex) {
|
||||
};
|
||||
Throwable root = nested.getRootCause();
|
||||
if (root instanceof MongoServerSelectionException
|
||||
|| root instanceof MongoTimeoutException) {
|
||||
if (root instanceof MongoTimeoutException) {
|
||||
if (root.getMessage().contains("Unable to connect to any server")) {
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user