Commit 99b9e0b 1 parent 8335731 commit 99b9e0b Copy full SHA for 99b9e0b
File tree 1 file changed +5
-7
lines changed
1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change 1
- import fs from 'fs' ;
2
- import path from 'path' ;
1
+ import fs from 'node:fs' ;
2
+ import path from 'node:path' ;
3
+ import { Script } from 'node:vm' ;
3
4
4
5
import { Suite , Event } from 'benchmark' ;
5
6
import { JSDOM } from 'jsdom' ;
6
- import { Script } from 'vm' ;
7
7
import cheerio from '../lib/index.js' ;
8
8
9
9
const documentDir = path . join ( __dirname , 'documents' ) ;
@@ -73,11 +73,9 @@ export default class Suites {
73
73
74
74
jQueryScript . runInContext ( dom . getInternalVMContext ( ) ) ;
75
75
76
- const setupData : T = options . setup ( dom . window . $ ) ;
76
+ const setupData : T = options . setup ( dom . window [ '$' ] ) ;
77
77
78
- suite . add ( 'jsdom' , ( ) => {
79
- testFn ( dom . window . $ , setupData ) ;
80
- } ) ;
78
+ suite . add ( 'jsdom' , ( ) => testFn ( dom . window [ '$' ] , setupData ) ) ;
81
79
suite . run ( ) ;
82
80
}
83
81
You can’t perform that action at this time.
0 commit comments