Skip to content

DST test for Engine.#5424

Open
Shubham8287 wants to merge 27 commits into
masterfrom
shub/new-dst
Open

DST test for Engine.#5424
Shubham8287 wants to merge 27 commits into
masterfrom
shub/new-dst

Conversation

@Shubham8287

@Shubham8287 Shubham8287 commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

Description of Changes

Sets the layout for DST tests and adds a basic test for spacetimedb-engine via engine mod.

Engine Test:

  • Generates random schemas with tables, indexes, unique constraints, primary keys, and sequence columns.
  • Drives randomized interactions: begin mutable tx, insert, delete, commit, and replay.
  • Uses an in-memory commitlog/durability implementation so replay can simulate shutdown/reopen without
    disk.
  • Define properties, check them while processing interactions.

Upnext:

  1. Fault-injection in commitlog.
  2. Multi connection support (async api call-ing is not needed for engine test as we expect caller/module to also be single-threaded).
  3. Increase API coverage of engine, especially schema migrations.
  4. Add more properties like check for sequences.
  5. simulated Snapshots.

Further more integration tests like standalone, replication can be added by implementing traits.rs similar to engine.

looking to get general feedback on overall design for test effectiveness and maintainability.

API and ABI breaking changes

NA

Expected complexity level and risk

It's a test addition.

@Shubham8287 Shubham8287 changed the title DST test for relationaldb. DST test for Engine. Jun 22, 2026
@@ -0,0 +1,494 @@
use std::{

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

copied from commitlog::repo::mem.rs, It is copied as we will be putting faults in this version later.

@Shubham8287 Shubham8287 self-assigned this Jun 24, 2026
@Shubham8287 Shubham8287 mentioned this pull request Jun 24, 2026
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants