Skip to content

Commit

Permalink
Merge pull request #2115 from danielstjules/dstjules/fix-browser-hooks
Browse files Browse the repository at this point in the history
Fix hook error in browser reporter by moving body prop from test to runnable
  • Loading branch information
danielstjules committed Feb 17, 2016
2 parents cb4248b + f7a42fc commit e290bc0
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 1 deletion.
1 change: 1 addition & 0 deletions lib/runnable.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ module.exports = Runnable;
function Runnable(title, fn) {
this.title = title;
this.fn = fn;
this.body = (fn || '').toString();
this.async = fn && fn.length;
this.sync = !this.async;
this._timeout = 2000;
Expand Down
1 change: 0 additions & 1 deletion lib/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ function Test(title, fn) {
Runnable.call(this, title, fn);
this.pending = !fn;
this.type = 'test';
this.body = (fn || '').toString();
}

/**
Expand Down

0 comments on commit e290bc0

Please sign in to comment.