mol_compare_deep 0.0.1418 → 0.0.1420

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.test.js CHANGED
@@ -930,7 +930,7 @@ var $;
930
930
  if (this[$mol_ambient_ref])
931
931
  return this[$mol_ambient_ref];
932
932
  const owner = $mol_owning_get(this);
933
- return this[$mol_ambient_ref] = owner?.$ || $mol_object2.$;
933
+ return this[$mol_ambient_ref] = owner?.$ || this.constructor.$ || $mol_object2.$;
934
934
  }
935
935
  set $(next) {
936
936
  if (this[$mol_ambient_ref])
@@ -1894,7 +1894,7 @@ var $;
1894
1894
  ;
1895
1895
  "use strict";
1896
1896
  var $;
1897
- (function ($) {
1897
+ (function ($_1) {
1898
1898
  $mol_test({
1899
1899
  'init with overload'() {
1900
1900
  class X extends $mol_object {
@@ -1907,6 +1907,13 @@ var $;
1907
1907
  });
1908
1908
  $mol_assert_equal(x.foo(), 2);
1909
1909
  },
1910
+ 'Context in instance inherits from class'($) {
1911
+ const custom = $.$mol_ambient({});
1912
+ class X extends $.$mol_object {
1913
+ static $ = custom;
1914
+ }
1915
+ $mol_assert_equal(new X().$, custom);
1916
+ },
1910
1917
  });
1911
1918
  })($ || ($ = {}));
1912
1919