aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> 2023-01-09 09:42:09 -0800
committerGravatar Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> 2023-01-09 09:42:09 -0800
commit55c1311aefad862bd55f59885f39a8e3b7a50b91 (patch)
tree63ff458277f83b95a70544a2619cbaf4110f2ea2
parentbeed35e55ec37dd305f02724e5f7bfd747af122b (diff)
downloadbun-55c1311aefad862bd55f59885f39a8e3b7a50b91.tar.gz
bun-55c1311aefad862bd55f59885f39a8e3b7a50b91.tar.zst
bun-55c1311aefad862bd55f59885f39a8e3b7a50b91.zip
fixup
-rw-r--r--src/cli/test_command.zig10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/cli/test_command.zig b/src/cli/test_command.zig
index 63dfc1525..39d4a7dbc 100644
--- a/src/cli/test_command.zig
+++ b/src/cli/test_command.zig
@@ -184,7 +184,7 @@ pub const CommandLineReporter = struct {
var this: *CommandLineReporter = @fieldParentPtr(CommandLineReporter, "callback", cb);
// If you do it.only, don't report the skipped tests because its pretty noisy
- if (jest.Jest.runner.?.only) {
+ if (jest.Jest.runner != null and !jest.Jest.runner.?.only) {
// when the tests skip, we want to repeat the failures at the end
// so that you can see them better when there are lots of tests that ran
const initial_length = this.skips_to_repeat_buf.items.len;
@@ -373,7 +373,7 @@ pub const TestCommand = struct {
.onTestSkip = CommandLineReporter.handleTestSkip,
};
reporter.jest.callback = &reporter.callback;
- jest.jest.runner = &reporter.jest;
+ jest.Jest.runner = &reporter.jest;
js_ast.Expr.Data.Store.create(default_allocator);
js_ast.Stmt.Data.Store.create(default_allocator);
@@ -591,12 +591,12 @@ pub const TestCommand = struct {
const initial_unhandled_counter = vm.unhandled_error_counter;
while (vm.active_tasks > 0 and vm.unhandled_error_counter == initial_unhandled_counter) {
- if (!jest.jest.runner.?.has_pending_tests) jest.jest.runner.?.drain();
+ if (!jest.Jest.runner.?.has_pending_tests) jest.Jest.runner.?.drain();
vm.eventLoop().tick();
- while (jest.jest.runner.?.has_pending_tests) {
+ while (jest.Jest.runner.?.has_pending_tests) {
vm.eventLoop().autoTick();
- if (!jest.jest.runner.?.has_pending_tests) break;
+ if (!jest.Jest.runner.?.has_pending_tests) break;
vm.eventLoop().tick();
}
}