Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 5 additions & 15 deletions integration-tests/interactive/cron-interactive.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,18 @@
import { describe, it, expect, afterEach } from 'vitest';
import { InteractiveSession } from './interactive-session.js';

const IS_SANDBOX =
process.env['QWEN_SANDBOX'] &&
process.env['QWEN_SANDBOX']!.toLowerCase() !== 'false';
const SANDBOX_MODE = process.env['QWEN_SANDBOX']?.toLowerCase().trim();
const IS_SANDBOX = Boolean(
SANDBOX_MODE && SANDBOX_MODE !== 'false' && SANDBOX_MODE !== '0',
);

function makeEnv(): NodeJS.ProcessEnv {
const env = { ...process.env };
delete env['NO_COLOR'];
return {
...env,
FORCE_COLOR: '1',
QWEN_CODE_LANG: 'en',
TERM: 'xterm-256color',
NODE_NO_WARNINGS: '1',
};
Expand Down Expand Up @@ -120,18 +122,6 @@ function makeEnv(): NodeJS.ProcessEnv {
(scr) => scr.includes('ALIVE99'),
'model response ALIVE99',
);

await session.send(
'Call cron_list and tell me how many jobs exist. Say "COUNT: N"',
);
await session.waitForScreen(
(screen) =>
screen.includes('COUNT: 1') ||
screen.includes('1 job') ||
screen.includes('Active cron jobs (1)'),
'cron list showing one active job',
60_000,
);
},
);
});
Loading