FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

fix(@angular/cli): serialize configuration as a single argv token in run_target strategies by herdiyana256 · Pull Request #33657 · angular/angular-cli · GitHub

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension .ts  (5) All 1 file type selected
Viewed files
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Unified
Split
Hide whitespace
Diff view
Unified
Split
Hide whitespace
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export class BuildTargetStrategy implements TargetStrategy {
): Promise<RunTargetOutput> {
const args = ['build', input.projectName];
if (input.configuration) {
args.push('-c', input.configuration);
args.push(`--configuration=${input.configuration}`);
}

args.push(...serializeOptions(input.options));
Expand Down
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export class GenericTargetStrategy implements TargetStrategy {
}

if (input.configuration) {
args.push('-c', input.configuration);
args.push(`--configuration=${input.configuration}`);
}

let options = input.options;
Expand Down
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ describe('Run Target Tool', () => {
mockContext.workspace.extensions['defaultProject'] = 'my-app';
await runTarget({ target: 'build', configuration: 'production' }, mockContext);
expect(mockHost.executeNgCommand).toHaveBeenCalledWith(
['build', 'my-app', '-c', 'production'],
['build', 'my-app', '--configuration=production'],
{
cwd: '/test',
},
Expand All @@ -53,7 +53,7 @@ describe('Run Target Tool', () => {
mockContext.workspace.extensions['defaultProject'] = 'my-app';
await runTarget({ target: 'storybook', configuration: 'docs' }, mockContext);
expect(mockHost.executeNgCommand).toHaveBeenCalledWith(
['run', 'my-app:storybook', '-c', 'docs'],
['run', 'my-app:storybook', '--configuration=docs'],
{ cwd: '/test' },
);
});
Expand Down
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export class UnitTestTargetStrategy implements TargetStrategy {
): Promise<RunTargetOutput> {
const args = ['test', input.projectName];
if (input.configuration) {
args.push('-c', input.configuration);
args.push(`--configuration=${input.configuration}`);
}

const builder = input.targetDefinition?.builder;
Expand Down
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,15 @@ describe('UnitTestTargetStrategy', () => {
);

expect(mockHost.executeNgCommand).toHaveBeenCalledWith(
['test', 'my-app', '-c', 'ci', '--browsers', 'ChromeHeadless', '--watch', 'false'],
[
'test',
'my-app',
'--configuration=ci',
'--browsers',
'ChromeHeadless',
'--watch',
'false',
],
{ cwd: '/test' },
);
});
Expand Down

Back | FazBrowse Home | New Git URL