Create encrypted journal

Add failing test for configuring an encrypted journal
Overload open for EncryptedJournal

This avoids the execution path that calls EncryptedJournal._create()
without a password parameter. It results in duplication of code that
requests and stores a password, which should be factored out in a
subsequent change.

Modify test to test for returned strings

The entered string for the password is not being used by the test and I
don't understand why.

Use util wrapper for getpass

This allows for tests to run without prompting for user input.
This commit is contained in:
Greg Bodnar 2019-08-03 16:48:10 +12:00
parent b260ff35b9
commit 623fa6c307
3 changed files with 41 additions and 0 deletions

View file

@ -9,6 +9,9 @@ journals:
ideas: features/journals/nothing.journal
simple: features/journals/simple.journal
work: features/journals/work.journal
new_encrypted:
encrypt: true
journal: features/journals/new_encrypted.journal
linewrap: 80
password: ''
tagsymbols: '@'