mirror of
https://github.com/jrnl-org/jrnl.git
synced 2025-06-28 05:26:13 +02:00
Prevent filtered delete from deleting journal (#935)
* Prevent filtered deletion from deleting entire journal #932 and add lots of deletion tests * Undo removal of deletion feature * Use more performant deletion
This commit is contained in:
parent
cfbebe0d38
commit
d9ebfe852b
6 changed files with 191 additions and 17 deletions
|
@ -257,6 +257,13 @@ def check_journal_content(context, text, journal_name="default"):
|
|||
assert text in journal, journal
|
||||
|
||||
|
||||
@then('the journal should not contain "{text}"')
|
||||
@then('journal "{journal_name}" should not contain "{text}"')
|
||||
def check_not_journal_content(context, text, journal_name="default"):
|
||||
journal = read_journal(journal_name)
|
||||
assert text not in journal, journal
|
||||
|
||||
|
||||
@then('journal "{journal_name}" should not exist')
|
||||
def journal_doesnt_exist(context, journal_name="default"):
|
||||
with open(install.CONFIG_FILE_PATH) as config_file:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue