[DTrace-devel] [PATCH v2 18/20] test, usdt, pid: remove arg count check

Kris Van Hees kris.van.hees at oracle.com
Thu Sep 22 20:47:33 UTC 2022


On Wed, Sep 07, 2022 at 02:00:05PM +0100, Nick Alcock via DTrace-devel wrote:
> This check is obsolescent and these days is only testing the *test
> runner*.  Tests don't need to test runtest.sh: the chain of blame is
> meant to run the other way :)

That check does not exist to test runtest.sh but rather is a user friendly
check for poeple who might execute the test script without runtest.sh.  I don't
think we really need to remove them from all the scripts - it can be convenient
(and has reminded me a couple of times in the past that I needed to supply that
argument).

> Drop from usdt/ and pid/ for now (the huge number of other tests that do
> the same can follow at a later date).
> 
> Signed-off-by: Nick Alcock <nick.alcock at oracle.com>
> ---
>  test/unittest/pid/tst.addprobes.sh    | 7 +------
>  test/unittest/pid/tst.main.sh         | 7 +------
>  test/unittest/pid/tst.manypids.sh     | 7 +------
>  test/unittest/pid/tst.newprobes.sh    | 7 +------
>  test/unittest/pid/tst.probemod.sh     | 7 +------
>  test/unittest/pid/tst.provregex1.sh   | 7 +------
>  test/unittest/pid/tst.provregex2.sh   | 7 +------
>  test/unittest/pid/tst.provregex3.sh   | 7 +------
>  test/unittest/pid/tst.provregex4.sh   | 7 +------
>  test/unittest/pid/tst.restartloop.sh  | 7 +------
>  test/unittest/pid/tst.self-grab.sh    | 6 +-----
>  test/unittest/usdt/tst.allargs.sh     | 7 +------
>  test/unittest/usdt/tst.andpid.ksh     | 6 +-----
>  test/unittest/usdt/tst.badguess.sh    | 6 +-----
>  test/unittest/usdt/tst.corruptenv.sh  | 7 +------
>  test/unittest/usdt/tst.dlclose2.sh    | 5 -----
>  test/unittest/usdt/tst.dlclose3.sh    | 5 -----
>  test/unittest/usdt/tst.eliminate.sh   | 5 -----
>  test/unittest/usdt/tst.enabled.sh     | 4 ----
>  test/unittest/usdt/tst.enabled2.sh    | 5 -----
>  test/unittest/usdt/tst.entryreturn.sh | 4 ----
>  test/unittest/usdt/tst.execstack.sh   | 6 +-----
>  test/unittest/usdt/tst.fork.sh        | 4 ----
>  test/unittest/usdt/tst.forker.sh      | 8 +-------
>  test/unittest/usdt/tst.guess32.sh     | 5 -----
>  test/unittest/usdt/tst.guess64.sh     | 4 ----
>  test/unittest/usdt/tst.header.sh      | 6 +-----
>  test/unittest/usdt/tst.lingering.sh   | 4 ----
>  test/unittest/usdt/tst.linkpriv.sh    | 6 +-----
>  test/unittest/usdt/tst.linkunpriv.sh  | 7 +------
>  test/unittest/usdt/tst.multiple.sh    | 4 ----
>  test/unittest/usdt/tst.onlyenabled.sh | 6 +-----
>  test/unittest/usdt/tst.reeval.sh      | 4 ----
>  test/unittest/usdt/tst.static.sh      | 4 ----
>  test/unittest/usdt/tst.static2.sh     | 5 -----
>  35 files changed, 21 insertions(+), 182 deletions(-)
> 
> diff --git a/test/unittest/pid/tst.addprobes.sh b/test/unittest/pid/tst.addprobes.sh
> index 81092c9fa055..a73cf003df5b 100755
> --- a/test/unittest/pid/tst.addprobes.sh
> +++ b/test/unittest/pid/tst.addprobes.sh
> @@ -1,7 +1,7 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2007, 2021, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2007, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> @@ -12,11 +12,6 @@
>  # pid provider.
>  #
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  
>  sleep 60 &
> diff --git a/test/unittest/pid/tst.main.sh b/test/unittest/pid/tst.main.sh
> index 5faafa5f19ca..9d332fb768f9 100755
> --- a/test/unittest/pid/tst.main.sh
> +++ b/test/unittest/pid/tst.main.sh
> @@ -1,16 +1,11 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2007, 2021, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2007, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  
>  #
> diff --git a/test/unittest/pid/tst.manypids.sh b/test/unittest/pid/tst.manypids.sh
> index 8f853c0f5bf2..7b76c5eb49e9 100755
> --- a/test/unittest/pid/tst.manypids.sh
> +++ b/test/unittest/pid/tst.manypids.sh
> @@ -1,16 +1,11 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2007, 2021, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2007, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  
>  declare -a pids
> diff --git a/test/unittest/pid/tst.newprobes.sh b/test/unittest/pid/tst.newprobes.sh
> index a4944688a8e4..04d55060ca55 100755
> --- a/test/unittest/pid/tst.newprobes.sh
> +++ b/test/unittest/pid/tst.newprobes.sh
> @@ -1,18 +1,13 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2008, 2018, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2008, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
>  
>  # @@xfail: not working yet
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  
>  # Note that awk is stripped and new versions (gawk 4.2.1 and higher) probably
> diff --git a/test/unittest/pid/tst.probemod.sh b/test/unittest/pid/tst.probemod.sh
> index ef278b9e3089..525d4cf1d2a2 100755
> --- a/test/unittest/pid/tst.probemod.sh
> +++ b/test/unittest/pid/tst.probemod.sh
> @@ -1,16 +1,11 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2006, 2021, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2006, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  
>  #
> diff --git a/test/unittest/pid/tst.provregex1.sh b/test/unittest/pid/tst.provregex1.sh
> index c672b23fa049..66a1b5463336 100755
> --- a/test/unittest/pid/tst.provregex1.sh
> +++ b/test/unittest/pid/tst.provregex1.sh
> @@ -1,7 +1,7 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2008, 2021, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2008, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> @@ -9,11 +9,6 @@
>  # (e.g., p*d$target) works.
>  #
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  DIR=$tmpdir/provregex1.$$
>  
> diff --git a/test/unittest/pid/tst.provregex2.sh b/test/unittest/pid/tst.provregex2.sh
> index 305aafe99a3b..36508562fa2f 100755
> --- a/test/unittest/pid/tst.provregex2.sh
> +++ b/test/unittest/pid/tst.provregex2.sh
> @@ -1,7 +1,7 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2008, 2020, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2008, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> @@ -10,11 +10,6 @@
>  #
>  # @@xfail: dtv2
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  DIR=$tmpdir/provregex2.$$
>  
> diff --git a/test/unittest/pid/tst.provregex3.sh b/test/unittest/pid/tst.provregex3.sh
> index e1c64949fcb6..3e597636b48f 100755
> --- a/test/unittest/pid/tst.provregex3.sh
> +++ b/test/unittest/pid/tst.provregex3.sh
> @@ -1,7 +1,7 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2008, 2020, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2008, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> @@ -11,11 +11,6 @@
>  #
>  # @@xfail: dtv2
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  DIR=$tmpdir/provregex3.$$
>  
> diff --git a/test/unittest/pid/tst.provregex4.sh b/test/unittest/pid/tst.provregex4.sh
> index a9ff32382837..4ca34048ab99 100755
> --- a/test/unittest/pid/tst.provregex4.sh
> +++ b/test/unittest/pid/tst.provregex4.sh
> @@ -1,7 +1,7 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2008, 2020, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2008, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> @@ -11,11 +11,6 @@
>  #
>  # @@xfail: dtv2
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  DIR=$tmpdir/provregex4.$$
>  
> diff --git a/test/unittest/pid/tst.restartloop.sh b/test/unittest/pid/tst.restartloop.sh
> index ee96080c7273..667a1009f841 100755
> --- a/test/unittest/pid/tst.restartloop.sh
> +++ b/test/unittest/pid/tst.restartloop.sh
> @@ -1,7 +1,7 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2014, 2018, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2014, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> @@ -29,11 +29,6 @@ script()
>  EOF
>  }
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  echo "$dtrace -Z $dt_flags -s /dev/stdin"
>  
> diff --git a/test/unittest/pid/tst.self-grab.sh b/test/unittest/pid/tst.self-grab.sh
> index 9cb9d9d56b45..88817533d360 100755
> --- a/test/unittest/pid/tst.self-grab.sh
> +++ b/test/unittest/pid/tst.self-grab.sh
> @@ -1,7 +1,7 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2018, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> @@ -11,10 +11,6 @@
>  # Note: we expect script compilation to fail!
>  # We do not expect a coredump.
>  #
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  
> diff --git a/test/unittest/usdt/tst.allargs.sh b/test/unittest/usdt/tst.allargs.sh
> index f0484793206f..a05547df1429 100755
> --- a/test/unittest/usdt/tst.allargs.sh
> +++ b/test/unittest/usdt/tst.allargs.sh
> @@ -1,7 +1,7 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2018, 2020, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2018, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> @@ -11,11 +11,6 @@
>  # Arguments values are checked only for first 10 arguments because
>  # there is support for arg0 ... arg9 only at this moment.
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  CC=/usr/bin/gcc
>  CFLAGS="-std=gnu89 -I${PWD}/uts/common"
> diff --git a/test/unittest/usdt/tst.andpid.ksh b/test/unittest/usdt/tst.andpid.ksh
> index b0ad1e398d53..48612f45c75d 100644
> --- a/test/unittest/usdt/tst.andpid.ksh
> +++ b/test/unittest/usdt/tst.andpid.ksh
> @@ -1,13 +1,9 @@
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2006, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  
> diff --git a/test/unittest/usdt/tst.badguess.sh b/test/unittest/usdt/tst.badguess.sh
> index ae4865f6fc27..c0f08f97a71d 100755
> --- a/test/unittest/usdt/tst.badguess.sh
> +++ b/test/unittest/usdt/tst.badguess.sh
> @@ -1,14 +1,10 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2006, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  CC=/usr/bin/gcc
> diff --git a/test/unittest/usdt/tst.corruptenv.sh b/test/unittest/usdt/tst.corruptenv.sh
> index 4f465c2c9db0..0564f19f85a7 100755
> --- a/test/unittest/usdt/tst.corruptenv.sh
> +++ b/test/unittest/usdt/tst.corruptenv.sh
> @@ -1,7 +1,7 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2008, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2008, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> @@ -14,11 +14,6 @@
>  
>  PATH=/usr/bin:/usr/sbin:$PATH
>  
> -if [ $# != 1 ]; then
> -	echo 'expected one argument: <dtrace-path>'
> -	exit 2
> -fi
> -
>  dtrace="$1"
>  
>  DIRNAME="$tmpdir/usdt-corruptenv.$$.$RANDOM"
> diff --git a/test/unittest/usdt/tst.dlclose2.sh b/test/unittest/usdt/tst.dlclose2.sh
> index 782e42555736..e3ba023e8883 100755
> --- a/test/unittest/usdt/tst.dlclose2.sh
> +++ b/test/unittest/usdt/tst.dlclose2.sh
> @@ -9,11 +9,6 @@
>  #
>  PATH=/usr/bin:/usr/sbin:$PATH
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  CC=/usr/bin/gcc
>  CFLAGS=
> diff --git a/test/unittest/usdt/tst.dlclose3.sh b/test/unittest/usdt/tst.dlclose3.sh
> index 9ee91c8d23ab..dea405f1fc5a 100755
> --- a/test/unittest/usdt/tst.dlclose3.sh
> +++ b/test/unittest/usdt/tst.dlclose3.sh
> @@ -15,11 +15,6 @@
>  
>  PATH=/usr/bin:/usr/sbin:$PATH
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  CC=/usr/bin/gcc
>  CFLAGS=
> diff --git a/test/unittest/usdt/tst.eliminate.sh b/test/unittest/usdt/tst.eliminate.sh
> index 63541ff2454f..cccab71f0262 100755
> --- a/test/unittest/usdt/tst.eliminate.sh
> +++ b/test/unittest/usdt/tst.eliminate.sh
> @@ -10,11 +10,6 @@
>  # functions are removed in the final link step.
>  #
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  CC=/usr/bin/gcc
>  CFLAGS=
> diff --git a/test/unittest/usdt/tst.enabled.sh b/test/unittest/usdt/tst.enabled.sh
> index 5363172fd8b4..70dcbdac7c05 100755
> --- a/test/unittest/usdt/tst.enabled.sh
> +++ b/test/unittest/usdt/tst.enabled.sh
> @@ -5,10 +5,6 @@
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  # @@xfail: dtv2, no is-enabled probes yet
>  
>  dtrace=$1
> diff --git a/test/unittest/usdt/tst.enabled2.sh b/test/unittest/usdt/tst.enabled2.sh
> index c70bef507e89..cf61b31ee37a 100755
> --- a/test/unittest/usdt/tst.enabled2.sh
> +++ b/test/unittest/usdt/tst.enabled2.sh
> @@ -9,11 +9,6 @@
>  # harm in running it on other platforms. Here, we verify that is-enabled
>  # probes don't interfere with return values from previously invoked functions.
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  CC=/usr/bin/gcc
>  CFLAGS=
> diff --git a/test/unittest/usdt/tst.entryreturn.sh b/test/unittest/usdt/tst.entryreturn.sh
> index c2afb358de26..fed307a36ddd 100755
> --- a/test/unittest/usdt/tst.entryreturn.sh
> +++ b/test/unittest/usdt/tst.entryreturn.sh
> @@ -5,10 +5,6 @@
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  CC=/usr/bin/gcc
> diff --git a/test/unittest/usdt/tst.execstack.sh b/test/unittest/usdt/tst.execstack.sh
> index 242a2ed9d9ee..24042bbf4f77 100755
> --- a/test/unittest/usdt/tst.execstack.sh
> +++ b/test/unittest/usdt/tst.execstack.sh
> @@ -1,14 +1,10 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2006, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  CC=/usr/bin/gcc
> diff --git a/test/unittest/usdt/tst.fork.sh b/test/unittest/usdt/tst.fork.sh
> index dc30b2c5598b..657f98ca1c69 100755
> --- a/test/unittest/usdt/tst.fork.sh
> +++ b/test/unittest/usdt/tst.fork.sh
> @@ -6,10 +6,6 @@
>  # http://oss.oracle.com/licenses/upl.
>  #
>  # @@xfail: dtv2, no real probe-in-forked-child support yet
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  CC=/usr/bin/gcc
> diff --git a/test/unittest/usdt/tst.forker.sh b/test/unittest/usdt/tst.forker.sh
> index 018a6572f398..747f0a756009 100755
> --- a/test/unittest/usdt/tst.forker.sh
> +++ b/test/unittest/usdt/tst.forker.sh
> @@ -1,18 +1,12 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2007, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2007, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> -#
>  # @@timeout: 120
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  
>  #
> diff --git a/test/unittest/usdt/tst.guess32.sh b/test/unittest/usdt/tst.guess32.sh
> index 20ad0e7346ab..f5a37144885b 100755
> --- a/test/unittest/usdt/tst.guess32.sh
> +++ b/test/unittest/usdt/tst.guess32.sh
> @@ -5,11 +5,6 @@
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  CC=/usr/bin/gcc
>  CFLAGS=
> diff --git a/test/unittest/usdt/tst.guess64.sh b/test/unittest/usdt/tst.guess64.sh
> index 52750baf4792..272a13e27df3 100755
> --- a/test/unittest/usdt/tst.guess64.sh
> +++ b/test/unittest/usdt/tst.guess64.sh
> @@ -5,10 +5,6 @@
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  CC=/usr/bin/gcc
> diff --git a/test/unittest/usdt/tst.header.sh b/test/unittest/usdt/tst.header.sh
> index c96b8787c84c..d86cb6320c11 100755
> --- a/test/unittest/usdt/tst.header.sh
> +++ b/test/unittest/usdt/tst.header.sh
> @@ -1,14 +1,10 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2006, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  CC=/usr/bin/gcc
> diff --git a/test/unittest/usdt/tst.lingering.sh b/test/unittest/usdt/tst.lingering.sh
> index bee59df44da7..9b94bcf92358 100755
> --- a/test/unittest/usdt/tst.lingering.sh
> +++ b/test/unittest/usdt/tst.lingering.sh
> @@ -8,10 +8,6 @@
>  # Test multiple probes, repeatedly invoked by multiple dtraces
>  # on the same running trigger
>  #
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  CC=/usr/bin/gcc
> diff --git a/test/unittest/usdt/tst.linkpriv.sh b/test/unittest/usdt/tst.linkpriv.sh
> index 1a088f8235bf..bf768f8aa5db 100755
> --- a/test/unittest/usdt/tst.linkpriv.sh
> +++ b/test/unittest/usdt/tst.linkpriv.sh
> @@ -1,14 +1,10 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2006, 2016, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2006, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  CC=/usr/bin/gcc
> diff --git a/test/unittest/usdt/tst.linkunpriv.sh b/test/unittest/usdt/tst.linkunpriv.sh
> index 71d42ae41721..e29eecda7701 100755
> --- a/test/unittest/usdt/tst.linkunpriv.sh
> +++ b/test/unittest/usdt/tst.linkunpriv.sh
> @@ -1,17 +1,12 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2006, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
>  # @@skip: no privilege support (yet)
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  CC=/usr/bin/gcc
>  CFLAGS="-I${PWD}/uts/common"
> diff --git a/test/unittest/usdt/tst.multiple.sh b/test/unittest/usdt/tst.multiple.sh
> index eb0a7ccf5e4d..fe6dd1254bdf 100755
> --- a/test/unittest/usdt/tst.multiple.sh
> +++ b/test/unittest/usdt/tst.multiple.sh
> @@ -5,10 +5,6 @@
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  CC=/usr/bin/gcc
> diff --git a/test/unittest/usdt/tst.onlyenabled.sh b/test/unittest/usdt/tst.onlyenabled.sh
> index a469fac156c0..e0396d77d2bc 100755
> --- a/test/unittest/usdt/tst.onlyenabled.sh
> +++ b/test/unittest/usdt/tst.onlyenabled.sh
> @@ -1,14 +1,10 @@
>  #!/bin/bash
>  #
>  # Oracle Linux DTrace.
> -# Copyright (c) 2006, 2020, Oracle and/or its affiliates. All rights reserved.
> +# Copyright (c) 2006, 2022, Oracle and/or its affiliates. All rights reserved.
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  CC=/usr/bin/gcc
> diff --git a/test/unittest/usdt/tst.reeval.sh b/test/unittest/usdt/tst.reeval.sh
> index 3b32a280f757..94f32b039ac8 100755
> --- a/test/unittest/usdt/tst.reeval.sh
> +++ b/test/unittest/usdt/tst.reeval.sh
> @@ -6,10 +6,6 @@
>  # http://oss.oracle.com/licenses/upl.
>  #
>  # @@xfail: dtv2, needs sdt
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  CC=/usr/bin/gcc
> diff --git a/test/unittest/usdt/tst.static.sh b/test/unittest/usdt/tst.static.sh
> index a016f1c6c174..08eb90a3936d 100755
> --- a/test/unittest/usdt/tst.static.sh
> +++ b/test/unittest/usdt/tst.static.sh
> @@ -5,10 +5,6 @@
>  # Licensed under the Universal Permissive License v 1.0 as shown at
>  # http://oss.oracle.com/licenses/upl.
>  #
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
>  
>  dtrace=$1
>  CC=/usr/bin/gcc
> diff --git a/test/unittest/usdt/tst.static2.sh b/test/unittest/usdt/tst.static2.sh
> index ec6118730283..4d30c8ed8c21 100755
> --- a/test/unittest/usdt/tst.static2.sh
> +++ b/test/unittest/usdt/tst.static2.sh
> @@ -9,11 +9,6 @@
>  # files containing the probes have already been modified. This tests that
>  # case by generating the DOF object, removing it, and building it again.
>  
> -if [ $# != 1 ]; then
> -	echo expected one argument: '<'dtrace-path'>'
> -	exit 2
> -fi
> -
>  dtrace=$1
>  CC=/usr/bin/gcc
>  CFLAGS="-I${PWD}/uts/common"
> -- 
> 2.37.1.265.g363c192786.dirty
> 
> 
> _______________________________________________
> DTrace-devel mailing list
> DTrace-devel at oss.oracle.com
> https://oss.oracle.com/mailman/listinfo/dtrace-devel



More information about the DTrace-devel mailing list