create_migration_test_plan
Generate a migration test plan covering 8 phases: pre-migration, data quality, transforms, sample migration, edge cases, rollback, performance, and post-validation with runnable Fix Scripts for user approval.
Instructions
Generate a full expert migration test plan for user approval before executing.
Covers all 8 testing phases:
Pre-Migration Checks — table access, transform map active, ACLs, schema, correlation field, no duplicate IDs
Source Data Quality — fill rates, null-heavy fields, long text truncation
Transform Rules — value map completeness, null handling, date format conversion
Sample Migration — end-to-end 1-record test, field accuracy spot-check, record count, zero import errors
Edge Cases — special characters, duplicate source IDs, null reference fields
Rollback Safety — clean delete by correlation field, no cascade side effects
Performance — staging query speed, throughput estimate and runtime projection
Post-Validation — zero error rows, correlation field populated, random spot-check
Each test case includes a ready-to-run ServiceNow Fix Script. Present the plan to the user for approval, then call run_approved_tests.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| analysis | Yes | The full analysis object from analyze_migration_for_testing | |
| field_mappings | No | ||
| transform_rules | No | ||
| sample_records | No | ||
| correlation_field | No | SN target field that stores the source platform ID (used for dedup + rollback) | u_source_id |
| source_id_field | No | Field in source records that is the unique ID (e.g. key for Jira, Id for Salesforce) | Id |
| priority | No | all=full 8-phase suite | critical=blockers only | smoke=first 5 tests | all |