0
나는 안드로이드에 대한 간단한 오이 BDD 테스트를 테스트하고이 오류가 어디에서 오는 내가 알아낼 수 없습니다 오이 오류Cucumber-jvm 지정한 매개 변수가 다음 생성자 중 하나와 일치하지 않습니다. [private java.lang.Class()];
org.picocontainer.PicoCompositionException: Either the specified
parameters do not match any of the following constructors: [private
java.lang.Class()]; OR the constructors were not accessible for
'java.lang.Class'
을 얻고있다. 내가 빠진 것이 있습니까?
내 기능 파일
Scenario Outline: Test scenario
Given I have a TestActivity
Then I should see <text> on the display
Examples:
| text |
| 123 |
| test |
단계 정의
@CucumberOptions(features = "features", format = "pretty")
public class TestActivitySteps extends ActivityInstrumentationTestCase2<TestActivity> {
public TestActivitySteps(Class<TestActivity> activityClass) {
super(activityClass);
}
@Given("^I have a TestActivity$")
public void I_have_a_TestActivity() {
assertNotNull(getActivity());
}
@Then("^I should see (\\S+) on the display$")
public void I_should_see_s_on_the_display(final String s) {
onView(withText(s)).check(matches(isDisplayed()));
}
}
참고 :
- 안드로이드 스튜디오 : 1.0.2
- Gradle을 : 2.2.1
- 오이 : 1.2.0
- 에스프레소 : 2.0