Skip to content

Commit 992cdf7

Browse files
committed
tests: Log the output, to be more self-documenting
1 parent 74977d3 commit 992cdf7

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

spec/examples.coffee

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
fbpDiff = require '../'
33
chai = require 'chai'
44

5+
indent = (text, idn) ->
6+
indented = idn + text.replace /\n/gm, "\n#{idn}"
7+
return indented
8+
59
testExample = (testcase) ->
610
options =
711
format: testcase.format or 'fbp'
@@ -13,6 +17,7 @@ testExample = (testcase) ->
1317
it 'diff should equal expected', ->
1418
expected = testcase.diff.trim()
1519
chai.expect(diff).to.equal expected
20+
console.log indent diff, '\t'
1621

1722
loadTestCases = () ->
1823
# currently node.js only

0 commit comments

Comments
 (0)