오이를 처음 접하고 특정 오이 시나리오를 실행하는 동안 이상한 문제에 직면했습니다. 다음은 필자의 기능 파일에서 정의한 두 가지 시나리오입니다. 첫 번째 시나리오는 문제없이 작동하지만 오이는 테스트 사례를 실행하는 동안 두 번째 테스트를 고려하지 않습니다. 다음은 오이 시나리오 실행 중 마주 보는 문제
Scenario Outline:
1.Validate create functionality
Given user is on "Home" screen
When click on Create
Then create screen should render
Scenario Outline:
2.Validate create Name,Description,Start Date
Given user is on create screen
When user enters following values:
| Name | dummyName |
| Desc | [email protected]# |
| Date | ghgh |
Then there should be error message on the screen.
는 자바의 기능 구현 방법입니다
시나리오 1.
@Given("^user is on \"([^\"]*)\" screen$")
public void homeScreen(String home) throws Throwable {
//someCode
}
@When("^click on Create$")
public clickCreate() throws Throwable {
//someCode
}
@Then ("^create screen should render$")
public void createRender() throws Throwable {
//someCode
}
시나리오 시나리오가 오이에 의해 호출되지 않는 이유 2.
@Given("^user is on create screen$")
public void crateScreen() throws Throwable {
//someCode
}
@When("^user enters following values :$")
public void EnterValues(Map<String,String> map) throws Throwable {
//someCode
}
@Then("^there should be error message on the screen.$")
public void errorMessage() throws Throwable {
//someCode
}
?
환경 - 오이, 셀레늄, JAVA
무엇이 오류입니까? – bcar
답장을 보내 주셔서 감사 합니다만 오류는 표시되지 않지만 시나리오 2는 실행되지 않습니다. – Gautam
러너는 어디 있습니까? –