From eb36d6e7a2fe89c9e8d1dd2d9fec027e95d90706 Mon Sep 17 00:00:00 2001 From: Geoffrey Booth Date: Sat, 10 Dec 2016 23:25:20 -0800 Subject: [PATCH] Get error messages tests to work in the browser --- Cakefile | 4 - docs/v1/test.html | 1197 +++++++++++++++++++++++++++++++++++++++ documentation/test.html | 2 + 3 files changed, 1199 insertions(+), 4 deletions(-) diff --git a/Cakefile b/Cakefile index 6e32d6aba8..1e3633dc83 100644 --- a/Cakefile +++ b/Cakefile @@ -240,10 +240,7 @@ task 'doc:test', 'watch and continually rebuild the browser-based tests', -> # Helpers testsInScriptBlocks = -> output = '' - excludedTestFiles = ['error_messages.coffee'] for filename in fs.readdirSync testsSourceFolder - continue if filename in excludedTestFiles - if filename.indexOf('.coffee') isnt -1 type = 'coffeescript' else if filename.indexOf('.litcoffee') isnt -1 @@ -266,7 +263,6 @@ task 'doc:test', 'watch and continually rebuild the browser-based tests', -> output = render testHelpers: testHelpers tests: testsInScriptBlocks() - majorVersion: majorVersion fs.writeFileSync "#{outputFolder}/test.html", output log 'compiled', green, "#{testFile} → #{outputFolder}/test.html" diff --git a/docs/v1/test.html b/docs/v1/test.html index 2a332e8eef..daf436a109 100644 --- a/docs/v1/test.html +++ b/docs/v1/test.html @@ -102,6 +102,8 @@

CoffeeScript Test Suite

if err if typeof err is 'function' and e instanceof err # Handle comparing exceptions ok yes + else if e.toString().indexOf('[stdin]') is 0 # Handle comparing error messages + ok err e else eq e, err else @@ -3410,6 +3412,1201 @@

CoffeeScript Test Suite

""" ok CoffeeScript.eval(code) + +