-
-
Notifications
You must be signed in to change notification settings - Fork 376
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(transformer_conformance): skip some tests that are known to fail (…
…#3293) I don't think we need to be completely consistent with Babel's output. Because Babel's output doesn't always make sense.
- Loading branch information
Showing
4 changed files
with
108 additions
and
90 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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 |
---|---|---|
@@ -0,0 +1,91 @@ | ||
pub(crate) const PLUGINS: &[&str] = &[ | ||
// // ES2024 | ||
// "babel-plugin-transform-unicode-sets-regex", | ||
// // ES2022 | ||
// "babel-plugin-transform-class-properties", | ||
// "babel-plugin-transform-class-static-block", | ||
// "babel-plugin-transform-private-methods", | ||
// "babel-plugin-transform-private-property-in-object", | ||
// // [Syntax] "babel-plugin-transform-syntax-top-level-await", | ||
// // ES2021 | ||
// "babel-plugin-transform-logical-assignment-operators", | ||
// "babel-plugin-transform-numeric-separator", | ||
// // ES2020 | ||
// "babel-plugin-transform-export-namespace-from", | ||
// "babel-plugin-transform-dynamic-import", | ||
// "babel-plugin-transform-nullish-coalescing-operator", | ||
// "babel-plugin-transform-optional-chaining", | ||
// // [Syntax] "babel-plugin-transform-syntax-bigint", | ||
// // [Syntax] "babel-plugin-transform-syntax-dynamic-import", | ||
// // [Syntax] "babel-plugin-transform-syntax-import-meta", | ||
// // ES2019 | ||
// "babel-plugin-transform-optional-catch-binding", | ||
// "babel-plugin-transform-json-strings", | ||
// // ES2018 | ||
// "babel-plugin-transform-async-generator-functions", | ||
// "babel-plugin-transform-object-rest-spread", | ||
// // [Regex] "babel-plugin-transform-unicode-property-regex", | ||
// "babel-plugin-transform-dotall-regex", | ||
// // [Regex] "babel-plugin-transform-named-capturing-groups-regex", | ||
// // ES2017 | ||
// "babel-plugin-transform-async-to-generator", | ||
// // ES2016 | ||
// "babel-plugin-transform-exponentiation-operator", | ||
// // ES2015 | ||
"babel-plugin-transform-arrow-functions", | ||
// "babel-plugin-transform-function-name", | ||
// "babel-plugin-transform-shorthand-properties", | ||
// "babel-plugin-transform-sticky-regex", | ||
// "babel-plugin-transform-unicode-regex", | ||
// "babel-plugin-transform-template-literals", | ||
// "babel-plugin-transform-duplicate-keys", | ||
// "babel-plugin-transform-instanceof", | ||
// "babel-plugin-transform-new-target", | ||
// // ES3 | ||
// "babel-plugin-transform-property-literals", | ||
// TypeScript | ||
"babel-preset-typescript", | ||
"babel-plugin-transform-typescript", | ||
// React | ||
"babel-preset-react", | ||
"babel-plugin-transform-react-jsx", | ||
"babel-plugin-transform-react-display-name", | ||
"babel-plugin-transform-react-jsx-self", | ||
"babel-plugin-transform-react-jsx-source", | ||
"babel-plugin-transform-react-jsx-development", | ||
// // Proposal | ||
// "babel-plugin-proposal-decorators", | ||
]; | ||
|
||
pub(crate) const PLUGINS_NOT_SUPPORTED_YET: &[&str] = &[ | ||
"proposal-decorators", | ||
"transform-class-properties", | ||
"transform-classes", | ||
"transform-destructuring", | ||
"transform-modules-commonjs", | ||
"transform-object-rest-spread", | ||
"transform-optional-chaining", | ||
"transform-parameters", | ||
"transform-private-methods", | ||
"transform-property-literals", | ||
"transform-react-constant-elements", | ||
]; | ||
|
||
pub(crate) const SKIP_TESTS: &[&str] = &[ | ||
// Shouldn't report in transformer | ||
"typescript/test/fixtures/node-extensions/type-assertion-in-cts/input.cts", | ||
"typescript/test/fixtures/node-extensions/type-assertion-in-mts/input.mts", | ||
"typescript/test/fixtures/node-extensions/type-param-arrow-in-cts/input.mts", | ||
"typescript/test/fixtures/node-extensions/type-param-arrow-in-mts/input.mts", | ||
"typescript/test/fixtures/node-extensions/with-in-mts/input.mts", | ||
// Report error for deprecate option or oxc doesn’t follow error message | ||
"typescript/test/fixtures/opts/allowDeclareFields/input.ts", | ||
"react-jsx/test/fixtures/react-automatic/should-throw-when-filter-is-specified/input.js", | ||
"react-jsx-development/test/fixtures/cross-platform/source-and-self-defined/input.js", | ||
// Not standard JavaScript or TypeScript syntax | ||
"typescript/test/fixtures/exports/export-type-star-from/input.ts", | ||
// The output is valid and semantically correct | ||
// but does not match Babel's expected output | ||
"typescript/test/fixtures/namespace/canonical/input.ts", | ||
"react-jsx-development/test/fixtures/cross-platform/self-inside-arrow/input.mjs", | ||
]; |
This file contains 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
This file contains 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