[Application] Table _ exists and doesn't match db format, trying __1
[Application] keys mismatch
messages in the test suite, which could happen if the test suite was run in relatively quick succession across db-format changes.
cleanup sqlitedb temporary db file after tests
Wouldn't it be better for that file to be created with tempfile instead of having a fixed 'tasks.db' name? That way, a stray /tmp/tasks.db file can't cause problems. A scenario where that could occur: user 1 runs the suite before this cleanup fix or with a crash that for some reason prevents cleanup, then user 2 on the same machine can't run the tests anymore because he can't create/write to /tmp/tasks.db. Making that filename with the tempfile machinery will prevent this, it can be simply a module-level global created in setup() and deleted in teardown() just like now, but with a random name made by tempfile.
Sensible, I'll write that up now.
Awesome, thx. I'll review and merge quickly.
generate random task db in tests
avoids potential conflict with simultaneous test runs
per review by @fperez
setup() now creates full temp file.
Perfect, thanks! Merging now.