From de054bd70138c9db939c239debae660f51d1a34d Mon Sep 17 00:00:00 2001 From: Lars Wirzenius Date: Sat, 28 Mar 2020 18:11:38 +0200 Subject: Add: source of a small example right there on the front page --- index.mdwn | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/index.mdwn b/index.mdwn index d969157..56a6c7c 100644 --- a/index.mdwn +++ b/index.mdwn @@ -42,6 +42,41 @@ to abide by its terms. ## Examples +This is a pretty minimal example. + +~~~{.markdown .numberLines} +--- +title: "**echo**(1) acceptance tests" +... + +Introduction +============================================================================= + +**echo**(1) is a Unix command line tool, which writes its command line +arguments to the standard output. This is a simple acceptance test +suite for the `/bin/echo` implementation. + +No arguments +============================================================================= + +```scenario +when user runs echo without arguments +then exit code is 0 +then standard output contains a newline +then standard error is empty +``` + +Hello, world +============================================================================= + +```scenario +when user runs echo with arguments hello, world +then exit code is 0 +then standard output contains "hello, world" +then standard error is empty +``` +~~~ + See actual, working, tested examples: * The Unix echo commandf -- cgit v1.2.1