-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Add integration tests for debug command #5263
Conversation
readyPrompt = `debug(${displayHost})>`; | ||
} else { | ||
readyPrompt = `truffle(${displayHost})>`; | ||
} |
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.
Thoughts on writing this as
const readyPrompt = executableCommand === "debug" ? `debug(${displayHost})>` : `truffle(${displayHost})>`;
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.
I like your idea of removing if/else
and using a ternary instead of that, @lsqproduction. I will change this. Thanks!
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.
I like it
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! Though, there are some valid feedback/conversations to resolve.
Thanks for the approvals, @cds-amal and @eggplantzzz. I thought @lsqproduction's suggestions make sense. So, I applied those changes and pushed a new commit. Requested for a re-review for clarity. |
@@ -54,7 +54,11 @@ module.exports = { | |||
displayHost | |||
} = {}) { | |||
const cmdLine = `${this.getExecString()} ${executableCommand} ${executableArgs}`; | |||
const readyPrompt = `truffle(${displayHost})>`; | |||
|
|||
const readyPrompt = |
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.
yeah this looks nicer to me :)
This PR includes few integration tests for
truffle debug
which includes the following scenarios ---network
option with a config file.--url
option -1) with a config file.
2) without a config file (outside a truffle project).