Merge branch 'develop' into encryption-rework

Conflicts:
  jrnl/Journal.py
  jrnl/commands.py
This commit is contained in:
Jonathan Wren 2022-10-29 14:41:10 -07:00
commit dda61296e5
No known key found for this signature in database
21 changed files with 164 additions and 96 deletions

View file

@ -64,10 +64,10 @@ Feature: Multiple journals
Then the output should contain "sell my junk on ebay and make lots of money"
Scenario: Don't crash if no default journal is specified using an alternate config
Given the config "bug343.yaml" exists
Given the config "no_default_journal.yaml" exists
And we use the config "basic_onefile.yaml"
When we run "jrnl --cf bug343.yaml a long day in the office"
Then the output should contain "No default journal configured"
When we run "jrnl --cf no_default_journal.yaml a long day in the office"
Then the output should contain "No 'default' journal configured"
Scenario: Don't crash if no file exists for a configured encrypted journal using an alternate config
Given the config "multiple.yaml" exists

View file

@ -612,3 +612,20 @@ Feature: Custom formats
config_path: .+basic_onefile\.yaml
journals:
default: features/journals/basic_onefile\.journal
Scenario: Export journal list to formats with no default journal
Given we use the config "no_default_journal.yaml"
When we run "jrnl --list"
Then the output should match
Journals defined in config \(.+no_default_journal\.yaml\)
\* simple -> features/journals/simple\.journal
\* work -> features/journals/work\.journal
When we run "jrnl --list --format json"
Then the output should match
{"config_path": ".+no_default_journal\.yaml", "journals": {"simple": "features/journals/simple\.journal", "work": "features/journals/work\.journal"}}
When we run "jrnl --list --format yaml"
Then the output should match
config_path: .+no_default_journal\.yaml
journals:
simple: features/journals/simple\.journal
work: features/journals/work\.journal

View file

@ -80,9 +80,9 @@ Feature: Multiple journals
2012-07-23 09:00 sell my junk on ebay and make lots of money
Scenario: Don't crash if no default journal is specified
Given we use the config "bug343.yaml"
Given we use the config "no_default_journal.yaml"
When we run "jrnl a long day in the office"
Then the output should contain "No default journal configured"
Then the output should contain "No 'default' journal configured"
Scenario: Don't crash if no file exists for a configured encrypted journal
Given we use the config "multiple.yaml"