Mike Qiu | 14 Aug 2012 08:54
Picon

[Autotest] [PATCH 2/2 v4] client.shared.based_utils:Make and copy the src dir to client/tmp/≤test>/

Currently, the src dir may be removed when the test version has changed.
Just to check to make and copy the src if it has been removed.

After check the src dir , patch files need to be copied to the parent
of src dir

Signed-off-by: Mike Qiu <qiudayu <at> linux.vnet.ibm.com>
---
 client/shared/base_utils.py |   17 ++++++++++++++---
 1 files changed, 14 insertions(+), 3 deletions(-)

diff --git a/client/shared/base_utils.py b/client/shared/base_utils.py
index 9f3489c..0921c8d 100644
--- a/client/shared/base_utils.py
+++ b/client/shared/base_utils.py
 <at>  <at>  -1,7 +1,7  <at>  <at> 
 #
 # Copyright 2008 Google Inc. Released under the GPL v2

-import os, pickle, random, re, resource, select, shutil, signal, StringIO
+import os, pickle, random, re, resource, select, shutil, signal, StringIO, glob
 import socket, struct, subprocess, sys, time, textwrap, traceback, urlparse
 import warnings, smtplib, logging, urllib2, string
 from threading import Thread, Event, Lock
 <at>  <at>  -767,9 +767,20  <at>  <at>  def update_version(srcdir, preserve_srcdir, new_version, install,
     if install_needed:
         if not preserve_srcdir and os.path.exists(srcdir):
             shutil.rmtree(srcdir)
+        source_code_dir = srcdir.replace('/client/tmp/','/client/tests/')
+        if not os.path.isdir(srcdir):
(Continue reading)


Gmane