Skip to content

Commit a6be79d

Browse files
authored
Remove old test262 and dt runner infra (microsoft#53125)
1 parent 0e34f18 commit a6be79d

File tree

12 files changed

+10
-649
lines changed

12 files changed

+10
-649
lines changed

.gitignore

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ node_modules/
22
.node_modules/
33
built/*
44
tests/cases/rwc/*
5-
tests/cases/test262/*
65
tests/cases/perf/*
76
!tests/cases/webharness/compilerToString.js
87
test-args.txt
@@ -14,7 +13,6 @@ tests/baselines/local.old/*
1413
tests/services/baselines/local/*
1514
tests/baselines/prototyping/local/*
1615
tests/baselines/rwc/*
17-
tests/baselines/test262/*
1816
tests/baselines/reference/projectOutput/*
1917
tests/baselines/local/projectOutput/*
2018
tests/baselines/reference/testresults.tap

scripts/build/tests.mjs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ export const localBaseline = "tests/baselines/local/";
1414
export const refBaseline = "tests/baselines/reference/";
1515
export const localRwcBaseline = "internal/baselines/rwc/local";
1616
export const refRwcBaseline = "internal/baselines/rwc/reference";
17-
export const localTest262Baseline = "internal/baselines/test262/local";
1817

1918
/**
2019
* @param {string} runJs

src/.eslintrc.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"extends": "../.eslintrc.json",
33
"parserOptions": {
44
"tsconfigRootDir": "src",
5-
"project": "./tsconfig-base.json"
5+
"project": "./tsconfig-eslint.json"
66
},
77
"rules": {
88
"@typescript-eslint/no-unnecessary-type-assertion": "error",

src/harness/harnessIO.ts

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -610,7 +610,7 @@ export namespace Compiler {
610610
// if lib.d.ts is explicitly included in input files and there are some errors in it (i.e. because of duplicate identifiers)
611611
// then they will be added twice thus triggering 'total errors' assertion with condition
612612
// Similarly for tsconfig, which may be in the input files and contain errors.
613-
// 'totalErrorsReportedInNonLibraryNonTsconfigFiles + numLibraryDiagnostics + numTsconfigDiagnostics + numTest262HarnessDiagnostics, diagnostics.length
613+
// 'totalErrorsReportedInNonLibraryNonTsconfigFiles + numLibraryDiagnostics + numTsconfigDiagnostics, diagnostics.length
614614

615615
if (!error.file || !isDefaultLibraryFile(error.file.fileName) && !vpath.isTsConfigFile(error.file.fileName)) {
616616
totalErrorsReportedInNonLibraryNonTsconfigFiles++;
@@ -719,13 +719,8 @@ export namespace Compiler {
719719
return !!diagnostic.file && (vpath.isTsConfigFile(diagnostic.file.fileName));
720720
});
721721

722-
const numTest262HarnessDiagnostics = ts.countWhere(diagnostics, diagnostic => {
723-
// Count an error generated from tests262-harness folder.This should only apply for test262
724-
return !!diagnostic.file && diagnostic.file.fileName.indexOf("test262-harness") >= 0;
725-
});
726-
727722
// Verify we didn't miss any errors in total
728-
assert.equal(totalErrorsReportedInNonLibraryNonTsconfigFiles + numLibraryDiagnostics + numTsconfigDiagnostics + numTest262HarnessDiagnostics, diagnostics.length, "total number of errors");
723+
assert.equal(totalErrorsReportedInNonLibraryNonTsconfigFiles + numLibraryDiagnostics + numTsconfigDiagnostics, diagnostics.length, "total number of errors");
729724
}
730725

731726
export function doErrorBaseline(baselinePath: string, inputFiles: readonly TestFile[], errors: readonly ts.Diagnostic[], pretty?: boolean) {

src/harness/runnerbase.ts

Lines changed: 1 addition & 1 deletion
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" | "test262" | "dt";
8+
export type TestRunnerKind = CompilerTestKind | FourslashTestKind | "project" | "rwc";
99
export type CompilerTestKind = "conformance" | "compiler";
1010
export type FourslashTestKind = "fourslash" | "fourslash-shims" | "fourslash-shims-pp" | "fourslash-server";
1111

src/testRunner/_namespaces/Harness.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,6 @@ export { Parallel };
88

99
export * from "../fourslashRunner";
1010
export * from "../compilerRunner";
11-
export * from "../externalCompileRunner";
12-
export * from "../test262Runner";
1311
export * from "../runner";
1412

1513
// If running as emitted CJS, don't start executing the tests here; instead start in runner.ts.

src/testRunner/compilerRunner.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ import * as vpath from "./_namespaces/vpath";
1818
export const enum CompilerTestType {
1919
Conformance,
2020
Regressions,
21-
Test262
2221
}
2322

2423
interface CompilerFileBasedTest extends FileBasedTest {
@@ -41,9 +40,6 @@ export class CompilerBaselineRunner extends RunnerBase {
4140
else if (testType === CompilerTestType.Regressions) {
4241
this.testSuiteName = "compiler";
4342
}
44-
else if (testType === CompilerTestType.Test262) {
45-
this.testSuiteName = "test262";
46-
}
4743
else {
4844
this.testSuiteName = "compiler"; // default to this for historical reasons
4945
}

src/testRunner/externalCompileRunner.ts

Lines changed: 0 additions & 132 deletions
This file was deleted.

src/testRunner/runner.ts

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ import * as FourSlash from "./_namespaces/FourSlash";
22
import {
33
CompilerBaselineRunner,
44
CompilerTestType,
5-
DefinitelyTypedRunner,
65
FourSlashRunner,
76
GeneratedFourslashRunner,
87
IO,
@@ -11,7 +10,6 @@ import {
1110
setLightMode,
1211
setShardId,
1312
setShards,
14-
Test262BaselineRunner,
1513
TestRunnerKind,
1614
} from "./_namespaces/Harness";
1715
import * as project from "./_namespaces/project";
@@ -76,10 +74,6 @@ export function createRunner(kind: TestRunnerKind): RunnerBase {
7674
return new project.ProjectRunner();
7775
case "rwc":
7876
return new RWC.RWCRunner();
79-
case "test262":
80-
return new Test262BaselineRunner();
81-
case "dt":
82-
return new DefinitelyTypedRunner();
8377
}
8478
return ts.Debug.fail(`Unknown runner kind ${kind}`);
8579
}
@@ -214,12 +208,6 @@ function handleTestConfig() {
214208
case "rwc":
215209
runners.push(new RWC.RWCRunner());
216210
break;
217-
case "test262":
218-
runners.push(new Test262BaselineRunner());
219-
break;
220-
case "dt":
221-
runners.push(new DefinitelyTypedRunner());
222-
break;
223211
}
224212
}
225213
}

src/testRunner/test262Runner.ts

Lines changed: 0 additions & 120 deletions
This file was deleted.

src/tsconfig-eslint.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"extends": "./tsconfig-base",
3+
"compilerOptions": {
4+
"types": ["node", "mocha", "chai"]
5+
}
6+
}

0 commit comments

Comments
 (0)