Testing Approaches
Agility offers two levels of testing:- Individual Agent Testing - Test a single agent in isolation
- Workflow Testing - Test the entire workflow from start to finish
Testing Individual Agents
Open Agent Configuration
Click on the agent card you want to test. The configuration sidebar opens on the right side with a colored header matching the agent type.
Configure the Agent
Complete the agent configuration:
- Add required API keys
- Set up prompts or parameters
- Configure any input field references
- Select appropriate models or settings
Each agent type has different configuration requirements. Check the configuration form for required fields.
Save Configuration
Click the “Save Configuration” button (green button). You’ll see a confirmation message: “Configuration saved successfully!”This saves your settings so they’re available when running the workflow.
Run Agent Test
Click the “Test Agent” button (blue button) to test the agent individually. The button will show:
- “Loading…” while the test runs
- A spinning icon during execution
- Results or errors when complete
Test Mode Features
When testing individual agents:- Tests run in isolation without executing connected agents
- Input data can be simulated or left empty
- No data is saved or sent to external services (depends on agent type)
- API calls are made with your configured keys
- Results are logged for debugging
Testing Complete Workflows
Configure All Agents
Before testing the workflow, ensure every agent is properly configured:
- API keys are set
- Prompts include proper field references
- All required parameters are filled
- Each agent has been individually tested
Save the Workflow
Click “Save Workflow” in the top-right corner. The button shows:
- “Saving…” with a spinner during save
- Returns to “Save Workflow” when complete
Select Starting Agent
Click on the agent where you want to start the workflow execution. This is typically:
- An input agent (Gmail Reader, GitHub Reader)
- The first agent in your workflow sequence
Run Workflow Test
In the agent’s configuration sidebar, click the “Test Workflow” button (purple button). The button displays:
- “Running Workflow…” with animated spinner
- Progress indication during execution
Monitor Execution
Watch for toast notifications during execution:
- “Running workflow…” (info) when starting
- “Workflow completed successfully! (X steps executed)” (success) when done
- Error messages if something fails
Workflow Execution Flow
When you test a workflow:- Starting point: Execution begins at the selected agent
- Sequential processing: Agents execute in order based on connections
- Data passing: Output from each agent flows to connected agents
- Error handling: Execution stops if any agent fails
- Result collection: All outputs are collected and returned
Understanding Test Results
Success Indicators
Individual Agent Test:Error Messages
Configuration Errors:- “API key is required”
- “You must be logged in to save configuration”
- “Failed to save configuration”
- “Failed to generate text”
- “You must be logged in to test the agent”
- “Workflow failed: [specific error message]”
- “Error: 401” - Authentication failed
- “Error: 429” - Rate limit exceeded
- “Error: 500” - Server error
Error messages include specific details to help you diagnose issues quickly. Read the error message carefully to understand what went wrong.
Testing Best Practices
Before Testing
Verify Configuration
- All API keys are valid and have proper permissions
- Prompts are complete and reference the correct fields
- Agent settings match your intended use case
Check Connections
- All agents are properly connected
- Data flows in the correct direction
- No circular connections exist
During Testing
- Test incrementally - Test each new agent before adding more
- Start simple - Begin with 2-3 agents, then expand
- Monitor output - Check that each agent produces expected results
- Note execution time - Track how long the workflow takes
- Watch for errors - Pay attention to error messages and warnings
After Testing
- Review all outputs - Verify each agent produced correct results
- Check external services - Confirm emails were sent, messages posted, etc.
- Analyze performance - Identify slow agents or bottlenecks
- Document findings - Note any issues or unexpected behavior
- Iterate and improve - Adjust configurations based on test results
Common Testing Scenarios
Testing Text Generation
Testing Email Workflows
Testing Multi-Output Workflows
Debugging Failed Tests
Agent Test Failures
Check Error Message
Read the error message in the red box. It usually indicates the specific problem.
Verify API Keys
- Ensure API keys are correct
- Check that keys have necessary permissions
- Verify keys haven’t expired
Review Configuration
- Check all required fields are filled
- Verify field references are correct
- Ensure model selection is appropriate
Workflow Test Failures
Verify Connections
Ensure all connections are properly established and pointing to the right agents.
Testing with Different Data
Using Sample Data
For agents that receive input:- Start with simple, predictable input
- Test with minimal data first
- Gradually increase complexity
- Test edge cases (empty data, special characters, etc.)
Testing External Services
Gmail Agents:- Use a test Gmail account
- Send test emails to yourself
- Check spam/trash folders
- Create a test Discord server
- Use a dedicated test channel
- Monitor for rate limits
- Use a test repository
- Create test commits
- Verify webhook configurations
Performance Testing
Measuring Execution Time
Track how long your workflow takes:- Note the start time when clicking “Test Workflow”
- Note the end time when receiving success message
- Calculate total execution time
- Identify slow agents
Optimization Tips
- Use faster AI models for simple tasks
- Minimize unnecessary text processing
- Reduce the number of API calls
- Cache results when possible
- Test during off-peak hours to avoid rate limits
Next Steps
- Explore common workflow patterns for proven designs
- Learn about creating workflows from scratch
- Review connecting agents for advanced data flow