Skip to content

Commit f99847b

Browse files
committed
Fix backwards compat test
1 parent abf0491 commit f99847b

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

packages/vertexai/src/backwards-compatbility.test.ts

+6-1
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ import {
2828
} from './api';
2929
import { AI, VertexAI, AIErrorCode } from './public-types';
3030
import { VertexAIBackend } from './backend';
31+
import { ChromeAdapter } from './methods/chrome-adapter';
3132

3233
function assertAssignable<T, _U extends T>(): void {}
3334

@@ -65,7 +66,11 @@ describe('backwards-compatible types', () => {
6566
it('AIModel is backwards compatible with VertexAIModel', () => {
6667
assertAssignable<typeof VertexAIModel, typeof AIModel>();
6768

68-
const model = new GenerativeModel(fakeAI, { model: 'model-name' });
69+
const model = new GenerativeModel(
70+
fakeAI,
71+
{ model: 'model-name' },
72+
new ChromeAdapter()
73+
);
6974
expect(model).to.be.instanceOf(AIModel);
7075
expect(model).to.be.instanceOf(VertexAIModel);
7176
});

0 commit comments

Comments
 (0)