[ospec] Make the default reporting nicer looking (#2147)

* feat(ospec): Add spacing before report results

...sometimes tested code emits console.log() messages
which then blend in with ospec's report

* feat(ospec): Reword and prettify the report messages

* feat(ospec): Make console.errors more compact, yet more readable

* docs(ospec): Update change-log.md

* fix(ospec): Fix grammar when number of assertions is 1

* feat(ospec): Make "all passed" message bright green

* refactor(ospec): define `cStyle()` helper for browser styling

* feat(ospec): Use en-dashes for the horizontal divider

* feat(ospec): Revert stacktrace coloring, make context bright red

...and add extra newline above each error - for readability
in commandline (node.js) mode

* feat(ospec): Improve the only-test-passed message

"1 assertion passed" --> "The 1 assertion passed"

* docs: Update LOC count
This commit is contained in:
Már Örlygsson 2018-05-22 16:19:54 +00:00 committed by Pierre-Yves Gérardy
parent 11940b427b
commit 2794ceb76f
3 changed files with 32 additions and 10 deletions

View file

@ -7,7 +7,7 @@ Noiseless testing framework
## About
- ~330 LOC including the CLI runner
- ~360 LOC including the CLI runner
- terser and faster test code than with mocha, jasmine or tape
- test code reads like bullet points
- assertion code follows [SVO](https://en.wikipedia.org/wiki/Subjectverbobject) structure in present tense for terseness and readability