@RegisterExtension
어노테이션이 추가되었으며 타입이 잘못되었거나, 필요한 static으로 선언되지 않은 필드@Nested
어노테이션이 추가된 static 또는 private 내부 클래스@MethodSource
를 사용하는 매개변수화된 테스트@ValueSource
또는 @EnumSource
값 간에 일치하지 않는 타입@Test
, @ParameterizedTest
또는 @RepeatedTest
중 2개 이상으로 어노테이션이 추가된 테스트setup()
또는 teropDown()
메서드.suite()
메서드@BeforeClass
, @AfterClass
, @BeforeAll
또는 @AfterAll
로 어노테이션이 추가되었으며 public이 아니거나 static이 아니거나 반환 타입이 void가 아니거나 올바른 매개변수 목록이 없는 메서드
@Before
, @After
, @BeforeEach
또는 @AfterEach
로 어노테이션이 추가되었으며 public이 아니거나 반환 타입이 void가 아니거나 인수를 취하는 메서드
@BeforeAll
또는 @AfterAll
메서드에 삽입된 RepetitionInfo
@Test
로 어노테이션이 추가된 테스트에서 사용되는 @BeforeEach
또는 @AfterEach
메서드에 삽입된 RepetitionInfo
@DataPoint
또는 @DataPoints
로 어노테이션이 추가되었으며, public이 아니거나 static이 아닌 필드 및 메서드@Rule
로 어노테이션이 추가되었으며, public이 아니거나 TestRule
또는 MethodRule
의 하위 타입이 아닌 필드 및 메서드
@ClassRule
로 어노테이션이 추가되었으며, public이 아니거나 static이 아니거나 TestRule
의 하위 타입이 아닌 필드 및 메서드test
접두사가 있는 TestCase
의 하위 클래스 내 메서드
@Test
로 어노테이션이 추가되었으며 public이 아니거나 반환 타입이 void가 아니거나 인수를 취하거나 static인 메서드
잘못된 형식의 @Before
메서드 예(Java):
@Before private int foo(int arg) { ... }
빠른 수정 적용 후:
@Before public void foo() { ... }
누락된 메서드 소스의 예(Kotlin):
class Example {
@MethodSource("parameters")
@ParameterizedTest
fun foo(param: String) { ... }
}
빠른 수정 적용 후:
class Example {
@MethodSource("parameters")
@ParameterizedTest
fun foo(param: String) { ... }
companion object {
@JvmStatic
fun parameters(): Stream<Arguments> {
TODO("Not yet implemented")
}
}
}
검사 옵션을 사용하여 어노테이션을 지정합니다. 해당 어노테이션 중 하나가 추가된 매개변수는 보고되지 않습니다.