Simple fix to unicode
Caolan,
Simple request: in two places in the default.js reporter, the actual character is used in the code, for the checkmark (passed) and the xmark (failed) for an individual test.
To make it more cross-platform and unicode (and IDE) friendly, can it be replaced by the actual unicode?
line 81: replace the checkmark with '\u2714' (that is backslash character followed by u2714) line 84: replace the xmark with '\u2716' (that is backslash character followed by u2716)
@deitch sorry this took so long. I think this has been resolved via https://github.com/caolan/nodeunit/commit/19998595d21e6ac7eb24978b6960a03a70f330b8
if not, we can re-open.
Actually, I don't think that one resolves it. The change you linked to only changes test-cli.js.
It looks like it was consolidated as pass_indicator and fail_indicator here https://github.com/caolan/nodeunit/blob/master/lib/reporters/default.js#L54 and https://github.com/caolan/nodeunit/blob/master/lib/reporters/default.js#L55 , but it still uses the actual checkmarks if not on windows. Why not just use the unicode everywhere?
ah ok, I'll re-open it then.
Why not just use the unicode everywhere?
I dunno, I'm just the project maintainer, I wasn't around when this was originally written. I know this is one of the oldest node unit testing packages; probably was created when windows support was spotty/non-existent. :) Pull request welcome! 👍
Hmm, it wasn't on Windows. At least I think it wasn't. I don't recall the circumstances. Any reason not to change it?
I don't mind a PR, but it would be changing the following line:
// from
var pass_indicator = process.platform === 'win32' ? '\u221A' : '✔';
// to
var pass_indicator = '\u221A';