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

snatalenko / node-cqrs / 16896487626

12 Aug 2025 01:28AM UTC coverage: 94.396% (-0.8%) from 95.151%
16896487626

push

github

snatalenko
0.17.0

563 of 876 branches covered (64.27%)

2375 of 2516 relevant lines covered (94.4%)

22.31 hits per line

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

85.0
/src/utils/getHandledMessageTypes.ts
1
import { getMessageHandlerNames } from './getMessageHandlerNames';
4✔
2

4✔
3
/**
4✔
4
 * Get a list of message types handled by observer
4✔
5
 */
4✔
6
export function getHandledMessageTypes(
16✔
7
        observerInstanceOrClass: (object | Function) & { handles?: string[] }
16✔
8
): string[] {
16✔
9
        if (!observerInstanceOrClass)
16✔
10
                throw new TypeError('observerInstanceOrClass argument required');
16!
11

16✔
12
        if (observerInstanceOrClass.handles)
16✔
13
                return observerInstanceOrClass.handles;
16✔
14

4✔
15
        const prototype = Object.getPrototypeOf(observerInstanceOrClass);
4✔
16
        if (prototype && prototype.constructor && prototype.constructor.handles)
16✔
17
                return prototype.constructor.handles;
16✔
18

×
19
        return getMessageHandlerNames(observerInstanceOrClass);
×
20
}
×
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