-
-
Notifications
You must be signed in to change notification settings - Fork 355
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
test: migrate PositionTest to JUnit 5 #4503
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The following has changed in the code: Replaced junit 4 test annotation with junit 5 test annotation in testPositionClass Replaced junit 4 test annotation with junit 5 test annotation in testPositionClassWithComments Replaced junit 4 test annotation with junit 5 test annotation in testPositionParameterTypeReference Replaced junit 4 test annotation with junit 5 test annotation in testPositionInterface Replaced junit 4 test annotation with junit 5 test annotation in testPositionAnnotation Replaced junit 4 test annotation with junit 5 test annotation in testPositionField Replaced junit 4 test annotation with junit 5 test annotation in testPositionGeneric Replaced junit 4 test annotation with junit 5 test annotation in testPositionTerminates Replaced junit 4 test annotation with junit 5 test annotation in testPositionMethod Replaced junit 4 test annotation with junit 5 test annotation in testPositionAbstractMethod Replaced junit 4 test annotation with junit 5 test annotation in testPositionStatement Replaced junit 4 test annotation with junit 5 test annotation in testSourcePosition Replaced junit 4 test annotation with junit 5 test annotation in defaultConstructorPositionTest Replaced junit 4 test annotation with junit 5 test annotation in getPositionOfImplicitBlock Replaced junit 4 test annotation with junit 5 test annotation in testPositionMethodTypeParameter Replaced junit 4 test annotation with junit 5 test annotation in testPositionOfAnnonymousType Replaced junit 4 test annotation with junit 5 test annotation in testPositionOfAnnonymousTypeByNewInterface Replaced junit 4 test annotation with junit 5 test annotation in testPositionOfCtImport Replaced junit 4 test annotation with junit 5 test annotation in testEmptyModifiersOfMethod Replaced junit 4 test annotation with junit 5 test annotation in testTypeModifiersPositionAfterComment Replaced junit 4 test annotation with junit 5 test annotation in testPositionTryCatch Replaced junit 4 test annotation with junit 5 test annotation in testArrayArgParameter Replaced junit 4 test annotation with junit 5 test annotation in testExpressions Replaced junit 4 test annotation with junit 5 test annotation in testCatchPosition Replaced junit 4 test annotation with junit 5 test annotation in testEnumConstructorCallComment Replaced junit 4 test annotation with junit 5 test annotation in testSwitchCase Replaced junit 4 test annotation with junit 5 test annotation in testFooForEach Replaced junit 4 test annotation with junit 5 test annotation in testEndColumn Replaced junit 4 test annotation with junit 5 test annotation in testFirstLineColumn Replaced junit 4 test annotation with junit 5 test annotation in testSingleLineClassColumn Replaced junit 4 test annotation with junit 5 test annotation in testLabel Replaced junit 4 test annotation with junit 5 test annotation in testNestedLabels Replaced junit 4 test annotation with junit 5 test annotation in testPackageDeclaration Replaced junit 4 test annotation with junit 5 test annotation in testPackageDeclarationPosition Replaced junit 4 test annotation with junit 5 test annotation in testImportPosition Replaced junit 4 test annotation with junit 5 test annotation in testPackageDeclarationWithCommentPosition Replaced junit 4 test annotation with junit 5 test annotation in testCommentedOutClass Replaced junit 4 test annotation with junit 5 test annotation in testSourcePositionOfFieldReference Replaced junit 4 test annotation with junit 5 test annotation in testPositionBuilderFailureIsCaugth Replaced junit 4 test annotation with junit 5 test annotation in testNoClasspathVariableAccessInInnerClass1 Replaced junit 4 test annotation with junit 5 test annotation in testNoClasspathVariableAccessInInnerClass2 Replaced junit 4 test annotation with junit 5 test annotation in testNoClasspathVariableAccessInInnerInterface Replaced junit 4 test annotation with junit 5 test annotation in testLinePositionOkWithOneLineClassCode Replaced junit 4 test annotation with junit 5 test annotation in testLambdaParameterPosition Replaced junit 4 test annotation with junit 5 test annotation in testLambdaParameterPosition1 Transformed junit4 assert to junit 5 assertion in testPositionClass Transformed junit4 assert to junit 5 assertion in testPositionClassWithComments Transformed junit4 assert to junit 5 assertion in testPositionParameterTypeReference Transformed junit4 assert to junit 5 assertion in testPositionInterface Transformed junit4 assert to junit 5 assertion in testPositionAnnotation Transformed junit4 assert to junit 5 assertion in testPositionField Transformed junit4 assert to junit 5 assertion in testPositionGeneric Transformed junit4 assert to junit 5 assertion in testPositionMethod Transformed junit4 assert to junit 5 assertion in testPositionAbstractMethod Transformed junit4 assert to junit 5 assertion in testPositionStatement Transformed junit4 assert to junit 5 assertion in testSourcePosition Transformed junit4 assert to junit 5 assertion in assertFails Transformed junit4 assert to junit 5 assertion in defaultConstructorPositionTest Transformed junit4 assert to junit 5 assertion in getPositionOfImplicitBlock Transformed junit4 assert to junit 5 assertion in testPositionMethodTypeParameter Transformed junit4 assert to junit 5 assertion in testPositionOfAnnonymousType Transformed junit4 assert to junit 5 assertion in testPositionOfAnnonymousTypeByNewInterface Transformed junit4 assert to junit 5 assertion in testPositionOfCtImport Transformed junit4 assert to junit 5 assertion in testEmptyModifiersOfMethod Transformed junit4 assert to junit 5 assertion in testTypeModifiersPositionAfterComment Transformed junit4 assert to junit 5 assertion in testPositionTryCatch Transformed junit4 assert to junit 5 assertion in testArrayArgParameter Transformed junit4 assert to junit 5 assertion in testExpressions Transformed junit4 assert to junit 5 assertion in testCatchPosition Transformed junit4 assert to junit 5 assertion in testEnumConstructorCallComment Transformed junit4 assert to junit 5 assertion in testSwitchCase Transformed junit4 assert to junit 5 assertion in testFooForEach Transformed junit4 assert to junit 5 assertion in testEndColumn Transformed junit4 assert to junit 5 assertion in testFirstLineColumn Transformed junit4 assert to junit 5 assertion in testSingleLineClassColumn Transformed junit4 assert to junit 5 assertion in testLabel Transformed junit4 assert to junit 5 assertion in testNestedLabels Transformed junit4 assert to junit 5 assertion in testPackageDeclaration Transformed junit4 assert to junit 5 assertion in testPackageDeclarationPosition Transformed junit4 assert to junit 5 assertion in testImportPosition Transformed junit4 assert to junit 5 assertion in testPackageDeclarationWithCommentPosition Transformed junit4 assert to junit 5 assertion in testCommentedOutClass Transformed junit4 assert to junit 5 assertion in testSourcePositionOfFieldReference Transformed junit4 assert to junit 5 assertion in testPositionBuilderFailureIsCaugth Transformed junit4 assert to junit 5 assertion in testNoClasspathVariableAccessInInnerClass1 Transformed junit4 assert to junit 5 assertion in testNoClasspathVariableAccessInInnerClass2 Transformed junit4 assert to junit 5 assertion in testNoClasspathVariableAccessInInnerInterface Transformed junit4 assert to junit 5 assertion in testLinePositionOkWithOneLineClassCode Transformed junit4 assert to junit 5 assertion in testLambdaParameterPosition Transformed junit4 assert to junit 5 assertion in testLambdaParameterPosition1
slarse
approved these changes
Jan 16, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
#3919
Change Log
The following bad smells are refactored:
JUnit4-@test
The JUnit 4
@Test
annotation should be replaced with JUnit 5@Test
annotation.JUnit4Assertion
The JUnit4 assertion should be replaced with JUnit5 Assertions.
The following has changed in the code:
JUnit4-@test
testPositionClass
testPositionClassWithComments
testPositionParameterTypeReference
testPositionInterface
testPositionAnnotation
testPositionField
testPositionGeneric
testPositionTerminates
testPositionMethod
testPositionAbstractMethod
testPositionStatement
testSourcePosition
defaultConstructorPositionTest
getPositionOfImplicitBlock
testPositionMethodTypeParameter
testPositionOfAnnonymousType
testPositionOfAnnonymousTypeByNewInterface
testPositionOfCtImport
testEmptyModifiersOfMethod
testTypeModifiersPositionAfterComment
testPositionTryCatch
testArrayArgParameter
testExpressions
testCatchPosition
testEnumConstructorCallComment
testSwitchCase
testFooForEach
testEndColumn
testFirstLineColumn
testSingleLineClassColumn
testLabel
testNestedLabels
testPackageDeclaration
testPackageDeclarationPosition
testImportPosition
testPackageDeclarationWithCommentPosition
testCommentedOutClass
testSourcePositionOfFieldReference
testPositionBuilderFailureIsCaugth
testNoClasspathVariableAccessInInnerClass1
testNoClasspathVariableAccessInInnerClass2
testNoClasspathVariableAccessInInnerInterface
testLinePositionOkWithOneLineClassCode
testLambdaParameterPosition
testLambdaParameterPosition1
JUnit4Assertion
testPositionClass
testPositionClassWithComments
testPositionParameterTypeReference
testPositionInterface
testPositionAnnotation
testPositionField
testPositionGeneric
testPositionMethod
testPositionAbstractMethod
testPositionStatement
testSourcePosition
assertFails
defaultConstructorPositionTest
getPositionOfImplicitBlock
testPositionMethodTypeParameter
testPositionOfAnnonymousType
testPositionOfAnnonymousTypeByNewInterface
testPositionOfCtImport
testEmptyModifiersOfMethod
testTypeModifiersPositionAfterComment
testPositionTryCatch
testArrayArgParameter
testExpressions
testCatchPosition
testEnumConstructorCallComment
testSwitchCase
testFooForEach
testEndColumn
testFirstLineColumn
testSingleLineClassColumn
testLabel
testNestedLabels
testPackageDeclaration
testPackageDeclarationPosition
testImportPosition
testPackageDeclarationWithCommentPosition
testCommentedOutClass
testSourcePositionOfFieldReference
testPositionBuilderFailureIsCaugth
testNoClasspathVariableAccessInInnerClass1
testNoClasspathVariableAccessInInnerClass2
testNoClasspathVariableAccessInInnerInterface
testLinePositionOkWithOneLineClassCode
testLambdaParameterPosition
testLambdaParameterPosition1