Function
countItemsNegativeZero
(aLength: number, bLength: number)
Source from the content-addressed store, hash-verified
| 278 | |
| 279 | describe('negative zero is equivalent to zero for length', () => { |
| 280 | const countItemsNegativeZero = (aLength: number, bLength: number) => { |
| 281 | let n = 0; |
| 282 | diff( |
| 283 | aLength, |
| 284 | bLength, |
| 285 | () => { |
| 286 | throw new Error('input function should not have been called'); |
| 287 | }, |
| 288 | nCommon => { |
| 289 | n += nCommon; |
| 290 | }, |
| 291 | ); |
| 292 | return n; |
| 293 | }; |
| 294 | |
| 295 | test('of a', () => { |
| 296 | expect(countItemsNegativeZero(-0, 1)).toBe(0); |
Tested by
no test coverage detected