# Testing Integration

> Run and debug integration tests (real Postgres via Prisma) for Drasil. Use when this capability is needed.

- Skill: `tomevault-io/testing-integration` (Agent Skill, multi-file: 2 files)
- Install (CLI): `npx skillmds@latest add tomevault-io/testing-integration`
- Raw SKILL.md: https://api.skillmd.com/api/skills/tomevault-io/testing-integration/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Integrations & APIs
- Author: tomevault-io (https://skillmd.com/u/tomevault-io)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/tomevault-io/testing-integration

---


Use this when validating workflows end-to-end against a real database.

## Commands

- Unit tests: `npm test`
- Integration tests: `npm run test:integration`

## Environment

- Integration tests are enabled by `JEST_INTEGRATION=1` (the integration test runner sets this).
- Provide one of:
  - `TEST_DATABASE_URL` (preferred)
  - `DATABASE_URL` (fallback)
- Optional but often needed:
  - `POSTGRES_DB_URL` (admin connection string used to create extensions)

## What the harness does

- Runs `prisma migrate deploy`
- Ensures extensions exist (uuid-ossp)
- Truncates tables between tests

---
> Converted and distributed by [TomeVault](https://tomevault.io/claim/basic-bit) — claim your Tome and manage your conversions.
<!-- tomevault:4.0:skill_md:2026-04-13 -->

