-
Notifications
You must be signed in to change notification settings - Fork 5.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: restore pty tests and make them run on the Linux CI #18424
Conversation
|
||
for item in deno_ast::lex(input, deno_ast::MediaType::TypeScript) { | ||
let current_line_index = line_info.line_index(item.range.start); | ||
let mut queued_validation_error = None; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The change here fixes another regression due to swc not having regex literals as tokens anymore. A pty test pointed this out.
)) | ||
} | ||
|
||
pub fn run(&self) -> TestCommandOutput { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Most of the below except cwd
and args
isn't new. The diff is just not great.
@@ -511,33 +539,30 @@ impl TestCommandOutput { | |||
.expect("call .split_output() on the builder") | |||
} | |||
|
|||
#[track_caller] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See https://blog.rust-lang.org/2020/08/27/Rust-1.46.0.html#track_caller
I just learned about this and it works way better than the failed_position()
thing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice find
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, sadly the tests don't yet work properly on macOS. We tried several things but none of them worked so far. I'll try to revisit this topic later this week.
@@ -511,33 +539,30 @@ impl TestCommandOutput { | |||
.expect("call .split_output() on the builder") | |||
} | |||
|
|||
#[track_caller] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice find
1. Rewrites the tests to be more back and forth rather than getting the output all at once (which I believe was causing the hangs on linux and maybe mac) 2. Runs the pty tests on the linux ci. 3. Fixes a bunch of tests that were just wrong. 4. Adds timeouts on the pty tests.
The repl tests now run on my system again. I will test on linux in a second.The tests didn't run on linux, so I'm rewriting them.This does a few things:
Closes #18129- Hangs on mac