From 1ac03c211f0a092e708864d338acb563362bcbd7 Mon Sep 17 00:00:00 2001 From: Yunfei Date: Thu, 12 Dec 2024 13:00:50 +0800 Subject: [PATCH 01/11] fix(transform/typescript): shoudn't strip values --- crates/oxc_semantic/src/builder.rs | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/crates/oxc_semantic/src/builder.rs b/crates/oxc_semantic/src/builder.rs index 0f9bc44e67da8..f57a1d72cc5c3 100644 --- a/crates/oxc_semantic/src/builder.rs +++ b/crates/oxc_semantic/src/builder.rs @@ -1845,13 +1845,8 @@ impl<'a> SemanticBuilder<'a> { /* cfg */ match kind { - AstKind::ExportNamedDeclaration(decl) => { - if decl.export_kind.is_type() { - self.current_reference_flags = ReferenceFlags::Type; - } - } AstKind::ExportSpecifier(s) => { - if self.current_reference_flags.is_type() || s.export_kind.is_type() { + if s.export_kind.is_type() || matches!(self.nodes.parent_kind(self.current_node_id), Some(AstKind::ExportNamedDeclaration(decl)) if decl.export_kind.is_type()) { self.current_reference_flags = ReferenceFlags::Type; } else { self.current_reference_flags = ReferenceFlags::Read | ReferenceFlags::Type; @@ -2016,9 +2011,7 @@ impl<'a> SemanticBuilder<'a> { self.class_table_builder.pop_class(); } AstKind::ExportSpecifier(_) => { - if !self.current_reference_flags.is_type_only() { - self.current_reference_flags = ReferenceFlags::empty(); - } + self.current_reference_flags = ReferenceFlags::empty(); self.current_node_flags -= NodeFlags::ExportSpecifier; } AstKind::Function(_) | AstKind::ArrowFunctionExpression(_) => { From ea42dfa149007e4d651c936dcc204d5405427cc0 Mon Sep 17 00:00:00 2001 From: "autofix-ci[bot]" <114827586+autofix-ci[bot]@users.noreply.github.com> Date: Thu, 12 Dec 2024 05:01:57 +0000 Subject: [PATCH 02/11] [autofix.ci] apply automated fixes --- crates/oxc_semantic/src/builder.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/crates/oxc_semantic/src/builder.rs b/crates/oxc_semantic/src/builder.rs index f57a1d72cc5c3..7d5d6d1b26b5c 100644 --- a/crates/oxc_semantic/src/builder.rs +++ b/crates/oxc_semantic/src/builder.rs @@ -1846,7 +1846,9 @@ impl<'a> SemanticBuilder<'a> { match kind { AstKind::ExportSpecifier(s) => { - if s.export_kind.is_type() || matches!(self.nodes.parent_kind(self.current_node_id), Some(AstKind::ExportNamedDeclaration(decl)) if decl.export_kind.is_type()) { + if s.export_kind.is_type() + || matches!(self.nodes.parent_kind(self.current_node_id), Some(AstKind::ExportNamedDeclaration(decl)) if decl.export_kind.is_type()) + { self.current_reference_flags = ReferenceFlags::Type; } else { self.current_reference_flags = ReferenceFlags::Read | ReferenceFlags::Type; From bbb486a3434124a4d0053e2e0baaa429d36187d5 Mon Sep 17 00:00:00 2001 From: Yunfei Date: Thu, 12 Dec 2024 13:12:32 +0800 Subject: [PATCH 03/11] Fix --- crates/oxc_semantic/src/builder.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/oxc_semantic/src/builder.rs b/crates/oxc_semantic/src/builder.rs index 7d5d6d1b26b5c..37fdf37a23a75 100644 --- a/crates/oxc_semantic/src/builder.rs +++ b/crates/oxc_semantic/src/builder.rs @@ -1851,7 +1851,7 @@ impl<'a> SemanticBuilder<'a> { { self.current_reference_flags = ReferenceFlags::Type; } else { - self.current_reference_flags = ReferenceFlags::Read | ReferenceFlags::Type; + self.current_reference_flags = ReferenceFlags::Read; } self.current_node_flags |= NodeFlags::ExportSpecifier; } From 3b275f53f356f27f2c378cfd9e7ff038575b9243 Mon Sep 17 00:00:00 2001 From: Yunfei Date: Thu, 12 Dec 2024 13:23:56 +0800 Subject: [PATCH 04/11] Fix --- crates/oxc_semantic/src/builder.rs | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/crates/oxc_semantic/src/builder.rs b/crates/oxc_semantic/src/builder.rs index 37fdf37a23a75..35cc2fcd16e94 100644 --- a/crates/oxc_semantic/src/builder.rs +++ b/crates/oxc_semantic/src/builder.rs @@ -490,6 +490,16 @@ impl<'a> SemanticBuilder<'a> { references.retain(|&reference_id| { let reference = &mut self.symbols.references[reference_id]; + + // Ensure having correct flags for the reference `foo` in case + // ```js + // type foo = number; + // export { foo }; + // ``` + if symbol_flags.is_type() { + *reference.flags_mut() = ReferenceFlags::Type; + } + let flags = reference.flags(); if flags.is_type() && symbol_flags.can_be_referenced_by_type() || flags.is_value() && symbol_flags.can_be_referenced_by_value() @@ -1850,8 +1860,6 @@ impl<'a> SemanticBuilder<'a> { || matches!(self.nodes.parent_kind(self.current_node_id), Some(AstKind::ExportNamedDeclaration(decl)) if decl.export_kind.is_type()) { self.current_reference_flags = ReferenceFlags::Type; - } else { - self.current_reference_flags = ReferenceFlags::Read; } self.current_node_flags |= NodeFlags::ExportSpecifier; } From 2a58aa94d0d053b5010f93d29a906a337e03b288 Mon Sep 17 00:00:00 2001 From: Yunfei Date: Thu, 12 Dec 2024 13:56:17 +0800 Subject: [PATCH 05/11] Fix --- crates/oxc_semantic/src/builder.rs | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/crates/oxc_semantic/src/builder.rs b/crates/oxc_semantic/src/builder.rs index 35cc2fcd16e94..59e4573c02181 100644 --- a/crates/oxc_semantic/src/builder.rs +++ b/crates/oxc_semantic/src/builder.rs @@ -491,15 +491,6 @@ impl<'a> SemanticBuilder<'a> { references.retain(|&reference_id| { let reference = &mut self.symbols.references[reference_id]; - // Ensure having correct flags for the reference `foo` in case - // ```js - // type foo = number; - // export { foo }; - // ``` - if symbol_flags.is_type() { - *reference.flags_mut() = ReferenceFlags::Type; - } - let flags = reference.flags(); if flags.is_type() && symbol_flags.can_be_referenced_by_type() || flags.is_value() && symbol_flags.can_be_referenced_by_value() @@ -1860,6 +1851,10 @@ impl<'a> SemanticBuilder<'a> { || matches!(self.nodes.parent_kind(self.current_node_id), Some(AstKind::ExportNamedDeclaration(decl)) if decl.export_kind.is_type()) { self.current_reference_flags = ReferenceFlags::Type; + } else { + // If the export specifier is not a explicit type export, oxc considers it as a potential type and value reference. + // If it references to a value in the end, oxc would delete the `ReferenceFlags::Type` flag in `fn resolve_references_for_current_scope`. + self.current_reference_flags = ReferenceFlags::Read | ReferenceFlags::Type; } self.current_node_flags |= NodeFlags::ExportSpecifier; } From 799265ddc6a38dee36949262110432db5c0ef551 Mon Sep 17 00:00:00 2001 From: Yunfei Date: Thu, 12 Dec 2024 14:05:01 +0800 Subject: [PATCH 06/11] Update snap --- tasks/coverage/snapshots/semantic_typescript.snap | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tasks/coverage/snapshots/semantic_typescript.snap b/tasks/coverage/snapshots/semantic_typescript.snap index dfda5632274e6..14078cbfd9908 100644 --- a/tasks/coverage/snapshots/semantic_typescript.snap +++ b/tasks/coverage/snapshots/semantic_typescript.snap @@ -25257,15 +25257,15 @@ tasks/coverage/typescript/tests/cases/compiler/noCircularDefinitionOnExportOfPri semantic error: Scope children mismatch: after transform: ScopeId(0): [ScopeId(1), ScopeId(2)] rebuilt : ScopeId(0): [ScopeId(1)] +Symbol reference IDs mismatch for "cat": +after transform: SymbolId(0): [ReferenceId(1)] +rebuilt : SymbolId(0): [] Symbol flags mismatch for "Foo": after transform: SymbolId(1): SymbolFlags(Class | NameSpaceModule | Ambient) rebuilt : SymbolId(1): SymbolFlags(Class) Symbol redeclarations mismatch for "Foo": after transform: SymbolId(1): [Span { start: 61, end: 64 }] rebuilt : SymbolId(1): [] -Unresolved references mismatch: -after transform: ["cat", "module"] -rebuilt : ["module"] tasks/coverage/typescript/tests/cases/compiler/noCollisionThisExpressionAndLocalVarInFunction.ts semantic error: Scope children mismatch: From 99799239983950947777b464eae186336a839631 Mon Sep 17 00:00:00 2001 From: Dunqing Date: Thu, 12 Dec 2024 14:25:23 +0800 Subject: [PATCH 07/11] foramt comment --- crates/oxc_semantic/src/builder.rs | 5 +- .../snapshots/babel_exec.snap.md | 148 +----------------- .../snapshots/oxc_exec.snap.md | 5 +- 3 files changed, 11 insertions(+), 147 deletions(-) diff --git a/crates/oxc_semantic/src/builder.rs b/crates/oxc_semantic/src/builder.rs index 59e4573c02181..6044c357fd3c9 100644 --- a/crates/oxc_semantic/src/builder.rs +++ b/crates/oxc_semantic/src/builder.rs @@ -1852,8 +1852,9 @@ impl<'a> SemanticBuilder<'a> { { self.current_reference_flags = ReferenceFlags::Type; } else { - // If the export specifier is not a explicit type export, oxc considers it as a potential type and value reference. - // If it references to a value in the end, oxc would delete the `ReferenceFlags::Type` flag in `fn resolve_references_for_current_scope`. + // If the export specifier is not a explicit type export, we consider it as a potential + // type and value reference. If it references to a value in the end, we would delete the + // `ReferenceFlags::Type` flag in `fn resolve_references_for_current_scope`. self.current_reference_flags = ReferenceFlags::Read | ReferenceFlags::Type; } self.current_node_flags |= NodeFlags::ExportSpecifier; diff --git a/tasks/transform_conformance/snapshots/babel_exec.snap.md b/tasks/transform_conformance/snapshots/babel_exec.snap.md index 87fe948a7cec7..8820341f83c90 100644 --- a/tasks/transform_conformance/snapshots/babel_exec.snap.md +++ b/tasks/transform_conformance/snapshots/babel_exec.snap.md @@ -1,148 +1,8 @@ commit: 54a8389f node: v22.12.0 +filter: fixtures/babel +include: **/*.{test,spec}.?(c|m)[jt]s?(x) +exclude: **/node_modules/**, **/dist/**, **/cypress/**, **/.{idea,git,cache,output,temp}/**, **/{karma,rollup,webpack,vite,vitest,jest,ava,babel,nyc,cypress,tsup,build,eslint,prettier}.config.*, "" -Passed: 186 of 215 (86.51%) - -Failures: - -./fixtures/babel/babel-plugin-transform-arrow-functions-test-fixtures-arrow-functions-implicit-var-arguments-exec.test.js -'eval' and 'arguments' cannot be used as a binding identifier in strict mode - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-assumption-setPublicClassFields-static-infer-name-exec.test.js -AssertionError: expected '_Class' to be 'Foo' // Object.is equality - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-assumption-setPublicClassFields-static-infer-name-exec.test.js:8:19 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-assumption-setPublicClassFields-static-super-exec.test.js -Invalid access to super - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-nested-class-super-call-in-decorator-exec.test.js -AssertionError: expected undefined to be 'hello' // Object.is equality - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-nested-class-super-call-in-decorator-exec.test.js:21:28 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-nested-class-super-property-in-accessor-key-exec.test.js -Unexpected token `[`. Expected * for generator, private key, identifier or async - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-nested-class-super-property-in-decorator-exec.test.js -AssertionError: expected undefined to be 'hello' // Object.is equality - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-nested-class-super-property-in-decorator-exec.test.js:22:28 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-constructor-collision-exec.test.js -AssertionError: expected undefined to be 'bar' // Object.is equality - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-constructor-collision-exec.test.js:18:19 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-constructor-collision-exec.test.js -AssertionError: expected undefined to be 'bar' // Object.is equality - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-constructor-collision-exec.test.js:21:19 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-nested-class-computed-redeclared-exec.test.js -Private field '#foo' must be declared in an enclosing class - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-nested-class-extends-computed-exec.test.js -AssertionError: expected [Function] to not throw an error but 'TypeError: attempted to use private f…' was thrown - at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:1438:21) - at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:923:17) - at Proxy.methodWrapper (./node_modules/.pnpm/chai@5.1.2/node_modules/chai/chai.js:1610:25) - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-nested-class-extends-computed-exec.test.js:36:9 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-in-function-param-with-transform-exec.test.js -TypeError: Cannot convert undefined or null to object - at hasOwnProperty () - at _classPrivateFieldBase (./node_modules/.pnpm/@babel+runtime@7.26.0/node_modules/@babel/runtime/helpers/classPrivateFieldLooseBase.js:2:26) - at value (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-in-function-param-with-transform-exec.test.js:63:11) - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-in-function-param-with-transform-exec.test.js:44:198 - at j (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-in-function-param-with-transform-exec.test.js:45:6) - at Function.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-in-function-param-with-transform-exec.test.js:52:11) - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-in-function-param-with-transform-exec.test.js:71:6 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-member-optional-call-with-transform-exec.test.js -TypeError: Cannot convert undefined or null to object - at hasOwnProperty () - at _classPrivateFieldBase (./node_modules/.pnpm/@babel+runtime@7.26.0/node_modules/@babel/runtime/helpers/classPrivateFieldLooseBase.js:2:26) - at value (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-member-optional-call-with-transform-exec.test.js:123:11) - at Function.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-member-optional-call-with-transform-exec.test.js:24:134) - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-member-optional-call-with-transform-exec.test.js:131:6 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-parenthesized-optional-member-call-exec.test.js -TypeError: Cannot read properties of undefined (reading 'bind') - at Foo.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-parenthesized-optional-member-call-exec.test.js:20:59) - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-parenthesized-optional-member-call-exec.test.js:78:12 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-parenthesized-optional-member-call-with-transform-exec.test.js -TypeError: Cannot read properties of undefined (reading 'bind') - at Foo.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-parenthesized-optional-member-call-with-transform-exec.test.js:20:59) - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-parenthesized-optional-member-call-with-transform-exec.test.js:78:12 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-nested-class-computed-redeclared-exec.test.js -Private field '#foo' must be declared in an enclosing class - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-nested-class-extends-computed-exec.test.js -AssertionError: expected [Function] to not throw an error but 'TypeError: Private element is not pre…' was thrown - at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:1438:21) - at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:923:17) - at Proxy.methodWrapper (./node_modules/.pnpm/chai@5.1.2/node_modules/chai/chai.js:1610:25) - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-nested-class-extends-computed-exec.test.js:31:9 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-static-shadow-exec.test.js -TypeError: e.has is not a function - at _assertClassBrand (./node_modules/.pnpm/@babel+runtime@7.26.0/node_modules/@babel/runtime/helpers/assertClassBrand.js:2:44) - at func (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-static-shadow-exec.test.js:10:12) - at Function.method (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-static-shadow-exec.test.js:12:11) - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-static-shadow-exec.test.js:16:14 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-computed-toPrimitive-exec.test.js -AssertionError: expected [Function] to throw error including '@@toPrimitive must return a primitive…' but got 'Cannot convert object to primitive va…' - at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:1438:21) - at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:923:17) - at Proxy.methodWrapper (./node_modules/.pnpm/chai@5.1.2/node_modules/chai/chai.js:1610:25) - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-computed-toPrimitive-exec.test.js:37:5 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-delete-super-property-exec.test.js -Invalid access to super - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-loose-static-infer-name-exec.test.js -AssertionError: expected '_Class' to be 'Foo' // Object.is equality - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-loose-static-infer-name-exec.test.js:8:19 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-loose-static-super-exec.test.js -Invalid access to super - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-static-infer-name-exec.test.js -AssertionError: expected '_Class' to be 'Foo' // Object.is equality - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-static-infer-name-exec.test.js:9:19 - -./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-static-super-exec.test.js -Invalid access to super - -./fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-assumption-noDocumentAll-parenthesized-expression-member-call-exec.test.js -TypeError: Cannot read properties of undefined (reading 'x') - at m (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-assumption-noDocumentAll-parenthesized-expression-member-call-exec.test.js:10:16) - at Foo.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-assumption-noDocumentAll-parenthesized-expression-member-call-exec.test.js:25:63) - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-assumption-noDocumentAll-parenthesized-expression-member-call-exec.test.js:68:12 - -./fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-exec.test.js -TypeError: Cannot read properties of undefined (reading 'x') - at m (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-exec.test.js:10:16) - at Foo.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-exec.test.js:25:63) - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-exec.test.js:68:12 - -./fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-loose-exec.test.js -TypeError: Cannot read properties of undefined (reading 'x') - at m (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-loose-exec.test.js:10:16) - at Foo.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-loose-exec.test.js:25:63) - at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-loose-exec.test.js:68:12 - -./fixtures/babel/babel-preset-env-test-fixtures-plugins-integration-issue-15170-exec.test.js -AssertionError: expected [Function] to not throw an error but 'ReferenceError: x is not defined' was thrown - at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:1438:21) - at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:923:17) - at Proxy.methodWrapper (./node_modules/.pnpm/chai@5.1.2/node_modules/chai/chai.js:1610:25) - at ./tasks/transform_conformance/fixtures/babel/babel-preset-env-test-fixtures-plugins-integration-issue-15170-exec.test.js:6:9 - -./fixtures/babel/babel-preset-env-test-fixtures-sanity-check-es2015-constants-exec.test.js -TypeError: Assignment to constant variable. - at ./tasks/transform_conformance/fixtures/babel/babel-preset-env-test-fixtures-sanity-check-es2015-constants-exec.test.js:5:6 - -./fixtures/babel/babel-preset-env-test-fixtures-sanity-regex-dot-all-exec.test.js -AssertionError: expected false to be true // Object.is equality - at ./tasks/transform_conformance/fixtures/babel/babel-preset-env-test-fixtures-sanity-regex-dot-all-exec.test.js:10:37 +No test files found, exiting with code 1 diff --git a/tasks/transform_conformance/snapshots/oxc_exec.snap.md b/tasks/transform_conformance/snapshots/oxc_exec.snap.md index 23e62427ba1c3..1c3b4e2a74fc8 100644 --- a/tasks/transform_conformance/snapshots/oxc_exec.snap.md +++ b/tasks/transform_conformance/snapshots/oxc_exec.snap.md @@ -1,5 +1,8 @@ commit: 54a8389f node: v22.12.0 +filter: fixtures/oxc +include: **/*.{test,spec}.?(c|m)[jt]s?(x) +exclude: **/node_modules/**, **/dist/**, **/cypress/**, **/.{idea,git,cache,output,temp}/**, **/{karma,rollup,webpack,vite,vitest,jest,ava,babel,nyc,cypress,tsup,build,eslint,prettier}.config.*, "" -Passed: 3 of 3 (100.00%) +No test files found, exiting with code 1 From 944453617add0983affb54682fde5e2a3ed36fa1 Mon Sep 17 00:00:00 2001 From: Dunqing Date: Thu, 12 Dec 2024 14:41:40 +0800 Subject: [PATCH 08/11] add semantic fixture test --- .../ts/export/named/type-and-non-type.snap | 50 +++++++++++++++++++ .../oxc/ts/export/named/type-and-non-type.ts | 4 ++ 2 files changed, 54 insertions(+) create mode 100644 crates/oxc_semantic/tests/fixtures/oxc/ts/export/named/type-and-non-type.snap create mode 100644 crates/oxc_semantic/tests/fixtures/oxc/ts/export/named/type-and-non-type.ts diff --git a/crates/oxc_semantic/tests/fixtures/oxc/ts/export/named/type-and-non-type.snap b/crates/oxc_semantic/tests/fixtures/oxc/ts/export/named/type-and-non-type.snap new file mode 100644 index 0000000000000..0858fc9ddc8e2 --- /dev/null +++ b/crates/oxc_semantic/tests/fixtures/oxc/ts/export/named/type-and-non-type.snap @@ -0,0 +1,50 @@ +--- +source: crates/oxc_semantic/tests/main.rs +input_file: crates/oxc_semantic/tests/fixtures/oxc/ts/export/named/type-and-non-type.ts +--- +[ + { + "children": [ + { + "children": [], + "flags": "ScopeFlags(StrictMode)", + "id": 1, + "node": "TSTypeAliasDeclaration", + "symbols": [] + } + ], + "flags": "ScopeFlags(StrictMode | Top)", + "id": 0, + "node": "Program", + "symbols": [ + { + "flags": "SymbolFlags(BlockScopedVariable | ConstVariable)", + "id": 0, + "name": "ToastViewport", + "node": "VariableDeclarator(ToastViewport)", + "references": [ + { + "flags": "ReferenceFlags(Read)", + "id": 1, + "name": "ToastViewport", + "node_id": 14 + } + ] + }, + { + "flags": "SymbolFlags(TypeAlias)", + "id": 1, + "name": "ToastProps", + "node": "TSTypeAliasDeclaration", + "references": [ + { + "flags": "ReferenceFlags(Type)", + "id": 0, + "name": "ToastProps", + "node_id": 11 + } + ] + } + ] + } +] diff --git a/crates/oxc_semantic/tests/fixtures/oxc/ts/export/named/type-and-non-type.ts b/crates/oxc_semantic/tests/fixtures/oxc/ts/export/named/type-and-non-type.ts new file mode 100644 index 0000000000000..9cb41349ce73c --- /dev/null +++ b/crates/oxc_semantic/tests/fixtures/oxc/ts/export/named/type-and-non-type.ts @@ -0,0 +1,4 @@ +const ToastViewport = 1; +type ToastProps = string; + +export { type ToastProps, ToastViewport }; From 52678a7f90f73f2dadfe6f79d4e166a3b1132d13 Mon Sep 17 00:00:00 2001 From: Dunqing Date: Thu, 12 Dec 2024 15:02:20 +0800 Subject: [PATCH 09/11] add a test in transformer --- tasks/transform_conformance/snapshots/oxc.snap.md | 7 +++++-- .../test/fixtures/exports/type-and-non-type/input.ts | 4 ++++ .../test/fixtures/exports/type-and-non-type/output.js | 2 ++ 3 files changed, 11 insertions(+), 2 deletions(-) create mode 100644 tasks/transform_conformance/tests/babel-plugin-transform-typescript/test/fixtures/exports/type-and-non-type/input.ts create mode 100644 tasks/transform_conformance/tests/babel-plugin-transform-typescript/test/fixtures/exports/type-and-non-type/output.js diff --git a/tasks/transform_conformance/snapshots/oxc.snap.md b/tasks/transform_conformance/snapshots/oxc.snap.md index 387c20f4e124e..a738e9676aa5c 100644 --- a/tasks/transform_conformance/snapshots/oxc.snap.md +++ b/tasks/transform_conformance/snapshots/oxc.snap.md @@ -1,6 +1,6 @@ commit: 54a8389f -Passed: 107/121 +Passed: 107/122 # All Passed: * babel-plugin-transform-class-static-block @@ -44,7 +44,7 @@ rebuilt : SymbolId(0): [ReferenceId(0), ReferenceId(2), ReferenceId(6), R x Output mismatch -# babel-plugin-transform-typescript (2/9) +# babel-plugin-transform-typescript (2/10) * class-property-definition/input.ts Unresolved references mismatch: after transform: ["const"] @@ -155,6 +155,9 @@ Reference symbol mismatch for "Name": after transform: SymbolId(7) "Name" rebuilt : SymbolId(5) "Name" +* exports/type-and-non-type/input.ts +x Output mismatch + * redeclarations/input.ts Scope children mismatch: after transform: ScopeId(0): [ScopeId(1), ScopeId(2)] diff --git a/tasks/transform_conformance/tests/babel-plugin-transform-typescript/test/fixtures/exports/type-and-non-type/input.ts b/tasks/transform_conformance/tests/babel-plugin-transform-typescript/test/fixtures/exports/type-and-non-type/input.ts new file mode 100644 index 0000000000000..9cb41349ce73c --- /dev/null +++ b/tasks/transform_conformance/tests/babel-plugin-transform-typescript/test/fixtures/exports/type-and-non-type/input.ts @@ -0,0 +1,4 @@ +const ToastViewport = 1; +type ToastProps = string; + +export { type ToastProps, ToastViewport }; diff --git a/tasks/transform_conformance/tests/babel-plugin-transform-typescript/test/fixtures/exports/type-and-non-type/output.js b/tasks/transform_conformance/tests/babel-plugin-transform-typescript/test/fixtures/exports/type-and-non-type/output.js new file mode 100644 index 0000000000000..a7978f29fd3a1 --- /dev/null +++ b/tasks/transform_conformance/tests/babel-plugin-transform-typescript/test/fixtures/exports/type-and-non-type/output.js @@ -0,0 +1,2 @@ +const ToastViewport = 1; +export { ToastViewport }; \ No newline at end of file From 938b41c39124c54d1de05903cfcd0eb25154a830 Mon Sep 17 00:00:00 2001 From: Dunqing Date: Thu, 12 Dec 2024 22:15:21 +0800 Subject: [PATCH 10/11] update snapshots --- .../snapshots/babel_exec.snap.md | 148 +++++++++++++++++- .../snapshots/oxc.snap.md | 7 +- .../snapshots/oxc_exec.snap.md | 5 +- 3 files changed, 151 insertions(+), 9 deletions(-) diff --git a/tasks/transform_conformance/snapshots/babel_exec.snap.md b/tasks/transform_conformance/snapshots/babel_exec.snap.md index 8820341f83c90..87fe948a7cec7 100644 --- a/tasks/transform_conformance/snapshots/babel_exec.snap.md +++ b/tasks/transform_conformance/snapshots/babel_exec.snap.md @@ -1,8 +1,148 @@ commit: 54a8389f node: v22.12.0 -filter: fixtures/babel -include: **/*.{test,spec}.?(c|m)[jt]s?(x) -exclude: **/node_modules/**, **/dist/**, **/cypress/**, **/.{idea,git,cache,output,temp}/**, **/{karma,rollup,webpack,vite,vitest,jest,ava,babel,nyc,cypress,tsup,build,eslint,prettier}.config.*, "" -No test files found, exiting with code 1 +Passed: 186 of 215 (86.51%) + +Failures: + +./fixtures/babel/babel-plugin-transform-arrow-functions-test-fixtures-arrow-functions-implicit-var-arguments-exec.test.js +'eval' and 'arguments' cannot be used as a binding identifier in strict mode + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-assumption-setPublicClassFields-static-infer-name-exec.test.js +AssertionError: expected '_Class' to be 'Foo' // Object.is equality + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-assumption-setPublicClassFields-static-infer-name-exec.test.js:8:19 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-assumption-setPublicClassFields-static-super-exec.test.js +Invalid access to super + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-nested-class-super-call-in-decorator-exec.test.js +AssertionError: expected undefined to be 'hello' // Object.is equality + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-nested-class-super-call-in-decorator-exec.test.js:21:28 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-nested-class-super-property-in-accessor-key-exec.test.js +Unexpected token `[`. Expected * for generator, private key, identifier or async + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-nested-class-super-property-in-decorator-exec.test.js +AssertionError: expected undefined to be 'hello' // Object.is equality + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-nested-class-super-property-in-decorator-exec.test.js:22:28 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-constructor-collision-exec.test.js +AssertionError: expected undefined to be 'bar' // Object.is equality + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-constructor-collision-exec.test.js:18:19 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-constructor-collision-exec.test.js +AssertionError: expected undefined to be 'bar' // Object.is equality + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-constructor-collision-exec.test.js:21:19 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-nested-class-computed-redeclared-exec.test.js +Private field '#foo' must be declared in an enclosing class + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-nested-class-extends-computed-exec.test.js +AssertionError: expected [Function] to not throw an error but 'TypeError: attempted to use private f…' was thrown + at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:1438:21) + at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:923:17) + at Proxy.methodWrapper (./node_modules/.pnpm/chai@5.1.2/node_modules/chai/chai.js:1610:25) + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-nested-class-extends-computed-exec.test.js:36:9 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-in-function-param-with-transform-exec.test.js +TypeError: Cannot convert undefined or null to object + at hasOwnProperty () + at _classPrivateFieldBase (./node_modules/.pnpm/@babel+runtime@7.26.0/node_modules/@babel/runtime/helpers/classPrivateFieldLooseBase.js:2:26) + at value (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-in-function-param-with-transform-exec.test.js:63:11) + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-in-function-param-with-transform-exec.test.js:44:198 + at j (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-in-function-param-with-transform-exec.test.js:45:6) + at Function.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-in-function-param-with-transform-exec.test.js:52:11) + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-in-function-param-with-transform-exec.test.js:71:6 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-member-optional-call-with-transform-exec.test.js +TypeError: Cannot convert undefined or null to object + at hasOwnProperty () + at _classPrivateFieldBase (./node_modules/.pnpm/@babel+runtime@7.26.0/node_modules/@babel/runtime/helpers/classPrivateFieldLooseBase.js:2:26) + at value (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-member-optional-call-with-transform-exec.test.js:123:11) + at Function.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-member-optional-call-with-transform-exec.test.js:24:134) + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-optional-chain-member-optional-call-with-transform-exec.test.js:131:6 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-parenthesized-optional-member-call-exec.test.js +TypeError: Cannot read properties of undefined (reading 'bind') + at Foo.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-parenthesized-optional-member-call-exec.test.js:20:59) + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-parenthesized-optional-member-call-exec.test.js:78:12 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-parenthesized-optional-member-call-with-transform-exec.test.js +TypeError: Cannot read properties of undefined (reading 'bind') + at Foo.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-parenthesized-optional-member-call-with-transform-exec.test.js:20:59) + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-loose-parenthesized-optional-member-call-with-transform-exec.test.js:78:12 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-nested-class-computed-redeclared-exec.test.js +Private field '#foo' must be declared in an enclosing class + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-nested-class-extends-computed-exec.test.js +AssertionError: expected [Function] to not throw an error but 'TypeError: Private element is not pre…' was thrown + at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:1438:21) + at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:923:17) + at Proxy.methodWrapper (./node_modules/.pnpm/chai@5.1.2/node_modules/chai/chai.js:1610:25) + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-nested-class-extends-computed-exec.test.js:31:9 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-static-shadow-exec.test.js +TypeError: e.has is not a function + at _assertClassBrand (./node_modules/.pnpm/@babel+runtime@7.26.0/node_modules/@babel/runtime/helpers/assertClassBrand.js:2:44) + at func (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-static-shadow-exec.test.js:10:12) + at Function.method (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-static-shadow-exec.test.js:12:11) + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-private-static-shadow-exec.test.js:16:14 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-computed-toPrimitive-exec.test.js +AssertionError: expected [Function] to throw error including '@@toPrimitive must return a primitive…' but got 'Cannot convert object to primitive va…' + at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:1438:21) + at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:923:17) + at Proxy.methodWrapper (./node_modules/.pnpm/chai@5.1.2/node_modules/chai/chai.js:1610:25) + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-computed-toPrimitive-exec.test.js:37:5 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-delete-super-property-exec.test.js +Invalid access to super + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-loose-static-infer-name-exec.test.js +AssertionError: expected '_Class' to be 'Foo' // Object.is equality + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-loose-static-infer-name-exec.test.js:8:19 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-loose-static-super-exec.test.js +Invalid access to super + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-static-infer-name-exec.test.js +AssertionError: expected '_Class' to be 'Foo' // Object.is equality + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-static-infer-name-exec.test.js:9:19 + +./fixtures/babel/babel-plugin-transform-class-properties-test-fixtures-public-static-super-exec.test.js +Invalid access to super + +./fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-assumption-noDocumentAll-parenthesized-expression-member-call-exec.test.js +TypeError: Cannot read properties of undefined (reading 'x') + at m (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-assumption-noDocumentAll-parenthesized-expression-member-call-exec.test.js:10:16) + at Foo.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-assumption-noDocumentAll-parenthesized-expression-member-call-exec.test.js:25:63) + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-assumption-noDocumentAll-parenthesized-expression-member-call-exec.test.js:68:12 + +./fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-exec.test.js +TypeError: Cannot read properties of undefined (reading 'x') + at m (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-exec.test.js:10:16) + at Foo.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-exec.test.js:25:63) + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-exec.test.js:68:12 + +./fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-loose-exec.test.js +TypeError: Cannot read properties of undefined (reading 'x') + at m (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-loose-exec.test.js:10:16) + at Foo.test (./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-loose-exec.test.js:25:63) + at ./tasks/transform_conformance/fixtures/babel/babel-plugin-transform-optional-chaining-test-fixtures-general-parenthesized-expression-member-call-loose-exec.test.js:68:12 + +./fixtures/babel/babel-preset-env-test-fixtures-plugins-integration-issue-15170-exec.test.js +AssertionError: expected [Function] to not throw an error but 'ReferenceError: x is not defined' was thrown + at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:1438:21) + at Proxy. (./node_modules/.pnpm/@vitest+expect@2.1.2/node_modules/@vitest/expect/dist/index.js:923:17) + at Proxy.methodWrapper (./node_modules/.pnpm/chai@5.1.2/node_modules/chai/chai.js:1610:25) + at ./tasks/transform_conformance/fixtures/babel/babel-preset-env-test-fixtures-plugins-integration-issue-15170-exec.test.js:6:9 + +./fixtures/babel/babel-preset-env-test-fixtures-sanity-check-es2015-constants-exec.test.js +TypeError: Assignment to constant variable. + at ./tasks/transform_conformance/fixtures/babel/babel-preset-env-test-fixtures-sanity-check-es2015-constants-exec.test.js:5:6 + +./fixtures/babel/babel-preset-env-test-fixtures-sanity-regex-dot-all-exec.test.js +AssertionError: expected false to be true // Object.is equality + at ./tasks/transform_conformance/fixtures/babel/babel-preset-env-test-fixtures-sanity-regex-dot-all-exec.test.js:10:37 diff --git a/tasks/transform_conformance/snapshots/oxc.snap.md b/tasks/transform_conformance/snapshots/oxc.snap.md index a738e9676aa5c..db09493de65d1 100644 --- a/tasks/transform_conformance/snapshots/oxc.snap.md +++ b/tasks/transform_conformance/snapshots/oxc.snap.md @@ -156,7 +156,12 @@ after transform: SymbolId(7) "Name" rebuilt : SymbolId(5) "Name" * exports/type-and-non-type/input.ts -x Output mismatch +Bindings mismatch: +after transform: ScopeId(0): ["ToastProps", "ToastViewport"] +rebuilt : ScopeId(0): ["ToastViewport"] +Scope children mismatch: +after transform: ScopeId(0): [ScopeId(1)] +rebuilt : ScopeId(0): [] * redeclarations/input.ts Scope children mismatch: diff --git a/tasks/transform_conformance/snapshots/oxc_exec.snap.md b/tasks/transform_conformance/snapshots/oxc_exec.snap.md index 1c3b4e2a74fc8..23e62427ba1c3 100644 --- a/tasks/transform_conformance/snapshots/oxc_exec.snap.md +++ b/tasks/transform_conformance/snapshots/oxc_exec.snap.md @@ -1,8 +1,5 @@ commit: 54a8389f node: v22.12.0 -filter: fixtures/oxc -include: **/*.{test,spec}.?(c|m)[jt]s?(x) -exclude: **/node_modules/**, **/dist/**, **/cypress/**, **/.{idea,git,cache,output,temp}/**, **/{karma,rollup,webpack,vite,vitest,jest,ava,babel,nyc,cypress,tsup,build,eslint,prettier}.config.*, "" -No test files found, exiting with code 1 +Passed: 3 of 3 (100.00%) From 7b92a06bb208814e67a6e6ac60ab50917e503531 Mon Sep 17 00:00:00 2001 From: Dunqing Date: Fri, 13 Dec 2024 11:45:41 +0800 Subject: [PATCH 11/11] update snapshot --- tasks/transform_conformance/snapshots/oxc.snap.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tasks/transform_conformance/snapshots/oxc.snap.md b/tasks/transform_conformance/snapshots/oxc.snap.md index 1158e5433f1bf..be452dd4654e3 100644 --- a/tasks/transform_conformance/snapshots/oxc.snap.md +++ b/tasks/transform_conformance/snapshots/oxc.snap.md @@ -1,6 +1,6 @@ commit: 54a8389f -Passed: 109/122 +Passed: 108/122 # All Passed: * babel-plugin-transform-class-static-block