Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

test: adds test coverage report to @ganache/cli, improve coverage #3735

Open
wants to merge 84 commits into
base: develop
Choose a base branch
from

Conversation

jeffsmale90
Copy link
Contributor

@jeffsmale90 jeffsmale90 commented Sep 28, 2022

Makes some of the components in @ganache/cli more testable, adds coverage report, and improves test coverage to process-name.ts and args.ts. The tests for args.ts cover all of the "general" configuration cases, but does not cover the flavor specific arguments.

image

Fixes: #3978

… (but don't show that in the help, because it's ugly)
…tance files if the process no longer exists.
mmand matches (otherwise assume the process has been killed)
@jeffsmale90 jeffsmale90 changed the base branch from develop to feat/detach-mode September 28, 2022 07:52
@jeffsmale90 jeffsmale90 marked this pull request as draft September 28, 2022 07:52
@@ -21,6 +21,7 @@ export type StartArgs<TFlavorName extends FlavorName> =
export type GanacheArgs =
| (AbstractArgs<"stop"> & { name: string })
| AbstractArgs<"list">
| AbstractArgs<"none">
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is required because Yargs parser no longer terminates the process when argument validation fails (or --help) is passed.

Base automatically changed from feat/detach-mode to develop December 1, 2022 19:54
Comment on lines +228 to +231
if (!isFinite(port) || port < 1 || port > 65535) {
throw new Error(
`Port should be >= 0 and < 65536. Received ${port}.`
);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will conflict with #4070

@jeffsmale90 jeffsmale90 marked this pull request as ready for review December 21, 2022 22:01
@@ -71,7 +73,7 @@
"@trufflesuite/ps-list": "0.0.3",
"@types/node": "17.0.0",
"chalk": "4.1.0",
"cli-table": "0.3.11",
"marked-terminal": "4.1.0"
"marked-terminal": "4.1.0",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was this change on purpose? It seems like the versions are the same and they are now out of alphabetical order.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nope!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
Status: Stalled
Development

Successfully merging this pull request may close these issues.

Update weird promises import in detach once node v12 is dropped
3 participants