Skip to content
This repository has been archived by the owner on Jul 29, 2024. It is now read-only.

Commit

Permalink
fix(cucumber): fix beforeFeature event handler call guard
Browse files Browse the repository at this point in the history
Fixes the run failures reported in cucumber/cucumber-js#342.
  • Loading branch information
jbpros authored and sjelin committed Jun 8, 2015
1 parent b00c822 commit 0262268
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/frameworks/cucumber.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ exports.run = function(runner, specs) {
var originalHandleBeforeFeatureEvent = formatter.handleBeforeFeatureEvent;
formatter.handleBeforeFeatureEvent = function(event, callback) {
feature = event.getPayloadItem('feature');
if (typeof originalHandleAfterScenarioEvent == 'function') {
if (typeof originalHandleBeforeFeatureEvent == 'function') {
originalHandleBeforeFeatureEvent.apply(formatter, arguments);
} else {
callback();
Expand Down

0 comments on commit 0262268

Please sign in to comment.