Skip to content
This repository was archived by the owner on Feb 22, 2018. It is now read-only.

Commit 5becb45

Browse files
committed
tests(interface_typing): Added a test for mixins and mirrors
1 parent 834f201 commit 5becb45

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

test/interface_typing_spec.dart

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,12 @@ class ClassWithDifferentMethods {
3333
method({c, d}) {}
3434
}
3535

36+
class Mixin {
37+
bool mixed = true;
38+
}
39+
class ClassWithMixin extends ClassWithFields with Mixin {
40+
}
41+
3642
main() {
3743
describe('Interface Typing', () {
3844
it('should recognize built-in objects as an object', () {
@@ -59,5 +65,11 @@ main() {
5965
expect(isInterface(new ClassWithMethods(), InterfaceWithMethods)).toBeTruthy();
6066
expect(isInterface(new ClassWithDifferentMethods(), InterfaceWithMethods)).toBeFalsy();
6167
});
68+
69+
// waiting on dartbug 9434
70+
xit('should match mix ins', () {
71+
expect(isInterface(new ClassWithMixin(), ClassWithFields)).toBeTruthy();
72+
expect(isInterface(new ClassWithMixin(), Mixin)).toBeTruthy();
73+
});
6274
});
6375
}

0 commit comments

Comments
 (0)