From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alex Kost Subject: [PATCH 2/8] tests: Rename 'dmd_pid' to 'shepherd_pid'. Date: Mon, 25 Jan 2016 13:50:15 +0300 Message-ID: <1453719021-13836-3-git-send-email-alezost@gmail.com> References: <1453719021-13836-1-git-send-email-alezost@gmail.com> Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:40218) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aNejr-0006aT-2J for guix-devel@gnu.org; Mon, 25 Jan 2016 05:51:16 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aNejp-0006wm-B6 for guix-devel@gnu.org; Mon, 25 Jan 2016 05:51:14 -0500 Received: from mail-lf0-x243.google.com ([2a00:1450:4010:c07::243]:36245) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aNejo-0006wh-U9 for guix-devel@gnu.org; Mon, 25 Jan 2016 05:51:13 -0500 Received: by mail-lf0-x243.google.com with SMTP id t141so7631221lfd.3 for ; Mon, 25 Jan 2016 02:51:12 -0800 (PST) Received: from localhost.localdomain ([217.107.192.146]) by smtp.gmail.com with ESMTPSA id p138sm2595299lfb.22.2016.01.25.02.51.11 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 25 Jan 2016 02:51:11 -0800 (PST) In-Reply-To: <1453719021-13836-1-git-send-email-alezost@gmail.com> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: guix-devel@gnu.org * tests/basic.sh: Rename 'dmd_pid' to 'shepherd_pid'. * tests/misbehaved-client.sh: Likewise. * tests/no-home.sh: Likewise. * tests/respawn.sh: Likewise. * tests/status-sexp.sh: Likewise. --- tests/basic.sh | 10 +++++----- tests/misbehaved-client.sh | 2 +- tests/no-home.sh | 4 ++-- tests/respawn.sh | 4 ++-- tests/status-sexp.sh | 6 +++--- 5 files changed, 13 insertions(+), 13 deletions(-) diff --git a/tests/basic.sh b/tests/basic.sh index a20e9dc..e2142c8 100644 --- a/tests/basic.sh +++ b/tests/basic.sh @@ -63,9 +63,9 @@ shepherd -I -s "$socket" -c "$conf" -l "$log" --pid="$pid" & # Wait till it's ready. while ! test -f "$pid" ; do sleep 0.3 ; done -dmd_pid="`cat $pid`" +shepherd_pid="`cat $pid`" -kill -0 $dmd_pid +kill -0 $shepherd_pid test -S "$socket" pristine_status=`$herd status root` # Prep for 'reload' test. echo $pristine_status | grep -E '(Start.*root|Stop.*test)' @@ -126,7 +126,7 @@ $herd status | grep "Stopped: ()" $herd status | grep "Started: (root)" $herd stop root -! kill -0 $dmd_pid +! kill -0 $shepherd_pid test -f "$log" @@ -152,9 +152,9 @@ $herd status test | grep started $herd stop test ! test -f "$stamp" -dmd_pid="`cat $pid`" +shepherd_pid="`cat $pid`" $herd stop root -! kill -0 $dmd_pid +! kill -0 $shepherd_pid rm -rf $confdir diff --git a/tests/misbehaved-client.sh b/tests/misbehaved-client.sh index fad5f4d..edacc45 100644 --- a/tests/misbehaved-client.sh +++ b/tests/misbehaved-client.sh @@ -35,7 +35,7 @@ shepherd -I -s "$socket" -c /dev/null -l "$log" --pid="$pid" & # Wait till it's ready. while ! test -f "$pid" ; do sleep 0.3 ; done -dmd_pid="`cat $pid`" +shepherd_pid="`cat $pid`" "$GUILE" -c " (use-modules (shepherd comm)) diff --git a/tests/no-home.sh b/tests/no-home.sh index 5af51e6..32fa842 100644 --- a/tests/no-home.sh +++ b/tests/no-home.sh @@ -37,10 +37,10 @@ trap "rm -f $socket; # Make sure 'dmd' starts even though $HOME is not writable. shepherd -I -s "$socket" -c /dev/null -l /dev/null --pid="$pid" & -dmd_pid="$!" +shepherd_pid="$!" # Wait until it's ready, or until it terminates. -while ! test -f "$pid" ; do kill -0 "$dmd_pid" ; sleep 0.3 ; done +while ! test -f "$pid" ; do kill -0 "$shepherd_pid" ; sleep 0.3 ; done kill -0 `cat "$pid"` $herd status root diff --git a/tests/respawn.sh b/tests/respawn.sh index 32d18db..ebc298d 100644 --- a/tests/respawn.sh +++ b/tests/respawn.sh @@ -90,9 +90,9 @@ shepherd -I -s "$socket" -c "$conf" -l "$log" --pid="$pid" & # Wait till it's ready. wait_for_file "$pid" -dmd_pid="`cat $pid`" +shepherd_pid="`cat $pid`" -kill -0 $dmd_pid +kill -0 $shepherd_pid test -S "$socket" $herd status $herd status test1 | grep started diff --git a/tests/status-sexp.sh b/tests/status-sexp.sh index 3452a15..0f1417c 100644 --- a/tests/status-sexp.sh +++ b/tests/status-sexp.sh @@ -54,9 +54,9 @@ shepherd -I -s "$socket" -c "$conf" -l "$log" --pid="$pid" & # Wait till it's ready. while ! test -f "$pid" ; do sleep 0.3 ; done -dmd_pid="`cat $pid`" +shepherd_pid="`cat $pid`" -kill -0 $dmd_pid +kill -0 $shepherd_pid test -S "$socket" # Code to fetch service status info. @@ -123,6 +123,6 @@ $herd unload root all (error #f) (messages ()))))" $herd stop root -! kill -0 $dmd_pid +! kill -0 $shepherd_pid test -f "$log" -- 2.6.3