mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
Fix database initialization in test_term.py
Signed-off-by: Kevin Morris <kevr@0cost.org>
This commit is contained in:
parent
718fa48a5c
commit
e1ab02c2bf
1 changed files with 6 additions and 1 deletions
|
@ -2,10 +2,15 @@ import pytest
|
||||||
|
|
||||||
from sqlalchemy.exc import IntegrityError
|
from sqlalchemy.exc import IntegrityError
|
||||||
|
|
||||||
from aurweb.db import create, delete
|
from aurweb.db import create, delete, get_engine
|
||||||
from aurweb.models.term import Term
|
from aurweb.models.term import Term
|
||||||
|
|
||||||
|
|
||||||
|
@pytest.fixture(autouse=True)
|
||||||
|
def setup():
|
||||||
|
get_engine()
|
||||||
|
|
||||||
|
|
||||||
def test_term_creation():
|
def test_term_creation():
|
||||||
term = create(Term, Description="Term description",
|
term = create(Term, Description="Term description",
|
||||||
URL="https://fake_url.io")
|
URL="https://fake_url.io")
|
||||||
|
|
Loading…
Add table
Reference in a new issue