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

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 2 additions & 25 deletions ts-perf/packages/api/src/expansion.ts
Original file line number Diff line number Diff line change
Expand Up @@ -259,33 +259,10 @@ export class CommandLineArgumentsBuilder {
}

addCompilerOptions(options: CompilerOptions, scenario: Scenario) {
// TODO(jakebailey): This is a weird thing to do at this point;
// only one caller needs this info and this should be moved there.
this.hasBuild =
-1 !== (scenario?.args ? Math.max(scenario.args.indexOf("-b"), scenario.args.indexOf("--build")) : -1);
if (!this.hasBuild) {
this.add(
"--target",
"es5",
"--module",
"amd",
);
if (scenario?.singleFileOutput) {
this.add("--outfile", "${outDirectory}/out.js");
}
else {
this.add("--outdir", "${outDirectory}");
}
if (options.full) {
this.add(
"--declaration",
"--sourcemap",
"--removeComments",
"--mapRoot",
"${maprootDirectory}",
"--sourceRoot",
"${sourcerootDirectory}",
);
}
}

this.addRange(scenario?.args);
this.addRange(options.compilerOptions);
Expand Down
8 changes: 0 additions & 8 deletions ts-perf/packages/api/src/model/scenario.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ export interface ScenarioComponents {
default?: boolean;
disabled?: boolean;
platforms?: string[];
singleFileOutput?: boolean;
configFile: string;
tsserverConfig?: TSServerConfig;
}
Expand All @@ -29,7 +28,6 @@ export class Scenario {
public readonly default?: boolean;
public readonly disabled?: boolean;
public readonly platforms?: string[];
public readonly singleFileOutput?: boolean;
public readonly configFile: string;
public readonly tsserverConfig?: TSServerConfig;

Expand All @@ -45,7 +43,6 @@ export class Scenario {
default?: boolean;
disabled?: boolean;
platforms?: string[];
singleFileOutput?: boolean;
tsserverConfig?: TSServerConfig;
},
) {
Expand All @@ -58,7 +55,6 @@ export class Scenario {
this.default = options && options.default;
this.disabled = options && options.disabled;
this.platforms = options && options.platforms;
this.singleFileOutput = options && options.singleFileOutput;
this.configFile = configFile;
this.tsserverConfig = options && options.tsserverConfig;
}
Expand Down Expand Up @@ -241,7 +237,6 @@ export class Scenario {
const { default: default_ = this.default } = components;
const { disabled = this.disabled } = components;
const { platforms = this.platforms } = components;
const { singleFileOutput = this.singleFileOutput } = components;
const { configFile = this.configFile } = components;
const { tsserverConfig = this.tsserverConfig } = components;
if (
Expand All @@ -251,7 +246,6 @@ export class Scenario {
&& this.default === default_
&& this.disabled === disabled
&& this.platforms === platforms
&& this.singleFileOutput === singleFileOutput
&& this.configFile === configFile
) {
return this;
Expand All @@ -261,7 +255,6 @@ export class Scenario {
default: default_,
disabled,
platforms,
singleFileOutput,
tsserverConfig,
});
}
Expand All @@ -278,7 +271,6 @@ export class Scenario {
default: this.default,
disabled: this.disabled,
platforms: this.platforms && this.platforms.slice(),
singleFileOutput: this.singleFileOutput,
tsserverConfig: this.tsserverConfig,
};
}
Expand Down
5 changes: 0 additions & 5 deletions ts-perf/packages/api/src/options.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import { CommandLineOption, CommandLineOptionSet, CommandLineOptionSets, Command
export interface CompilerOptions {
tsc: string;
suite: string;
full?: boolean;
compilerOptions?: string[];
}

Expand Down Expand Up @@ -63,10 +62,6 @@ const compiler: CommandLineOptionSet = {
description: "Use <file> as the compiler (i.e. './built/local/tsc.js').",
},
suite,
full: {
type: "boolean",
description: "Runs the compiler with additional options.",
},
compilerOptions: {
type: "string",
passthru: true,
Expand Down