@@ -13,18 +13,11 @@ go build -o bin/litestream-test ./cmd/litestream-test
1313
1414## Quick Reference
1515
16+ > ** Note:** Some tests have been migrated to Go integration tests in ` tests/integration/ ` . See [ tests/integration/README.md] ( ../../tests/integration/README.md ) for the Go-based test suite.
17+
1618| Script | Purpose | Duration | Status |
1719| --------| ---------| ----------| --------|
1820| verify-test-setup.sh | Environment validation | ~ 5s | ✅ Stable |
19- | test-fresh-start.sh | Fresh database creation | ~ 30s | ✅ Stable |
20- | test-rapid-checkpoints.sh | Checkpoint stress test | ~ 2min | ✅ Stable |
21- | test-wal-growth.sh | Large WAL handling (100MB+) | ~ 5min | ✅ Stable |
22- | test-concurrent-operations.sh | Multi-database concurrent replication | ~ 5min | ✅ Stable |
23- | test-database-integrity.sh | Complex data integrity validation | ~ 3min | ✅ Stable |
24- | test-database-deletion.sh | Database deletion scenarios | ~ 2min | ✅ Stable |
25- | test-replica-failover.sh | Replica failover testing | ~ 3min | ✅ Stable |
26- | test-busy-timeout.sh | Database busy timeout handling | ~ 2min | ✅ Stable |
27- | test-1gb-boundary.sh | SQLite 1GB lock page boundary | ~ 10min | ⚠️ Blocked by #754 |
2821| reproduce-critical-bug.sh | Checkpoint during downtime bug | ~ 2min | 🐛 Reproduces #752 |
2922| test-754-s3-scenarios.sh | Issue #754 S3 vs file replication | ~ 10min | 🐛 Tests #754 |
3023| test-754-restore-focus.sh | Issue #754 restore focus | ~ 5min | 🐛 Tests #754 |
@@ -58,148 +51,6 @@ Verifies that the test environment is properly configured with required binaries
5851- SQLite3 available
5952- Python dependencies for S3 mock
6053
61- ### Core Functionality Tests
62-
63- #### test-fresh-start.sh
64- Tests replication with a fresh database that doesn't exist when Litestream starts.
65-
66- ``` bash
67- ./cmd/litestream-test/scripts/test-fresh-start.sh
68- ```
69-
70- ** Tests:**
71- - Starting Litestream before database exists
72- - Database creation while Litestream is running
73- - Automatic detection of new database
74- - Replication and restore integrity
75-
76- #### test-database-integrity.sh
77- Creates complex data patterns and verifies integrity after restore.
78-
79- ``` bash
80- ./cmd/litestream-test/scripts/test-database-integrity.sh
81- ```
82-
83- ** Tests:**
84- - Complex data patterns (multiple tables, indexes)
85- - SQLite PRAGMA integrity_check
86- - Full database restoration
87- - Data consistency verification
88-
89- #### test-database-deletion.sh
90- Tests scenarios where the source database is deleted during replication.
91-
92- ``` bash
93- ./cmd/litestream-test/scripts/test-database-deletion.sh
94- ```
95-
96- ** Tests:**
97- - Database deletion during active replication
98- - Recovery behavior
99- - Replica consistency
100-
101- #### test-replica-failover.sh
102- Tests replica failover scenarios with multiple replicas.
103-
104- ``` bash
105- ./cmd/litestream-test/scripts/test-replica-failover.sh
106- ```
107-
108- ** Tests:**
109- - Multiple replica configuration
110- - Failover when primary replica fails
111- - Data consistency across replicas
112-
113- ### Stress & Performance Tests
114-
115- #### test-rapid-checkpoints.sh
116- Tests Litestream under rapid checkpoint pressure with continuous writes.
117-
118- ``` bash
119- ./cmd/litestream-test/scripts/test-rapid-checkpoints.sh
120- ```
121-
122- ** Tests:**
123- - 100+ writes/second
124- - Forced rapid checkpoints
125- - Replication under checkpoint pressure
126- - Data integrity under stress
127-
128- ** Key Metrics:**
129- - Checkpoint frequency
130- - WAL file growth
131- - Replication lag
132- - Error rates
133-
134- #### test-wal-growth.sh
135- Tests handling of large WAL files (100MB+) under sustained write load.
136-
137- ``` bash
138- ./cmd/litestream-test/scripts/test-wal-growth.sh
139- ```
140-
141- ** Tests:**
142- - Sustained high write rates (400+ writes/sec)
143- - Large WAL file creation and handling
144- - Checkpoint behavior with large WALs
145- - Replication performance with large data
146-
147- ** Key Findings:**
148- - Successfully handles 100MB+ WAL files
149- - Maintains data integrity
150- - Handles 400+ writes/second
151-
152- #### test-concurrent-operations.sh
153- Tests multiple databases replicating simultaneously with competing operations.
154-
155- ``` bash
156- ./cmd/litestream-test/scripts/test-concurrent-operations.sh
157- ```
158-
159- ** Tests:**
160- - Multiple databases (3-5) replicating concurrently
161- - Mixed read/write operations
162- - Competing checkpoints
163- - Resource contention handling
164-
165- #### test-busy-timeout.sh
166- Tests database busy timeout handling with concurrent access.
167-
168- ``` bash
169- ./cmd/litestream-test/scripts/test-busy-timeout.sh
170- ```
171-
172- ** Tests:**
173- - Concurrent database access
174- - Busy timeout configuration
175- - Lock contention handling
176- - Recovery from busy states
177-
178- ### Boundary & Edge Case Tests
179-
180- #### test-1gb-boundary.sh
181- Tests SQLite's 1GB lock page boundary handling.
182-
183- ``` bash
184- ./cmd/litestream-test/scripts/test-1gb-boundary.sh
185- ```
186-
187- ** Tests:**
188- - Database growth beyond 1GB (with 4KB pages)
189- - Lock page at #262145 properly skipped
190- - Replication across lock page boundary
191- - Restoration integrity after crossing boundary
192-
193- ** Status:** ⚠️ Currently blocked by ltx v0.5.0 flag compatibility issue (#754 )
194-
195- ** Lock Page Numbers by Page Size:**
196- | Page Size | Lock Page # |
197- | -----------| -------------|
198- | 4KB | 262145 |
199- | 8KB | 131073 |
200- | 16KB | 65537 |
201- | 32KB | 32769 |
202-
20354### Bug Reproduction Scripts
20455
20556#### reproduce-critical-bug.sh
0 commit comments