gherkin

SpecFlow equivalent to parameterized test fixture

断了今生、忘了曾经 提交于 2021-01-28 10:21:47
问题 I’m using SpecFlow to write a set of tests, and I’d like to run each test multiple times, with different input data. I could do this with scenario outlines, but I want to run every scenario in the feature file with the same test cases. I know I can use the Background to share the setup for one case, but I’m looking for something like a cross between Background and Scenario Outline, where I can supply a table of data to the Background and run the entire feature file once per row. In NUnit, I’d

SpecFlow equivalent to parameterized test fixture

纵然是瞬间 提交于 2021-01-28 10:21:29
问题 I’m using SpecFlow to write a set of tests, and I’d like to run each test multiple times, with different input data. I could do this with scenario outlines, but I want to run every scenario in the feature file with the same test cases. I know I can use the Background to share the setup for one case, but I’m looking for something like a cross between Background and Scenario Outline, where I can supply a table of data to the Background and run the entire feature file once per row. In NUnit, I’d

SpecFlow equivalent to parameterized test fixture

点点圈 提交于 2021-01-28 10:20:42
问题 I’m using SpecFlow to write a set of tests, and I’d like to run each test multiple times, with different input data. I could do this with scenario outlines, but I want to run every scenario in the feature file with the same test cases. I know I can use the Background to share the setup for one case, but I’m looking for something like a cross between Background and Scenario Outline, where I can supply a table of data to the Background and run the entire feature file once per row. In NUnit, I’d

Can you save a result (Given) to a variable in a Gherkin feature file, and then compare the variable with another result (Then)? (Cucumber for Java)

 ̄綄美尐妖づ 提交于 2021-01-28 08:58:10
问题 I am new to Cucumber for Java and trying to automate testing of a SpringBoot server backed by a MS SQL Server. I have an endpoint "Get All Employees". Writing the traditional feature file, I will have to list all the Employees in the @Then clause. This is not possible with thousands of employees. So I just want to get a row count of the Employee table in the database, and then compare with the number of objects returned from the "Get All Employees" endpoint. Compare SELECT count(*) from

Can you save a result (Given) to a variable in a Gherkin feature file, and then compare the variable with another result (Then)? (Cucumber for Java)

巧了我就是萌 提交于 2021-01-28 08:41:47
问题 I am new to Cucumber for Java and trying to automate testing of a SpringBoot server backed by a MS SQL Server. I have an endpoint "Get All Employees". Writing the traditional feature file, I will have to list all the Employees in the @Then clause. This is not possible with thousands of employees. So I just want to get a row count of the Employee table in the database, and then compare with the number of objects returned from the "Get All Employees" endpoint. Compare SELECT count(*) from

Cucumber : How to read examples from external excel file for Scenarios Outline

南楼画角 提交于 2021-01-02 11:55:32
问题 My requirement is to read examples from external excel file rather than hard code it into feature file. I have more than 100 examples which is difficult to maintain in feature file. Can you please help me on this. Here is my scenario - Scenario Outline: Browser Test When I visit the URL <base>/<page>/<ordNumber>/<custName> Then the browser contains test <custNumber> Examples: | base | page | ordNumber | custName | | http://www.stackoverflow.com | orders | 123 | John | | http://www

Cucumber : How to read examples from external excel file for Scenarios Outline

戏子无情 提交于 2021-01-02 11:51:25
问题 My requirement is to read examples from external excel file rather than hard code it into feature file. I have more than 100 examples which is difficult to maintain in feature file. Can you please help me on this. Here is my scenario - Scenario Outline: Browser Test When I visit the URL <base>/<page>/<ordNumber>/<custName> Then the browser contains test <custNumber> Examples: | base | page | ordNumber | custName | | http://www.stackoverflow.com | orders | 123 | John | | http://www

Cucumber : How to read examples from external excel file for Scenarios Outline

試著忘記壹切 提交于 2021-01-02 11:50:40
问题 My requirement is to read examples from external excel file rather than hard code it into feature file. I have more than 100 examples which is difficult to maintain in feature file. Can you please help me on this. Here is my scenario - Scenario Outline: Browser Test When I visit the URL <base>/<page>/<ordNumber>/<custName> Then the browser contains test <custNumber> Examples: | base | page | ordNumber | custName | | http://www.stackoverflow.com | orders | 123 | John | | http://www

Cucumber : How to read examples from external excel file for Scenarios Outline

◇◆丶佛笑我妖孽 提交于 2021-01-02 11:50:21
问题 My requirement is to read examples from external excel file rather than hard code it into feature file. I have more than 100 examples which is difficult to maintain in feature file. Can you please help me on this. Here is my scenario - Scenario Outline: Browser Test When I visit the URL <base>/<page>/<ordNumber>/<custName> Then the browser contains test <custNumber> Examples: | base | page | ordNumber | custName | | http://www.stackoverflow.com | orders | 123 | John | | http://www

Cucumber : How to read examples from external excel file for Scenarios Outline

烂漫一生 提交于 2021-01-02 11:50:21
问题 My requirement is to read examples from external excel file rather than hard code it into feature file. I have more than 100 examples which is difficult to maintain in feature file. Can you please help me on this. Here is my scenario - Scenario Outline: Browser Test When I visit the URL <base>/<page>/<ordNumber>/<custName> Then the browser contains test <custNumber> Examples: | base | page | ordNumber | custName | | http://www.stackoverflow.com | orders | 123 | John | | http://www