Testing & Validation
Verify your RDN integration setup is working correctly.
Pre-Testing Checklist
Before running tests, confirm you have:
- ✅ Installed the RDN package
- ✅ Created RDN API Configuration metadata records
- ✅ Created RDN API Input Field records
- ✅ Created RDN API Provider with valid token
- ✅ Created RDN Field Update records
- ✅ Implemented triggers on Lead/Contact objects
- ✅ Added remote site for RDN API endpoint
- ✅ All metadata records marked as Active
Test Data Setup
Sample Lead Record
Create a test Lead with these fields:
First Name: Test
Last Name: Lead
Company: Acme Corp
Title: Sales Manager
Phone: (555) 123-4567
Email: testlead@example.com
Country: USA
Industry: Technology
Sample Contact Record
Create a test Contact with these fields:
First Name: Test
Last Name: Contact
Email: testcontact@example.com
Phone: (555) 234-5678
Title: Product Manager
Mailing Country: United Kingdom
tip
Use different field values each time you test to avoid duplicate data clogging your org.
Test Execution
Test 1: Basic Integration Flow
Goal: Verify the complete integration workflow
Steps:
- Create Record - Create a new Lead with test data
- Wait for Processing - Wait 5-10 seconds for async job
- Check Trigger Execution - View debug logs to verify trigger fired
- Verify API Call - Confirm RDN API was called in logs
- Check Field Updates - Refresh the record and verify mapped fields populated
Expected Results:
- Trigger executes without errors
- Queueable job is enqueued
- API call completes successfully
- Fields are updated with API response data
- No error emails received
Test 2: Change Detection
Goal: Verify that only field changes trigger the integration
Steps:
- Create Record - Create a Lead without updating any fields afterward
- Update Field - Change the Title field to a different value
- Check Logs - Verify API was called
- Update Non-Monitored Field - Change email or phone
- Check Logs - Verify API was NOT called (no changes to monitored field)
Expected Results:
- API call only triggered when monitored fields change
- Non-monitored field changes don't trigger API
- No unnecessary API calls made
Test 3: Error Handling
Goal: Verify error handling and notifications
Steps:
- Disable Auth Token - Temporarily update API Provider with invalid token
- Create/Update Record - Trigger the integration
- Wait for Error - Allow API call to fail
- Check Logs - Verify error was logged
- Check Email - Verify error notification email received
- Re-enable Token - Update API Provider with correct token
Expected Results:
- Error is captured and logged
- Error notification email is sent
- Integration can be re-enabled without restarting
Test 4: Batch Processing
Goal: Verify batch job handling for large record sets
Steps:
- Create Multiple Records - Create 150+ leads in bulk
- Execute Batch Job - Trigger batch execution from RDN
- Monitor Progress - Check RDN logs for batch status
- Verify Results - Confirm all records processed
- Check Error Rate - Verify <1% error rate
Expected Results:
- Records processed in batches of 98
- All records successfully processed
- Batch job completes without timeout
Validation Checklist
After completing tests, verify:
- ✅ New records trigger the integration automatically
- ✅ Mapped fields are populated with API response data
- ✅ Error notifications are sent when issues occur
- ✅ Processing time is acceptable (<10 seconds per record)
- ✅ API call limits are not exceeded
- ✅ Debug logs show expected flow
Performance Validation
Measurement Points
| Metric | Target | Action if Exceeded |
|---|---|---|
| Processing Time (per record) | <10 seconds | Check API latency |
| Success Rate | >99% | Review error logs |
| API Response Time | <5 seconds | Contact RDN support |
| Error Rate | <1% | Check field mappings |
How to Measure
- Create a test record and note timestamp
- Monitor Salesforce debug logs
- Note when API call completes
- Calculate elapsed time
- Record in a tracking spreadsheet
Moving to Production
Pre-Production Checklist
- ✅ All tests passed in Sandbox
- ✅ Error handling verified
- ✅ Performance acceptable
- ✅ Stakeholders aware of changes
- ✅ Monitoring/alerting configured
- ✅ Runbook prepared for ops team
Production Deployment
- Clone Configuration - Copy metadata from Sandbox to Production
- Deploy Triggers - Deploy trigger code via Change Set
- Verify Setup - Confirm all metadata and triggers are active
- Run Smoke Tests - Create 1-2 test records in production
- Monitor Logs - Watch logs for first hour
- Notify Teams - Inform stakeholders of successful deployment
Production Validation
After deploying to production:
- Create Test Record - Create a test Lead/Contact
- Verify Processing - Confirm API call succeeded
- Check Fields - Verify field population
- Monitor 24 Hours - Watch for issues
- Sign Off - Confirm successful production deployment
Troubleshooting During Tests
Issue: Trigger Not Firing
Check:
- Is trigger deployed and active? (Setup → Apex Triggers)
- Is the trigger on the correct object?
- Are you in After Insert/After Update events?
Issue: API Call Fails
Check:
- Is the remote site configured correctly?
- Is the Auth Token valid?
- Is the endpoint URL correct?
- Check RDN status page for outages
Issue: Fields Not Updating
Check:
- Are RDN Field Update records configured?
- Do field names match API response keys?
- Are target fields accessible (not read-only)?
- Check field-level security permissions
Next Steps
- Troubleshooting - Common issues and solutions
- Security & Compliance - Security best practices
Was this page helpful?