Skip to content

Commit

Permalink
Don't bother with jsxdev tests because they put the filename in and b…
Browse files Browse the repository at this point in the history
…reak snapshots on other computers
  • Loading branch information
dsherret committed Feb 8, 2024
1 parent 89a080a commit 32cd164
Show file tree
Hide file tree
Showing 8 changed files with 6 additions and 57 deletions.
3 changes: 0 additions & 3 deletions tests/__snapshots__/jsx/jsx_type_reactjsxdev/deno.json

This file was deleted.

This file was deleted.

3 changes: 0 additions & 3 deletions tests/__snapshots__/jsx/jsx_type_reactjsxdev/modules.json

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

25 changes: 0 additions & 25 deletions tests/jsx_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,28 +71,3 @@ Deno.test({
},
),
});

Deno.test({
name: "jsx type react-jsxdev",
fn: testTranspile(
resolveFixture("jsx/main.tsx"),
{
compilerOptions: {
jsx: "react-jsxdev",
},
},
),
});

Deno.test({
name: "jsx type react-jsxdev with custom import source",
fn: testTranspile(
resolveFixture("jsx/main.tsx"),
{
compilerOptions: {
jsx: "react-jsxdev",
jsxImportSource: "example",
},
},
),
});
10 changes: 6 additions & 4 deletions wasm/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -64,20 +64,22 @@ impl From<CompilerOptions> for EmitOptions {
Self {
use_decorators_proposal: !options.experimental_decorators,
use_ts_decorators: options.experimental_decorators,
precompile_jsx: false,
emit_metadata: options.emit_decorator_metadata,
imports_not_used_as_values,
inline_source_map: options.inline_source_map,
inline_sources: options.inline_sources,
jsx_factory: options.jsx_factory,
jsx_fragment_factory: options.jsx_fragment_factory,
transform_jsx: options.jsx == "react" || options.jsx == "react-jsx" || options.jsx == "react-jsxdev",
transform_jsx: options.jsx == "react"
|| options.jsx == "react-jsx"
|| options.jsx == "react-jsxdev",
var_decl_imports: false,
source_map: options.source_map,
jsx_automatic: options.jsx == "react-jsx" || options.jsx == "react-jsxdev",
jsx_automatic: options.jsx == "react-jsx"
|| options.jsx == "react-jsxdev",
jsx_development: options.jsx == "react-jsxdev",
jsx_import_source: options.jsx_import_source,
precompile_jsx: false
precompile_jsx: false,
}
}
}
Expand Down

0 comments on commit 32cd164

Please sign in to comment.