• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

joaoh82 / rust_sqlite / 25306044810
65%

Build:
DEFAULT BRANCH: main
Ran 04 May 2026 07:18AM UTC
Jobs 1
Files 45
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

04 May 2026 07:14AM UTC coverage: 61.422% (+1.7%) from 59.771%
25306044810

push

github

web-flow
feat(ddl): DEFAULT clause, DROP TABLE/INDEX, ALTER TABLE (#86)

* feat(ddl): DEFAULT clause for CREATE TABLE columns

Honour `DEFAULT <literal>` on column definitions. Literal expressions
only — text, integer, real, boolean, NULL, and unary +/- on numerics.
Function calls and other non-literal expressions are rejected at
CREATE TABLE time so users see the limit upfront.

Default fires only when the column is omitted from INSERT (matches
SQLite — explicit NULL is preserved as NULL). Persists through save
and reopen via `table_to_create_sql` emitting the DEFAULT clause and
`parse_create_sql` propagating it back into Column.

Refactors `CreateQuery::new`'s per-column body into a free
`parse_one_column` helper so ALTER TABLE ADD COLUMN can reuse the
same column-shape parsing in a follow-up commit.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* feat(ddl): DROP TABLE and DROP INDEX

Mirror SQLite's DROP semantics on the in-memory engine:

- DROP TABLE [IF EXISTS] <name>; — single target, rejects the reserved
  catalog name `sqlrite_master`. The dropped table's
  secondary/HNSW/FTS indexes ride along with the Table struct.
- DROP INDEX [IF EXISTS] <name>; — single target. Walks every table
  looking across all three index families. Refuses to drop
  auto-indexes (`sqlrite_autoindex_*` from PK / UNIQUE columns) —
  same rule SQLite enforces.

The full-rebuild-on-save pager naturally cascades drops: the next
`save_database` call regenerates `sqlrite_master` from current state
and simply doesn't write rows for the dropped objects. Pages
previously occupied become orphans on disk (no free-list yet — file
size doesn't shrink until a future VACUUM lands).

Replaces the existing `process_command_unsupported_statement_test`
which used DROP TABLE as the canary; switched to CREATE VIEW since
DROP TABLE now executes.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* feat(ddl): ALTER TABLE — RENAME / ADD COLUMN / DROP COL... (continued)

649 of 766 new or added lines in 5 files covered. (84.73%)

1 existing line in 1 file now uncovered.

6991 of 11382 relevant lines covered (61.42%)

1.18 hits per line

Uncovered Changes

Lines Coverage ∆ File
42
66.75
0.46% src/sql/db/table.rs
25
92.38
-0.13% src/sql/mod.rs
19
75.36
0.49% src/sql/executor.rs
19
75.57
7.57% src/sql/parser/create.rs
12
90.04
0.19% src/sql/pager/mod.rs

Coverage Regressions

Lines Coverage ∆ File
1
75.57
7.57% src/sql/parser/create.rs
Jobs
ID Job ID Ran Files Coverage
1 25306044810.1 04 May 2026 07:18AM UTC 45
61.42
GitHub Action Run
Source Files on build 25306044810
  • Tree
  • List 45
  • Changed 5
  • Source Changed 0
  • Coverage Changed 5
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • 00d1e4e2 on github
  • Prev Build on main (#25291286945)
  • Next Build on main (#25306724518)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc