summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--fable-arch.md20
-rw-r--r--fable-arch.yaml3
2 files changed, 19 insertions, 4 deletions
diff --git a/fable-arch.md b/fable-arch.md
index 2f29edf..4070b52 100644
--- a/fable-arch.md
+++ b/fable-arch.md
@@ -428,12 +428,20 @@ other resource constraints.
## The simplest possible scenario
-This tests that Fable can run a simplest possible scenario
-successfully. The test is based on generating the test program from an
-input file, running the test program, and examining the log file.
+This tests that Fable can build a PDF and an HTML document, and
+execute a simple scenario successfully. The test is based on
+generating the test program from an input file, running the test
+program, and examining the log file.
```fable
given files simple.md, simple.yaml, and simple.py
+
+when I run ftt-docgen --pdf simple.md
+then file simple.pdf exists
+
+when I run ftt-docgen --html simple.md
+then file simple.html exists
+
when I run ftt-codegen --run simple.md
then log file says scenario "Simple" was run
and log file says step "given precondition foo" was run
@@ -486,15 +494,18 @@ Markdown file successfully.
```fable
given files two.md, two.yaml, and two.py
when I run ftt-codegen --run two.md
+
then log file says scenario "First" was run
and log file says step "given precondition foo" was run
and log file says step "when I do bar" was run
and log file says step "then bar was done" was run
+
then log file says scenario "Second" was run
and log file says step "given precondition foo" was run
and log file says step "when I do bar" was run
and log file says step "then bar was done" was run
-and program finished successfully
+
+and test program finished successfully
```
### two.md—markdown file
@@ -549,6 +560,7 @@ This tests that Fable can run handle a scenario step failing.
```fable
given files fail.md, fail.yaml, and fail.py
when I run ftt-codegen --run fail.md
+
then log file says scenario "Fail" was run
and log file says step "given precondition foo" was run
and log file says step "then bar was done" failed
diff --git a/fable-arch.yaml b/fable-arch.yaml
index 5dc8278..0777104 100644
--- a/fable-arch.yaml
+++ b/fable-arch.yaml
@@ -1,5 +1,8 @@
- given: files (?P<md>\S+), (?P<yaml>\S+), and (?P<py>\S+)
+- when: I run ftt-docgen --html (?P<filename>\S+)
+- when: I run ftt-docgen --pdf (?P<filename>\S+)
- when: I run ftt-codegen --run (?P<filename>\S+)
+- then: file (?P<filename>\S+) exists
- then: log file says scenario "(?P<name>.+)" was run
- then: log file says step "(?P<keyword>given|when|then) (?P<name>.+)" was run
- then: program finished successfully