On 02/10/2012 05:21 PM, Jérémy Compostella wrote:

Sorry, this is a bit late, but I have 2 notes about the
new dd/bytes test:

> diff --git a/tests/dd/bytes b/tests/dd/bytes
> new file mode 100755
> index 0000000..6038742
> --- /dev/null
> +++ b/tests/dd/bytes
> @@ -0,0 +1,57 @@

> +# seek bytes
> +echo abcdefghijklm |
> + dd bs=5 seek=8 oflag=seek_bytes > out 2> /dev/null || fail=1
> +echo abcdefghijklm |
> + dd bs=4 seek=2 > expected 2> /dev/null || fail=1
> +compare expected out || fail=1

I don't know why, but I somehow do not have a good feeling
about a test comparing the result of the program to be tested
with another run. If something cowardly fails, then this test
would succeed.

> +# seek bytes on empty file
> +echo abcdefghijklm |
> + dd bs=5 seek=8 oflag=seek_bytes > out2 2> /dev/null || fail=1
> +compare expected out2 || fail=1

The comment is wrong here, isn't it?

Have a nice day,
Berny

Reply via email to