Skip to content

Commit 8b6f50f

Browse files
author
Vlad Balin
committed
test for 27756
1 parent 00a40dd commit 8b6f50f

File tree

5 files changed

+29
-5
lines changed

5 files changed

+29
-5
lines changed

tests/typescript/dist/index.js

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15988,6 +15988,10 @@ describe('Bugs from Volicon Observer', function () {
1598815988
attr(String.has.watcher(function (x) { return calls.push('inherited'); })),
1598915989
__metadata("design:type", String)
1599015990
], Base.prototype, "inherited", void 0);
15991+
__decorate([
15992+
attr(String.has.watcher('onNamedWatcher')),
15993+
__metadata("design:type", String)
15994+
], Base.prototype, "namedWatcher", void 0);
1599115995
__decorate([
1599215996
attr(String.has.watcher(function (x) { return calls.push('base'); })),
1599315997
__metadata("design:type", String)
@@ -16002,6 +16006,9 @@ describe('Bugs from Volicon Observer', function () {
1600216006
function Subclass() {
1600316007
return _super !== null && _super.apply(this, arguments) || this;
1600416008
}
16009+
Subclass.prototype.onNamedWatcher = function () {
16010+
calls.push('named');
16011+
};
1600516012
__decorate([
1600616013
attr(String.has.watcher(function (x) { return calls.push('added'); })),
1600716014
__metadata("design:type", String)
@@ -16019,7 +16026,8 @@ describe('Bugs from Volicon Observer', function () {
1601916026
subclass.inherited = "a";
1602016027
subclass.added = "b";
1602116028
subclass.overriden = "b";
16022-
chai_1(calls).to.eql(['inherited', 'added', 'subclass', 'base']);
16029+
subclass.namedWatcher = "t";
16030+
chai_1(calls).to.eql(['inherited', 'added', 'subclass', 'base', 'named']);
1602316031
});
1602416032
});
1602516033
describe('Validation', function () {

tests/typescript/dist/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/typescript/lib/reported-bugs.js

Lines changed: 9 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/typescript/lib/reported-bugs.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/typescript/src/reported-bugs.ts

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@ describe( 'Bugs from Volicon Observer', () =>{
1212
@attr( String.has.watcher( x => calls.push( 'inherited' ) ) )
1313
inherited : string;
1414

15+
@attr( String.has.watcher( 'onNamedWatcher' ) )
16+
namedWatcher : string;
17+
1518
@attr( String.has.watcher( x => calls.push( 'base' ) ) )
1619
overriden : string;
1720
}
@@ -22,14 +25,19 @@ describe( 'Bugs from Volicon Observer', () =>{
2225

2326
@attr( String.has.watcher( x => calls.push( 'subclass') ) )
2427
overriden : string;
28+
29+
onNamedWatcher(){
30+
calls.push( 'named' );
31+
}
2532
}
2633

2734
const subclass = new Subclass();
2835
subclass.inherited = "a";
2936
subclass.added = "b";
3037
subclass.overriden = "b";
38+
subclass.namedWatcher = "t";
3139

32-
expect( calls ).to.eql( [ 'inherited', 'added', 'subclass', 'base' ] );
40+
expect( calls ).to.eql( [ 'inherited', 'added', 'subclass', 'base', 'named' ] );
3341
} );
3442

3543
} );

0 commit comments

Comments
 (0)