Skip to content

Commit dacada8

Browse files
author
Guiners
committed
fixing package.json and adding delay to test
1 parent 2391915 commit dacada8

File tree

4 files changed

+11
-5
lines changed

4 files changed

+11
-5
lines changed

genai/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
"mocha": "^10.0.0",
2828
"sinon": "^18.0.0",
2929
"uuid": "^10.0.0",
30-
"proxyquire": "^2.1.3"
30+
"proxyquire": "^2.1.3",
31+
"node-fetch": "^3.3.2"
3132
}
3233
}

genai/test/live-ground-ragengine-with-txt.test.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ const sinon = require('sinon');
1919
const {describe, it, beforeEach, afterEach} = require('mocha');
2020

2121
const sample = require('../live/live-ground-ragengine-with-txt');
22+
const {delay} = require('./util');
2223

2324
describe('live-ground-ragengine-with-txt', () => {
2425
let mockClient, mockSession;
@@ -50,7 +51,9 @@ describe('live-ground-ragengine-with-txt', () => {
5051
});
5152

5253
it('should return text from mocked RAG session', async function () {
53-
this.timeout(5000);
54+
this.timeout(180000);
55+
this.retries(4);
56+
await delay(this.test);
5457

5558
const output = await sample.generateLiveRagTextResponse();
5659

genai/test/live-txt-with-audio.test.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,13 @@ const {describe, it} = require('mocha');
1919

2020
const projectId = process.env.CAIP_PROJECT_ID;
2121
const sample = require('../live/live-txt-with-audio');
22+
const {delay} = require('./util');
2223

2324
describe('live-txt-with-audio', () => {
2425
it('should generate txt content in a live session from an audio', async function () {
25-
this.timeout(18000);
26+
this.timeout(180000);
27+
this.retries(4);
28+
await delay(this.test);
2629
const output = await sample.generateLiveConversation(projectId);
2730
console.log('Generated output:', output);
2831
assert(output.length > 0);

package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@
3232
},
3333
"dependencies": {
3434
"commander": "^12.0.0",
35-
"eslint": "^8.57.0",
36-
"node-fetch": "^3.3.2"
35+
"eslint": "^8.57.0"
3736
}
3837
}

0 commit comments

Comments
 (0)