[tracker] functional-tests: Allow whitespaces in the tags and creators labels



commit 21e244f2cbe9a352a609a4b1611b8a876a7d9e54
Author: Ivan Frade <ivan frade nokia com>
Date:   Fri Mar 4 14:17:59 2011 +0200

    functional-tests: Allow whitespaces in the tags and creators labels
    
    More flexible parsing the results coming from the extractor, to allow
    tags like "test 1" or creators as "Bob Dylan"

 tests/functional-tests/common/utils/helpers.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/tests/functional-tests/common/utils/helpers.py b/tests/functional-tests/common/utils/helpers.py
index 9c56034..5c82dfd 100644
--- a/tests/functional-tests/common/utils/helpers.py
+++ b/tests/functional-tests/common/utils/helpers.py
@@ -266,7 +266,7 @@ class ExtractorHelper ():
         
         # hasTag case
         if line.startswith ("nao:hasTag"):
-            getlabel = re.compile ("nao:prefLabel\ \"(\w+)\"")
+            getlabel = re.compile ("nao:prefLabel\ \"([\w\ -]+)\"")
             match = getlabel.search (line)
             if (match):
                 line = 'nao:hasTag:prefLabel "%s" ;' % (match.group(1))
@@ -290,7 +290,7 @@ class ExtractorHelper ():
 
             return results
         elif line.startswith ("nco:creator"):
-            getcreator = re.compile ("nco:fullname\ \"(\w+)\"")
+            getcreator = re.compile ("nco:fullname\ \"([\w\ ]+)\"")
             creator_match = getcreator.search (line)
 
             if (creator_match):



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