Re: [PATCH 1/1] add tests

Herbert Xu <[email protected]>
Newsgroups org.kernel.vger.dash
Message-ID <[email protected]>
On Sat, Jul 06, 2024 at 07:44:16PM +0000, Buck Evan wrote:
>
> diff --git a/test b/test
> new file mode 100755
> index 0000000..8d214f5
> --- /dev/null
> +++ b/test
> @@ -0,0 +1,33 @@
> +#!/bin/sh
> +set -eu
> +export PATH="$PWD/src:$PATH"

It appears that most references to dash are already doing src/dash.
So just change the naked calls to dash to do src/dash instead of
modifying PATH.

> +if [ "$#" -eq 0 ]; then
> +  # default arguments: all tests
> +  set -- ./tests/*
> +fi

Please use tabs for indentation.

> +for test in "$@"; do

This could simply be

	for test; do

Thanks,
-- 
Email: Herbert Xu <[email protected]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.