Skip to content

Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.

feat(ts/e2e): minor updates to e2e-tests

jkomynoe3ec4b5e4d30
diff --git a/ts/e2e-tests/_utils/package.json b/ts/e2e-tests/_utils/package.json
index 95a27a947..3bd45ecd4 100644
--- a/ts/e2e-tests/_utils/package.json
+++ b/ts/e2e-tests/_utils/package.json
@@ -11,6 +11,12 @@
"types": "./src/index.ts",
"default": "./src/index.ts"
}
+ },
+ "./const": {
+ "import": {
+ "types": "./src/const.ts",
+ "default": "./src/const.ts"
+ }
}
},
"scripts": {
diff --git a/ts/e2e-tests/_utils/src/const.ts b/ts/e2e-tests/_utils/src/const.ts
index 609fb3e1d..a2b3846af 100644
--- a/ts/e2e-tests/_utils/src/const.ts
+++ b/ts/e2e-tests/_utils/src/const.ts
@@ -1 +1,16 @@
+/**
+ * Environment variables to automatically pass through to Docker containers.
+ */
+export const WELL_KNOWN_ENV_VARS = ['COMPOSIO_API_KEY', 'OPENAI_API_KEY'] as const;
+
+/**
+ * Node.js versions that are well-known to the CI matrix strategy.
+ * `current` refers to `process.versions.node`, or (on CI) to the Node.js version specified in `.nvmrc`.
+ */
export const WELL_KNOWN_NODE_VERSIONS = ['20.18.0', '20.19.0', '22.12.0', 'current'] as const;
+
+export const TIMEOUTS = {
+ DEFAULT: 5_000,
+ LLM_SHORT: 15_000,
+ LLM_LONG: 60_000,
+} as const;
diff --git a/ts/e2e-tests/_utils/src/runner.ts b/ts/e2e-tests/_utils/src/runner.ts
index 397ccdb62..1eaf1f4ad 100644
--- a/ts/e2e-tests/_utils/src/runner.ts
+++ b/ts/e2e-tests/_utils/src/runner.ts
@@ -2,11 +2,7 @@ import { describe, beforeAll, it } from 'bun:test';
import type { E2EConfig, E2ETestResult, NodeVersionMeta } from './types';
import { getRepoRoot, resolveNodeVersionMetaList } from './config';
import { ensureNodeImage, runNodeContainer } from './image-lifecycle';
-
-/**
- * Environment variables to automatically pass through to Docker containers.
- */
-const PASSTHROUGH_ENV_VARS = ['COMPOSIO_API_KEY', 'OPENAI_API_KEY'] as const;
+import { WELL_KNOWN_ENV_VARS } from './const'
/**
* Builds environment variables to pass to the container.
@@ -17,7 +13,7 @@ function buildContainerEnv(
): Record<string, string | undefined> {
const env: Record<string, string | undefined> = {};
- for (const varName of PASSTHROUGH_ENV_VARS) {
+ for (const varName of WELL_KNOWN_ENV_VARS) {
if (process.env[varName]) {
env[varName] = process.env[varName];
}