Skip to content

Commit bf05722

Browse files
committed
delete old helper
1 parent 698051f commit bf05722

File tree

1 file changed

+1
-15
lines changed

1 file changed

+1
-15
lines changed

src/test/suite/participant/participant.test.ts

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2171,24 +2171,10 @@ Schema:
21712171

21722172
expect(messages).to.have.lengthOf(4);
21732173

2174-
// VSCode's messages' content could either be array of values or a string
2175-
// This helper supports both.
2176-
const contentIncludes = (message: any, pattern: string): boolean => {
2177-
if (Array.isArray(message.content)) {
2178-
return message.content.find((sub: { value: string }) =>
2179-
sub.value.includes(pattern)
2180-
);
2181-
}
2182-
if (message.content instanceof String) {
2183-
return message.content.includes(pattern);
2184-
}
2185-
throw new Error(`Unhandled message content type ${message}`);
2186-
};
2187-
21882174
const messageContents = messages.map((message) => {
21892175
// There may be different types for the messages' content
21902176
const content = Array.isArray(message.content)
2191-
? message.content.flatMap((sub) => sub.value).join('')
2177+
? message.content.map((sub) => sub.value).join('')
21922178
: message.content;
21932179

21942180
return content;

0 commit comments

Comments
 (0)