mirror of
https://github.com/jrnl-org/jrnl.git
synced 2025-07-06 00:16:13 +02:00
Add test for empty stdin input
This commit is contained in:
parent
91dcb812d7
commit
455261c55e
2 changed files with 18 additions and 1 deletions
|
@ -20,12 +20,20 @@ Feature: Basic reading and writing to a journal
|
|||
When we run "jrnl -n 1"
|
||||
Then the output should contain "2013-07-23 09:00 A cold and stormy day."
|
||||
|
||||
# Note that the expected output is actually "[Nothing saved to file]" but due to mocking limitations, we expect no output here.
|
||||
Scenario: Writing an empty entry from the editor
|
||||
Given we use the config "editor.yaml"
|
||||
When we open the editor and enter ""
|
||||
Then we should see the message "[Nothing saved to file]"
|
||||
|
||||
Scenario: Writing an empty entry from the command line
|
||||
Given we use the config "basic.yaml"
|
||||
When we run "jrnl ''"
|
||||
Then we should get no error
|
||||
And the unstripped output should be
|
||||
"""
|
||||
|
||||
"""
|
||||
|
||||
Scenario: Filtering for dates
|
||||
Given we use the config "basic.yaml"
|
||||
When we run "jrnl -on 2013-06-10 --short"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue