• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

rokucommunity / brighterscript / #15048

01 Jan 2026 11:17PM UTC coverage: 87.048% (-0.9%) from 87.907%
#15048

push

web-flow
Merge 02ba2bb57 into 2ea4d2108

14498 of 17595 branches covered (82.4%)

Branch coverage included in aggregate %.

192 of 261 new or added lines in 12 files covered. (73.56%)

897 existing lines in 48 files now uncovered.

15248 of 16577 relevant lines covered (91.98%)

24112.76 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

91.89
/src/types/InterfaceType.ts
1
import type { TypeCompatibilityData } from '../interfaces';
2
import { SymbolTypeFlag } from '../SymbolTypeFlag';
1✔
3
import { isCallFuncableType, isDynamicType, isInterfaceType, isInvalidType, isObjectType } from '../astUtils/reflection';
1✔
4
import type { BscType } from './BscType';
5
import { BscTypeKind } from './BscTypeKind';
1✔
6
import { isUnionTypeCompatible } from './helpers';
1✔
7
import type { ReferenceType } from './ReferenceType';
8
import { CallFuncableType } from './CallFuncableType';
1✔
9

10
export class InterfaceType extends CallFuncableType {
1✔
11
    public constructor(
12
        public name: string,
363,424✔
13
        public readonly superInterface?: InterfaceType | ReferenceType
363,424✔
14
    ) {
15
        super(name, superInterface);
363,424✔
16
    }
17

18
    public readonly kind = BscTypeKind.InterfaceType;
363,424✔
19

20
    public isTypeCompatible(targetType: BscType, data?: TypeCompatibilityData) {
21
        if (isInvalidType(targetType) ||
106✔
22
            isDynamicType(targetType) ||
23
            isObjectType(targetType) ||
24
            isUnionTypeCompatible(this, targetType, data)) {
25
            return true;
6✔
26
        }
27
        if (isCallFuncableType(targetType)) {
100✔
28
            return this.checkCompatibilityBasedOnMembers(targetType, SymbolTypeFlag.runtime, data) &&
49✔
29
                this.checkCompatibilityBasedOnMembers(targetType, SymbolTypeFlag.runtime, data, this.callFuncMemberTable, targetType.callFuncMemberTable);
30
        }
31

32
        const ancestorTypes = this.getAncestorTypeList();
51✔
33
        if (ancestorTypes?.find(ancestorType => ancestorType.isEqual(targetType))) {
51!
UNCOV
34
            return true;
×
35
        }
36
        return this.checkCompatibilityBasedOnMembers(targetType, SymbolTypeFlag.runtime, data);
51✔
37
    }
38

39
    /**
40
     *  Is this the exact same interface as the target?
41
     */
42
    isEqual(targetType: BscType, data?: TypeCompatibilityData): boolean {
43
        return isInterfaceType(targetType) && super.isEqual(targetType, data);
118✔
44
    }
45
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc