blob: cf31fe4270c78184819ab728d305d3f99d203b19 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
"use strict";
const assert = require( "node:assert" );
const { ensureGlobalNotCreated } = require( "./lib/ensure_global_not_created.cjs" );
const { getJQueryModuleSpecifier } = require( "./lib/jquery-module-specifier.cjs" );
const jQueryModuleSpecifier = getJQueryModuleSpecifier();
const jQueryFactory = require( jQueryModuleSpecifier );
assert.throws( () => {
jQueryFactory( {} );
}, /jQuery requires a window with a document/ );
ensureGlobalNotCreated( module.exports );
|