fix helpers test
This commit is contained in:
@@ -12,10 +12,17 @@ test = DbTestModel(id=1, name="test", value="yes")
|
|||||||
@pytest.mark.asyncio
|
@pytest.mark.asyncio
|
||||||
async def test_helpers_insert_query():
|
async def test_helpers_insert_query():
|
||||||
q = insert_query("test_helpers_query", test)
|
q = insert_query("test_helpers_query", test)
|
||||||
assert q == "INSERT INTO test_helpers_query (id, name, value) VALUES (?, ?, ?)"
|
assert (
|
||||||
|
q == "INSERT INTO test_helpers_query (id, name, value) "
|
||||||
|
"VALUES (:id, :name, :value)"
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.asyncio
|
@pytest.mark.asyncio
|
||||||
async def test_helpers_update_query():
|
async def test_helpers_update_query():
|
||||||
q = update_query("test_helpers_query", test)
|
q = update_query("test_helpers_query", test)
|
||||||
assert q == "UPDATE test_helpers_query SET id = ?, name = ?, value = ? WHERE id = ?"
|
assert (
|
||||||
|
q == "UPDATE test_helpers_query "
|
||||||
|
"SET id = :id, name = :name, value = :value "
|
||||||
|
"WHERE id = :id"
|
||||||
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user