@@ -40,6 +40,12 @@ exports[`not throwing Error objects 4`] = `
4040 expect(received).toBeTruthy()
4141 Expected value to be truthy, instead received
4242 false
43+ 11 | const throws = () => {
44+ 12 | expect .assertions (2 );
45+ > 13 | expect (false ).toBeTruthy ();
46+ 14 | } ;
47+ 15 | const redeclare = () => {
48+ 16 | expect .assertions (1 );
4349 at __tests__ / assertion_count .test .js :13 :17
4450 ● .assertions () › throws
4551 expect .assertions (2 )
@@ -48,6 +54,12 @@ exports[`not throwing Error objects 4`] = `
4854 expect (received ).toBeTruthy ()
4955 Expected value to be truthy , instead received
5056 false
57+ 15 | const redeclare = () => {
58+ 16 | expect .assertions (1 );
59+ > 17 | expect (false ).toBeTruthy ();
60+ 18 | expect .assertions (2 );
61+ 19 | };
62+ 20 |
5163 at __tests__ / assertion_count .test .js :17 :17
5264 ● .assertions () › throws on assertion
5365 expect .assertions (0 )
@@ -85,6 +97,13 @@ exports[`works with node assert 1`] = `
8597 true
8698 Received:
8799 false
100+
101+ 13 |
102+ 14 | test('assert', () => {
103+ > 15 | assert (false );
104+ 16 | } );
105+ 17 |
106+ 18 | test('assert with a message', () => {
88107
89108 at __tests__ / node_assertion_error .test .js :15 :3
90109
@@ -99,6 +118,13 @@ exports[`works with node assert 1`] = `
99118
100119 Message :
101120 this is a message
121+
122+ 17 |
123+ 18 | test (' assert with a message' , () => {
124+ > 19 | assert (false , ' this is a message' );
125+ 20 | });
126+ 21 |
127+ 22 | test (' assert.ok' , () => {
102128
103129 at __tests__ / node_assertion_error .test .js :19 :3
104130
@@ -110,6 +136,13 @@ exports[`works with node assert 1`] = `
110136 true
111137 Received :
112138 false
139+
140+ 21 |
141+ 22 | test (' assert.ok' , () => {
142+ > 23 | assert .ok (false );
143+ 24 | });
144+ 25 |
145+ 26 | test (' assert.ok with a message' , () => {
113146
114147 at __tests__ / node_assertion_error .test .js :23 :10
115148
@@ -124,6 +157,13 @@ exports[`works with node assert 1`] = `
124157
125158 Message :
126159 this is a message
160+
161+ 25 |
162+ 26 | test (' assert.ok with a message' , () => {
163+ > 27 | assert .ok (false , ' this is a message' );
164+ 28 | });
165+ 29 |
166+ 30 | test (' assert.equal' , () => {
127167
128168 at __tests__ / node_assertion_error .test .js :27 :10
129169
@@ -135,6 +175,13 @@ exports[`works with node assert 1`] = `
135175 2
136176 Received :
137177 1
178+
179+ 29 |
180+ 30 | test (' assert.equal' , () => {
181+ > 31 | assert .equal (1 , 2 );
182+ 32 | });
183+ 33 |
184+ 34 | test (' assert.notEqual' , () => {
138185
139186 at __tests__ / node_assertion_error .test .js :31 :10
140187
@@ -150,6 +197,13 @@ exports[`works with node assert 1`] = `
150197 Difference :
151198
152199 Compared values have no visual difference .
200+
201+ 33 |
202+ 34 | test (' assert.notEqual' , () => {
203+ > 35 | assert .notEqual (1 , 1 );
204+ 36 | });
205+ 37 |
206+ 38 | test (' assert.deepEqual' , () => {
153207
154208 at __tests__ / node_assertion_error .test .js :35 :10
155209
@@ -175,6 +229,13 @@ exports[`works with node assert 1`] = `
175229 },
176230 },
177231 }
232+
233+ 37 |
234+ 38 | test (' assert.deepEqual' , () => {
235+ > 39 | assert .deepEqual ({a: {b: {c: 5 }}}, {a: {b: {c: 6 }}});
236+ 40 | });
237+ 41 |
238+ 42 | test (' assert.deepEqual with a message' , () => {
178239
179240 at __tests__ / node_assertion_error .test .js :39 :10
180241
@@ -203,6 +264,13 @@ exports[`works with node assert 1`] = `
203264 },
204265 },
205266 }
267+
268+ 41 |
269+ 42 | test (' assert.deepEqual with a message' , () => {
270+ > 43 | assert .deepEqual ({a: {b: {c: 5 }}}, {a: {b: {c: 7 }}}, ' this is a message' );
271+ 44 | });
272+ 45 |
273+ 46 | test (' assert.notDeepEqual' , () => {
206274
207275 at __tests__ / node_assertion_error .test .js :43 :10
208276
@@ -218,6 +286,13 @@ exports[`works with node assert 1`] = `
218286 Difference :
219287
220288 Compared values have no visual difference .
289+
290+ 45 |
291+ 46 | test (' assert.notDeepEqual' , () => {
292+ > 47 | assert .notDeepEqual ({a: 1 }, {a: 1 });
293+ 48 | });
294+ 49 |
295+ 50 | test (' assert.strictEqual' , () => {
221296
222297 at __tests__ / node_assertion_error .test .js :47 :10
223298
@@ -229,6 +304,13 @@ exports[`works with node assert 1`] = `
229304 NaN
230305 Received :
231306 1
307+
308+ 49 |
309+ 50 | test (' assert.strictEqual' , () => {
310+ > 51 | assert .strictEqual (1 , NaN );
311+ 52 | });
312+ 53 |
313+ 54 | test (' assert.notStrictEqual' , () => {
232314
233315 at __tests__ / node_assertion_error .test .js :51 :10
234316
@@ -247,6 +329,13 @@ exports[`works with node assert 1`] = `
247329 Difference :
248330
249331 Compared values have no visual difference .
332+
333+ 53 |
334+ 54 | test (' assert.notStrictEqual' , () => {
335+ > 55 | assert .notStrictEqual (1 , 1 , ' My custom error message' );
336+ 56 | });
337+ 57 |
338+ 58 | test (' assert.deepStrictEqual' , () => {
250339
251340 at __tests__ / node_assertion_error .test .js :55 :10
252341
@@ -268,6 +357,13 @@ exports[`works with node assert 1`] = `
268357 - \\" a\\ " : 2 ,
269358 + \\" a\\ " : 1 ,
270359 }
360+
361+ 57 |
362+ 58 | test (' assert.deepStrictEqual' , () => {
363+ > 59 | assert .deepStrictEqual ({a: 1 }, {a: 2 });
364+ 60 | });
365+ 61 |
366+ 62 | test (' assert.notDeepStrictEqual' , () => {
271367
272368 at __tests__ / node_assertion_error .test .js :59 :10
273369
@@ -283,6 +379,13 @@ exports[`works with node assert 1`] = `
283379 Difference :
284380
285381 Compared values have no visual difference .
382+
383+ 61 |
384+ 62 | test (' assert.notDeepStrictEqual' , () => {
385+ > 63 | assert .notDeepStrictEqual ({a: 1 }, {a: 1 });
386+ 64 | });
387+ 65 |
388+ 66 | test (' assert.ifError' , () => {
286389
287390 at __tests__ / node_assertion_error .test .js :63 :10
288391
@@ -301,6 +404,13 @@ exports[`works with node assert 1`] = `
301404
302405 Message:
303406 Got unwanted exception.
407+
408+ 69 |
409+ 70 | test('assert .doesNotThrow ', () => {
410+ > 71 | assert .doesNotThrow (() => {
411+ 72 | throw Error (' err!' );
412+ 73 | });
413+ 74 | });
304414
305415 at __tests__ / node_assertion_error .test .js :71 :10
306416
@@ -313,6 +423,12 @@ exports[`works with node assert 1`] = `
313423
314424 Message:
315425 Missing expected exception.
426+
427+ 75 |
428+ 76 | test('assert .throws ', () => {
429+ > 77 | assert .throws (() => {});
430+ 78 | });
431+ 79 |
316432
317433 at __tests__ / node_assertion_error .test .js :77 :10
318434
0 commit comments