Skip to content

Commit de47cb5

Browse files
committed
Add extension loading test to Makefile; add missing sqlite3 header file
1 parent e547d50 commit de47cb5

File tree

3 files changed

+13976
-4
lines changed

3 files changed

+13976
-4
lines changed

.github/workflows/main.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -265,8 +265,8 @@ jobs:
265265
with:
266266
submodules: ${{ !contains(matrix.make, 'OMIT_LOCAL_ENGINE=1') && 'true' || 'false' }}
267267

268-
- name: windows install sqlite (remote builds)
269-
if: matrix.name == 'windows' && matrix.variant == 'remote'
268+
- name: windows install sqlite
269+
if: matrix.name == 'windows'
270270
run: choco install sqlite -y
271271

272272
- uses: msys2/setup-msys2@v2.27.0

Makefile

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -382,9 +382,13 @@ $(TARGET): $(C_OBJECTS) $(LLAMA_LIBS) | $(DIST_DIR)
382382

383383
# Build and run tests
384384
.PHONY: test
385-
test: $(BUILD_DEPS) $(BUILD_DIR)/unittest
386-
@echo "Running tests..."
385+
test: $(BUILD_DEPS) $(TARGET) $(BUILD_DIR)/unittest
386+
@echo "Running unit tests..."
387387
@$(BUILD_DIR)/unittest
388+
@echo ""
389+
@echo "Testing extension loading..."
390+
@sqlite3 :memory: ".load $(TARGET)" "SELECT 'memory_version: ' || memory_version();"
391+
@echo "Extension loading test passed!"
388392

389393
# Unit test needs SQLITE_CORE to use direct SQLite calls (not extension API)
390394
TEST_DEFINES := -DSQLITE_CORE

0 commit comments

Comments
 (0)