supabase-test 0.2.13 → 0.2.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/README.md +39 -39
- package/package.json +8 -8
package/LICENSE
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
The MIT License (MIT)
|
|
2
2
|
|
|
3
3
|
Copyright (c) 2025 Dan Lynch <pyramation@gmail.com>
|
|
4
|
-
Copyright (c) 2025
|
|
4
|
+
Copyright (c) 2025 Constructive <developers@constructive.io>
|
|
5
5
|
Copyright (c) 2020-present, Interweb, Inc.
|
|
6
6
|
|
|
7
7
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
package/README.md
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
# supabase-test
|
|
2
2
|
|
|
3
3
|
<p align="center" width="100%">
|
|
4
|
-
<img height="250" src="https://raw.githubusercontent.com/
|
|
4
|
+
<img height="250" src="https://raw.githubusercontent.com/constructive-io/constructive/refs/heads/main/assets/supatest.svg" />
|
|
5
5
|
</p>
|
|
6
6
|
|
|
7
7
|
<p align="center" width="100%">
|
|
8
|
-
<a href="https://github.com/
|
|
9
|
-
<img height="20" src="https://github.com/
|
|
8
|
+
<a href="https://github.com/constructive-io/constructive/actions/workflows/run-tests.yaml">
|
|
9
|
+
<img height="20" src="https://github.com/constructive-io/constructive/actions/workflows/run-tests.yaml/badge.svg" />
|
|
10
10
|
</a>
|
|
11
|
-
<a href="https://github.com/
|
|
11
|
+
<a href="https://github.com/constructive-io/constructive/blob/main/LICENSE">
|
|
12
12
|
<img height="20" src="https://img.shields.io/badge/license-MIT-blue.svg"/>
|
|
13
13
|
</a>
|
|
14
14
|
<a href="https://www.npmjs.com/package/supabase-test">
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
|
|
19
19
|
`supabase-test` is a Supabase-optimized version of [`pgsql-test`](https://www.npmjs.com/package/pgsql-test) with Supabase defaults baked in. It provides instant, isolated PostgreSQL databases for testing with automatic transaction rollbacks, context switching, and clean seeding — configured for Supabase's local development environment. It's also great for GitHub Actions and CI/CD testing.
|
|
20
20
|
|
|
21
|
-
Explore a full working example (including GitHub Actions CI/CD) in the [`supabase-test-suite`](https://github.com/
|
|
21
|
+
Explore a full working example (including GitHub Actions CI/CD) in the [`supabase-test-suite`](https://github.com/constructive-iosupabase-test-suite) repo.
|
|
22
22
|
|
|
23
23
|
## Install
|
|
24
24
|
|
|
@@ -37,7 +37,7 @@ npm install supabase-test
|
|
|
37
37
|
|
|
38
38
|
### Tutorials
|
|
39
39
|
|
|
40
|
-
📚 **[Learn how to test with Supabase →](https://
|
|
40
|
+
📚 **[Learn how to test with Supabase →](https://constructive.io/learn/supabase)**
|
|
41
41
|
|
|
42
42
|
## Table of Contents
|
|
43
43
|
|
|
@@ -642,71 +642,71 @@ See [`pgsql-test` Snapshot Utilities](https://www.npmjs.com/package/pgsql-test#s
|
|
|
642
642
|
|
|
643
643
|
## Education and Tutorials
|
|
644
644
|
|
|
645
|
-
1. 🚀 [Quickstart: Getting Up and Running](https://
|
|
645
|
+
1. 🚀 [Quickstart: Getting Up and Running](https://constructive.io/learn/quickstart)
|
|
646
646
|
Get started with modular databases in minutes. Install prerequisites and deploy your first module.
|
|
647
647
|
|
|
648
|
-
2. 📦 [Modular PostgreSQL Development with Database Packages](https://
|
|
648
|
+
2. 📦 [Modular PostgreSQL Development with Database Packages](https://constructive.io/learn/modular-postgres)
|
|
649
649
|
Learn to organize PostgreSQL projects with pgpm workspaces and reusable database modules.
|
|
650
650
|
|
|
651
|
-
3. ✏️ [Authoring Database Changes](https://
|
|
651
|
+
3. ✏️ [Authoring Database Changes](https://constructive.io/learn/authoring-database-changes)
|
|
652
652
|
Master the workflow for adding, organizing, and managing database changes with pgpm.
|
|
653
653
|
|
|
654
|
-
4. 🧪 [End-to-End PostgreSQL Testing with TypeScript](https://
|
|
654
|
+
4. 🧪 [End-to-End PostgreSQL Testing with TypeScript](https://constructive.io/learn/e2e-postgres-testing)
|
|
655
655
|
Master end-to-end PostgreSQL testing with ephemeral databases, RLS testing, and CI/CD automation.
|
|
656
656
|
|
|
657
|
-
5. ⚡ [Supabase Testing](https://
|
|
657
|
+
5. ⚡ [Supabase Testing](https://constructive.io/learn/supabase)
|
|
658
658
|
Use TypeScript-first tools to test Supabase projects with realistic RLS, policies, and auth contexts.
|
|
659
659
|
|
|
660
|
-
6. 💧 [Drizzle ORM Testing](https://
|
|
660
|
+
6. 💧 [Drizzle ORM Testing](https://constructive.io/learn/drizzle-testing)
|
|
661
661
|
Run full-stack tests with Drizzle ORM, including database setup, teardown, and RLS enforcement.
|
|
662
662
|
|
|
663
|
-
7. 🔧 [Troubleshooting](https://
|
|
663
|
+
7. 🔧 [Troubleshooting](https://constructive.io/learn/troubleshooting)
|
|
664
664
|
Common issues and solutions for pgpm, PostgreSQL, and testing.
|
|
665
665
|
|
|
666
|
-
## Related
|
|
666
|
+
## Related Constructive Tooling
|
|
667
667
|
|
|
668
668
|
### 🧪 Testing
|
|
669
669
|
|
|
670
|
-
* [
|
|
671
|
-
* [
|
|
672
|
-
* [
|
|
673
|
-
* [
|
|
670
|
+
* [pgsql-test](https://github.com/constructive-io/constructive/tree/main/packages/pgsql-test): **📊 Isolated testing environments** with per-test transaction rollbacks—ideal for integration tests, complex migrations, and RLS simulation.
|
|
671
|
+
* [supabase-test](https://github.com/constructive-io/constructive/tree/main/packages/supabase-test): **🧪 Supabase-native test harness** preconfigured for the local Supabase stack—per-test rollbacks, JWT/role context helpers, and CI/GitHub Actions ready.
|
|
672
|
+
* [graphile-test](https://github.com/constructive-io/constructive/tree/main/packages/graphile-test): **🔐 Authentication mocking** for Graphile-focused test helpers and emulating row-level security contexts.
|
|
673
|
+
* [pg-query-context](https://github.com/constructive-io/constructive/tree/main/packages/pg-query-context): **🔒 Session context injection** to add session-local context (e.g., `SET LOCAL`) into queries—ideal for setting `role`, `jwt.claims`, and other session settings.
|
|
674
674
|
|
|
675
675
|
### 🧠 Parsing & AST
|
|
676
676
|
|
|
677
|
-
* [
|
|
678
|
-
* [
|
|
679
|
-
* [
|
|
680
|
-
* [@pgsql/enums](https://
|
|
681
|
-
* [@pgsql/types](https://
|
|
682
|
-
* [@pgsql/utils](https://
|
|
683
|
-
* [
|
|
677
|
+
* [pgsql-parser](https://www.npmjs.com/package/pgsql-parser): **🔄 SQL conversion engine** that interprets and converts PostgreSQL syntax.
|
|
678
|
+
* [libpg-query-node](https://www.npmjs.com/package/libpg-query): **🌉 Node.js bindings** for `libpg_query`, converting SQL into parse trees.
|
|
679
|
+
* [pg-proto-parser](https://www.npmjs.com/package/pg-proto-parser): **📦 Protobuf parser** for parsing PostgreSQL Protocol Buffers definitions to generate TypeScript interfaces, utility functions, and JSON mappings for enums.
|
|
680
|
+
* [@pgsql/enums](https://www.npmjs.com/package/@pgsql/enums): **🏷️ TypeScript enums** for PostgreSQL AST for safe and ergonomic parsing logic.
|
|
681
|
+
* [@pgsql/types](https://www.npmjs.com/package/@pgsql/types): **📝 Type definitions** for PostgreSQL AST nodes in TypeScript.
|
|
682
|
+
* [@pgsql/utils](https://www.npmjs.com/package/@pgsql/utils): **🛠️ AST utilities** for constructing and transforming PostgreSQL syntax trees.
|
|
683
|
+
* [pg-ast](https://www.npmjs.com/package/pg-ast): **🔍 Low-level AST tools** and transformations for Postgres query structures.
|
|
684
684
|
|
|
685
685
|
### 🚀 API & Dev Tools
|
|
686
686
|
|
|
687
|
-
* [launchql/server](https://github.com/
|
|
688
|
-
* [launchql/explorer](https://github.com/
|
|
687
|
+
* [launchql/server](https://github.com/constructive-io/constructive/tree/main/packages/server): **⚡ Express-based API server** powered by PostGraphile to expose a secure, scalable GraphQL API over your Postgres database.
|
|
688
|
+
* [launchql/explorer](https://github.com/constructive-io/constructive/tree/main/packages/explorer): **🔎 Visual API explorer** with GraphiQL for browsing across all databases and schemas—useful for debugging, documentation, and API prototyping.
|
|
689
689
|
|
|
690
690
|
### 🔁 Streaming & Uploads
|
|
691
691
|
|
|
692
|
-
* [launchql/s3-streamer](https://github.com/
|
|
693
|
-
* [launchql/etag-hash](https://github.com/
|
|
694
|
-
* [launchql/etag-stream](https://github.com/
|
|
695
|
-
* [launchql/uuid-hash](https://github.com/
|
|
696
|
-
* [launchql/uuid-stream](https://github.com/
|
|
697
|
-
* [launchql/upload-names](https://github.com/
|
|
692
|
+
* [launchql/s3-streamer](https://github.com/constructive-io/constructive/tree/main/packages/s3-streamer): **📤 Direct S3 streaming** for large files with support for metadata injection and content validation.
|
|
693
|
+
* [launchql/etag-hash](https://github.com/constructive-io/constructive/tree/main/packages/etag-hash): **🏷️ S3-compatible ETags** created by streaming and hashing file uploads in chunks.
|
|
694
|
+
* [launchql/etag-stream](https://github.com/constructive-io/constructive/tree/main/packages/etag-stream): **🔄 ETag computation** via Node stream transformer during upload or transfer.
|
|
695
|
+
* [launchql/uuid-hash](https://github.com/constructive-io/constructive/tree/main/packages/uuid-hash): **🆔 Deterministic UUIDs** generated from hashed content, great for deduplication and asset referencing.
|
|
696
|
+
* [launchql/uuid-stream](https://github.com/constructive-io/constructive/tree/main/packages/uuid-stream): **🌊 Streaming UUID generation** based on piped file content—ideal for upload pipelines.
|
|
697
|
+
* [launchql/upload-names](https://github.com/constructive-io/constructive/tree/main/packages/upload-names): **📂 Collision-resistant filenames** utility for structured and unique file names for uploads.
|
|
698
698
|
|
|
699
699
|
### 🧰 CLI & Codegen
|
|
700
700
|
|
|
701
|
-
* [pgpm](https://github.com/
|
|
702
|
-
* [@launchql/cli](https://github.com/
|
|
703
|
-
* [launchql/launchql-gen](https://github.com/
|
|
704
|
-
* [@launchql/query-builder](https://github.com/
|
|
705
|
-
* [@launchql/query](https://github.com/
|
|
701
|
+
* [pgpm](https://github.com/constructive-io/constructive/tree/main/packages/pgpm): **🖥️ PostgreSQL Package Manager** for modular Postgres development. Works with database workspaces, scaffolding, migrations, seeding, and installing database packages.
|
|
702
|
+
* [@launchql/cli](https://github.com/constructive-io/constructive/tree/main/packages/cli): **🖥️ Command-line toolkit** for managing LaunchQL projects—supports database scaffolding, migrations, seeding, code generation, and automation.
|
|
703
|
+
* [launchql/launchql-gen](https://github.com/constructive-io/constructive/tree/main/packages/launchql-gen): **✨ Auto-generated GraphQL** mutations and queries dynamically built from introspected schema data.
|
|
704
|
+
* [@launchql/query-builder](https://github.com/constructive-io/constructive/tree/main/packages/query-builder): **🏗️ SQL constructor** providing a robust TypeScript-based query builder for dynamic generation of `SELECT`, `INSERT`, `UPDATE`, `DELETE`, and stored procedure calls—supports advanced SQL features like `JOIN`, `GROUP BY`, and schema-qualified queries.
|
|
705
|
+
* [@launchql/query](https://github.com/constructive-io/constructive/tree/main/packages/query): **🧩 Fluent GraphQL builder** for PostGraphile schemas. ⚡ Schema-aware via introspection, 🧩 composable and ergonomic for building deeply nested queries.
|
|
706
706
|
|
|
707
707
|
## Credits
|
|
708
708
|
|
|
709
|
-
🛠 Built by
|
|
709
|
+
🛠 Built by Constructive — if you like our tools, please checkout and contribute to [our github ⚛️](https://github.com/constructive-io)
|
|
710
710
|
|
|
711
711
|
|
|
712
712
|
## Disclaimer
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "supabase-test",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.15",
|
|
4
4
|
"author": "Interweb <developers@interweb.io>",
|
|
5
5
|
"description": "supabase-test offers isolated, role-aware, and rollback-friendly PostgreSQL environments for integration tests with Supabase defaults baked in",
|
|
6
6
|
"main": "index.js",
|
|
7
7
|
"module": "esm/index.js",
|
|
8
8
|
"types": "index.d.ts",
|
|
9
|
-
"homepage": "https://github.com/
|
|
9
|
+
"homepage": "https://github.com/constructive-io/constructive",
|
|
10
10
|
"license": "MIT",
|
|
11
11
|
"publishConfig": {
|
|
12
12
|
"access": "public",
|
|
@@ -14,10 +14,10 @@
|
|
|
14
14
|
},
|
|
15
15
|
"repository": {
|
|
16
16
|
"type": "git",
|
|
17
|
-
"url": "https://github.com/
|
|
17
|
+
"url": "https://github.com/constructive-io/constructive"
|
|
18
18
|
},
|
|
19
19
|
"bugs": {
|
|
20
|
-
"url": "https://github.com/
|
|
20
|
+
"url": "https://github.com/constructive-io/constructive/issues"
|
|
21
21
|
},
|
|
22
22
|
"keywords": [
|
|
23
23
|
"supabase",
|
|
@@ -52,12 +52,12 @@
|
|
|
52
52
|
"test:watch": "jest --watch"
|
|
53
53
|
},
|
|
54
54
|
"dependencies": {
|
|
55
|
-
"@launchql/types": "^2.8.
|
|
56
|
-
"pg-env": "^1.1.
|
|
57
|
-
"pgsql-test": "^2.14.
|
|
55
|
+
"@launchql/types": "^2.8.7",
|
|
56
|
+
"pg-env": "^1.1.8",
|
|
57
|
+
"pgsql-test": "^2.14.15"
|
|
58
58
|
},
|
|
59
59
|
"devDependencies": {
|
|
60
60
|
"makage": "^0.1.8"
|
|
61
61
|
},
|
|
62
|
-
"gitHead": "
|
|
62
|
+
"gitHead": "5a0d7c7502624bd42a214f983fd7ab957e1fb3e3"
|
|
63
63
|
}
|