mirror of
https://github.com/ankitects/anki.git
synced 2025-09-23 08:22:24 -04:00
fix unit tests
This commit is contained in:
parent
1b6cf2bef8
commit
3ab91c600b
2 changed files with 2 additions and 2 deletions
|
@ -60,7 +60,7 @@ def test_remove():
|
||||||
c.load()
|
c.load()
|
||||||
assert c.did == g1
|
assert c.did == g1
|
||||||
# but if we try to get it, we get the default
|
# but if we try to get it, we get the default
|
||||||
assert deck.decks.name(c.did) == "Default"
|
assert deck.decks.name(c.did) == "[no deck]"
|
||||||
# let's create another deck and explicitly set the card to it
|
# let's create another deck and explicitly set the card to it
|
||||||
g2 = deck.decks.id("g2")
|
g2 = deck.decks.id("g2")
|
||||||
c.did = g2; c.flush()
|
c.did = g2; c.flush()
|
||||||
|
|
|
@ -45,7 +45,7 @@ def test_anki2():
|
||||||
"select count() from cards where nid not in (select id from notes)")
|
"select count() from cards where nid not in (select id from notes)")
|
||||||
assert not dst.db.scalar(
|
assert not dst.db.scalar(
|
||||||
"select count() from revlog where cid not in (select id from cards)")
|
"select count() from revlog where cid not in (select id from cards)")
|
||||||
assert dst.fixIntegrity().startswith("Database rebuilt")
|
assert dst.fixIntegrity()[0].startswith("Database rebuilt")
|
||||||
check()
|
check()
|
||||||
# importing should be idempotent
|
# importing should be idempotent
|
||||||
imp.run()
|
imp.run()
|
||||||
|
|
Loading…
Reference in a new issue