diff --git a/crates/oxc_isolated_declarations/tests/fixtures/export-default2.ts b/crates/oxc_isolated_declarations/tests/fixtures/export-default2.ts index 2195aa2b18cb7..60f275fd1fd23 100644 --- a/crates/oxc_isolated_declarations/tests/fixtures/export-default2.ts +++ b/crates/oxc_isolated_declarations/tests/fixtures/export-default2.ts @@ -1,6 +1,4 @@ -/** - * comment should be a leading comment of the arrow function - */ +/** comment should be a leading comment of the arrow function */ export default () => { - return 0; + return 0; }; diff --git a/crates/oxc_isolated_declarations/tests/fixtures/ts-export-assignment.ts b/crates/oxc_isolated_declarations/tests/fixtures/ts-export-assignment.ts index bc241cf7c8083..c91931032b367 100644 --- a/crates/oxc_isolated_declarations/tests/fixtures/ts-export-assignment.ts +++ b/crates/oxc_isolated_declarations/tests/fixtures/ts-export-assignment.ts @@ -1,8 +1,6 @@ const Res = 0; -/** - * comment should be a leading comment of the function Foo - */ +/** comment should be a leading comment of the function Foo */ export = function Foo(): typeof Res { - return Res; + return Res; }; diff --git a/crates/oxc_isolated_declarations/tests/mod.rs b/crates/oxc_isolated_declarations/tests/mod.rs index a3d88cc81b780..ca924ee87f0ee 100644 --- a/crates/oxc_isolated_declarations/tests/mod.rs +++ b/crates/oxc_isolated_declarations/tests/mod.rs @@ -3,7 +3,7 @@ mod deno; use std::{fmt::Write, fs, path::Path, sync::Arc}; use oxc_allocator::Allocator; -use oxc_codegen::CodeGenerator; +use oxc_codegen::Codegen; use oxc_isolated_declarations::{IsolatedDeclarations, IsolatedDeclarationsOptions}; use oxc_parser::Parser; use oxc_span::SourceType; @@ -16,7 +16,7 @@ fn transform(path: &Path, source_text: &str) -> String { let id_ret = IsolatedDeclarations::new(&allocator, IsolatedDeclarationsOptions { strip_internal: true }) .build(&parser_ret.program); - let code = CodeGenerator::new().build(&id_ret.program).code; + let code = Codegen::new().build(&id_ret.program).code; let mut snapshot = format!("```\n==================== .D.TS ====================\n\n{code}\n\n"); diff --git a/crates/oxc_isolated_declarations/tests/snapshots/export-default2.snap b/crates/oxc_isolated_declarations/tests/snapshots/export-default2.snap index 0dd8e975d9817..df89164f3c5ba 100644 --- a/crates/oxc_isolated_declarations/tests/snapshots/export-default2.snap +++ b/crates/oxc_isolated_declarations/tests/snapshots/export-default2.snap @@ -5,8 +5,6 @@ input_file: crates/oxc_isolated_declarations/tests/fixtures/export-default2.ts ``` ==================== .D.TS ==================== -/** -* comment should be a leading comment of the arrow function -*/ +/** comment should be a leading comment of the arrow function */ declare const _default: () => number; export default _default; diff --git a/crates/oxc_isolated_declarations/tests/snapshots/ts-export-assignment.snap b/crates/oxc_isolated_declarations/tests/snapshots/ts-export-assignment.snap index e358ebe3664df..948d5be9c4b69 100644 --- a/crates/oxc_isolated_declarations/tests/snapshots/ts-export-assignment.snap +++ b/crates/oxc_isolated_declarations/tests/snapshots/ts-export-assignment.snap @@ -6,8 +6,6 @@ input_file: crates/oxc_isolated_declarations/tests/fixtures/ts-export-assignment ==================== .D.TS ==================== declare const Res = 0; -/** -* comment should be a leading comment of the function Foo -*/ +/** comment should be a leading comment of the function Foo */ declare const _default: () => typeof Res; export = _default;