summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2021-09-15 20:02:46 +0300
committerLars Wirzenius <liw@liw.fi>2021-09-15 20:02:46 +0300
commit4da2a60a5db498c9605497d8709b1a0ea5a92045 (patch)
treeed10a6a15a1a276176b030a443e4ff36df04849f
parenteda39c3aaa01298788b13edcd96adbc32ff8df62 (diff)
downloadjt2-4da2a60a5db498c9605497d8709b1a0ea5a92045.tar.gz
fix: add impl to the bindings file, for current Subplot
Sponsored-by: author
-rw-r--r--subplot/jt.yaml84
1 files changed, 63 insertions, 21 deletions
diff --git a/subplot/jt.yaml b/subplot/jt.yaml
index dc2a666..90ca3ef 100644
--- a/subplot/jt.yaml
+++ b/subplot/jt.yaml
@@ -1,65 +1,107 @@
- given: "an installed jt"
- function: install_jt
+ impl:
+ python:
+ function: install_jt
- given: "an executable script {filename}"
- function: create_script
+ impl:
+ python:
+ function: create_script
- when: I invoke jt init (?P<dirname>\S+) (?P<journalname>\S+) "(?P<title>.*)"
regex: true
- function: run_jt_init
+ impl:
+ python:
+ function: run_jt_init
- when: I invoke jt list-journals
- function: run_jt_list_journals
+ impl:
+ python:
+ function: run_jt_list_journals
- when: I invoke jt is-journal {dirname}
- function: run_jt_is_journal
+ impl:
+ python:
+ function: run_jt_is_journal
- when: I invoke jt new "{title:text}" --editor=none --dirname={dirname}
- function: run_jt_new
+ impl:
+ python:
+ function: run_jt_new
- when: "I invoke jt edit --editor={editor} --dirname={dirname}"
regex: false
- function: run_jt_edit
+ impl:
+ python:
+ function: run_jt_edit
- when: I invoke jt finish --dirname={dirname}
- function: run_jt_finish
+ impl:
+ python:
+ function: run_jt_finish
- when: I edit draft {draftno} in {dirname} to also contain "{text}"
- function: edit_draft
+ impl:
+ python:
+ function: edit_draft
- then: output contains "(?P<pattern>.*)"
regex: true
- function: output_contains
+ impl:
+ python:
+ function: output_contains
- then: there are no drafts in {dirname}
- function: journal_has_no_drafts
+ impl:
+ python:
+ function: journal_has_no_drafts
- then: there is one draft in {dirname}
- function: journal_has_one_draft
+ impl:
+ python:
+ function: journal_has_one_draft
- then: there are two drafts in {dirname}
- function: journal_has_two_drafts
+ impl:
+ python:
+ function: journal_has_two_drafts
- then: draft {draftno} in {dirname} contains "{pattern:text}"
- function: draft_contains_string
+ impl:
+ python:
+ function: draft_contains_string
- then: draft {draftno} in {dirname} links to "{topic}"
- function: draft_links_to_topic
+ impl:
+ python:
+ function: draft_links_to_topic
- then: there are no journal entries in {dirname}
- function: journal_has_no_entries
+ impl:
+ python:
+ function: journal_has_no_entries
- then: there is one journal entry in {dirname}, at {variable}
- function: journal_has_one_entry
+ impl:
+ python:
+ function: journal_has_one_entry
- then: there are two journal entries in {dirname}, at {variable1} and {variable2}
- function: journal_has_two_entries
+ impl:
+ python:
+ function: journal_has_two_entries
- then: journal entry <{variable}> contains "{pattern:text}"
- function: file_contains
+ impl:
+ python:
+ function: file_contains
- then: file name <{varname}> ends with {suffix}
- function: file_name_has_suffix
+ impl:
+ python:
+ function: file_name_has_suffix
- then: there are no uncommitted changes in {dirname}
- function: git_is_clean
+ impl:
+ python:
+ function: git_is_clean