Repository: authorjapps/zerocode
Pull request #171 (2018-12-21 20:39:02)

ISS-167 - ignoreStepFailures - Execute all steps when true


Patch:
diff --git a/src/main/java/org/jsmart/zerocode/core/domain/ScenarioSpec.java b/src/main/java/org/jsmart/zerocode/core/domain/ScenarioSpec.java
index 6778194a..8268e197 100644
--- a/src/main/java/org/jsmart/zerocode/core/domain/ScenarioSpec.java
+++ b/src/main/java/org/jsmart/zerocode/core/domain/ScenarioSpec.java
@@ -11,15 +11,18 @@ import java.util.List;
 public class ScenarioSpec {
 
     private final Integer loop;
+    private final Boolean ignoreStepFailures;
     private final String scenarioName;
     private final List<Step> steps;
 
     @JsonCreator
     public ScenarioSpec(
             @JsonProperty("stepLoop") Integer loop,
+            @JsonProperty("ignoreStepFailures") Boolean ignoreStepFailures,
             @JsonProperty("scenarioName") String scenarioName,
             @JsonProperty("steps") List<Step> steps) {
         this.loop = loop;
+        this.ignoreStepFailures = ignoreStepFailures;
         this.scenarioName = scenarioName;
         this.steps = steps;
     }
@@ -28,6 +31,10 @@ public class ScenarioSpec {
         return loop;
     }
 
+    public Boolean getIgnoreStepFailures() {
+        return ignoreStepFailures;
+    }
+
     public String getScenarioName() {
         return scenarioName;
     }
@@ -39,7 +46,8 @@ public class ScenarioSpec {
     @Override
     public String toString() {
         return "ScenarioSpec{" +
-                "stepLoop=" + loop +
+                "loop=" + loop +
+                ", ignoreStepFailures=" + ignoreStepFailures +
                 ", scenarioName='" + scenarioName + '\'' +
                 ", steps=" + steps +
                 '}';
diff --git a/src/main/java/org/jsmart/zerocode/core/report/ZeroCodeReportGeneratorImpl.java b/src/main/java/org/jsmart/zerocode/core/report/ZeroCodeReportGeneratorImpl.java
index bf4c4777..ae8f60a2 100644
--- a/src/main/java/org/jsmart/zerocode/core/report/ZeroCodeReportGeneratorImpl.java
+++ b/src/main/java/org/jsmart/zerocode/core/report/ZeroCodeReportGeneratorImpl.java
@@ -106,9 +106,11 @@ public class ZeroCodeReportGeneratorImpl implements ZeroCodeReportGenerator {
                     test.createNode(thisStep.getName(), TEST_STEP_CORRELATION_ID + " "
                             + thisStep.getCorrelationId()).log(testStatus, thisStep.getName()
                             + " has " + thisStep.getResult()
-                            + ". \n Search in the log file for-  " + TEST_STEP_CORRELATION_ID + "  \n"
+                            + ". \n Search in the log file in 'target/logs' folder for-  " + TEST_STEP_CORRELATION_ID + "  \n"
                             + thisStep.getCorrelationId() + "\n"
                             + ", url:" + thisStep.getUrl() + "\n"
+                            + "\n .See the entire Request, Response and Assertions at a single place. "
+                            + "Copy paste this content into an email and share with the interested stakeholders."
                     );
 
                     extentReports.flush();
diff --git a/src/main/java/org/jsmart/zerocode/core/runner/ZeroCodeMultiStepsScenarioRunnerImpl.java b/src/main/java/org/jsmart/zerocode/core/runner/ZeroCodeMultiStepsScenarioRunnerImpl.java
index ac1a6df0..c6576846 100644
--- a/src/main/java/org/jsmart/zerocode/core/runner/ZeroCodeMultiStepsScenarioRunnerImpl.java
+++ b/src/main/java/org/jsmart/zerocode/core/runner/ZeroCodeMultiStepsScenarioRunnerImpl.java
@@ -62,17 +62,19 @@ public class ZeroCodeMultiStepsScenarioRunnerImpl implements ZeroCodeMultiStepsS
 
     private static StepNotificationHandler notificationHandler = new StepNotificationHandler();
 
-    private ZeroCodeReportBuilder reportBuilder = ZeroCodeReportBuilder.newInstance().timeStamp(LocalDateTime.now());
+    private ZeroCodeReportBuilder reportBuilder;
 
     private ZeroCodeExecResultBuilder reportResultBuilder;
 
-    private Boolean stepOutcome;
+    private Boolean stepOutcomeGreen;
 
     @Override
     public synchronized boolean runScenario(ScenarioSpec scenario, RunNotifier notifier, Description description) {
 
         LOGGER.info("\n-------------------------- BDD: Scenario:{} -------------------------\n", scenario.getScenarioName());
 
+        reportBuilder = ZeroCodeReportBuilder.newInstance().timeStamp(LocalDateTime.now());
+
         ScenarioExecutionState scenarioExecutionState = new ScenarioExecutionState();
 
         final int scenarioLoopTimes = scenario.getLoop() == null ? 1 : scenario.getLoop();
@@ -173,7 +175,8 @@ public class ZeroCodeMultiStepsScenarioRunnerImpl implements ZeroCodeMultiStepsS
                                 break;
 
                             default:
-                                throw new RuntimeException("Opps! Service Undecided. If it is intentional, then leave it blank for same response as request");
+                                throw new RuntimeException("Oops! Service Type Undecided. If it is intentional, " +
+                                        "then keep the value as empty to receive the request in the response");
                         }
 
                         // logging response
@@ -200,11 +203,39 @@ public class ZeroCodeMultiStepsScenarioRunnerImpl implements ZeroCodeMultiStepsS
                         List<JsonAsserter> asserters = zeroCodeJsonTestProcesor.createAssertersFrom(resolvedAssertionJson);
                         List<AssertionReport> failureResults = zeroCodeJsonTestProcesor.assertAllAndReturnFailed(asserters, executionResult);
 
+                        // --------------------------------------------------------------------------------
+                        // Non dependent requests into a single JSON file (Issue-167 - Feature Implemented)
+                        // --------------------------------------------------------------------------------
+                        boolean ignoreStepFailures = scenario.getIgnoreStepFailures() == null? false : scenario.getIgnoreStepFailures();
+                        if(ignoreStepFailures == true && !failureResults.isEmpty()){
+                            stepOutcomeGreen = notificationHandler.handleAssertion(
+                                    notifier,
+                                    description,
+                                    scenario.getScenarioName(),
+                                    thisStepName,
+                                    failureResults,
+                                    notificationHandler::handleAssertionFailed);
+
+                            logCorrelationshipPrinter.result(stepOutcomeGreen);
+
+                            // ---------------------------------------------------------------------
+                            // Make it Green so that the report doesn't get generated again,
+                            // in the finally block i.e. printToFile. Once the scenario
+                            // get executed all reports(passed n failed) printed to file at once
+                            // ---------------------------------------------------------------------
+                            stepOutcomeGreen = true;
+
+                            // ---------------------------------------------------------------------
+                            // Do not stop execution after this step.
+                            // Continue to the next step after printing/logging the failure report.
+                            // ---------------------------------------------------------------------
+                            continue;
+                        }
                         if (!failureResults.isEmpty()) {
                             /*
                              * Step failed
                              */
-                            stepOutcome = notificationHandler.handleAssertion(
+                            stepOutcomeGreen = notificationHandler.handleAssertion(
                                     notifier,
                                     description,
                                     scenario.getScenarioName(),
@@ -212,15 +243,15 @@ public class ZeroCodeMultiStepsScenarioRunnerImpl implements ZeroCodeMultiStepsS
                                     failureResults,
                                     notificationHandler::handleAssertionFailed);
 
-                            logCorrelationshipPrinter.result(stepOutcome);
+                            logCorrelationshipPrinter.result(stepOutcomeGreen);
 
-                            return stepOutcome;
+                            return stepOutcomeGreen;
                         }
 
                         /*
-                         * Test step stepOutcome
+                         * Test step stepOutcomeGreen
                          */
-                        stepOutcome = notificationHandler.handleAssertion(
+                        stepOutcomeGreen = notificationHandler.handleAssertion(
                                 notifier,
                                 description,
                                 scenario.getScenarioName(),
@@ -231,7 +262,7 @@ public class ZeroCodeMultiStepsScenarioRunnerImpl implements ZeroCodeMultiStepsS
                         // Handle assertion section -END
                         // ---------------------------------
 
-                        logCorrelationshipPrinter.result(stepOutcome);
+                        logCorrelationshipPrinter.result(stepOutcomeGreen);
 
                     } catch (Exception ex) {
 
@@ -249,7 +280,7 @@ public class ZeroCodeMultiStepsScenarioRunnerImpl implements ZeroCodeMultiStepsS
                         /*
                          * Step threw an exception
                          */
-                        stepOutcome = notificationHandler.handleAssertion(
+                        stepOutcomeGreen = notificationHandler.handleAssertion(
                                 notifier,
                                 description,
                                 scenario.getScenarioName(),
@@ -257,9 +288,9 @@ public class ZeroCodeMultiStepsScenarioRunnerImpl implements ZeroCodeMultiStepsS
                                 (new RuntimeException("ZeroCode Step execution failed. Details:" + ex)),
                                 notificationHandler::handleStepException);
 
-                        logCorrelationshipPrinter.result(stepOutcome);
+                        logCorrelationshipPrinter.result(stepOutcomeGreen);
 
-                        return stepOutcome;
+                        return stepOutcomeGreen;
 
                     } finally {
                         logCorrelationshipPrinter.print();
@@ -273,7 +304,7 @@ public class ZeroCodeMultiStepsScenarioRunnerImpl implements ZeroCodeMultiStepsS
                         /*
                          * FAILED and Exception reports are generated here
                          */
-                        if (!stepOutcome) {
+                        if (!stepOutcomeGreen) {
                             reportBuilder.result(reportResultBuilder.build());
                             reportBuilder.printToFile(scenario.getScenarioName() + logCorrelationshipPrinter.getCorrelationId() + ".json");
                         }


Test patch:
diff --git a/src/main/resources/01_verification_test_cases/22_ignoreStepFailures_exec_all.json b/src/main/resources/01_verification_test_cases/22_ignoreStepFailures_exec_all.json
new file mode 100644
index 00000000..da727177
--- /dev/null
+++ b/src/main/resources/01_verification_test_cases/22_ignoreStepFailures_exec_all.json
@@ -0,0 +1,46 @@
+{
+    "scenarioName": "Multi step - ignoreStepFailures",
+    "ignoreStepFailures": true,
+    "steps": [
+        {
+            "name": "step1",
+            "url": "/home/bathroom/1",
+            "operation": "GET",
+            "request": {
+                "headers": {
+                    "Content-Type": "application/json;charset=UTF-8",
+                    "Cookie": "cookie_123"
+                },
+                "body": {
+                }
+            },
+            "assertions": {
+                "status": 900, //<--- mismatch, this step will fail
+                "body": {
+                    "id": 999
+                }
+            }
+        },
+        {
+            "name": "step2",
+            "url": "/home/bathroom/2${$.step1.response.body.id}",
+            "operation": "GET",
+            "request": {
+                "headers": {
+                    "Content-Type": "application/json;charset=UTF-8",
+                    "Cookie": "some_cookie___${$.step1.response.body.id}"
+                },
+                "body": {
+                }
+            },
+            "assertions": {
+                "status": 200,
+                "body": {
+                    "id": 21,
+                    "name": "Shower-21",
+                    "availability": true
+                }
+            }
+        }
+    ]
+}
diff --git a/src/test/java/org/jsmart/zerocode/core/domain/ScenarioSpecTest.java b/src/test/java/org/jsmart/zerocode/core/domain/ScenarioSpecTest.java
index 3f8b3464..f2d426fc 100644
--- a/src/test/java/org/jsmart/zerocode/core/domain/ScenarioSpecTest.java
+++ b/src/test/java/org/jsmart/zerocode/core/domain/ScenarioSpecTest.java
@@ -84,7 +84,6 @@ public class ScenarioSpecTest {
 
         assertThat(flowSpecNode.get("scenarioName").asText(), containsString("Given_When_Then"));
         assertThat(flowSpecNode.get("loop").asInt(), is(5));
-
     }
 
     @Test
@@ -135,4 +134,16 @@ public class ScenarioSpecTest {
         final JsonNode id2 = jsonNode.get("id2");
 
     }
+
+    @Test
+    public void test_ignoreStepFailuresField() throws Exception {
+        String jsonDocumentAsString = smartUtils
+                .getJsonDocumentAsString("01_test_smart_test_cases/04_ignoreStepFailures_in_multistep.json");
+        ScenarioSpec scenarioSpec = mapper.readValue(jsonDocumentAsString, ScenarioSpec.class);
+
+        assertThat(scenarioSpec, notNullValue());
+        assertThat(scenarioSpec.getSteps().size(), is(2));
+        assertThat(scenarioSpec.getIgnoreStepFailures(), is(true));
+    }
+
 }
\ No newline at end of file
diff --git a/src/test/java/org/jsmart/zerocode/core/domain/reports/ZeroCodeReportTest.java b/src/test/java/org/jsmart/zerocode/core/domain/reports/ZeroCodeReportTest.java
index 60adc73a..f9bd9b59 100644
--- a/src/test/java/org/jsmart/zerocode/core/domain/reports/ZeroCodeReportTest.java
+++ b/src/test/java/org/jsmart/zerocode/core/domain/reports/ZeroCodeReportTest.java
@@ -8,15 +8,25 @@ import org.jsmart.zerocode.core.domain.builders.ZeroCodeReportStepBuilder;
 import org.jsmart.zerocode.core.domain.builders.ZeroCodeExecResultBuilder;
 import org.jsmart.zerocode.core.utils.SmartUtils;
 import org.junit.Test;
+import org.junit.runner.JUnitCore;
+import org.junit.runner.Result;
 
+import java.io.File;
+import java.io.IOException;
 import java.time.LocalDateTime;
 import java.util.Arrays;
+import java.util.List;
+import java.util.stream.Collectors;
 
 import static org.hamcrest.CoreMatchers.is;
 import static org.hamcrest.CoreMatchers.notNullValue;
 import static org.hamcrest.MatcherAssert.assertThat;
+import static org.jsmart.zerocode.core.domain.reports.ZeroCodeReportProperties.TARGET_REPORT_DIR;
 
 public class ZeroCodeReportTest {
+    public static final String SCENARIO_1 = "Unique Scenario 1";
+    public static final String SCENARIO_2 = "Unique Scenario 2";
+
     private ObjectMapper mapper = new ObjectMapperProvider().get();
 
     @Test
@@ -57,6 +67,40 @@ public class ZeroCodeReportTest {
         assertThat(jsonDeDone.getResults().get(0).getLoop(), is(10));
         assertThat(jsonDeDone.getResults().get(0).getSteps().get(0).getLoop(), is(30));
         assertThat(jsonDeDone.getResults().get(0).getSteps().get(0).getResult(), is("PASS-PASS"));
+    }
+
+    @Test
+    public void testReport_correct_scenariosAndSteps() {
+        Result result = JUnitCore.runClasses(ZeroCodeRunTwoScenariosForReport.class);
+        assertThat(result.getRunCount(), is(2));
+
+        File[] files = new File(TARGET_REPORT_DIR).listFiles((dir, fileName) -> fileName.endsWith(".json"));
+
+        List<File> relevantReportFiles = Arrays.asList(files).stream()
+                .filter(thisFile -> thisFile.getName().contains(SCENARIO_1) || thisFile.getName().contains(SCENARIO_2))
+                .collect(Collectors.toList());
 
+        assertThat(relevantReportFiles.size(), is(2));
+
+        relevantReportFiles.forEach(this::testStepSize);
+    }
+
+    private void testStepSize(File thisFile) {
+        ZeroCodeReport rawJsonReport = null;
+        try {
+            rawJsonReport = mapper.readValue(new File(thisFile.getAbsolutePath()), ZeroCodeReport.class);
+        } catch (IOException e) {
+            throw new RuntimeException(e);
+        }
+
+        if (thisFile.getName().contains(SCENARIO_1)) {
+            assertThat(rawJsonReport.getResults().size(), is(1));
+            assertThat(rawJsonReport.getResults().get(0).getSteps().size(), is(2));
+
+        } else if (thisFile.getName().contains(SCENARIO_2)) {
+            assertThat(rawJsonReport.getResults().size(), is(1));
+            assertThat(rawJsonReport.getResults().get(0).getSteps().size(), is(2));
+        }
     }
+
 }
\ No newline at end of file
diff --git a/src/test/java/org/jsmart/zerocode/core/domain/reports/ZeroCodeRunTwoScenariosForReport.java b/src/test/java/org/jsmart/zerocode/core/domain/reports/ZeroCodeRunTwoScenariosForReport.java
new file mode 100644
index 00000000..40cecd18
--- /dev/null
+++ b/src/test/java/org/jsmart/zerocode/core/domain/reports/ZeroCodeRunTwoScenariosForReport.java
@@ -0,0 +1,31 @@
+package org.jsmart.zerocode.core.domain.reports;
+
+import org.jsmart.zerocode.core.domain.HostProperties;
+import org.jsmart.zerocode.core.domain.JsonTestCase;
+import org.jsmart.zerocode.core.tests.customrunner.TestOnlyZeroCodeUnitRunner;
+import org.junit.Ignore;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+@HostProperties(host="http://localhost", port=9998, context = "")
+@RunWith(TestOnlyZeroCodeUnitRunner.class)
+public class ZeroCodeRunTwoScenariosForReport {
+    
+    /**
+     * Mock end points are in test/resources: simulators/test_purpose_end_points.json
+     */
+
+    @Test
+    @JsonTestCase("reports_e2e/two_step_scenario_1.json")
+    public void test_scene1() throws Exception {
+    }
+
+    @Test
+    @JsonTestCase("reports_e2e/two_step_scenario_2.json")
+    public void test_scene2() throws Exception {
+    }
+
+}
+
+
+
diff --git a/src/test/java/org/jsmart/zerocode/core/runner/ZeroCodeMultiStepsScenarioRunnerImplE2ETest.java b/src/test/java/org/jsmart/zerocode/core/runner/ZeroCodeMultiStepsScenarioRunnerImplE2ETest.java
new file mode 100644
index 00000000..9372da34
--- /dev/null
+++ b/src/test/java/org/jsmart/zerocode/core/runner/ZeroCodeMultiStepsScenarioRunnerImplE2ETest.java
@@ -0,0 +1,65 @@
+package org.jsmart.zerocode.core.runner;
+
+import com.fasterxml.jackson.databind.ObjectMapper;
+import org.jsmart.zerocode.core.di.ObjectMapperProvider;
+import org.jsmart.zerocode.core.domain.reports.ZeroCodeReport;
+import org.jsmart.zerocode.core.runner.e2e.IgnoreTestFailureFlagRunE2E;
+import org.junit.Test;
+import org.junit.runner.JUnitCore;
+import org.junit.runner.Result;
+
+import java.io.File;
+import java.io.IOException;
+import java.util.Arrays;
+import java.util.List;
+import java.util.stream.Collectors;
+
+import static org.hamcrest.CoreMatchers.is;
+import static org.hamcrest.MatcherAssert.assertThat;
+import static org.jsmart.zerocode.core.domain.reports.ZeroCodeReportProperties.TARGET_REPORT_DIR;
+
+public class ZeroCodeMultiStepsScenarioRunnerImplE2ETest {
+    public static final String SCENARIO_NAME = "Multi step - ignoreStepFailures";
+
+    private ObjectMapper mapper = new ObjectMapperProvider().get();
+
+    @Test
+    public void test_AllStepsAfterFailedStepExecuted() {
+        Result result = JUnitCore.runClasses(IgnoreTestFailureFlagRunE2E.class);
+        assertThat(result.getRunCount(), is(1));
+
+        File[] files = new File(TARGET_REPORT_DIR).listFiles((dir, fileName) -> fileName.endsWith(".json"));
+
+        List<File> relevantReportFiles = Arrays.asList(files).stream()
+                .filter(thisFile -> thisFile.getName().contains(SCENARIO_NAME) )
+                .collect(Collectors.toList());
+
+        assertThat(relevantReportFiles.size(), is(1));
+
+        relevantReportFiles.forEach(this::testStepSize);
+    }
+
+    private void testStepSize(File thisFile) {
+        ZeroCodeReport rawJsonReport = null;
+        try {
+            rawJsonReport = mapper.readValue(new File(thisFile.getAbsolutePath()), ZeroCodeReport.class);
+        } catch (IOException e) {
+            throw new RuntimeException(e);
+        }
+
+        if (thisFile.getName().contains(SCENARIO_NAME)) {
+            assertThat(rawJsonReport.getResults().size(), is(1));
+            assertThat(rawJsonReport.getResults().get(0).getSteps().size(), is(2));
+
+            assertThat(rawJsonReport.getResults().get(0).getSteps().get(0).getName(), is("step1"));
+            assertThat(rawJsonReport.getResults().get(0).getSteps().get(0).getResult(), is("FAILED"));
+
+            assertThat(rawJsonReport.getResults().get(0).getSteps().get(1).getName(), is("step2"));
+            assertThat(rawJsonReport.getResults().get(0).getSteps().get(1).getResult(), is("PASSED"));
+        }
+    }
+
+}
+
+
+
diff --git a/src/test/java/org/jsmart/zerocode/core/runner/ZeroCodeMultiStepsScenarioRunnerImplVerifyTest.java b/src/test/java/org/jsmart/zerocode/core/runner/ZeroCodeMultiStepsScenarioRunnerImplVerifyTest.java
index 8e1d9e6f..80424f85 100644
--- a/src/test/java/org/jsmart/zerocode/core/runner/ZeroCodeMultiStepsScenarioRunnerImplVerifyTest.java
+++ b/src/test/java/org/jsmart/zerocode/core/runner/ZeroCodeMultiStepsScenarioRunnerImplVerifyTest.java
@@ -43,8 +43,8 @@ public class ZeroCodeMultiStepsScenarioRunnerImplVerifyTest {
     @Test
     @JsonTestCase("01_verification_test_cases/20_ignored.json")
     public void willNotRunIf_ignored() throws Exception {
-        
     }
+
 }
 
 
diff --git a/src/test/java/org/jsmart/zerocode/core/runner/e2e/IgnoreTestFailureFlagRunE2E.java b/src/test/java/org/jsmart/zerocode/core/runner/e2e/IgnoreTestFailureFlagRunE2E.java
new file mode 100644
index 00000000..32f1dcf8
--- /dev/null
+++ b/src/test/java/org/jsmart/zerocode/core/runner/e2e/IgnoreTestFailureFlagRunE2E.java
@@ -0,0 +1,25 @@
+package org.jsmart.zerocode.core.runner.e2e;
+
+import org.jsmart.zerocode.core.domain.HostProperties;
+import org.jsmart.zerocode.core.domain.JsonTestCase;
+import org.jsmart.zerocode.core.tests.customrunner.TestOnlyZeroCodeUnitRunner;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+@HostProperties(host="http://localhost", port=9998, context = "")
+@RunWith(TestOnlyZeroCodeUnitRunner.class)
+public class IgnoreTestFailureFlagRunE2E {
+    
+    /**
+     * Mock end points are in test/resources: simulators/test_purpose_end_points.json
+     */
+
+    @Test
+    @JsonTestCase("01_verification_test_cases/22_ignoreStepFailures_exec_all.json")
+    public void testMultiStepIgnoreStepFailures_execAll() throws Exception {
+    }
+
+}
+
+
+
diff --git a/src/test/java/org/jsmart/zerocode/core/utils/SmartUtilsTest.java b/src/test/java/org/jsmart/zerocode/core/utils/SmartUtilsTest.java
index 5510311c..3e81f14a 100644
--- a/src/test/java/org/jsmart/zerocode/core/utils/SmartUtilsTest.java
+++ b/src/test/java/org/jsmart/zerocode/core/utils/SmartUtilsTest.java
@@ -69,7 +69,7 @@ public class SmartUtilsTest {
     @Test
     public void willReadAllfileNamesFrom_TestResource() throws Exception {
         List<String> allTestCaseFiles = SmartUtils.getAllEndPointFiles("01_test_smart_test_cases");
-        assertThat(allTestCaseFiles.size(), is(4));
+        assertThat(allTestCaseFiles.size(), is(5));
         assertThat(allTestCaseFiles.get(0).toString(), is("01_test_smart_test_cases/01_test_json_single_step.json"));
     }
 
diff --git a/src/test/resources/01_test_smart_test_cases/04_ignoreStepFailures_in_multistep.json b/src/test/resources/01_test_smart_test_cases/04_ignoreStepFailures_in_multistep.json
new file mode 100644
index 00000000..03124fdb
--- /dev/null
+++ b/src/test/resources/01_test_smart_test_cases/04_ignoreStepFailures_in_multistep.json
@@ -0,0 +1,26 @@
+{
+    "scenarioName": "For deserialize only",
+    "ignoreStepFailures": true,
+    "steps": [
+        {
+            "name": "step1",
+            "url": "/anUrl",
+            "operation": "GET",
+            "request": {
+            },
+            "assertions": {
+                "status": 900
+            }
+        },
+        {
+            "name": "step2",
+            "url": "/otherUrl",
+            "operation": "GET",
+            "request": {
+            },
+            "assertions": {
+                "status": 200
+            }
+        }
+    ]
+}
diff --git a/src/test/resources/reports_e2e/two_step_scenario_1.json b/src/test/resources/reports_e2e/two_step_scenario_1.json
new file mode 100644
index 00000000..36037675
--- /dev/null
+++ b/src/test/resources/reports_e2e/two_step_scenario_1.json
@@ -0,0 +1,38 @@
+{
+    "scenarioName": "Unique Scenario 1",
+    "ignoreStepFailures": true,
+    "steps": [
+        {
+            "name": "us_step1",
+            "url": "/home/bathroom/1",
+            "operation": "GET",
+            "request": {
+                "headers": {
+                    "Content-Type": "application/json;charset=UTF-8",
+                    "Cookie": "cookie_123"
+                },
+                "body": {
+                }
+            },
+            "assertions": {
+                "status": 200
+            }
+        },
+        {
+            "name": "us_step2",
+            "url": "/home/bathroom/2${$.us_step1.response.body.id}",
+            "operation": "GET",
+            "request": {
+                "headers": {
+                    "Content-Type": "application/json;charset=UTF-8",
+                    "Cookie": "some_cookie___${$.us_step1.response.body.id}"
+                },
+                "body": {
+                }
+            },
+            "assertions": {
+                "status": 200
+            }
+        }
+    ]
+}
diff --git a/src/test/resources/reports_e2e/two_step_scenario_2.json b/src/test/resources/reports_e2e/two_step_scenario_2.json
new file mode 100644
index 00000000..f6c5d117
--- /dev/null
+++ b/src/test/resources/reports_e2e/two_step_scenario_2.json
@@ -0,0 +1,38 @@
+{
+    "scenarioName": "Unique Scenario 2",
+    "ignoreStepFailures": true,
+    "steps": [
+        {
+            "name": "us2_step1",
+            "url": "/home/bathroom/1",
+            "operation": "GET",
+            "request": {
+                "headers": {
+                    "Content-Type": "application/json;charset=UTF-8",
+                    "Cookie": "cookie_123"
+                },
+                "body": {
+                }
+            },
+            "assertions": {
+                "status": 200
+            }
+        },
+        {
+            "name": "us2_step2",
+            "url": "/home/bathroom/2${$.us2_step1.response.body.id}",
+            "operation": "GET",
+            "request": {
+                "headers": {
+                    "Content-Type": "application/json;charset=UTF-8",
+                    "Cookie": "some_cookie___${$.us2_step1.response.body.id}"
+                },
+                "body": {
+                }
+            },
+            "assertions": {
+                "status": 200
+            }
+        }
+    ]
+}