-
Notifications
You must be signed in to change notification settings - Fork 52
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
Support debug gem #118
base: main
Are you sure you want to change the base?
Support debug gem #118
Conversation
@@ -192,7 +189,8 @@ export class RspecTests extends Tests { | |||
this.log.info(`Running test file: ${testFile}`); | |||
const spawnArgs: childProcess.SpawnOptions = { | |||
cwd: this.workspace.uri.fsPath, | |||
shell: true | |||
shell: true, | |||
env: this.getProcessEnv() |
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.
This fixes a bug that debug fails (due to lack of EXT_DIR
environment variable).
Thank you! My biggest concern with merging this right now would be the merge conflicts/issues it may cause with the rewrite in #90. I may ask that we wait until that's merged, or to rebase this PR on top of that one. |
This isn't a particularly big PR, so it shouldn't be too much work to incorporate it into the rewrite if you want to get it merged, and I'd be happy to do so :) |
Thank you! I'll try to make another patch based on #90. |
@@ -141,6 +141,20 @@ | |||
}, | |||
"scope": "resource" | |||
}, | |||
"rubyTestExplorer.debugger": { | |||
"description": "Which debugger to use. `rdebug-ide` or `rdbg`.", |
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.
This should probably be markdownDescription
given the use of backticks, otherwise they won't be rendered nicely
"description": "Which debugger to use. `rdebug-ide` or `rdbg`.", | |
"markdownDescription": "Which debugger to use. `rdebug-ide` or `rdbg`.", |
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.
also need to add ruby_lsp
https://github.com/Shopify/ruby-lsp
This PR enables debug tests with debug gem by using vscode-rdbg extension. (debug gem is bundled with Ruby 3.1+)
Users can choose which debugger to use by
rubyTestExplorer.debugger
configuration. (rdebug-ide
orrdbg
)Example