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

RoundingWell / care-ops-frontend / 7aa5b7f8-1c6c-4217-9451-6c465b36e5e1

02 Jun 2026 03:06PM UTC coverage: 85.595% (-14.4%) from 100.0%
7aa5b7f8-1c6c-4217-9451-6c465b36e5e1

Pull #1707

circleci

paulfalgout
fix(ws): preserve filter-only reconnect subscriptions
Pull Request #1707: fix(ws): preserve filter-only reconnect subscriptions

1535 of 1893 branches covered (81.09%)

Branch coverage included in aggregate %.

0 of 3 new or added lines in 1 file covered. (0.0%)

794 existing lines in 88 files now uncovered.

5328 of 6125 relevant lines covered (86.99%)

167.15 hits per line

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

96.97
/src/js/apps/programs/program/program_app.js
1
import { partial } from 'underscore';
2
import Radio from 'backbone.radio';
3

4
import SubRouterApp from 'js/base/subrouterapp';
5

6
import { PROGRAM_BEHAVIORS } from 'js/static';
7

8
import WorkflowsApp from 'js/apps/programs/program/workflows/workflows_app';
9
import ActionApp from 'js/apps/programs/program/action/action_app';
10
import ProgramSidebarApp from 'js/apps/programs/sidebar/program-sidebar_app';
11
import FlowSidebarApp from 'js/apps/programs/sidebar/flow-sidebar_app';
12

13
import { LayoutView } from 'js/views/programs/program/program_views';
14
import { SidebarView } from 'js/views/programs/program/sidebar/sidebar-views';
15

16
export default SubRouterApp.extend({
17
  eventRoutes() {
18
    return {
132✔
19
      'program:details': partial(this.startCurrent, 'workflows'),
20
      'program:action': this.startProgramAction,
21
      'program:action:new': this.startProgramAction,
22
      'programFlow:new': this.startFlowSidebar,
23
    };
24
  },
25

26
  childApps: {
27
    workflows: WorkflowsApp,
28
    action: ActionApp,
29
    programSidebar: ProgramSidebarApp,
30
    flowSidebar: FlowSidebarApp,
31
  },
32

33
  currentAppOptions() {
34
    return {
12✔
35
      region: this.getRegion('content'),
36
      program: this.getOption('program'),
37
    };
38
  },
39

40
  onBeforeStart() {
41
    this.getRegion().startPreloader();
12✔
42
  },
43

44
  beforeStart({ programId }) {
45
    return Radio.request('entities', 'fetch:programs:model', programId);
12✔
46
  },
47

48
  onStart({ currentRoute }, program) {
49
    this.program = program;
12✔
50

51
    this.setView(new LayoutView({ model: program }));
12✔
52

53
    this.showSidebar();
12✔
54

55
    this.startRoute(currentRoute);
12✔
56

57
    this.showView();
12✔
58
  },
59

60
  startProgramAction(programId, actionId) {
61
    const actionApp = this.getChildApp('action');
4✔
62

63
    this.listenToOnce(actionApp, {
4✔
64
      'start'(options, action) {
65
        this.editList(action);
4✔
66
      },
67
      'fail'() {
UNCOV
68
        this.startCurrent('workflows');
×
69
      },
70
    });
71

72
    this.startChildApp('action', { actionId, programId });
4✔
73
  },
74

75
  // Triggers event on started workflow for marking the edited item
76
  editList(item) {
77
    const currentWorkflow = this.getCurrent() || this.startCurrent('workflows');
9✔
78

79
    if (!currentWorkflow.isRunning()) {
9✔
80
      this.listenToOnce(currentWorkflow, 'start', () => {
2✔
81
        currentWorkflow.triggerMethod('edit:item', item);
2✔
82
      });
83
      return;
2✔
84
    }
85

86
    currentWorkflow.triggerMethod('edit:item', item);
7✔
87
  },
88

89
  startFlowSidebar(programId) {
90
    const flow = Radio.request('entities', 'programFlows:model', {
5✔
91
      _program: { id: programId, type: 'programs' },
92
      _owner: null,
93
      published_at: null,
94
      archived_at: null,
95
      behavior: PROGRAM_BEHAVIORS.STANDARD,
96
    });
97

98
    const flowSidebar = this.getChildApp('flowSidebar');
5✔
99

100
    Radio.request('sidebar', 'start', flowSidebar, { flow });
5✔
101

102
    this.editList(flow);
5✔
103
  },
104

105
  showSidebar() {
106
    const sidebarView = new SidebarView({ model: this.program });
12✔
107

108
    this.listenTo(sidebarView, {
12✔
109
      'edit': this.onEdit,
110
    });
111

112
    this.showChildView('sidebar', sidebarView);
12✔
113
  },
114

115
  onEdit() {
116
    const programSidebar = this.getChildApp('programSidebar');
1✔
117
    Radio.request('sidebar', 'start', programSidebar, { program: this.program });
1✔
118
  },
119
});
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