DATAMONGO-2394 - Polishing.
Move tests to JUnit Jupiter. Original pull request: #798.
This commit is contained in:
committed by
Mark Paluch
parent
3bffe402c0
commit
5c2370399f
@@ -30,11 +30,11 @@ import java.util.Optional;
|
||||
|
||||
import org.bson.types.Code;
|
||||
import org.bson.types.ObjectId;
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
import org.junit.runner.RunWith;
|
||||
import org.junit.jupiter.api.BeforeEach;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.junit.jupiter.api.extension.ExtendWith;
|
||||
import org.mockito.Mock;
|
||||
import org.mockito.junit.MockitoJUnitRunner;
|
||||
import org.mockito.junit.jupiter.MockitoExtension;
|
||||
import org.springframework.data.annotation.Id;
|
||||
import org.springframework.data.domain.Sort;
|
||||
import org.springframework.data.domain.Sort.Direction;
|
||||
@@ -69,7 +69,7 @@ import com.mongodb.QueryBuilder;
|
||||
* @author Christoph Strobl
|
||||
* @author Mark Paluch
|
||||
*/
|
||||
@RunWith(MockitoJUnitRunner.class)
|
||||
@ExtendWith(MockitoExtension.class)
|
||||
public class QueryMapperUnitTests {
|
||||
|
||||
QueryMapper mapper;
|
||||
@@ -78,8 +78,8 @@ public class QueryMapperUnitTests {
|
||||
|
||||
@Mock MongoDbFactory factory;
|
||||
|
||||
@Before
|
||||
public void setUp() {
|
||||
@BeforeEach
|
||||
public void beforeEach() {
|
||||
|
||||
this.context = new MongoMappingContext();
|
||||
|
||||
|
||||
@@ -27,9 +27,8 @@ import java.util.regex.Pattern;
|
||||
|
||||
import org.bson.Document;
|
||||
import org.bson.types.ObjectId;
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
|
||||
import org.junit.jupiter.api.BeforeEach;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.data.domain.Range;
|
||||
import org.springframework.data.domain.Range.Bound;
|
||||
import org.springframework.data.geo.Distance;
|
||||
@@ -73,8 +72,8 @@ public class MongoQueryCreatorUnitTests {
|
||||
MappingContext<? extends MongoPersistentEntity<?>, MongoPersistentProperty> context;
|
||||
MongoConverter converter;
|
||||
|
||||
@Before
|
||||
public void setUp() {
|
||||
@BeforeEach
|
||||
public void beforeEach() {
|
||||
|
||||
context = new MongoMappingContext();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user