Author: bugman Date: Sun Jun 29 12:08:39 2008 New Revision: 6574 URL: http://svn.gna.org/viewcvs/relax?rev=6574&view=rev Log: Reverted r6573, as this was committed by accident. The command used was: svn merge -r6573:6572 . Modified: 1.3/test_suite/test_suite_runner.py 1.3/test_suite/unit_tests/unit_test_runner.py Modified: 1.3/test_suite/test_suite_runner.py URL: http://svn.gna.org/viewcvs/relax/1.3/test_suite/test_suite_runner.py?rev=6574&r1=6573&r2=6574&view=diff ============================================================================== --- 1.3/test_suite/test_suite_runner.py (original) +++ 1.3/test_suite/test_suite_runner.py Sun Jun 29 12:08:39 2008 @@ -19,10 +19,6 @@ # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # # # ############################################################################### - -# Python module imports. -import os -import sys # Formatting. from formatting import heading, summary_line @@ -84,7 +80,7 @@ heading('Unit tests') # Run the tests. - unit_runner = Unit_test_runner(root_path=sys.path[-1] + os.sep + 'test_suite/unit_tests') + unit_runner = Unit_test_runner(root_path='test_suite/unit_tests') self.unit_result = unit_runner.run(runner=RelaxTestRunner()) Modified: 1.3/test_suite/unit_tests/unit_test_runner.py URL: http://svn.gna.org/viewcvs/relax/1.3/test_suite/unit_tests/unit_test_runner.py?rev=6574&r1=6573&r2=6574&view=diff ============================================================================== --- 1.3/test_suite/unit_tests/unit_test_runner.py (original) +++ 1.3/test_suite/unit_tests/unit_test_runner.py Sun Jun 29 12:08:39 2008 @@ -287,7 +287,6 @@ @return: ''' - print "Hello1: " + `package_path` result = None packages = None package_path=get_module_relative_path(package_path, module_name) @@ -306,16 +305,11 @@ result.addTest(bad_syntax) - print "Hello2: " + `package_path` - print "Hello3: " + `packages` - import sys - print "sys.path: " + `sys.path` if packages != None: # some input packages may not contain the required class if hasattr(packages[-1], class_name): clazz = getattr(packages[-1], class_name) result = unittest.TestLoader().loadTestsFromTestCase(clazz) - return result @@ -376,7 +370,6 @@ a file as one containing a unit test TestCase ''' - print "root_path: " + `root_path` self.root_path = root_path if self.root_path == None: self.root_path = get_startup_path() @@ -385,7 +378,6 @@ self.patterns.append(re.compile(pattern)) self.paths_scanned = False - print "root_path: " + `self.root_path` def scan_paths(self): '''Scan directories and paths for unit test classes and load them into TestSuites @@ -401,9 +393,6 @@ if __debug__: dir_names=dir_names - print "Walk, dir_path: " + `dir_path` - print "Walk, dir_names: " + `dir_names` - print "Walk, file_names: " + `file_names` for file_name in file_names: module_found = None for pattern in self.patterns: @@ -417,9 +406,7 @@ class_name = string.upper(module_found[0]) + module_found[1:] - print "dir_path: " + `dir_path` module_path = get_module_relative_path(dir_path, module_found) - print "Module_path: " + `module_path` #FIXME add verbose search option #if self.verbose: # print 'loading module: ' + module_path @@ -720,7 +707,6 @@ result.add(tuple(mpath)) - print "XXX: " + `result` return result @@ -756,9 +742,7 @@ module_paths = self.paths_from_test_module(self.test_module) - print "Hello: " + `self.test_module` - print "Hello: " + `module_paths` - if 1: + if self.verbose: print 'root path: ', self.root_path print 'system directory: ', self.system_directory print 'unit test directory:', self.unit_test_directory @@ -769,8 +753,8 @@ # add SystemDirectory to python path - #sys.path.pop(0) - #sys.path.insert(0,self.system_directory) + sys.path.pop(0) + sys.path.insert(0,self.system_directory) @@ -780,10 +764,6 @@ for module_path in module_paths: module_string = os.path.join(*module_path) - # Convert to an absolute path. - #module_string = sys.path[-1] + os.sep + module_string - - print "module_string: " + `module_string` if os.path.isdir(module_string): #iterate and load unit tests from module path finder = Test_finder(module_string, self.test_case_patterns) @@ -792,10 +772,9 @@ break - print "Module paths: " +`module_paths` if tests == None: for module_path in module_paths: - print "Module path: " +`module_path` + print module_path path_len = len(module_path) if path_len <= 1: continue