summaryrefslogtreecommitdiff
path: root/cli/tests
diff options
context:
space:
mode:
Diffstat (limited to 'cli/tests')
-rw-r--r--cli/tests/integration/test_tests.rs10
-rw-r--r--cli/tests/testdata/test/ops_sanitizer_multiple_timeout_tests_no_trace.out29
2 files changed, 37 insertions, 2 deletions
diff --git a/cli/tests/integration/test_tests.rs b/cli/tests/integration/test_tests.rs
index 0697fc69c..c80406935 100644
--- a/cli/tests/integration/test_tests.rs
+++ b/cli/tests/integration/test_tests.rs
@@ -146,7 +146,7 @@ itest!(allow_none {
});
itest!(ops_sanitizer_unstable {
- args: "test --unstable test/ops_sanitizer_unstable.ts",
+ args: "test --unstable --trace-ops test/ops_sanitizer_unstable.ts",
exit_code: 1,
output: "test/ops_sanitizer_unstable.out",
});
@@ -157,11 +157,17 @@ itest!(ops_sanitizer_timeout_failure {
});
itest!(ops_sanitizer_multiple_timeout_tests {
- args: "test test/ops_sanitizer_multiple_timeout_tests.ts",
+ args: "test --trace-ops test/ops_sanitizer_multiple_timeout_tests.ts",
exit_code: 1,
output: "test/ops_sanitizer_multiple_timeout_tests.out",
});
+itest!(ops_sanitizer_multiple_timeout_tests_no_trace {
+ args: "test test/ops_sanitizer_multiple_timeout_tests.ts",
+ exit_code: 1,
+ output: "test/ops_sanitizer_multiple_timeout_tests_no_trace.out",
+});
+
itest!(ops_sanitizer_nexttick {
args: "test test/ops_sanitizer_nexttick.ts",
output: "test/ops_sanitizer_nexttick.out",
diff --git a/cli/tests/testdata/test/ops_sanitizer_multiple_timeout_tests_no_trace.out b/cli/tests/testdata/test/ops_sanitizer_multiple_timeout_tests_no_trace.out
new file mode 100644
index 000000000..9dad65525
--- /dev/null
+++ b/cli/tests/testdata/test/ops_sanitizer_multiple_timeout_tests_no_trace.out
@@ -0,0 +1,29 @@
+Check [WILDCARD]/testdata/test/ops_sanitizer_multiple_timeout_tests.ts
+running 2 tests from [WILDCARD]/testdata/test/ops_sanitizer_multiple_timeout_tests.ts
+test test 1 ... FAILED ([WILDCARD])
+test test 2 ... FAILED ([WILDCARD])
+
+failures:
+
+test 1
+Test case is leaking async ops.
+
+- 2 async operations to sleep for a duration were started in this test, but never completed. This is often caused by not cancelling a `setTimeout` or `setInterval` call.
+
+To get more details where ops were leaked, run again with --trace-ops flag.
+
+test 2
+Test case is leaking async ops.
+
+- 2 async operations to sleep for a duration were started in this test, but never completed. This is often caused by not cancelling a `setTimeout` or `setInterval` call.
+
+To get more details where ops were leaked, run again with --trace-ops flag.
+
+failures:
+
+ test 1
+ test 2
+
+test result: FAILED. 0 passed; 2 failed; 0 ignored; 0 measured; 0 filtered out ([WILDCARD])
+
+error: Test failed