Skip to content

Commit 7eece9f

Browse files
authored
Remove RWC runner and related infrastructure (#55187)
1 parent 9a771d5 commit 7eece9f

19 files changed

+4
-954
lines changed

Herebyfile.mjs

+1-20
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import util from "util";
1414
import { localizationDirectories } from "./scripts/build/localization.mjs";
1515
import cmdLineOptions from "./scripts/build/options.mjs";
1616
import { buildProject, cleanProject, watchProject } from "./scripts/build/projects.mjs";
17-
import { localBaseline, localRwcBaseline, refBaseline, refRwcBaseline, runConsoleTests } from "./scripts/build/tests.mjs";
17+
import { localBaseline, refBaseline, runConsoleTests } from "./scripts/build/tests.mjs";
1818
import { Debouncer, Deferred, exec, getDiffTool, memoize, needsUpdate, readJson } from "./scripts/build/utils.mjs";
1919

2020
const glob = util.promisify(_glob);
@@ -740,12 +740,6 @@ export const diff = task({
740740
run: () => exec(getDiffTool(), [refBaseline, localBaseline], { ignoreExitCode: true, waitForExit: false }),
741741
});
742742

743-
export const diffRwc = task({
744-
name: "diff-rwc",
745-
description: "Diffs the RWC baselines using the diff tool specified by the 'DIFF' environment variable",
746-
run: () => exec(getDiffTool(), [refRwcBaseline, localRwcBaseline], { ignoreExitCode: true, waitForExit: false }),
747-
});
748-
749743
/**
750744
* @param {string} localBaseline Path to the local copy of the baselines
751745
* @param {string} refBaseline Path to the reference copy of the baselines
@@ -780,12 +774,6 @@ export const baselineAccept = task({
780774
run: baselineAcceptTask(localBaseline, refBaseline),
781775
});
782776

783-
export const baselineAcceptRwc = task({
784-
name: "baseline-accept-rwc",
785-
description: "Makes the most recent rwc test results the new baseline, overwriting the old baseline",
786-
run: baselineAcceptTask(localRwcBaseline, refRwcBaseline),
787-
});
788-
789777
// TODO(rbuckton): Determine if we still need this task. Depending on a relative
790778
// path here seems like a bad idea.
791779
export const updateSublime = task({
@@ -799,13 +787,6 @@ export const updateSublime = task({
799787
}
800788
});
801789

802-
// TODO(rbuckton): Should the path to DefinitelyTyped be configurable via an environment variable?
803-
export const importDefinitelyTypedTests = task({
804-
name: "importDefinitelyTypedTests",
805-
description: "Runs the importDefinitelyTypedTests script to copy DT's tests to the TS-internal RWC tests",
806-
run: () => exec(process.execPath, ["scripts/importDefinitelyTypedTests.mjs", "./", "../DefinitelyTyped"]),
807-
});
808-
809790

810791
export const produceLKG = task({
811792
name: "LKG",

scripts/build/tests.mjs

+2-9
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,6 @@ import { exec, ExecError } from "./utils.mjs";
1212
const mochaJs = path.resolve(findUpRoot(), "node_modules", "mocha", "bin", "_mocha");
1313
export const localBaseline = "tests/baselines/local/";
1414
export const refBaseline = "tests/baselines/reference/";
15-
export const localRwcBaseline = "internal/baselines/rwc/local";
16-
export const refRwcBaseline = "internal/baselines/rwc/reference";
1715
export const coverageDir = "coverage";
1816

1917
/**
@@ -25,7 +23,7 @@ export const coverageDir = "coverage";
2523
* @param {boolean} [options.watching]
2624
*/
2725
export async function runConsoleTests(runJs, defaultReporter, runInParallel, options = {}) {
28-
let testTimeout = cmdLineOptions.timeout;
26+
const testTimeout = cmdLineOptions.timeout;
2927
const tests = cmdLineOptions.tests;
3028
const inspect = cmdLineOptions.break || cmdLineOptions.inspect;
3129
const runners = cmdLineOptions.runners;
@@ -67,10 +65,6 @@ export async function runConsoleTests(runJs, defaultReporter, runInParallel, opt
6765
workerCount = cmdLineOptions.workers;
6866
}
6967

70-
if (tests && tests.toLocaleLowerCase() === "rwc") {
71-
testTimeout = 400000;
72-
}
73-
7468
if (options.watching) {
7569
console.log(chalk.yellowBright(`[watch] running tests...`));
7670
}
@@ -174,8 +168,7 @@ export async function runConsoleTests(runJs, defaultReporter, runInParallel, opt
174168
}
175169

176170
export async function cleanTestDirs() {
177-
await del([localBaseline, localRwcBaseline]);
178-
await fs.promises.mkdir(localRwcBaseline, { recursive: true });
171+
await del([localBaseline]);
179172
await fs.promises.mkdir(localBaseline, { recursive: true });
180173
}
181174

scripts/importDefinitelyTypedTests.mjs

-178
This file was deleted.

src/harness/runnerbase.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import {
55
} from "./_namespaces/Harness";
66
import * as ts from "./_namespaces/ts";
77

8-
export type TestRunnerKind = CompilerTestKind | FourslashTestKind | "project" | "rwc";
8+
export type TestRunnerKind = CompilerTestKind | FourslashTestKind | "project";
99
export type CompilerTestKind = "conformance" | "compiler";
1010
export type FourslashTestKind = "fourslash" | "fourslash-shims" | "fourslash-shims-pp" | "fourslash-server";
1111

src/loggedIO/_namespaces/Harness.ts

-4
This file was deleted.

src/loggedIO/_namespaces/Playback.ts

-3
This file was deleted.

src/loggedIO/_namespaces/ts.server.ts

-7
This file was deleted.

src/loggedIO/_namespaces/ts.ts

-10
This file was deleted.

0 commit comments

Comments
 (0)