Skip to content

Commit 354afd6

Browse files
committed
chore: fix check
1 parent 20e985e commit 354afd6

File tree

5 files changed

+11
-6
lines changed

5 files changed

+11
-6
lines changed

packages/atlas-service/src/atlas-service.spec.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ const ATLAS_CONFIG = {
1515
issuer: 'http://example.com/oauth2/default',
1616
},
1717
authPortalUrl: 'http://example.com/account/login',
18+
assistantApiBaseUrl: 'http://example.com/assistant',
1819
};
1920

2021
function getAtlasService(

packages/atlas-service/src/main.spec.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ describe('CompassAuthServiceMain', function () {
5656
clientId: '1234abcd',
5757
},
5858
authPortalUrl: 'http://example.com',
59+
assistantApiBaseUrl: 'http://example.com/assistant',
5960
};
6061

6162
const fetch = CompassAuthService['fetch'];

packages/compass-assistant/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,14 +51,14 @@
5151
"dependencies": {
5252
"@ai-sdk/openai": "^2.0.4",
5353
"@mongodb-js/atlas-service": "^0.54.0",
54+
"@mongodb-js/compass-app-registry": "^9.4.18",
5455
"@mongodb-js/compass-components": "^1.30.5",
5556
"@mongodb-js/compass-logging": "^1.7.10",
56-
"@mongodb-js/compass-app-registry": "^9.4.18",
5757
"ai": "^5.0.5",
5858
"compass-preferences-model": "^2.49.0",
5959
"react": "^17.0.2",
60-
"use-sync-external-store": "^1.5.0",
61-
"throttleit": "^2.1.0"
60+
"throttleit": "^2.1.0",
61+
"use-sync-external-store": "^1.5.0"
6262
},
6363
"devDependencies": {
6464
"@mongodb-js/eslint-config-compass": "^1.4.5",

packages/compass-assistant/src/assistant-chat.spec.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,8 @@ describe('AssistantChat', function () {
208208
role: 'assistant',
209209
parts: [
210210
{ type: 'text', text: 'This is text content.' },
211-
{ type: 'tool-call' as any, text: 'This should be filtered out.' },
211+
// @ts-expect-error - tool-call is not a valid part type
212+
{ type: 'tool-call', text: 'This should be filtered out.' },
212213
{ type: 'text', text: ' More text content.' },
213214
],
214215
},

packages/compass-assistant/src/index.spec.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ import {
77
DrawerAnchor,
88
DrawerContentProvider,
99
} from '@mongodb-js/compass-components';
10+
import { Chat } from './@ai-sdk/react/chat-react';
11+
import type { AtlasService } from '@mongodb-js/atlas-service/provider';
1012

1113
describe('CompassAssistantProvider', function () {
1214
beforeEach(function () {
@@ -25,13 +27,13 @@ describe('CompassAssistantProvider', function () {
2527
};
2628

2729
const MockedProvider = CompassAssistantProvider.withMockServices({
28-
atlasService: mockAtlasService,
30+
atlasService: mockAtlasService as unknown as AtlasService,
2931
});
3032

3133
render(
3234
<DrawerContentProvider>
3335
<DrawerAnchor />
34-
<MockedProvider />
36+
<MockedProvider chat={new Chat({})} />
3537
</DrawerContentProvider>,
3638
{
3739
preferences: { enableAIAssistant: true },

0 commit comments

Comments
 (0)