Bael 6556 3 (#4382)

* Added parent module on poms that have no parent defined

* Removed dependency reduced pom from undertow module

* [BAEL-6556] - Next set of renames of testcases

* [BAEL-6556] - Next set of renames of testcases

* [BAEL-6556] - Next set of renames of testcases

* [BAEL-6556] - Next set of renames of testcases
This commit is contained in:
Amit Pandey
2018-06-01 16:42:51 +05:30
committed by Grzegorz Piwowarek
parent cfa5f07c96
commit 7206e64bef
150 changed files with 187 additions and 182 deletions
@@ -19,13 +19,13 @@ import static org.junit.jupiter.api.Assertions.*;
@ExtendWith({ EnvironmentExtension.class, EmployeeDatabaseSetupExtension.class, EmployeeDaoParameterResolver.class })
@ExtendWith(LoggingExtension.class)
@ExtendWith(IgnoreFileNotFoundExceptionExtension.class)
public class EmployeesTest {
public class EmployeesUnitTest {
private EmployeeJdbcDao employeeDao;
private Logger logger;
public EmployeesTest(EmployeeJdbcDao employeeDao) {
public EmployeesUnitTest(EmployeeJdbcDao employeeDao) {
this.employeeDao = employeeDao;
}
@@ -9,7 +9,7 @@ import org.junit.runner.RunWith;
import com.baeldung.junit5.Greetings;
@RunWith(JUnitPlatform.class)
public class GreetingsTest {
public class GreetingsUnitTest {
@Test
void whenCallingSayHello_thenReturnHello() {
@@ -4,7 +4,7 @@ import static org.junit.jupiter.api.Assertions.assertThrows;
import org.junit.jupiter.api.Test;
public class ExceptionAssertionTest {
public class ExceptionAssertionUnitTest {
@Test
public void whenExceptionThrown_thenAssertionSucceeds() {
String test = null;
@@ -11,7 +11,7 @@ import com.baeldung.junit5.Greetings;
@ExtendWith(SpringExtension.class)
@ContextConfiguration(classes = { SpringTestConfiguration.class })
public class GreetingsSpringTest {
public class GreetingsSpringUnitTest {
@Test
void whenCallingSayHello_thenReturnHello() {
@@ -5,10 +5,10 @@ import org.junit.Test;
import org.junit.experimental.categories.Category;
import com.baeldung.migration.junit4.categories.Annotations;
import com.baeldung.migration.junit4.categories.JUnit4Tests;
import com.baeldung.migration.junit4.categories.JUnit4UnitTest;
@Category(value = { Annotations.class, JUnit4Tests.class })
public class AnnotationTestExampleTest {
@Category(value = { Annotations.class, JUnit4UnitTest.class })
public class AnnotationTestExampleUnitTest {
@Test(expected = Exception.class)
public void shouldRaiseAnException() throws Exception {
throw new Exception("This is my expected exception");
@@ -8,7 +8,7 @@ import java.util.List;
import org.junit.Ignore;
import org.junit.Test;
public class AssertionsExampleTest {
public class AssertionsExampleUnitTest {
@Test
@Ignore
public void shouldFailBecauseTheNumbersAreNotEqualld() {
@@ -15,9 +15,9 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@RunWith(JUnit4.class)
public class BeforeAndAfterAnnotationsTest {
public class BeforeAndAfterAnnotationsUnitTest {
private static final Logger LOG = LoggerFactory.getLogger(BeforeAndAfterAnnotationsTest.class);
private static final Logger LOG = LoggerFactory.getLogger(BeforeAndAfterAnnotationsUnitTest.class);
private List<String> list;
@@ -9,9 +9,9 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@RunWith(JUnit4.class)
public class BeforeClassAndAfterClassAnnotationsTest {
public class BeforeClassAndAfterClassAnnotationsUnitTest {
private static final Logger LOG = LoggerFactory.getLogger(BeforeClassAndAfterClassAnnotationsTest.class);
private static final Logger LOG = LoggerFactory.getLogger(BeforeClassAndAfterClassAnnotationsUnitTest.class);
@BeforeClass
public static void setup() {
@@ -4,7 +4,7 @@ import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.ExpectedException;
public class ExceptionAssertionTest {
public class ExceptionAssertionUnitTest {
@Rule
public ExpectedException exceptionRule = ExpectedException.none();
@@ -5,7 +5,7 @@ import org.junit.Test;
import com.baeldung.migration.junit4.rules.TraceUnitTestRule;
public class RuleExampleTest {
public class RuleExampleUnitTest {
@Rule
public final TraceUnitTestRule traceRuleTests = new TraceUnitTestRule();
@@ -1,5 +1,5 @@
package com.baeldung.migration.junit4.categories;
public interface JUnit4Tests {
public interface JUnit4UnitTest {
}
@@ -12,7 +12,7 @@ import org.junit.runner.RunWith;
@Tag("annotations")
@Tag("junit5")
@RunWith(JUnitPlatform.class)
public class AnnotationTestExampleTest {
public class AnnotationTestExampleUnitTest {
@Test
public void shouldRaiseAnException() throws Exception {
Assertions.assertThrows(Exception.class, () -> {
@@ -10,7 +10,7 @@ import org.junit.platform.runner.JUnitPlatform;
import org.junit.runner.RunWith;
@RunWith(JUnitPlatform.class)
public class AssertionsExampleTest {
public class AssertionsExampleUnitTest {
@Test
@Disabled
public void shouldFailBecauseTheNumbersAreNotEqual() {
@@ -9,9 +9,9 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@RunWith(JUnitPlatform.class)
public class BeforeAllAndAfterAllAnnotationsTest {
public class BeforeAllAndAfterAllAnnotationsUnitTest {
private static final Logger LOG = LoggerFactory.getLogger(BeforeAllAndAfterAllAnnotationsTest.class);
private static final Logger LOG = LoggerFactory.getLogger(BeforeAllAndAfterAllAnnotationsUnitTest.class);
@BeforeAll
public static void setup() {
@@ -15,9 +15,9 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@RunWith(JUnitPlatform.class)
public class BeforeEachAndAfterEachAnnotationsTest {
public class BeforeEachAndAfterEachAnnotationsUnitTest {
private static final Logger LOG = LoggerFactory.getLogger(BeforeEachAndAfterEachAnnotationsTest.class);
private static final Logger LOG = LoggerFactory.getLogger(BeforeEachAndAfterEachAnnotationsUnitTest.class);
private List<String> list;
@@ -9,7 +9,7 @@ import com.baeldung.migration.junit5.extensions.TraceUnitExtension;
@RunWith(JUnitPlatform.class)
@ExtendWith(TraceUnitExtension.class)
public class RuleExampleTest {
public class RuleExampleUnitTest {
@Test
public void whenTracingTests() {
@@ -13,7 +13,7 @@ import org.junit.runner.RunWith;
@RunWith(JUnitPlatform.class)
@DisplayName("Testing PersonValidator")
public class PersonValidatorTest {
public class PersonValidatorUnitTest {
/**
* Nested class, uses ExtendWith
@@ -7,6 +7,6 @@ import org.junit.runner.RunWith;
@RunWith(JUnitPlatform.class)
@SelectPackages("com.baeldung")
// @SelectClasses({AssertionTest.class, AssumptionTest.class, ExceptionTest.class})
public class AllTests {
public class AllUnitTest {
}
@@ -11,7 +11,7 @@ import org.mockito.exceptions.base.MockitoAssertionError;
import org.mockito.junit.MockitoJUnit;
import org.mockito.junit.VerificationCollector;
public class LazyVerificationTest {
public class LazyVerificationUnitTest {
@Test
public void whenLazilyVerified_thenReportsMultipleFailures() {
@@ -14,7 +14,7 @@ import org.powermock.modules.junit4.PowerMockRunner;
@RunWith(PowerMockRunner.class)
@PrepareForTest(fullyQualifiedNames = "com.baeldung.powermockito.introduction.LuckyNumberGenerator")
public class LuckyNumberGeneratorTest {
public class LuckyNumberGeneratorIntegrationTest {
@Test
public final void givenPrivateMethodWithReturn_whenUsingPowerMockito_thenCorrect() throws Exception {
@@ -10,7 +10,7 @@ import org.mockito.Mockito;
import org.mockito.invocation.InvocationOnMock;
public class BDDMockitoTest {
public class BDDMockitoIntegrationTest {
PhoneBookService phoneBookService;
PhoneBookRepository phoneBookRepository;
@@ -11,7 +11,7 @@ import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.core.StringEndsWith.endsWith;
import static org.hamcrest.core.StringStartsWith.startsWith;
public class HamcrestCoreMatchersTest {
public class HamcrestCoreMatchersUnitTest {
@Test
public void givenTestInput_WhenUsingIsForMatch() {
@@ -11,7 +11,7 @@ import org.mockito.stubbing.Answer;
import org.mockito.runners.MockitoJUnitRunner;
@RunWith(MockitoJUnitRunner.class)
public class MockitoVoidMethodsTest {
public class MockitoVoidMethodsUnitTest {
@Test
public void whenAddCalledVerified() {
@@ -11,7 +11,7 @@ import java.util.NoSuchElementException;
import static org.easymock.EasyMock.*;
@RunWith(EasyMockRunner.class)
public class BaeldungReaderAnnotatedTest {
public class BaeldungReaderAnnotatedUnitTest {
@Mock ArticleReader mockArticleReader;
@@ -9,7 +9,7 @@ import java.util.NoSuchElementException;
import static org.easymock.EasyMock.*;
public class BaeldungReaderAnnotatedWithRuleTest {
public class BaeldungReaderAnnotatedWithRuleUnitTest {
@Rule public EasyMockRule mockRule = new EasyMockRule(this);
@@ -5,7 +5,7 @@ import org.junit.*;
import static org.easymock.EasyMock.*;
public class BaeldungReaderMockDelegationTest {
public class BaeldungReaderMockDelegationUnitTest {
EasyMockSupport easyMockSupport = new EasyMockSupport();
@@ -10,7 +10,7 @@ import static org.easymock.EasyMock.*;
import static org.junit.Assert.assertEquals;
@RunWith(EasyMockRunner.class)
public class BaeldungReaderMockSupportTest extends EasyMockSupport {
public class BaeldungReaderMockSupportUnitTest extends EasyMockSupport {
@TestSubject BaeldungReader baeldungReader = new BaeldungReader();
@Mock ArticleReader mockArticleReader;
@@ -7,7 +7,7 @@ import java.util.NoSuchElementException;
import static org.easymock.EasyMock.*;
import static org.junit.Assert.assertEquals;
public class BaeldungReaderTest {
public class BaeldungReaderUnitTest {
private BaeldungReader baeldungReader;
@@ -8,7 +8,7 @@ import org.junit.runner.RunWith;
import static org.junit.Assert.*;
@RunWith(JukitoRunner.class)
public class CalculatorTest {
public class CalculatorUnitTest {
public static class Module extends JukitoModule {
@@ -4,7 +4,7 @@ import org.junit.Test;
import static org.junit.Assert.assertEquals;
public class AdditionTest {
public class AdditionUnitTest {
Calculator calculator = new Calculator();
@Test
@@ -7,7 +7,7 @@ import org.junit.runners.JUnit4;
import static org.junit.Assert.assertEquals;
@RunWith(JUnit4.class)
public class CalculatorTest {
public class CalculatorUnitTest {
Calculator calculator = new Calculator();
@Test
@@ -4,7 +4,7 @@ import org.junit.Test;
import static org.junit.Assert.assertEquals;
public class SubstractionTest {
public class SubstractionUnitTest {
Calculator calculator = new Calculator();
@Test
@@ -6,7 +6,7 @@ import org.junit.runners.Suite.SuiteClasses;
@RunWith(Suite.class)
@SuiteClasses({
AdditionTest.class,
SubstractionTest.class})
public class SuiteTest {
AdditionUnitTest.class,
SubstractionUnitTest.class})
public class SuiteUnitTest {
}
@@ -9,7 +9,7 @@ import org.junit.runner.RunWith;
import static org.junit.Assert.assertEquals;
@RunWith(JUnitParamsRunner.class)
public class SafeAdditionUtilTest {
public class SafeAdditionUtilUnitTest {
private SafeAdditionUtil serviceUnderTest = new SafeAdditionUtil();
@@ -7,7 +7,7 @@ import com.insightfullogic.lambdabehave.generators.SourceGenerator;
import org.junit.runner.RunWith;
@RunWith(JunitSuiteRunner.class)
public class CalculatorTest {
public class CalculatorUnitTest {
private Calculator calculator;