File tree 15 files changed +30
-20
lines changed
15 files changed +30
-20
lines changed Original file line number Diff line number Diff line change 4
4
< meta charset ='utf-8 '/>
5
5
6
6
<!-- npm modules -->
7
- < script src ='../../node_modules/chai/chai.js '> </ script >
8
7
< script src ='../../node_modules/mocha/mocha.js '> </ script >
9
8
10
9
<!-- initialize the test framework; this must come first -->
Original file line number Diff line number Diff line change 4
4
5
5
/**
6
6
* @fileoverview Test framework setup when run inside the browser.
7
+ * @suppress {moduleLoad} closure compiler can't handle node_modules/.
7
8
*/
8
9
10
+ import { assert } from '../../node_modules/chai/chai.js' ;
11
+
9
12
// Setup the mocha framework.
10
13
mocha . setup ( 'bdd' ) ;
11
14
mocha . checkLeaks ( ) ;
12
15
13
16
// Add a global shortcut to the assert API.
14
- globalThis [ 'assert' ] = chai . assert ;
17
+ globalThis [ 'assert' ] = assert ;
15
18
16
19
// Catch any random errors before the test runner runs.
17
20
let earlyError = null ;
Original file line number Diff line number Diff line change 29
29
},
30
30
"devDependencies" : {
31
31
"@rollup/plugin-node-resolve" : " ~15" ,
32
- "chai" : " ~4 " ,
32
+ "chai" : " ~5 " ,
33
33
"eslint" : " ~8" ,
34
34
"mocha" : " ~11" ,
35
35
"mocha-headless-chrome" : " ~4" ,
Original file line number Diff line number Diff line change @@ -16,7 +16,7 @@ import libdot
16
16
# The hash of the node_modules that we maintain.
17
17
# Allow a long line for easy automated updating.
18
18
NODE_MODULES_HASH = (
19
- "f54d402945ab7d7be9cc882249ace797e392b24abbbf3ea20feeb6b71d6c4ea8 "
19
+ "d384bf88a099d6b1f1140c8eefee178d1b6923fda2fe8d0a9f0055a44acd171f "
20
20
)
21
21
22
22
# In sync with Chromium's DEPS file because it's easier to use something that
Original file line number Diff line number Diff line change 4
4
< meta charset ='utf-8 '/>
5
5
6
6
<!-- npm modules -->
7
- < script src ='../../node_modules/chai/chai.js '> </ script >
8
7
< script src ='../../node_modules/mocha/mocha.js '> </ script >
9
8
10
9
<!-- initialize the test framework; this must come first -->
Original file line number Diff line number Diff line change 4
4
5
5
/**
6
6
* @fileoverview Test framework setup when run inside the browser.
7
+ * @suppress {moduleLoad} closure compiler can't handle node_modules/.
7
8
*/
8
9
10
+ import { assert } from '../../node_modules/chai/chai.js' ;
11
+
9
12
// Setup the mocha framework.
10
13
mocha . setup ( 'bdd' ) ;
11
14
mocha . checkLeaks ( ) ;
12
15
13
16
// Add a global shortcut to the assert API.
14
- globalThis [ 'assert' ] = chai . assert ;
17
+ globalThis [ 'assert' ] = assert ;
15
18
16
19
// Catch any random errors before the test runner runs.
17
20
let earlyError = null ;
Original file line number Diff line number Diff line change 26
26
"test" : " ./bin/load_tests"
27
27
},
28
28
"devDependencies" : {
29
- "chai" : " ~4 " ,
29
+ "chai" : " ~5 " ,
30
30
"eslint" : " ~8" ,
31
31
"mocha" : " ~11" ,
32
32
"mocha-headless-chrome" : " ~4" ,
Original file line number Diff line number Diff line change 4
4
< meta charset ='utf-8 '/>
5
5
6
6
<!-- npm modules -->
7
- < script src ='../../node_modules/chai/chai.js '> </ script >
8
7
< script src ='../../node_modules/mocha/mocha.js '> </ script >
9
8
10
9
<!-- initialize the test framework; this must come first -->
Original file line number Diff line number Diff line change 4
4
5
5
/**
6
6
* @fileoverview Test framework setup when run inside the browser.
7
+ * @suppress {moduleLoad} closure compiler can't handle node_modules/.
7
8
*/
8
9
10
+ import { assert } from '../../node_modules/chai/chai.js' ;
11
+
9
12
// Setup the mocha framework.
10
13
mocha . setup ( 'bdd' ) ;
11
14
mocha . checkLeaks ( ) ;
12
15
13
16
// Add a global shortcut to the assert API.
14
- globalThis [ 'assert' ] = chai . assert ;
17
+ globalThis [ 'assert' ] = assert ;
15
18
16
19
// Catch any random errors before the test runner runs.
17
20
let earlyError = null ;
Original file line number Diff line number Diff line change 31
31
"devDependencies" : {
32
32
"@rollup/plugin-node-resolve" : " ~15" ,
33
33
"@rollup/plugin-terser" : " ~0" ,
34
- "chai" : " ~4 " ,
34
+ "chai" : " ~5 " ,
35
35
"eslint" : " ~8" ,
36
36
"http-server" : " ~14" ,
37
37
"license-checker" : " ~25" ,
Original file line number Diff line number Diff line change 26
26
"@rollup/plugin-terser" : " ~0" ,
27
27
"@rollup/plugin-url" : " ~8" ,
28
28
"@rollup/plugin-yaml" : " ~4" ,
29
- "@types/chai" : " ~4 " ,
29
+ "@types/chai" : " ~5 " ,
30
30
"@types/chrome" : " ~0" ,
31
31
"@types/filesystem" : " ~0" ,
32
32
"@types/filewriter" : " ~0" ,
35
35
"@types/punycode" : " ~2" ,
36
36
"@types/trusted-types" : " ~2" ,
37
37
"asn1js" : " ~2" ,
38
- "chai" : " ~4 " ,
38
+ "chai" : " ~5 " ,
39
39
"csso" : " >=5" ,
40
40
"csso-cli" : " >=4" ,
41
41
"eslint" : " ~8" ,
Original file line number Diff line number Diff line change 6
6
< link rel ="icon " href ="../images/empty.svg " type ="image/svg+xml ">
7
7
8
8
<!-- npm modules -->
9
- < script src ='../../node_modules/chai/chai.js '> </ script >
10
9
< script src ='../../node_modules/mocha/mocha.js '> </ script >
11
10
12
11
<!-- Initialize the test framework first. -->
13
- < script src ='../js/terminal_test_preload.js '> </ script >
12
+ < script type =' module ' src ='../js/terminal_test_preload.js '> </ script >
14
13
< script type ='module ' src ='../js/terminal_test.js '> </ script >
15
14
16
15
<!-- All the unittests go below here. -->
Original file line number Diff line number Diff line change 4
4
5
5
/**
6
6
* @fileoverview Test framework setup when run inside the browser.
7
+ * @suppress {moduleLoad} closure compiler can't handle node_modules/.
7
8
*/
8
9
10
+ import { assert } from '../../node_modules/chai/chai.js' ;
11
+
9
12
// Add a global shortcut to the assert API.
10
- globalThis [ 'assert' ] = chai . assert ;
13
+ globalThis [ 'assert' ] = assert ;
Original file line number Diff line number Diff line change 4
4
< meta charset ='utf-8 '/>
5
5
6
6
<!-- npm modules -->
7
- < script src ='../../node_modules/chai/chai.js '> </ script >
8
7
< script src ='../../node_modules/mocha/mocha.js '> </ script >
9
8
10
9
<!-- Initialize the test framework; this must come first. -->
Original file line number Diff line number Diff line change 4
4
5
5
/**
6
6
* @fileoverview WASI main test runner.
7
+ * @suppress {moduleLoad} closure compiler can't handle node_modules/.
7
8
*/
8
9
10
+ import { assert , config } from '../../node_modules/chai/chai.js' ;
11
+
9
12
// Setup the mocha framework.
10
13
mocha . setup ( 'bdd' ) ;
11
14
mocha . checkLeaks ( ) ;
12
15
13
16
// Make failure output more useful.
14
- chai . config . includeStack = true ;
15
- chai . config . showDiff = true ;
16
- chai . config . truncateThreshold = 0 ;
17
+ config . includeStack = true ;
18
+ config . showDiff = true ;
19
+ config . truncateThreshold = 0 ;
17
20
18
21
// Add a global shortcut to the assert API.
19
- globalThis [ 'assert' ] = chai . assert ;
22
+ globalThis [ 'assert' ] = assert ;
20
23
21
24
// Catch any random errors before the test runner runs.
22
25
let earlyError = null ;
You can’t perform that action at this time.
0 commit comments