Skip to content

Testcase for ElectricSQL referential integrity problem

Notifications You must be signed in to change notification settings

fooware/electric-testcase-01

Repository files navigation

Test cases for Electric-SQL

This repository contains some test cases created to assist the Electric-SQL team.

1. Incorrect Types in generated client

See GitHub issue 1001 for details.

Reproducible in commit 10e5ff75b4fc92852ef04cbff69c167024aac7d1 on main. Fixed by upgrading to Electric 0.9.6 in the following commit.

2. Failing referential integrity (discussed in Discord)

Failing referential integrity when doing overlapping deletes and inserts, Discussed in Discord. Test case and instructions can be found in the electric_8_1 branch.

********************* Officials docs below *********************

This is a web application using ElectricSQL in the browser with wa-sqlite.

Pre-reqs

You need NodeJS >= 16.11 and Docker Compose v2.

Install

Install the dependencies:

npm install

Setup

Start Postgres and Electric using Docker (see running the examples for more options):

npm run backend:up
# Or `npm run backend:start` to foreground

Note that, if useful, you can connect to Postgres using:

npm run db:psql

Setup your database schema:

npm run db:migrate

Generate your type-safe client:

npm run client:generate
# or `npm run client:watch`` to re-generate whenever the DB schema changes

Run

Start your app:

npm run dev

Open localhost:5173 in your web browser.

Develop

This template contains the basic Electric code which you can adapt to your use case. For more information see the:

If you need help let us know on Discord.

About

Testcase for ElectricSQL referential integrity problem

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published