#!/bin/sh # Copyright (c) 2023 DTB # SPDX-License-Identifier: FSFAP # # Copying and distribution of this file, with or without modification, are # permitted in any medium without royalty provided the copyright notice and this # notice are preserved. This file is offered as-is, without any warranty. set -e i=1 while test -e "$i".test; do printf '%s: %s: Running test...\n' "$0" "$i".test ./"$i".test >"$i".result diff 1.expected 1.result printf '%s: %s: Test passed.\n' "$0" "$i".test i="$(printf '%s + %s\n' 1 "$i" | bc)" done