substack/tape — pull request #87 by maslennikov (2014-06-02 20:23:48+00:00)
Title: Unifying assert results and comments format + bugfix

I took the liberty to refactor a little bit the result-producing area of code. This allowed me to achieve the following:

- emitting of the properly formatted result happens in a separate method `Test._emitResult()`;
- comments and assertions are formatted uniformely as objects with types `'message'` and `'assert'` correspondingly;
- fixed the incorrectly set to `1` `exitCode` when any comment was emitted.

Described bug can be reproduced with the following snippet:
```javascript
test('comment breaks exit code', function(assert) {
assert.comment('here comes trouble...');
assert.ok(1);
assert.end();
});
```

P.S.: sorry for whitespace line changes - I was struggling to prevent it but bastards just slipped through my fingers ;)