[conduit: 55/138] Don't return folders from get test files function



commit 9dfad0c262bec9b6364f2e50d5d666d296e803bd
Author: John Carr <john carr unrouted co uk>
Date:   Thu Apr 30 07:06:27 2009 -0700

    Don't return folders from get test files function
---
 test/soup/data/__init__.py |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/test/soup/data/__init__.py b/test/soup/data/__init__.py
index 474dcf7..97c11e5 100644
--- a/test/soup/data/__init__.py
+++ b/test/soup/data/__init__.py
@@ -16,7 +16,8 @@ class DataWrapper(object):
         """ Yields files that match the glob in the data dir """
         files = []
         for i in glob.glob(os.path.join(self.get_data_dir(),glob_str)):
-            yield os.path.abspath(i)
+            if os.path.isfile(i):
+                yield os.path.abspath(i)
 
     def iter_samples(self):
         """ Yield DataType objects containing sample data """



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]