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

microsoft / botbuilder-js / 11579379955

29 Oct 2024 05:34PM UTC coverage: 84.703% (-0.5%) from 85.23%
11579379955

push

github

web-flow
refactor: [#4684] Replace browserify with tsup (#4774)

* Replace browserify with tsup in adaptive-expressions

* Remove remaining browserify packages

* Fix streaming tests

* Fix yarn.lock

* fix depcheck

8186 of 10820 branches covered (75.66%)

Branch coverage included in aggregate %.

2 of 2 new or added lines in 1 file covered. (100.0%)

23 existing lines in 13 files now uncovered.

20514 of 23063 relevant lines covered (88.95%)

7296.87 hits per line

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

63.89
/libraries/botframework-streaming/src/disassemblers/requestDisassembler.ts
1
/**
8✔
2
 * @module botframework-streaming
3
 */
4
/**
5
 * Copyright (c) Microsoft Corporation. All rights reserved.
6
 * Licensed under the MIT License.
7
 */
8

9
import { IStreamWrapper } from '../interfaces';
10
import { PayloadTypes } from '../payloads/payloadTypes';
2✔
11
import type { PayloadSender } from '../payloadTransport/payloadSender';
12
import type { StreamingRequest } from '../streamingRequest';
13
import { PayloadDisassembler } from './payloadDisassembler';
2✔
14

15
/**
16
 * Streaming request disassembler.
17
 */
18
export class RequestDisassembler extends PayloadDisassembler {
2✔
19
    payloadType: PayloadTypes = PayloadTypes.request;
24✔
20

21
    /**
22
     * Initializes a new instance of the [RequestDisassembler](xref:botframework-streaming.RequestDisassembler) class.
23
     *
24
     * @param sender The [PayloadSender](xref:botframework-streaming.PayloadSender) to send the disassembled data to.
25
     * @param id The ID of this disassembler.
26
     * @param request The request to be disassembled.
27
     */
28
    constructor(sender: PayloadSender, id: string, public request?: StreamingRequest) {
24✔
29
        super(sender, id);
24✔
30
    }
31

32
    /**
33
     * Gets the stream this disassembler is operating on.
34
     *
35
     * @returns An [IStreamWrapper](xref:botframework-streaming.IStreamWrapper) with a Subscribable Stream.
36
     */
UNCOV
37
    async getStream(): Promise<IStreamWrapper> {
×
38
        const payload = { verb: this.request?.verb, path: this.request?.path, streams: [] };
24!
39
        this.request?.streams?.forEach(function (stream) {
24!
40
            payload.streams.push(stream.description);
22✔
41
        });
42

43
        return PayloadDisassembler.serialize(payload);
24✔
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

© 2025 Coveralls, Inc