nancy/tests/test_store.py

20 lines
344 B
Python

import pytest
@pytest.fixture
def store():
from nancy import store
s = store.Store.init()
yield s
def test_schema_version_match(store):
from nancy.version import schema_version
cur = store.conn.cursor()
(db_schema_ver,) = cur.execute("PRAGMA user_version;").fetchone()
assert schema_version == db_schema_ver