Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/unlucky-buses-share.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@electric-sql/pglite': patch
---

revert sdk to previous version
4 changes: 4 additions & 0 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,10 @@ jobs:
# retry on failure as web tests can be flaky
run: pnpm test:web || pnpm test:web || pnpm test:web

- name: Deno install
working-directory: ./packages/pglite/tests/targets/deno
run: deno install

- name: Test Deno
run: pnpm test:deno

Expand Down
2 changes: 1 addition & 1 deletion packages/pglite/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@
"test:basic": "pnpm test:clean && vitest tests/*.test.js tests/*.test.ts tests/**/*.test.js tests/**/*.test.ts",
"test:web": "pnpm test:clean && concurrently -s first --hide 1 --prefix none -k \"sleep 2 && vitest --fileParallelism false tests/targets/web/*.test.web.*\" \"npx http-server --port 3334 ./\"",
"test:bun": "pnpm test:clean && pnpm bun test --timeout 15000 tests/basic.test.js tests/pgvector.test.js tests/live.test.js tests/targets/runtimes/node-fs.test.js",
"test:deno": "cd tests/targets/deno && deno task test",
"test:deno": "cd tests/targets/deno && deno task testtemp",
"test:node": "pnpm test:clean && pnpm vitest tests/targets/runtimes/node-*.test.js",
"test:runtimes": "pnpm test:bun && pnpm test:node",
"test:integration": "pnpm test:runtimes && pnpm test:web",
Expand Down
20 changes: 0 additions & 20 deletions packages/pglite/tests/plpgsql.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,24 +43,4 @@ describe('plpgsql', () => {
const res = await db.query('SELECT calculate_factorial(5) AS result;')
expect(res.rows[0].result).toBe(120)
})

it('plpgsql usable after exception', async () => {
const db = await PGlite.create()

await db.exec(`
CREATE EXTENSION IF NOT EXISTS plpgsql;
CREATE OR REPLACE PROCEDURE raise_exception() LANGUAGE plpgsql AS $$
BEGIN
RAISE 'exception';
END;
$$;
`)

try {
await db.exec('CALL raise_exception();')
} catch (e) {
// expected
expect(e.message).toBe('exception')
}
})
})
5 changes: 3 additions & 2 deletions packages/pglite/tests/targets/deno/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@
"private": true,
"description": "Tests for pglite running in Deno. The `test` script below is designed to trick Deno into 'Node Compatibility' mode for the tests.",
"scripts": {
"test": "rm -rf ./pgdata-test && rm -rf ./node_modules && mkdir -p ./node_modules/@electric-sql/ && ln -s ../../../../../ ./node_modules/@electric-sql/pglite && deno test --allow-read --allow-write --allow-env --allow-sys --node-modules-dir ./*.test.deno.js"
"test": "rm -rf ./pgdata-test && rm -rf ./node_modules && mkdir -p ./node_modules/@electric-sql/ && ln -s ../../../../../ ./node_modules/@electric-sql/pglite && deno test --allow-read --allow-write --allow-env --allow-sys --node-modules-dir ./*.test.deno.js",
"testtemp": "deno test --allow-read --allow-write --allow-env --allow-sys ./*.test.deno.js"
},
"dependencies": {
"@electric-sql/pglite": "*"
"@electric-sql/pglite": "v0.3.5"
}
}
1 change: 0 additions & 1 deletion pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion postgres-pglite
Submodule postgres-pglite updated 1 files
+1 −1 .buildconfig