Skip to content
Permalink
Browse files

Fix browser example

closes #448
  • Loading branch information...
karinepires authored and charlierudolph committed Nov 2, 2015
1 parent c195c0f commit 45c2da781fe63e11ea79cee3156073fb52103dcd
Showing with 4 additions and 10 deletions.
  1. +3 −7 example/example.js
  2. +1 −3 example/index.html
@@ -39,16 +39,12 @@
case 'StepResult':
var result;
var stepResult = event.getPayloadItem('stepResult');
if (stepResult.isSuccessful()) {
result = {status: 'passed'};
} else if (stepResult.isPending()) {
result = {status: 'pending'};
} else if (stepResult.isUndefined() || stepResult.isSkipped()) {
result = {status:'skipped'};
} else {
if (stepResult.getStatus() === Cucumber.Status.FAILED) {
var error = stepResult.getFailureException();
var errorMessage = error.stack || error;
result = {status: 'failed', error_message: errorMessage};
} else {
result = {status: stepResult.getStatus()};
}
formatter.match({uri:'report.feature', step: {line: currentStep.getLine()}});
formatter.result(result);
@@ -37,9 +37,7 @@ <h2>Step definitions</h2>
<textarea id="step-definitions">///// Your World /////

// Provide a custom World constructor. It's optional, a default one is supplied.
this.World = function(callback) {
callback();
};
this.World = function() {};

// Define your World!

0 comments on commit 45c2da7

Please sign in to comment.
You can’t perform that action at this time.