mol_wire_lib 1.0.198 → 1.0.201

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
@@ -2335,7 +2335,7 @@ var $;
2335
2335
  return $mol_jsx("button", { title: props.hint }, target());
2336
2336
  };
2337
2337
  const dom = $mol_jsx(Button, { id: "foo", hint: "click me" }, () => 'hey!');
2338
- $mol_assert_equal(dom.outerHTML, '<button title="click me" id="foo" class="Button">hey!</button>');
2338
+ $mol_assert_equal(dom.outerHTML, '<button id="foo" title="click me" class="Button">hey!</button>');
2339
2339
  },
2340
2340
  'Nested guid generation'() {
2341
2341
  const Foo = () => {
@@ -3684,6 +3684,33 @@ var $;
3684
3684
  $mol_assert_equal(Fib.value(4), 8);
3685
3685
  $mol_assert_equal(Fib.sums, 6);
3686
3686
  },
3687
+ 'Unsubscribe from temp pubs on complete'($) {
3688
+ class Random extends $mol_object2 {
3689
+ static $ = $;
3690
+ static seed() {
3691
+ return Math.random();
3692
+ }
3693
+ static resets(next) {
3694
+ return Math.random();
3695
+ }
3696
+ static value() {
3697
+ this.resets();
3698
+ return this.seed();
3699
+ }
3700
+ }
3701
+ __decorate([
3702
+ $mol_wire_method
3703
+ ], Random, "seed", null);
3704
+ __decorate([
3705
+ $mol_wire_mem(0)
3706
+ ], Random, "resets", null);
3707
+ __decorate([
3708
+ $mol_wire_mem(0)
3709
+ ], Random, "value", null);
3710
+ const first = Random.value();
3711
+ Random.resets(null);
3712
+ $mol_assert_unique(Random.value(), first);
3713
+ },
3687
3714
  });
3688
3715
  })($ || ($ = {}));
3689
3716
  //mol/wire/mem/mem.test.ts