diff options
author | Ryan Dahl <ry@tinyclouds.org> | 2018-12-10 17:50:41 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-12-10 17:50:41 -0500 |
commit | 9a960b9f5804f5e855163e7ec43327c28daef845 (patch) | |
tree | f67a70c4c35999ff89601968e57783644063a062 /tests | |
parent | 1548792fb3530efb63432c0c704a3f0053410eb3 (diff) |
Use stderr for exceptions (#1303)
Diffstat (limited to 'tests')
-rw-r--r-- | tests/006_url_imports.ts.out | 2 | ||||
-rw-r--r-- | tests/015_import_no_ext.ts.out | 3 | ||||
-rw-r--r-- | tests/017_import_redirect.ts.out | 1 | ||||
-rw-r--r-- | tests/019_media_types.ts.out | 8 | ||||
-rw-r--r-- | tests/async_error.test | 1 | ||||
-rw-r--r-- | tests/async_error.ts.out | 2 | ||||
-rw-r--r-- | tests/error_001.test | 1 | ||||
-rw-r--r-- | tests/error_001.ts.out | 2 | ||||
-rw-r--r-- | tests/error_002.test | 1 | ||||
-rw-r--r-- | tests/error_002.ts.out | 2 | ||||
-rw-r--r-- | tests/error_004_missing_module.test | 1 | ||||
-rw-r--r-- | tests/error_004_missing_module.ts.out | 2 | ||||
-rw-r--r-- | tests/error_005_missing_dynamic_import.test | 1 | ||||
-rw-r--r-- | tests/error_005_missing_dynamic_import.ts.out | 2 | ||||
-rw-r--r-- | tests/error_006_import_ext_failure.test | 1 | ||||
-rw-r--r-- | tests/error_006_import_ext_failure.ts.out | 2 | ||||
-rw-r--r-- | tests/error_007_any.test | 1 | ||||
-rw-r--r-- | tests/error_007_any.ts.out | 2 | ||||
-rw-r--r-- | tests/https_import.ts.out | 1 |
19 files changed, 14 insertions, 22 deletions
diff --git a/tests/006_url_imports.ts.out b/tests/006_url_imports.ts.out index f481ff137..989ce33e9 100644 --- a/tests/006_url_imports.ts.out +++ b/tests/006_url_imports.ts.out @@ -1,4 +1,2 @@ -Downloading http://localhost:4545/tests/subdir/mod2.ts -Downloading http://localhost:4545/tests/subdir/print_hello.ts Hello success diff --git a/tests/015_import_no_ext.ts.out b/tests/015_import_no_ext.ts.out index 92f21e2a7..954e8636a 100644 --- a/tests/015_import_no_ext.ts.out +++ b/tests/015_import_no_ext.ts.out @@ -1,6 +1,3 @@ -Downloading http://localhost:4545/tests/subdir/mod2 -Downloading http://localhost:4545/tests/subdir/mod2.ts -Downloading http://localhost:4545/tests/subdir/print_hello.ts true [Function: printHello] [Function: printHello] diff --git a/tests/017_import_redirect.ts.out b/tests/017_import_redirect.ts.out index d1ec08c42..e965047ad 100644 --- a/tests/017_import_redirect.ts.out +++ b/tests/017_import_redirect.ts.out @@ -1,2 +1 @@ -Downloading http://gist.githubusercontent.com/ry/f12b2aa3409e6b52645bc346a9e22929/raw/79318f239f51d764384a8bded8d7c6a833610dde/print_hello.ts Hello diff --git a/tests/019_media_types.ts.out b/tests/019_media_types.ts.out index 31f5d8de0..7b5fdd44f 100644 --- a/tests/019_media_types.ts.out +++ b/tests/019_media_types.ts.out @@ -1,9 +1 @@ -Downloading http://localhost:4545/tests/subdir/mt_text_typescript.t1.ts -Downloading http://localhost:4545/tests/subdir/mt_video_vdn.t2.ts -Downloading http://localhost:4545/tests/subdir/mt_video_mp2t.t3.ts -Downloading http://localhost:4545/tests/subdir/mt_application_x_typescript.t4.ts -Downloading http://localhost:4545/tests/subdir/mt_text_javascript.j1.js -Downloading http://localhost:4545/tests/subdir/mt_application_ecmascript.j2.js -Downloading http://localhost:4545/tests/subdir/mt_text_ecmascript.j3.js -Downloading http://localhost:4545/tests/subdir/mt_application_x_javascript.j4.js success true true true true true true true true diff --git a/tests/async_error.test b/tests/async_error.test index 6734876c5..4667f6e09 100644 --- a/tests/async_error.test +++ b/tests/async_error.test @@ -1,3 +1,4 @@ exit_code: 1 args: tests/async_error.ts --reload +check_stderr: true output: tests/async_error.ts.out diff --git a/tests/async_error.ts.out b/tests/async_error.ts.out index 602d76424..dd844f9a9 100644 --- a/tests/async_error.ts.out +++ b/tests/async_error.ts.out @@ -1,4 +1,4 @@ -hello +[WILDCARD]hello before error world Error: error diff --git a/tests/error_001.test b/tests/error_001.test index 549b00995..354f536d5 100644 --- a/tests/error_001.test +++ b/tests/error_001.test @@ -1,3 +1,4 @@ args: tests/error_001.ts --reload +check_stderr: true exit_code: 1 output: tests/error_001.ts.out diff --git a/tests/error_001.ts.out b/tests/error_001.ts.out index 7ca70a6af..b9ad7938c 100644 --- a/tests/error_001.ts.out +++ b/tests/error_001.ts.out @@ -1,4 +1,4 @@ -Error: bad +[WILDCARD]Error: bad at foo (file://[WILDCARD]tests/error_001.ts:2:9) at bar (file://[WILDCARD]tests/error_001.ts:6:3) at eval (file://[WILDCARD]tests/error_001.ts:9:1) diff --git a/tests/error_002.test b/tests/error_002.test index e7eb6c83c..e8658ad96 100644 --- a/tests/error_002.test +++ b/tests/error_002.test @@ -1,3 +1,4 @@ args: tests/error_002.ts --reload +check_stderr: true exit_code: 1 output: tests/error_002.ts.out diff --git a/tests/error_002.ts.out b/tests/error_002.ts.out index 88f5138f3..6ea4ede78 100644 --- a/tests/error_002.ts.out +++ b/tests/error_002.ts.out @@ -1,4 +1,4 @@ -Error: exception from mod1 +[WILDCARD]Error: exception from mod1 at throwsError (file://[WILDCARD]/tests/subdir/mod1.ts:16:9) at foo (file://[WILDCARD]/tests/error_002.ts:4:3) at eval (file://[WILDCARD]/tests/error_002.ts:7:1) diff --git a/tests/error_004_missing_module.test b/tests/error_004_missing_module.test index 6f584e56a..b94c86004 100644 --- a/tests/error_004_missing_module.test +++ b/tests/error_004_missing_module.test @@ -1,3 +1,4 @@ args: tests/error_004_missing_module.ts --reload +check_stderr: true exit_code: 1 output: tests/error_004_missing_module.ts.out diff --git a/tests/error_004_missing_module.ts.out b/tests/error_004_missing_module.ts.out index e78692489..a15b65653 100644 --- a/tests/error_004_missing_module.ts.out +++ b/tests/error_004_missing_module.ts.out @@ -1,4 +1,4 @@ -NotFound: Cannot resolve module "bad-module.ts" from "[WILDCARD]/tests/error_004_missing_module.ts" +[WILDCARD]NotFound: Cannot resolve module "bad-module.ts" from "[WILDCARD]/tests/error_004_missing_module.ts" at DenoError ([WILDCARD]/js/errors.ts:[WILDCARD]) at maybeError ([WILDCARD]/js/errors.ts:[WILDCARD]) at maybeThrowError ([WILDCARD]/js/errors.ts:[WILDCARD]) diff --git a/tests/error_005_missing_dynamic_import.test b/tests/error_005_missing_dynamic_import.test index 826b3345d..2acf467c1 100644 --- a/tests/error_005_missing_dynamic_import.test +++ b/tests/error_005_missing_dynamic_import.test @@ -1,3 +1,4 @@ args: tests/error_005_missing_dynamic_import.ts --reload +check_stderr: true exit_code: 1 output: tests/error_005_missing_dynamic_import.ts.out diff --git a/tests/error_005_missing_dynamic_import.ts.out b/tests/error_005_missing_dynamic_import.ts.out index 7cf79a9b4..f59d19034 100644 --- a/tests/error_005_missing_dynamic_import.ts.out +++ b/tests/error_005_missing_dynamic_import.ts.out @@ -1,4 +1,4 @@ -NotFound: Cannot resolve module "bad-module.ts" from "[WILDCARD]/tests/error_005_missing_dynamic_import.ts" +[WILDCARD]NotFound: Cannot resolve module "bad-module.ts" from "[WILDCARD]/tests/error_005_missing_dynamic_import.ts" at DenoError ([WILDCARD]/js/errors.ts:[WILDCARD]) at maybeError ([WILDCARD]/js/errors.ts:[WILDCARD]) at maybeThrowError ([WILDCARD]/js/errors.ts:[WILDCARD]) diff --git a/tests/error_006_import_ext_failure.test b/tests/error_006_import_ext_failure.test index 90a625a17..5fe245739 100644 --- a/tests/error_006_import_ext_failure.test +++ b/tests/error_006_import_ext_failure.test @@ -1,3 +1,4 @@ args: tests/error_006_import_ext_failure.ts --reload +check_stderr: true exit_code: 1 output: tests/error_006_import_ext_failure.ts.out diff --git a/tests/error_006_import_ext_failure.ts.out b/tests/error_006_import_ext_failure.ts.out index aa56cc316..3c07bee70 100644 --- a/tests/error_006_import_ext_failure.ts.out +++ b/tests/error_006_import_ext_failure.ts.out @@ -1,4 +1,4 @@ -NotFound: Cannot resolve module "./non-existent" from "[WILDCARD]/tests/error_006_import_ext_failure.ts" +[WILDCARD]NotFound: Cannot resolve module "./non-existent" from "[WILDCARD]/tests/error_006_import_ext_failure.ts" at DenoError ([WILDCARD]/js/errors.ts:[WILDCARD]) at maybeError ([WILDCARD]/js/errors.ts:[WILDCARD]) at maybeThrowError ([WILDCARD]/js/errors.ts:[WILDCARD]) diff --git a/tests/error_007_any.test b/tests/error_007_any.test index 2c63c932a..970049195 100644 --- a/tests/error_007_any.test +++ b/tests/error_007_any.test @@ -1,3 +1,4 @@ args: tests/error_007_any.ts --reload +check_stderr: true exit_code: 1 output: tests/error_007_any.ts.out diff --git a/tests/error_007_any.ts.out b/tests/error_007_any.ts.out index 5bf110299..068b4b474 100644 --- a/tests/error_007_any.ts.out +++ b/tests/error_007_any.ts.out @@ -1 +1 @@ -[object Object] +[WILDCARD][object Object] diff --git a/tests/https_import.ts.out b/tests/https_import.ts.out index efc3fd543..e965047ad 100644 --- a/tests/https_import.ts.out +++ b/tests/https_import.ts.out @@ -1,2 +1 @@ -Downloading https://gist.githubusercontent.com/ry/f12b2aa3409e6b52645bc346a9e22929/raw/79318f239f51d764384a8bded8d7c6a833610dde/print_hello.ts Hello |