limbo/testing
Jussi Saurio 7948259d37
Some checks are pending
Build and push limbo-sim image / deploy (push) Waiting to run
C compat Tests / test (push) Waiting to run
Dart/Flutter / precompile (blacksmith-4vcpu-ubuntu-2404) (push) Waiting to run
Dart/Flutter / precompile (macOS-latest) (push) Waiting to run
Dart/Flutter / test (windows-latest) (push) Waiting to run
Dart/Flutter / publish (push) Waiting to run
Dart/Flutter / test (blacksmith-4vcpu-ubuntu-2404) (push) Waiting to run
Dart/Flutter / precompile (windows-latest) (push) Waiting to run
Java Tests / test (push) Waiting to run
Run long fuzz tests and stress test / run-long-tests (push) Waiting to run
Run long fuzz tests and stress test / simple-stress-test (push) Waiting to run
Build & publish @tursodatabase/database / db-bindings-aarch64-apple-darwin - node@20 (push) Waiting to run
Build & publish @tursodatabase/database / db-bindings-aarch64-unknown-linux-gnu - node@20 (push) Waiting to run
Build & publish @tursodatabase/database / db-bindings-wasm32-wasip1-threads - node@20 (push) Waiting to run
Build & publish @tursodatabase/database / db-bindings-x86_64-pc-windows-msvc - node@20 (push) Waiting to run
Build & publish @tursodatabase/database / db-bindings-x86_64-unknown-linux-gnu - node@20 (push) Waiting to run
Build & publish @tursodatabase/database / sync-bindings-aarch64-apple-darwin - node@20 (push) Waiting to run
Build & publish @tursodatabase/database / sync-bindings-aarch64-unknown-linux-gnu - node@20 (push) Waiting to run
Build & publish @tursodatabase/database / sync-bindings-wasm32-wasip1-threads - node@20 (push) Waiting to run
Build & publish @tursodatabase/database / sync-bindings-x86_64-pc-windows-msvc - node@20 (push) Waiting to run
Build & publish @tursodatabase/database / sync-bindings-x86_64-unknown-linux-gnu - node@20 (push) Waiting to run
Build & publish @tursodatabase/database / Test DB bindings on Linux-x64-gnu - node@20 (push) Blocked by required conditions
Build & publish @tursodatabase/database / Test DB bindings on browser@20 (push) Blocked by required conditions
Build & publish @tursodatabase/database / Publish (push) Blocked by required conditions
Python / configure-strategy (push) Waiting to run
Python / test (push) Blocked by required conditions
Python / lint (push) Waiting to run
Python / linux (x86_64) (push) Waiting to run
Python / macos-arm64 (aarch64) (push) Waiting to run
Python / sdist (push) Waiting to run
Python / Release (push) Blocked by required conditions
Rust / clippy (push) Waiting to run
Rust / cargo-fmt-check (push) Waiting to run
Rust / build-native (blacksmith-4vcpu-ubuntu-2404) (push) Waiting to run
Rust / build-native (macos-latest) (push) Waiting to run
Rust / build-native (windows-latest) (push) Waiting to run
Rust Benchmarks+Nyrkiö / tpc-h-criterion (push) Waiting to run
Rust Benchmarks+Nyrkiö / tpc-h (push) Waiting to run
Rust Benchmarks+Nyrkiö / vfs-bench-compile (push) Waiting to run
Rust / simulator (push) Waiting to run
Rust / test-limbo (push) Waiting to run
Rust / test-sqlite (push) Waiting to run
Rust Benchmarks+Nyrkiö / bench (push) Waiting to run
Rust Benchmarks+Nyrkiö / clickbench (push) Waiting to run
Merge 'optimizer: optimize range scans to use upper and lower bounds more efficiently' from Jussi Saurio
Made a new PR based on @sivukhin 's PR #2869 that had a lot of
conflicts. You can check out the PR description from there.
## The main idea is:
Before, if we had an index on `x` and had a query like `WHERE x > 100
and x < 200`, the plan would be something like:
```
- Seek to first row where x > 100
- Then, for every row, discard the row if x >= 200
```
This is highly wasteful in cases where there are a lot of rows where `x
>= 200`. Since our index is sorted on `x`, we know that once we hit the
_first_ row where `x >= 200`, we can stop iterating entirely.
So, the new plan is:
```
- Seek to first row where x > 100
- Then, iterate rows until x >= 200, and then stop
```
This also improves the situation for multi-column indexes. Imagine index
on `(x,y)` and a condition like `WHERE x = 100 and y > 100 and y < 200`.
Before, the plan was:
```
- Seek to first row where x=100 and y > 100
- Then, iterate rows while x = 100 and discard the row if y >= 200
- Stop when x > 100
```
This also suffers from a problem where if there are a lot of rows where
`x=100` and `y >= 200`, we go through those rows unnecessarily. The new
plan is:
```
- Seek to first row where x=100 and y > 100
- Then, iterate rows while x = 100 and y < 200
- Stop when either x > 100 or y >= 200
```
Which prevents us from iterating rows like `x=100, y = 666`
unnecessarily because we know the index is sorted on `(x,y)` - once we
hit any row where `x>100` OR `x=100, y >= 200`, we can stop.

Closes #3644
2025-10-09 14:47:15 +03:00
..
cli_tests rename limbo -> turso 2025-09-29 22:33:39 -03:00
javascript fix tests in testing/javascript 2025-09-25 12:07:57 +04:00
sqlite3 testing/sqlite3: Update all.test 2025-08-02 13:00:18 +03:00
sqlite_test_ext Implement xBestIndex for kvstore.c 2025-08-04 19:25:11 +02:00
test_files CSV import fixes 2025-07-15 16:44:11 +03:00
unreliable-libc Add short writes to pwritev in faulty_libc. 2025-10-03 18:35:03 +02:00
wal testing: Add test database + WAL file 2024-08-03 12:16:34 +03:00
affinity.test Add regression test for rowid affinity 2025-10-02 14:31:22 -04:00
agg-functions.test printf truncates floats 2025-09-28 21:16:33 +05:30
all.test Remove unnecessary FK resolution on schema parsing 2025-10-07 16:45:16 -04:00
alter_column.test feat+fix: add tests and restrict altering some constraints 2025-08-30 03:43:31 -03:00
alter_table.test Add TCL regression test for DROP COLUMN issue #3448 2025-09-30 10:04:31 +03:00
analyze.test ANALYZE creates sqlite_stat1 if it doesn't exist 2025-08-24 13:35:39 -07:00
attach.test Add regression test for #3540 attach issue 2025-10-06 21:33:42 -04:00
autoincr.test update seq table onconflict nothing too and refactor logic into seperate function 2025-09-23 11:41:52 +05:30
boolean.test Fix incompatibility AND Expression 2025-04-13 22:38:43 -03:00
changes.test Add test to ensure we return proper changes() 2025-09-22 19:18:18 -04:00
cmdlineshell.test refactor(testing): move .table tests to shelltests.py 2024-12-18 09:10:37 +02:00
coalesce.test extend TCL tests for COALESCE 2025-02-09 22:01:33 +04:00
collate.test Collate: add more TCL tests 2025-10-02 21:49:33 +03:00
compare.test testing/compare.test: Clean up tests by using in-memory database 2025-09-10 14:14:46 +03:00
concat.test Added Concat Opcode 2025-01-21 00:29:23 +05:30
create_index.test Fix: actually enforce uniqueness in CREATE UNIQUE INDEX 2025-10-03 22:58:42 +03:00
create_table.test add more tests 2025-10-09 08:28:59 +05:30
default_value.test fix(3301): Remove identifier assert assumption 2025-09-29 22:33:21 -03:00
delete.test chore: enable indexes by default 2025-08-01 15:44:56 +03:00
drop_index.test Including tests 2025-08-05 21:18:52 -07:00
drop_table.test chore: enable indexes by default 2025-08-01 15:44:56 +03:00
foreign_keys.test Implement proper handling of deferred foreign keys 2025-10-07 16:45:23 -04:00
gen-bigass-database.py add gen-bigass-database.py 2025-09-08 13:05:33 -04:00
gen-database.py ruff lint fix 2025-06-20 15:59:03 -03:00
glob.test testing/glob.test: Run in-memory mode 2025-07-07 11:09:54 +03:00
groupby.test fix: result columns have varying binding precedence 2025-09-25 08:07:37 +03:00
insert.test Don't panic if doing INSERT INTO ... SELECT rowid 2025-10-03 23:12:24 +03:00
integrity_check.test integrity test with tcl 2025-06-11 18:39:06 +02:00
join.test Fix: JOIN USING should pick columns from left table, not right 2025-10-02 06:56:52 +03:00
json.test implement json_tree 2025-09-23 14:22:02 -04:00
like.test Escape character is ignored in LIKE function #1051 2025-03-01 18:32:09 +01:00
literal.test handle int64 overflow by f64 2025-05-08 22:22:55 +08:00
materialized_views.test fix mviews with re-insertion of data with the same key 2025-10-06 20:12:49 -05:00
math.test is_nonnull returns true on 1 / 0 2025-09-17 14:50:15 +07:00
null.test Fix TCL test 2025-09-01 11:39:43 -04:00
offset.test Add test for ungrouped aggregate with offset 2025-09-25 16:47:26 -04:00
orderby.test fix: result columns have varying binding precedence 2025-09-25 08:07:37 +03:00
partial_idx.test Add some tests for UPSERT with partial indexes 2025-09-20 18:32:50 -04:00
pragma.test Fix pragma module list tests 2025-08-11 12:13:47 -04:00
pyproject.toml Add bench-sqlite script and makefile command for benchmarking an I/O backend against sqlite3 2025-08-18 15:11:29 -04:00
README.md Add framework for testing extensions in TCL 2025-08-15 21:06:27 +02:00
rollback.test chore: enable indexes by default 2025-08-01 15:44:56 +03:00
scalar-functions-datetime.test core(datetime): added implementation of ceiling modifier to datetime 2025-08-23 22:59:08 -05:00
scalar-functions-printf.test core/testing: Basic sqlite compatibility tests for printf() 2025-09-30 01:02:12 -03:00
scalar-functions.test add test 2025-09-30 15:26:13 -03:00
select.test Merge 'optimizer: optimize range scans to use upper and lower bounds more efficiently' from Jussi Saurio 2025-10-09 14:47:15 +03:00
subquery.test chore: enable indexes by default 2025-08-01 15:44:56 +03:00
tester.tcl Add framework for testing extensions in TCL 2025-08-15 21:06:27 +02:00
testing.db fix: revert changes on testing dbs 2025-08-11 08:42:08 -03:00
testing_norowidalias.db fix: revert changes on testing dbs 2025-08-11 08:42:08 -03:00
testing_small.db implement is and is not where constraints 2025-01-31 23:01:49 -05:00
testing_user_version_10.db Add read implementation of user_version pragma with ReadCookie opcode 2025-02-07 09:23:48 -05:00
time.test extensions/time: normalize offset_sec 2025-02-19 21:25:14 +08:00
total-changes.test Add total_changes test 2025-06-07 17:37:36 +09:00
transactions.test Implement deferred transactions 2025-03-17 10:01:00 -03:00
update.test Add regression test for explicit rowid update 2025-09-25 19:16:20 -04:00
upsert.test fix upsert conflict handling 2025-09-30 22:39:55 +04:00
values.test improve handling of double quotes 2025-07-18 10:39:02 -05:00
vector.test testing: Add few TCL tests for vector extensions 2025-01-28 14:24:09 +02:00
views.test Circle detection for views 2025-10-01 02:12:21 +07:00
vtab.test Extract TVF-related tests to TCL 2025-08-15 21:06:30 +02:00
where.test fix: result columns have varying binding precedence 2025-09-25 08:07:37 +03:00
window.test Add support for window functions 2025-09-13 11:12:44 +02:00

Turso Testing

Testing Extensions

When adding tests for extensions, please follow these guidelines:

  • Tests that verify the internal logic or behavior of a particular extension should go into cli_tests/extensions.py.
  • Tests that verify how extensions interact with the database engine, such as virtual table handling, should be written in TCL (see vtab.test as an example).

To check which extensions are available in TCL, or to add a new one, refer to the tester.tcl file and look at the extension_map.