pg.test.ts — drizzle-orm Source File
Architecture documentation for pg.test.ts, a typescript file in the drizzle-orm codebase. 6 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR 495abf15_7e69_b985_3edc_4ea75ba9843d["pg.test.ts"] cbab40d4_ac7c_1d5b_bd7b_7bf6059aeaf6["pglite"] 495abf15_7e69_b985_3edc_4ea75ba9843d --> cbab40d4_ac7c_1d5b_bd7b_7bf6059aeaf6 690f7dfc_0aea_9ee8_d6e7_26bbb3689031["drizzle-orm"] 495abf15_7e69_b985_3edc_4ea75ba9843d --> 690f7dfc_0aea_9ee8_d6e7_26bbb3689031 53497908_16e7_977d_e97d_7414884a88a6["pg-core"] 495abf15_7e69_b985_3edc_4ea75ba9843d --> 53497908_16e7_977d_e97d_7414884a88a6 9a46d98d_eb2d_c1e4_a37b_506dd514a6a7["fs"] 495abf15_7e69_b985_3edc_4ea75ba9843d --> 9a46d98d_eb2d_c1e4_a37b_506dd514a6a7 2080849e_169d_739e_1ba9_1396fc229951["schemaDiffer"] 495abf15_7e69_b985_3edc_4ea75ba9843d --> 2080849e_169d_739e_1ba9_1396fc229951 8d35eaf2_a542_cfd4_fa1a_fafca0f02686["vitest"] 495abf15_7e69_b985_3edc_4ea75ba9843d --> 8d35eaf2_a542_cfd4_fa1a_fafca0f02686 style 495abf15_7e69_b985_3edc_4ea75ba9843d fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import { PGlite } from '@electric-sql/pglite';
import { SQL, sql } from 'drizzle-orm';
import {
bigint,
bigserial,
boolean,
char,
check,
cidr,
date,
doublePrecision,
index,
inet,
integer,
interval,
json,
jsonb,
macaddr,
macaddr8,
numeric,
pgEnum,
pgMaterializedView,
pgPolicy,
pgRole,
pgSchema,
pgTable,
pgView,
real,
serial,
smallint,
smallserial,
text,
time,
timestamp,
uuid,
varchar,
} from 'drizzle-orm/pg-core';
import fs from 'fs';
import { introspectPgToFile } from 'tests/schemaDiffer';
import { expect, test } from 'vitest';
if (!fs.existsSync('tests/introspect/postgres')) {
fs.mkdirSync('tests/introspect/postgres');
}
test('basic introspect test', async () => {
const client = new PGlite();
const schema = {
users: pgTable('users', {
id: integer('id').notNull(),
email: text('email'),
}),
};
const { statements, sqlStatements } = await introspectPgToFile(
client,
schema,
'basic-introspect',
);
// ... (869 more lines)
Dependencies
- drizzle-orm
- fs
- pg-core
- pglite
- schemaDiffer
- vitest
Source
Frequently Asked Questions
What does pg.test.ts do?
pg.test.ts is a source file in the drizzle-orm codebase, written in typescript.
What does pg.test.ts depend on?
pg.test.ts imports 6 module(s): drizzle-orm, fs, pg-core, pglite, schemaDiffer, vitest.
Where is pg.test.ts in the architecture?
pg.test.ts is located at drizzle-kit/tests/introspect/pg.test.ts (directory: drizzle-kit/tests/introspect).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free