mol_plot_all 1.2.1138 → 1.2.1140
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/node.d.ts +90 -90
- package/node.deps.json +1 -1
- package/node.js +2 -1
- package/node.js.map +1 -1
- package/node.mjs +2 -1
- package/node.test.js +16 -1
- package/node.test.js.map +1 -1
- package/package.json +1 -1
- package/web.d.ts +90 -90
- package/web.deps.json +1 -1
- package/web.js +2 -1
- package/web.js.map +1 -1
- package/web.mjs +2 -1
- package/web.test.js +14 -0
- package/web.test.js.map +1 -1
package/node.mjs
CHANGED
|
@@ -984,9 +984,10 @@ var $;
|
|
|
984
984
|
return right_cache;
|
|
985
985
|
}
|
|
986
986
|
else {
|
|
987
|
-
left_cache = new WeakMap(
|
|
987
|
+
left_cache = new WeakMap();
|
|
988
988
|
$.$mol_compare_deep_cache.set(left, left_cache);
|
|
989
989
|
}
|
|
990
|
+
left_cache.set(right, true);
|
|
990
991
|
let result;
|
|
991
992
|
try {
|
|
992
993
|
if (!left_proto)
|
package/node.test.js
CHANGED
|
@@ -975,9 +975,10 @@ var $;
|
|
|
975
975
|
return right_cache;
|
|
976
976
|
}
|
|
977
977
|
else {
|
|
978
|
-
left_cache = new WeakMap(
|
|
978
|
+
left_cache = new WeakMap();
|
|
979
979
|
$.$mol_compare_deep_cache.set(left, left_cache);
|
|
980
980
|
}
|
|
981
|
+
left_cache.set(right, true);
|
|
981
982
|
let result;
|
|
982
983
|
try {
|
|
983
984
|
if (!left_proto)
|
|
@@ -6732,6 +6733,20 @@ var $;
|
|
|
6732
6733
|
b['self'] = b;
|
|
6733
6734
|
$mol_assert_ok($mol_compare_deep(a, b));
|
|
6734
6735
|
},
|
|
6736
|
+
'same POJOs with cyclic reference with cache warmup'() {
|
|
6737
|
+
const obj1 = { test: 1, obj3: null };
|
|
6738
|
+
const obj1_copy = { test: 1, obj3: null };
|
|
6739
|
+
const obj2 = { test: 2, obj1 };
|
|
6740
|
+
const obj2_copy = { test: 2, obj1: obj1_copy };
|
|
6741
|
+
const obj3 = { test: 3, obj2 };
|
|
6742
|
+
const obj3_copy = { test: 3, obj2: obj2_copy };
|
|
6743
|
+
obj1.obj3 = obj3;
|
|
6744
|
+
obj1_copy.obj3 = obj3_copy;
|
|
6745
|
+
$mol_assert_not($mol_compare_deep(obj1, {}));
|
|
6746
|
+
$mol_assert_not($mol_compare_deep(obj2, {}));
|
|
6747
|
+
$mol_assert_not($mol_compare_deep(obj3, {}));
|
|
6748
|
+
$mol_assert_ok($mol_compare_deep(obj3, obj3_copy));
|
|
6749
|
+
},
|
|
6735
6750
|
'Date'() {
|
|
6736
6751
|
$mol_assert_ok($mol_compare_deep(new Date(12345), new Date(12345)));
|
|
6737
6752
|
$mol_assert_not($mol_compare_deep(new Date(12345), new Date(12346)));
|