TbChangeOriginatorNodeTest refactored to use init() in @BeforeEach
This commit is contained in:
parent
1756d19820
commit
0fbc89d893
@ -50,7 +50,6 @@ import static org.mockito.ArgumentMatchers.same;
|
|||||||
import static org.mockito.Mockito.verify;
|
import static org.mockito.Mockito.verify;
|
||||||
import static org.mockito.Mockito.when;
|
import static org.mockito.Mockito.when;
|
||||||
|
|
||||||
//@ExtendWith(MockitoExtension.class)
|
|
||||||
@ExtendWith(MockitoExtension.class)
|
@ExtendWith(MockitoExtension.class)
|
||||||
public class TbChangeOriginatorNodeTest {
|
public class TbChangeOriginatorNodeTest {
|
||||||
|
|
||||||
@ -66,13 +65,13 @@ public class TbChangeOriginatorNodeTest {
|
|||||||
private ListeningExecutor dbExecutor;
|
private ListeningExecutor dbExecutor;
|
||||||
|
|
||||||
@BeforeEach
|
@BeforeEach
|
||||||
public void before() {
|
public void before() throws TbNodeException {
|
||||||
dbExecutor = new TestDbCallbackExecutor();
|
dbExecutor = new TestDbCallbackExecutor();
|
||||||
|
init();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void originatorCanBeChangedToCustomerId() throws TbNodeException {
|
public void originatorCanBeChangedToCustomerId() {
|
||||||
init();
|
|
||||||
AssetId assetId = new AssetId(Uuids.timeBased());
|
AssetId assetId = new AssetId(Uuids.timeBased());
|
||||||
CustomerId customerId = new CustomerId(Uuids.timeBased());
|
CustomerId customerId = new CustomerId(Uuids.timeBased());
|
||||||
Asset asset = new Asset();
|
Asset asset = new Asset();
|
||||||
@ -96,8 +95,7 @@ public class TbChangeOriginatorNodeTest {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void newChainCanBeStarted() throws TbNodeException {
|
public void newChainCanBeStarted() {
|
||||||
init();
|
|
||||||
AssetId assetId = new AssetId(Uuids.timeBased());
|
AssetId assetId = new AssetId(Uuids.timeBased());
|
||||||
CustomerId customerId = new CustomerId(Uuids.timeBased());
|
CustomerId customerId = new CustomerId(Uuids.timeBased());
|
||||||
Asset asset = new Asset();
|
Asset asset = new Asset();
|
||||||
@ -120,8 +118,7 @@ public class TbChangeOriginatorNodeTest {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void exceptionThrownIfCannotFindNewOriginator() throws TbNodeException {
|
public void exceptionThrownIfCannotFindNewOriginator() {
|
||||||
init();
|
|
||||||
AssetId assetId = new AssetId(Uuids.timeBased());
|
AssetId assetId = new AssetId(Uuids.timeBased());
|
||||||
CustomerId customerId = new CustomerId(Uuids.timeBased());
|
CustomerId customerId = new CustomerId(Uuids.timeBased());
|
||||||
Asset asset = new Asset();
|
Asset asset = new Asset();
|
||||||
|
|||||||
@ -1,3 +1,3 @@
|
|||||||
junit.jupiter.execution.parallel.enabled = true
|
junit.jupiter.execution.parallel.enabled = true
|
||||||
junit.jupiter.execution.parallel.mode.default = concurrent
|
junit.jupiter.execution.parallel.mode.default = concurrent
|
||||||
junit.jupiter.execution.parallel.mode.classes.default = concurrent
|
junit.jupiter.execution.parallel.mode.classes.default = concurrent
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user