Skip to content
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

[cli] Move bin.ts core into -cli/run.ts #2602

Merged
merged 5 commits into from
Jun 28, 2017
Merged

[cli] Move bin.ts core into -cli/run.ts #2602

merged 5 commits into from
Jun 28, 2017

Conversation

paulirish
Copy link
Member

(partial) fix for #2601

Unblocks issues like addyosmani/webpack-lighthouse-plugin#5

No functional changes was made in this PR; it was only a copypaste party.

@patrickhulce
Copy link
Collaborator

needs a yarn format?

Copy link
Member

@brendankenny brendankenny left a comment

Choose a reason for hiding this comment

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

even though no code is really changing, should probably have at least one new test that calling the code from a module works :)

@paulirish
Copy link
Member Author

@brendankenny
Copy link
Member

need a rebase (not sure whats going on with codecov)


return handleError(err);
}
}
Copy link
Member

Choose a reason for hiding this comment

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

new line

@@ -0,0 +1,35 @@
/**
* @license Copyright 2016 Google Inc. All Rights Reserved.
Copy link
Member

Choose a reason for hiding this comment

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

2017

@@ -17,8 +17,10 @@ export interface Flags {
view: boolean, maxWaitForLoad: number
}

export function getFlags() {
return yargs.help('help')
export function getFlags(fakeInput?: string) {
Copy link
Member

Choose a reason for hiding this comment

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

nice, but can we call the parameter something else? It seems like a legitimate use, not just for testing, so what about manualInput, manualArgv, argvString, or something something :)

@paulirish
Copy link
Member Author

@brendankenny sg. done.
rebased.


describe('CLI run', function() {
it('runLighthouse completes a LH round trip', () => {
const url = 'chrome://version';
Copy link
Member

Choose a reason for hiding this comment

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

:)

Copy link
Member

@brendankenny brendankenny left a comment

Choose a reason for hiding this comment

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

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants