Пример #1
0
 public SELF the_report_has_$_scenarios(int n) {
   reportModel.getScenarios().clear();
   for (int i = 0; i < n; i++) {
     createScenarioModel("something should happen " + i, "something_should_happen_" + i);
   }
   return self();
 }
Пример #2
0
 public SELF a_report_model_with_name(String name) {
   a_report_model();
   reportModel.setClassName(name);
   for (ScenarioModel model : reportModel.getScenarios()) {
     model.setClassName(name);
   }
   return self();
 }
Пример #3
0
 private StepModel getStep(int stepNr, int scenarioNr, int caseNr) {
   return reportModel
       .getScenarios()
       .get(scenarioNr - 1)
       .getScenarioCases()
       .get(caseNr - 1)
       .getStep(stepNr - 1);
 }
Пример #4
0
  private void createScenarioModel(String description, String testMethodName) {
    ScenarioModel scenarioModel = new ScenarioModel();
    scenarioModel.setClassName(reportModel.getClassName());
    scenarioModel.setDescription(description);
    scenarioModel.setTestMethodName(testMethodName);

    addDefaultCase(scenarioModel);

    reportModel.getScenarios().add(scenarioModel);
  }
Пример #5
0
 public SELF scenario_$_has_tag_$_with_value_$(int i, String name, String value) {
   latestTag = new Tag(name, value).setPrependType(true);
   reportModel.getScenarios().get(i - 1).addTag(latestTag);
   reportModel.addTag(latestTag);
   return self();
 }
Пример #6
0
 private ScenarioCaseModel getCase(int scenarioNr, int caseNr) {
   return reportModel.getScenarios().get(scenarioNr - 1).getCase(caseNr - 1);
 }