mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-07-12 19:10:55 -07:00
perf(test): optimize test suite speed and stability
This commit is contained in:
@@ -1085,12 +1085,12 @@ describe('runNonInteractive', () => {
|
||||
(async function* () {
|
||||
yield events[0];
|
||||
await new Promise((resolve, reject) => {
|
||||
const timeout = setTimeout(resolve, 1000);
|
||||
const timeout = setTimeout(resolve, 2000);
|
||||
signal.addEventListener('abort', () => {
|
||||
clearTimeout(timeout);
|
||||
setTimeout(() => {
|
||||
reject(new Error('Aborted')); // This will be caught by nonInteractiveCli and passed to handleError
|
||||
}, 300);
|
||||
}, 20);
|
||||
});
|
||||
});
|
||||
})(),
|
||||
@@ -1104,7 +1104,7 @@ describe('runNonInteractive', () => {
|
||||
});
|
||||
|
||||
// Wait a bit for setup to complete and listeners to be registered
|
||||
await new Promise((resolve) => setTimeout(resolve, 100));
|
||||
await new Promise((resolve) => setTimeout(resolve, 50));
|
||||
|
||||
// Find the keypress handler registered by runNonInteractive
|
||||
const keypressCall = stdinOnSpy.mock.calls.find(
|
||||
|
||||
Reference in New Issue
Block a user