Migrate to JUnit5
This commit is contained in:
@ -23,7 +23,7 @@
|
||||
|
||||
package com.iluwatar.tls;
|
||||
|
||||
import org.junit.Test;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
/**
|
||||
* Tests that thread local storage example runs without errors.
|
||||
|
@ -32,10 +32,11 @@ import java.util.concurrent.ExecutorService;
|
||||
import java.util.concurrent.Executors;
|
||||
import java.util.concurrent.Future;
|
||||
|
||||
import org.junit.BeforeClass;
|
||||
import org.junit.Test;
|
||||
import static org.junit.Assert.assertEquals;
|
||||
import static org.junit.Assert.fail;
|
||||
import org.junit.jupiter.api.BeforeAll;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
import static org.junit.jupiter.api.Assertions.fail;
|
||||
|
||||
/**
|
||||
*
|
||||
@ -86,7 +87,7 @@ public class DateFormatCallableTest {
|
||||
/**
|
||||
* Run Callable and prepare results for usage in the test methods
|
||||
*/
|
||||
@BeforeClass
|
||||
@BeforeAll
|
||||
public static void setup() {
|
||||
// Create a callable
|
||||
DateFormatCallable callableDf = new DateFormatCallable("dd/MM/yyyy", "15/12/2015");
|
||||
|
@ -30,10 +30,11 @@ import java.util.concurrent.ExecutorService;
|
||||
import java.util.concurrent.Executors;
|
||||
import java.util.concurrent.Future;
|
||||
|
||||
import org.junit.BeforeClass;
|
||||
import org.junit.Test;
|
||||
import static org.junit.Assert.assertEquals;
|
||||
import static org.junit.Assert.fail;
|
||||
import org.junit.jupiter.api.BeforeAll;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
import static org.junit.jupiter.api.Assertions.fail;
|
||||
|
||||
/**
|
||||
*
|
||||
@ -84,7 +85,7 @@ public class DateFormatCallableTestIncorrectDateFormat {
|
||||
/**
|
||||
* Run Callable and prepare results for usage in the test methods
|
||||
*/
|
||||
@BeforeClass
|
||||
@BeforeAll
|
||||
public static void setup() {
|
||||
// Create a callable. Pass a string date value not matching the format string
|
||||
DateFormatCallable callableDf = new DateFormatCallable("dd/MM/yyyy", "15.12.2015");
|
||||
|
@ -32,10 +32,11 @@ import java.util.concurrent.ExecutorService;
|
||||
import java.util.concurrent.Executors;
|
||||
import java.util.concurrent.Future;
|
||||
|
||||
import org.junit.BeforeClass;
|
||||
import org.junit.Test;
|
||||
import static org.junit.Assert.assertEquals;
|
||||
import static org.junit.Assert.fail;
|
||||
import org.junit.jupiter.api.BeforeAll;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
import static org.junit.jupiter.api.Assertions.fail;
|
||||
|
||||
/**
|
||||
*
|
||||
@ -90,7 +91,7 @@ public class DateFormatCallableTestMultiThread {
|
||||
/**
|
||||
* Run Callable and prepare results for usage in the test methods
|
||||
*/
|
||||
@BeforeClass
|
||||
@BeforeAll
|
||||
public static void setup() {
|
||||
// Create a callable
|
||||
DateFormatCallable callableDf = new DateFormatCallable("dd/MM/yyyy", "15/12/2015");
|
||||
|
Reference in New Issue
Block a user