Skip to content

Commit

Permalink
Fix hook error in browser reporter by moving body prop from test to r…
Browse files Browse the repository at this point in the history
…unnable
  • Loading branch information
danielstjules committed Feb 17, 2016
1 parent 2a85944 commit f7a42fc
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 f7a42fc

Please sign in to comment.