mol_wire_lib 1.0.418 → 1.0.419
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 +11 -12
- package/node.test.js.map +1 -1
- package/package.json +1 -1
- package/web.test.js +11 -12
- package/web.test.js.map +1 -1
package/package.json
CHANGED
package/web.test.js
CHANGED
|
@@ -1092,21 +1092,17 @@ var $;
|
|
|
1092
1092
|
'Flow: Auto'($) {
|
|
1093
1093
|
class App extends $mol_object2 {
|
|
1094
1094
|
static get $() { return $; }
|
|
1095
|
-
static
|
|
1096
|
-
static second(next = 2) { return next; }
|
|
1095
|
+
static source(next = 1) { return next; }
|
|
1097
1096
|
static condition(next = true) { return next; }
|
|
1098
1097
|
static counter = 0;
|
|
1099
1098
|
static result() {
|
|
1100
|
-
const res = this.condition() ? this.
|
|
1099
|
+
const res = this.condition() ? this.source() : 0;
|
|
1101
1100
|
return res + this.counter++;
|
|
1102
1101
|
}
|
|
1103
1102
|
}
|
|
1104
1103
|
__decorate([
|
|
1105
1104
|
$mol_wire_solo
|
|
1106
|
-
], App, "
|
|
1107
|
-
__decorate([
|
|
1108
|
-
$mol_wire_solo
|
|
1109
|
-
], App, "second", null);
|
|
1105
|
+
], App, "source", null);
|
|
1110
1106
|
__decorate([
|
|
1111
1107
|
$mol_wire_solo
|
|
1112
1108
|
], App, "condition", null);
|
|
@@ -1115,17 +1111,20 @@ var $;
|
|
|
1115
1111
|
], App, "result", null);
|
|
1116
1112
|
$mol_assert_equal(App.result(), 1);
|
|
1117
1113
|
$mol_assert_equal(App.counter, 1);
|
|
1118
|
-
App.
|
|
1114
|
+
App.source(10);
|
|
1119
1115
|
$mol_assert_equal(App.result(), 11);
|
|
1120
1116
|
$mol_assert_equal(App.counter, 2);
|
|
1121
1117
|
App.condition(false);
|
|
1122
|
-
$mol_assert_equal(App.result(),
|
|
1118
|
+
$mol_assert_equal(App.result(), 2);
|
|
1123
1119
|
$mol_assert_equal(App.counter, 3);
|
|
1124
1120
|
$mol_wire_fiber.sync();
|
|
1125
|
-
$mol_assert_equal(App.
|
|
1126
|
-
App.
|
|
1127
|
-
$mol_assert_equal(App.result(),
|
|
1121
|
+
$mol_assert_equal(App.source(), 1);
|
|
1122
|
+
App.source(20);
|
|
1123
|
+
$mol_assert_equal(App.result(), 2);
|
|
1128
1124
|
$mol_assert_equal(App.counter, 3);
|
|
1125
|
+
App.condition(true);
|
|
1126
|
+
$mol_assert_equal(App.result(), 23);
|
|
1127
|
+
$mol_assert_equal(App.counter, 4);
|
|
1129
1128
|
},
|
|
1130
1129
|
'Dupes: Equality'($) {
|
|
1131
1130
|
let counter = 0;
|