repositories
/
e-mobility-charging-stations-simulator.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3fad0de
)
test: improve clone() test expectation
author
Jérôme Benoit
<jerome.benoit@sap.com>
Tue, 13 Feb 2024 23:54:12 +0000
(
00:54
+0100)
committer
Jérôme Benoit
<jerome.benoit@sap.com>
Tue, 13 Feb 2024 23:54:12 +0000
(
00:54
+0100)
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
tests/utils/Utils.test.ts
patch
|
blob
|
blame
|
history
diff --git
a/tests/utils/Utils.test.ts
b/tests/utils/Utils.test.ts
index 3b2a52ae88d8b33911033f607155d0c3a89daaf3..3622d8aec45cb0e80ad81381bf46af96b30b6362 100644
(file)
--- a/
tests/utils/Utils.test.ts
+++ b/
tests/utils/Utils.test.ts
@@
-346,8
+346,10
@@
await describe('Utils test suite', async () => {
expect(clone(url)).toStrictEqual({})
const map = new Map([['1', '2']])
expect(clone(map)).toStrictEqual(map)
+ expect(clone(map) === map).toBe(false)
const set = new Set(['1'])
expect(clone(set)).toStrictEqual(set)
+ expect(clone(set) === set).toBe(false)
const weakMap = new WeakMap([[{ 1: 1 }, { 2: 2 }]])
expect(() => clone(weakMap)).toThrow(new Error('#<WeakMap> could not be cloned.'))
const weakSet = new WeakSet([{ 1: 1 }, { 2: 2 }])