mirror of
https://github.com/jquery/jquery.git
synced 2024-11-23 02:54:22 +00:00
14 lines
454 B
JavaScript
14 lines
454 B
JavaScript
|
import assert from "node:assert/strict";
|
||
|
import { JSDOM } from "jsdom";
|
||
|
|
||
|
const { window } = new JSDOM( "" );
|
||
|
|
||
|
// Set the window global.
|
||
|
globalThis.window = window;
|
||
|
|
||
|
const { $: $imported } = await import( process.argv[ 2 ] );
|
||
|
const { $: $required } = await import( "../lib/jquery-require.cjs" );
|
||
|
|
||
|
assert( $imported === $required, "More than one copy of jQuery exists" );
|
||
|
assert( /^jQuery/.test( $imported.expando ), "jQuery.expando should be detected" );
|