Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
1bde004
refactor: optimization
bernard-ng Feb 21, 2026
6f1c698
feat: schema support init
bernard-ng Feb 22, 2026
57e03ca
feat: document parity matrix
bernard-ng Feb 23, 2026
d2847ef
feat: add support for pg and sqlite3 drivers
bernard-ng Feb 23, 2026
95af675
feat: review exception and formalize api
bernard-ng Feb 23, 2026
0ee29f0
feat: more optimization and api alignment
bernard-ng Feb 24, 2026
1eb387b
feat: more optimization and api alignment
bernard-ng Feb 24, 2026
4e8d917
feat: fix tests
bernard-ng Feb 24, 2026
285ac19
feat: api unification for connection, driver, result
bernard-ng Feb 24, 2026
bd743f2
feat: fill api gap
bernard-ng Feb 24, 2026
20fb2fc
feat: fix typing
bernard-ng Feb 24, 2026
0161704
refactor: remove dev scripts and tests
bernard-ng Feb 24, 2026
84f73fb
test: add coverage with istanbull
bernard-ng Feb 24, 2026
bb3325e
feat: refactor tests
bernard-ng Feb 25, 2026
7b468dd
test: robust testing
bernard-ng Feb 25, 2026
8243a4a
test: robust testing'
bernard-ng Feb 25, 2026
935a9a0
test: functional tests setup
bernard-ng Feb 25, 2026
c1ca796
test: fix mismatch between tests and implementations
bernard-ng Feb 26, 2026
720ded5
test: ci fix
bernard-ng Feb 26, 2026
bd66cd4
test: more functional tests for types and platforms
bernard-ng Feb 26, 2026
9f24acc
test: wip for functional final tests
bernard-ng Mar 4, 2026
62b6a22
test: finishing functional test setup
bernard-ng Mar 5, 2026
5f3d3c0
test: name normalization
bernard-ng Mar 6, 2026
3a74b0d
ci: allow mysql 5.7 and mariadb to fail
bernard-ng Mar 6, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
39 changes: 39 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: CI
on:
push:
pull_request:
workflow_dispatch:

jobs:
lint:
uses: ./.github/workflows/lint.yml
secrets: inherit

test:
uses: ./.github/workflows/test.yml
secrets: inherit

functional-sqlite3:
needs: test
uses: ./.github/workflows/test-sqlite3.yaml
secrets: inherit

functional-mysql:
needs: test
uses: ./.github/workflows/test-mysql.yaml
secrets: inherit

functional-mariadb:
needs: test
uses: ./.github/workflows/test-mariadb.yaml
secrets: inherit

functional-postgresql:
needs: test
uses: ./.github/workflows/test-postgresql.yaml
secrets: inherit

functional-sqlserver:
needs: test
uses: ./.github/workflows/test-sqlserver.yaml
secrets: inherit
3 changes: 1 addition & 2 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
name: Quality Assurance
on:
workflow_call:
push:
pull_request:
workflow_dispatch:

jobs:
typecheck:
Expand Down
61 changes: 61 additions & 0 deletions .github/workflows/test-mariadb.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: Functional Tests (mariadb)
on:
workflow_call:
workflow_dispatch:

jobs:
test-mariadb:
name: functional (mariadb ${{ matrix.version }})
continue-on-error: true
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
version: ["10.4", "10.5", "10.6", "10.11", "11.4", "11.8", "12.1"]
services:
mariadb:
image: mariadb:${{ matrix.version }}
env:
MARIADB_DATABASE: datazen
MARIADB_USER: datazen
MARIADB_PASSWORD: datazen
MARIADB_ROOT_PASSWORD: root
ports:
- 3306:3306
options: >-
--health-cmd="mariadb-admin ping -h 127.0.0.1 -uroot -proot --silent"
--health-interval=5s
--health-timeout=5s
--health-retries=20

steps:
- name: Checkout Repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 22

- name: Setup Bun
uses: oven-sh/setup-bun@v2

- name: Cache Bun Dependencies
uses: actions/cache@v4
with:
path: ~/.bun/install/cache
key: ${{ runner.os }}-bun-${{ hashFiles('bun.lock') }}
restore-keys: |
${{ runner.os }}-bun-

- name: Install Dependencies
run: bun install --frozen-lockfile

- name: Run Functional Tests (mariadb)
env:
DATAZEN_FUNCTIONAL_PLATFORM: mariadb
DATAZEN_FUNCTIONAL_SERVER_VERSION: ${{ matrix.version }}
DATAZEN_FUNCTIONAL_CONFIG_FILE: ci/github/vitest/mariadb.json
run: bun run test:functional
61 changes: 61 additions & 0 deletions .github/workflows/test-mysql.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: Functional Tests (mysql)
on:
workflow_call:
workflow_dispatch:

jobs:
test-mysql:
name: functional (mysql ${{ matrix.version }})
continue-on-error: ${{ matrix.version == '5.7' }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
version: ["5.7", "8.0", "8.4", "9.6"]
services:
mysql:
image: mysql:${{ matrix.version }}
env:
MYSQL_DATABASE: datazen
MYSQL_USER: datazen
MYSQL_PASSWORD: datazen
MYSQL_ROOT_PASSWORD: root
ports:
- 3306:3306
options: >-
--health-cmd="mysqladmin ping -h 127.0.0.1 -uroot -proot --silent"
--health-interval=5s
--health-timeout=5s
--health-retries=20

steps:
- name: Checkout Repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 22

- name: Setup Bun
uses: oven-sh/setup-bun@v2

- name: Cache Bun Dependencies
uses: actions/cache@v4
with:
path: ~/.bun/install/cache
key: ${{ runner.os }}-bun-${{ hashFiles('bun.lock') }}
restore-keys: |
${{ runner.os }}-bun-

- name: Install Dependencies
run: bun install --frozen-lockfile

- name: Run Functional Tests (mysql)
env:
DATAZEN_FUNCTIONAL_PLATFORM: mysql
DATAZEN_FUNCTIONAL_SERVER_VERSION: ${{ matrix.version }}
DATAZEN_FUNCTIONAL_CONFIG_FILE: ci/github/vitest/mysql.json
run: bun run test:functional
59 changes: 59 additions & 0 deletions .github/workflows/test-postgresql.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
name: Functional Tests (postgresql)
on:
workflow_call:
workflow_dispatch:

jobs:
test-postgresql:
name: functional (postgresql ${{ matrix.version }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
version: ["10", "16", "17"]
services:
postgresql:
image: postgres:${{ matrix.version }}
env:
POSTGRES_DB: datazen
POSTGRES_USER: datazen
POSTGRES_PASSWORD: datazen
ports:
- 5432:5432
options: >-
--health-cmd="pg_isready -U datazen -d datazen"
--health-interval=5s
--health-timeout=5s
--health-retries=20

steps:
- name: Checkout Repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 22

- name: Setup Bun
uses: oven-sh/setup-bun@v2

- name: Cache Bun Dependencies
uses: actions/cache@v4
with:
path: ~/.bun/install/cache
key: ${{ runner.os }}-bun-${{ hashFiles('bun.lock') }}
restore-keys: |
${{ runner.os }}-bun-

- name: Install Dependencies
run: bun install --frozen-lockfile

- name: Run Functional Tests (postgresql)
env:
DATAZEN_FUNCTIONAL_PLATFORM: postgresql
DATAZEN_FUNCTIONAL_SERVER_VERSION: ${{ matrix.version }}
DATAZEN_FUNCTIONAL_CONFIG_FILE: ci/github/vitest/postgresql.json
run: bun run test:functional
40 changes: 40 additions & 0 deletions .github/workflows/test-sqlite3.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Functional Tests (sqlite3)
on:
workflow_call:
workflow_dispatch:

jobs:
test-sqlite3:
name: functional (sqlite3)
runs-on: ubuntu-latest

steps:
- name: Checkout Repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 22

- name: Setup Bun
uses: oven-sh/setup-bun@v2

- name: Cache Bun Dependencies
uses: actions/cache@v4
with:
path: ~/.bun/install/cache
key: ${{ runner.os }}-bun-${{ hashFiles('bun.lock') }}
restore-keys: |
${{ runner.os }}-bun-

- name: Install Dependencies
run: bun install --frozen-lockfile

- name: Run Functional Tests (sqlite3)
env:
DATAZEN_FUNCTIONAL_PLATFORM: sqlite3
DATAZEN_FUNCTIONAL_CONFIG_FILE: ci/github/vitest/sqlite3.json
run: bun run test:functional
69 changes: 69 additions & 0 deletions .github/workflows/test-sqlserver.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
name: Functional Tests (sqlserver)
on:
workflow_call:
workflow_dispatch:

jobs:
test-sqlserver:
name: functional (sqlserver ${{ matrix.version }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- version: "2022"
image_tag: "2022-latest"
- version: "2025"
image_tag: "2025-latest"
services:
sqlserver:
image: mcr.microsoft.com/mssql/server:${{ matrix.image_tag }}
env:
ACCEPT_EULA: Y
MSSQL_SA_PASSWORD: Datazen123!
ports:
- 1433:1433

steps:
- name: Checkout Repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 22

- name: Setup Bun
uses: oven-sh/setup-bun@v2

- name: Cache Bun Dependencies
uses: actions/cache@v4
with:
path: ~/.bun/install/cache
key: ${{ runner.os }}-bun-${{ hashFiles('bun.lock') }}
restore-keys: |
${{ runner.os }}-bun-

- name: Install Dependencies
run: bun install --frozen-lockfile

- name: Wait For SQL Server Port
shell: bash
run: |
for _ in {1..60}; do
if (echo > /dev/tcp/127.0.0.1/1433) >/dev/null 2>&1; then
exit 0
fi
sleep 2
done
echo "SQL Server did not become reachable on port 1433 in time."
exit 1

- name: Run Functional Tests (sqlserver)
env:
DATAZEN_FUNCTIONAL_PLATFORM: sqlserver
DATAZEN_FUNCTIONAL_SERVER_VERSION: ${{ matrix.version }}
DATAZEN_FUNCTIONAL_CONFIG_FILE: ci/github/vitest/sqlserver.json
run: bun run test:functional
16 changes: 12 additions & 4 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
name: Tests
on:
workflow_call:
push:
pull_request:
workflow_dispatch:

jobs:
test:
Expand Down Expand Up @@ -34,6 +33,15 @@ jobs:
- name: Install Dependencies
run: bun install --frozen-lockfile

- name: Run Tests
- name: Run Tests With Coverage
run: |
bun run test
bun run test:coverage

- name: Upload Vitest Coverage Report
if: always()
uses: actions/upload-artifact@v4
with:
name: vitest-coverage-report
path: coverage/
if-no-files-found: ignore
retention-days: 1
Loading
Loading