Replace magic and complexity with Unix and simplicity.
Tad Better Behavior
Tad Better Behavior (TBB) is a fresh take on
- Markdown spec parsing
- Suite / scenario / step hierarchy
- Tagging and filtering (
--only,--excludeCLI flags) - Rich text and structured JSON output formats
- Condensed output for successful steps
- Observations system (text, code snippet, link, and more)
- Source information tracking (file paths, line numbers)
- Report status indicators (✓, x, ?, ⊞, ⊠, □)
- Self-check - of course we use TBB to verify correctness of TBB
TBB is inspired by Gauge from Thoughtworks, but aims to be simpler and more flexible. It sends steps from Markdown documents to custom interpreters. Interpreters are simple
- Python,
- Clojure (Babashka),
- and Nushell.
It's relatively easy to port those helpers to other languages and we are always happy to help.
Typical TBB workflow
- Take free form notes during a client meeting or design session (I use pen and paper, but you can go straight to markdown)
- Later structure your notes into
spec document(s) with scenarios describing use cases. - Write steps to reproduce each scenario as Markdown bullet points.
- Discuss the scenarios with interested parties, until you get an agreement on all the important aspects.
- Write the interpreter (or several specialized interpreters) to evaluate the scenarios.
- Implement the
SUT (i.e. your product) features with confidence.
Latest developments
from see older.
tbb.nu: Send more details about a non-record updates
On by
If a step of a Nushell interpreter returns a record, it's going to be merged into the interpreter state. Anything that is not a record needs to be ignored. The ignored value is observed via Snippet message.
While working od Devlog Excavator I've run into a problem, where a
bullean true was returned and sent as a snippet, but without being
stringified. I.e. the JSON payload contained literal true. This is
not a valid type, and TBB was terminating the interpreter.
To prevent this kind of thing, now this kind of values are send together
with a description. That way observe snippet function will always
produce a JSON string that TBB can consume.
index 0bf7a1d..40e7bf8 100644
--- a/lib/tbb.nu
+++ b/lib/tbb.nu
@@ -25,6 +25,7 @@ export def run [
= $state | merge $state_update
= } else {
= $state_update
+ | describe --detailed
= | observe snippet --caption "The value returned by the step is not a record; Not updating"
= $state
= }Describe the issue with invalid observation
On by
index 0fbd6d3..311b6ab 100644
--- a/spec/failing-interpreters.md
+++ b/spec/failing-interpreters.md
@@ -85,3 +85,10 @@ This is currently **not implemented**.
=Similarly, if a single step is never reported as success of failure, the interpreter process should be terminated, and **the step** marked as failed.
=
=This is currently **not implemented**.
+
+
+## Invalid observation sent
+
+While working on `tbb.nu` (the Nushell interpreter library) I ran into the issue where the interpreter sent wrong data in a Snippet observation. The value, instead of being a string was a boolean. The interpreter was terminated, and there was a trace of the issue, but only at the top of the report. There was no error summary at the bottom. Also no step was marked as failing. The last step was green, and the rest were not evaluated. The offending step was in a delegated scenario, which might have been a relevant factor.
+
+TODO: Reproduce and assert that the error is properly reported (in a step status and a report summary).
Older Devlog Entries
- Tad Better Behavior 2026-W19
- Tad Better Behavior 2026-W18
- Tad Better Behavior 2026-W17
- Tad Better Behavior 2026-W16
- Tad Better Behavior 2026-W15
- Tad Better Behavior 2026-W14
- Tad Better Behavior 2026-W12
- Tad Better Behavior 2025-W50
- Tad Better Behavior 2025-W49
- Tad Better Behavior 2025-W48
- Tad Better Behavior 2025-W47
- Tad Better Behavior 2025-W46