From adbb9d560982944181897486dfb94c461bce0073 Mon Sep 17 00:00:00 2001 From: amy0701 Date: Wed, 10 Apr 2013 11:34:17 +0000 Subject: [PATCH] spelling mistake for Script_Post make script_post fail to work git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@15932 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-test/xcattest | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/xCAT-test/xcattest b/xCAT-test/xcattest index 815f22fa5..5804f2c93 100755 --- a/xCAT-test/xcattest +++ b/xCAT-test/xcattest @@ -254,7 +254,7 @@ sub getConfig } if(exists $config{script_post}){ - log_this("Script_Prev:"); + log_this("Script_Post:"); foreach $cmd (@{$config{script_post}}){ log_this(" $cmd"); } @@ -370,7 +370,7 @@ sub uninit log_this("******************************"); log_this("un-initialize xCAT test evironment"); log_this("******************************"); -# my $cmd = undef;; + my $cmd = undef;; # if(exists $config{object}){ # foreach my $type (keys %{$config{object}}){ # foreach my $name (keys %{$config{object}{$type}}){ @@ -397,14 +397,15 @@ sub uninit # } # } # } -# foreach $cmd (@{$config{script_post}}){ -# log_this($cmd); -# runcmd($cmd); -# if($::RUNCMD_RC != 0){ -# log_this("Fail to run $cmd"); -# return 1; -# } -# } + foreach $cmd (@{$config{script_post}}){ + log_this($cmd); + runcmd($cmd); + if($::RUNCMD_RC != 0){ + log_this("Fail to run $cmd"); + return 1; + } + } + &runcmd("restorexCATdb -p /tmp/xCATdbbackup"); &runcmd("rm -rf /tmp/xCATdbbackup"); return 0;