Skip to content

Commit 442dc40

Browse files
committed
remove streamId from first entity
1 parent eeec789 commit 442dc40

File tree

6 files changed

+9
-9
lines changed

6 files changed

+9
-9
lines changed

__tests__/html2/livestream/entities.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
npm <!doctype html>
1+
<!doctype html>
22
<html lang="en-US">
33
<head>
44
<link href="/assets/index.css" rel="stylesheet" type="text/css" />
@@ -70,7 +70,7 @@
7070
const firstTypingActivityId = 't-00001';
7171

7272
await directLine.emulateIncomingActivity({
73-
entities: [{ streamSequence: 1, streamType: 'streaming', type: 'streaminfo', streamId: 'a-entities' }],
73+
entities: [{ streamSequence: 1, streamType: 'streaming', type: 'streaminfo' }],
7474
from: { id: 'u-00001', name: 'Bot', role: 'bot' },
7575
id: firstTypingActivityId,
7676
text: 'A quick',
@@ -100,7 +100,7 @@
100100

101101
// WHEN: Bot continue typing the message.
102102
await directLine.emulateIncomingActivity({
103-
entities: [{ streamId: 'a-entities', streamSequence: 2, type: 'streaminfo', streamType: 'streaming' }],
103+
entities: [{ streamId: firstTypingActivityId, streamSequence: 2, type: 'streaminfo', streamType: 'streaming' }],
104104
from: { id: 'u-00001', name: 'Bot', role: 'bot' },
105105
id: 't-00002',
106106
text: 'A quick brown fox',
@@ -128,7 +128,7 @@
128128

129129
// WHEN: Bot continue typing the message.
130130
await directLine.emulateIncomingActivity({
131-
entities: [{ streamId: 'a-entities', streamSequence: 3, type: 'streaminfo', streamType: 'streaming' }],
131+
entities: [{ streamId: firstTypingActivityId, streamSequence: 3, type: 'streaminfo', streamType: 'streaming' }],
132132
from: { id: 'u-00001', name: 'Bot', role: 'bot' },
133133
id: 't-00003',
134134
text: 'A quick brown fox jumped over',
@@ -153,7 +153,7 @@
153153

154154
// WHEN: Bot finished typing the message.
155155
await directLine.emulateIncomingActivity({
156-
entities: [{ streamId: 'a-entities', type: 'streaminfo', streamType: 'final' }],
156+
entities: [{ streamId: firstTypingActivityId, type: 'streaminfo', streamType: 'final' }],
157157
from: { id: 'u-00001', name: 'Bot', role: 'bot' },
158158
id: 'a-00002',
159159
text: 'A quick brown fox jumped over the lazy dogs.',
-17.1 KB
Loading
-17.2 KB
Loading
-17.2 KB
Loading
-17.5 KB
Loading

__tests__/html2/livestream/entities.outOfOrder.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@
7575
const firstTypingActivityId = 't-00001';
7676

7777
await directLine.emulateIncomingActivity({
78-
entities: [{ type: 'streaminfo', streamId: 'stream', streamSequence: 1, streamType: 'streaming' }],
78+
entities: [{ type: 'streaminfo', streamSequence: 1, streamType: 'streaming' }],
7979
from: { id: 'u-00001', name: 'Bot', role: 'bot' },
8080
id: firstTypingActivityId,
8181
text: 'A quick',
@@ -116,7 +116,7 @@
116116

117117
// WHEN: Bot send typing message in out-of-order fashion.
118118
await directLine.emulateIncomingActivity({
119-
entities: [{ type: 'streaminfo', streamId: 'stream', streamSequence: 3, streamType: 'streaming' }],
119+
entities: [{ type: 'streaminfo', streamId: firstTypingActivityId, streamSequence: 3, streamType: 'streaming' }],
120120
from: { id: 'u-00001', name: 'Bot', role: 'bot' },
121121
id: 't-00003',
122122
text: 'A quick brown fox jumped over',
@@ -155,7 +155,7 @@
155155

156156
// WHEN: Bot send the belated typing message.
157157
await directLine.emulateIncomingActivity({
158-
entities: [{ type: 'streaminfo', streamId: 'stream', streamSequence: 2, streamType: 'streaming' }],
158+
entities: [{ type: 'streaminfo', streamId: firstTypingActivityId, streamSequence: 2, streamType: 'streaming' }],
159159
from: { id: 'u-00001', name: 'Bot', role: 'bot' },
160160
id: 't-00002',
161161
text: 'A quick brown fox',
@@ -194,7 +194,7 @@
194194

195195
// WHEN: Bot finished typing the message.
196196
await directLine.emulateIncomingActivity({
197-
entities: [{ type: 'streaminfo', streamId: 'stream', streamType: 'final' }],
197+
entities: [{ type: 'streaminfo', streamId: firstTypingActivityId, streamType: 'final' }],
198198
from: { id: 'u-00001', name: 'Bot', role: 'bot' },
199199
id: 'a-00002',
200200
text: 'A quick brown fox jumped over the lazy dogs.',

0 commit comments

Comments
 (0)