
Oracle to PostgreSQL Migration Tests
OfficialFreeAutomate integration tests for database migrations.
Free · Opens the source repo
What Oracle to PostgreSQL Migration Tests does
The Oracle to PostgreSQL Migration Tests skill is designed to assist developers in creating integration test cases specifically for .NET data access artifacts during the migration from Oracle to PostgreSQL databases. This skill generates DB-agnostic xUnit tests that validate the consistency of behavior across both database systems. It is particularly useful when migrating existing projects, ensuring that the data access layers function correctly in the new environment while maintaining the integrity of the original Oracle database.
To effectively use this skill, developers must have an existing test project that compiles and adheres to specific conventions regarding test structure and seed data management. The workflow involves several steps, including discovering the project's test conventions, identifying testable data access methods, creating appropriate seed data, writing the test cases, and reviewing the determinism of assertions. Each step is crucial to ensure that the generated tests are reliable and accurately reflect the expected behavior of the data access methods.
This skill is particularly beneficial for teams working on migration projects who need to ensure comprehensive test coverage for their data access layers. By generating tests that are independent of the underlying database, it allows developers to focus on validating business logic without being tied to specific database behaviors. The emphasis on deterministic assertions against seeded data ensures that tests are repeatable and maintainable, which is essential during migration phases.
Overall, the Oracle to PostgreSQL Migration Tests skill streamlines the process of creating integration tests, making it easier for developers to validate their migrations and maintain high-quality code throughout the transition.
When to use it
Use this skill when migrating a .NET project from Oracle to PostgreSQL and needing to validate data access layers.
When not to use it
This skill is not suitable for projects that do not utilize .NET or for those not undergoing a database migration.
What you can build with it
Validating Migration Accuracy
When migrating a .NET application from Oracle to PostgreSQL, use this skill to generate tests that validate the accuracy of data access methods.
Ensuring Test Coverage
Leverage this skill to create comprehensive test coverage for all data access layers in your migrated project, ensuring no critical paths are untested.
Maintaining Data Integrity
Utilize the skill to preserve existing data during testing, ensuring that your tests do not disrupt the current database state.
How to install Oracle to PostgreSQL Migration Tests
View source1. Install with the skills CLI
npx skills add github/awesome-copilot/creating-oracle-to-postgres-migration-integration-tests --agent claude-code2. Or install it manually
Download the skill folder and drop it into ~/.claude/skills/ for all projects, or .claude/skills/ to scope it to one repo. Restart Claude Code so it picks up the new skill.
Anthropic's agentic coding CLI, and the reference implementation of Agent Skills. Drop a skill folder into ~/.claude/skills and Claude Code loads it automatically whenever a task matches the skill's description. Claude Code docs
Inside SKILL.md
Written by githubCreating Integration Tests for Oracle-to-PostgreSQL Migration
Generates integration test cases for data access artifacts in a single target project. Tests validate behavior consistency when running against Oracle or PostgreSQL.
Prerequisites
- The test project must already exist and compile (scaffolded separately).
- Read the existing base test class and seed manager conventions before writing tests.
Workflow
Test Creation:
- [ ] Step 1: Discover the test project conventions
- [ ] Step 2: Identify testable data access artifacts
- [ ] Step 3: Create seed data
- [ ] Step 4: Write test cases
- [ ] Step 5: Review determinism
Step 1: Discover the test project conventions
Read the base test class, seed manager, and project file to understand inheritance patterns, transaction management, and seed file conventions.
Step 2: Identify testable data access artifacts
Scope to the target project only. List data access methods that interact with the database — repositories, DAOs, stored procedure callers, query builders.
Step 3: Create seed data
- Follow seed file location and naming conventions from the existing project.
- Reuse existing seed files when possible.
- Avoid
TRUNCATE TABLE— keep existing database data intact. - Assume existing business rows and lookup rows are already present; add only minimal, collision-safe seed records needed for the scenario.
- Do not commit seed data; tests run in transactions that roll back.
- Ensure seed data does not conflict with other tests.
- Load and verify seed data before assertions depend on it.
- Create or reuse a test
LookupConstantsclass for stable lookup IDs/codes used across seed builders and assertions.
Step 4: Write test cases
- Inherit from the base test class to get automatic transaction create/rollback.
- Ensure each database-touching method in scope has at least one integration test (or multiple tests for higher-risk behavior branches).
- Assert logical outputs (rows, columns, counts, error types), not platform-specific messages.
- Assert specific expected values — never assert that a value is merely non-null or non-empty when a concrete value is available from seed data.
- Avoid testing code paths that do not exist or asserting behavior that cannot occur.
- Avoid redundant assertions across tests targeting the same method.
- For text parameters, include both empty-string and
NULL/missing input coverage where applicable. - For datetime behavior, include explicit timezone-sensitive assertions when methods write/read
timestamp without time zoneortimestamp(0)targets.
Step 5: Review determinism
Re-examine every assertion against non-null values. Confirm each is deterministic against the seeded data. Fix any assertion that depends on database state outside the test's control.
Key Constraints
- Oracle is the golden source — tests capture Oracle's expected behavior.
- DB-agnostic assertions — no platform-specific error messages or syntax in assertions.
- Seed only against Oracle — test project will be migrated to PostgreSQL later.
- Scoped to one project — do not create tests for artifacts outside the target project.
- Preserve existing data — never rewrite or wipe pre-existing business or lookup rows.
Frequently asked questions about Oracle to PostgreSQL Migration Tests
Similar skills
ClickHouse Logs Queries
Efficiently manage Supabase logs with ClickHouse SQL.
EF Core D2 Database Diagram Generator
Visualize your EF Core models as D2 diagrams effortlessly.
Safe SQL Execution
Ensure secure SQL execution in Supabase applications.
Oracle to PostgreSQL Migration
Identify migration risks between Oracle and PostgreSQL.
SSMA Console
Streamline Oracle to SQL Server migrations with ease.
SQL Performance Optimization
Enhance SQL query efficiency across all databases.
