diff --git a/tests/bdd/features/datetime.feature b/tests/bdd/features/datetime.feature index 0b5ce472..1b9d00b9 100644 --- a/tests/bdd/features/datetime.feature +++ b/tests/bdd/features/datetime.feature @@ -69,7 +69,7 @@ Feature: Reading and writing to journal with custom date formats Scenario: Writing an entry at the prompt with custom date Given we use the config "little_endian_dates.yaml" - When we run "jrnl" and pipe "2013-05-10: I saw Elvis. He's alive." + When we run "jrnl" and type "2013-05-10: I saw Elvis. He's alive." Then we should get no error When we run "jrnl -999" Then the output should contain "10.05.2013 09:00 I saw Elvis." diff --git a/tests/bdd/features/override.feature b/tests/bdd/features/override.feature index ef761d9c..90b7e40b 100644 --- a/tests/bdd/features/override.feature +++ b/tests/bdd/features/override.feature @@ -3,7 +3,7 @@ Feature: Implementing Runtime Overrides for Select Configuration Keys Scenario: Override configured editor with built-in input === editor:'' Given we use the config "basic_encrypted.yaml" And we use the password "test" if prompted - When we run "jrnl --config-override editor ''" and pipe + When we run "jrnl --config-override editor ''" and type This is a journal entry Then the stdin prompt should have been called And the editor should not have been called diff --git a/tests/bdd/features/write.feature b/tests/bdd/features/write.feature index 0c860b54..ede1934b 100644 --- a/tests/bdd/features/write.feature +++ b/tests/bdd/features/write.feature @@ -172,7 +172,7 @@ Feature: Writing new entries. Scenario Outline: Writing an entry at the prompt (no editor) should store the entry Given we use the config "" And we use the password "bad doggie no biscuit" if prompted - When we run "jrnl" and pipe "25 jul 2013: I saw Elvis. He's alive." + When we run "jrnl" and type "25 jul 2013: I saw Elvis. He's alive." Then we should get no error When we run "jrnl -on '2013-07-25'" Then the output should contain "2013-07-25 09:00 I saw Elvis." diff --git a/tests/lib/fixtures.py b/tests/lib/fixtures.py index 7f510585..3080f2ae 100644 --- a/tests/lib/fixtures.py +++ b/tests/lib/fixtures.py @@ -273,8 +273,8 @@ def stdin_input(request, is_tty): @fixture def is_tty(input_method): - assert input_method in ["", "enter", "pipe"] - return input_method != "pipe" + assert input_method in ["", "enter", "pipe", "type"] + return input_method not in ["pipe", "type"] @fixture diff --git a/tests/lib/when_steps.py b/tests/lib/when_steps.py index 6e60f61c..bc1d742d 100644 --- a/tests/lib/when_steps.py +++ b/tests/lib/when_steps.py @@ -21,7 +21,7 @@ def when_we_change_directory(directory_name): # These variables are used in the `@when(re(...))` section below command = '(?P[^"]*)' -input_method = "(?Penter|pipe)" +input_method = "(?Penter|pipe|type)" all_input = '("(?P[^"]*)")'