-
Notifications
You must be signed in to change notification settings - Fork 82
Inkeep push e2e testing #1267
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Inkeep push e2e testing #1267
Conversation
|
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Claude finished @Gaurav1998-dev's task —— View job Code Review CompleteI've thoroughly reviewed this E2E testing implementation for the push command. Here are my findings and recommendations: SummaryThis PR adds comprehensive end-to-end testing for the 🔧 Critical Issues1. Hard-coded Configuration DependenciesThe test relies on hardcoded localhost URLs and a specific database setup without proper environment isolation. // agents-cli/src/__tests__/e2e/src/projects/inkeep.config.ts:5-10
agentsManageApi: {
url: 'http://localhost:3002',
},
agentsRunApi: {
url: 'http://localhost:3003',
},Recommendation: Use environment variables or mock services to avoid external dependencies: agentsManageApi: {
url: process.env.TEST_AGENTS_MANAGE_API_URL || 'http://localhost:3002',
},2. Real Database Usage in E2E TestsThe test connects to a real database using // Line 29-30: Creates real database connection
db = createDatabaseClient();
await createTestOrganization(db, tenantId);Recommendation: Consider using the existing 🚨 Architecture & Design Concerns3. Inconsistent Test Data StructureThe E2E test project duplicates files already in Files duplicated:
Recommendation:
4. Manual Cleanup LogicThe // Lines 42-91: Manual cleanup with multiple delete operations
await db.delete(subAgentToolRelations)...
await db.delete(subAgents)...
await db.delete(agents)...
// etc.Recommendation: Leverage existing test utilities like
|
This PR adds end-to-end testing for the inkeep push command in the CLI.
What's Added
Test Coverage
The test suite validates:
✅ Project metadata (name, description, models configuration)
✅ Agent and sub-agent creation with correct attributes
✅ Tool configuration (MCP server URLs)
✅ Tool-to-sub-agent relationship linking
✅ Foreign key constraint integrity across all tables
✅ Update behavior (no duplicate records on re-push)
Requirements
⚠️ Important: The Management API must be running locally for this test to pass, as it tests against the real database using DATABASE_URL.