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;