Skip to content

Commit 3e475e6

Browse files
committed
#6905 Added test testing class into the current feature branch, to not lose it.
1 parent 16f3c3a commit 3e475e6

1 file changed

Lines changed: 29 additions & 0 deletions

File tree

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
import Neo from '../../../../src/Neo.mjs';
2+
import * as core from '../../../../src/core/_export.mjs';
3+
4+
StartTest(t => {
5+
t.it('should merge static configs from mixins', t => {
6+
class TestMixin extends core.Base {
7+
static config = {
8+
className : 'Neo.test.mixin.TestMixin',
9+
mixinConfig : 'mixinValue',
10+
reactiveMixinConfig_: 'reactiveValue'
11+
}
12+
}
13+
14+
Neo.setupClass(TestMixin);
15+
16+
class TestClass extends core.Base {
17+
static config = {
18+
className: 'Neo.test.mixin.TestClass',
19+
mixins : [TestMixin]
20+
}
21+
}
22+
23+
Neo.setupClass(TestClass);
24+
25+
// const instance = Neo.create(TestClass);
26+
// t.is(instance.mixinConfig, 'mixinValue', 'mixinConfig should be merged from the mixin');
27+
// t.is(instance.reactiveMixinConfig, 'reactiveValue', 'reactiveMixinConfig should be merged from the mixin and the underscore removed');
28+
});
29+
});

0 commit comments

Comments
 (0)