GTG

Merge lp:~sara.ribeiro/gtg/quickadd_tag_parser into lp:~gtg/gtg/old-trunk

Proposed by Sara Ribeiro
Status: Merged
Merged at revision: 1365
Proposed branch: lp:~sara.ribeiro/gtg/quickadd_tag_parser
Merge into: lp:~gtg/gtg/old-trunk
Diff against target: 38 lines (+5/-1)
3 files modified
CHANGELOG (+1/-0)
GTG/tools/tags.py (+1/-1)
tests/tools/test_tags.py (+3/-0)
To merge this branch: bzr merge lp:~sara.ribeiro/gtg/quickadd_tag_parser
Reviewer Review Type Date Requested Status
Izidor Matušov Needs Fixing
Review via email: mp+209584@code.launchpad.net

Description of the change

Changed the parser in the quick add entry to accept "&" inside a tag

To post a comment you must log in.
Revision history for this message
Izidor Matušov (izidor) wrote :

Can you please extend the test suite in tests/tools/test_tags.py ? ( You might need to merge trunk into your branch first)

review: Needs Fixing
1361. By Sara Ribeiro

Solve merge conflict

1362. By Sara Ribeiro

Extended test suit

Revision history for this message
Sara Ribeiro (sara.ribeiro) wrote :

Ok, I've done that and resubmitted!

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'CHANGELOG'
2--- CHANGELOG 2014-03-11 03:14:22 +0000
3+++ CHANGELOG 2014-03-14 05:36:47 +0000
4@@ -22,6 +22,7 @@
5 * Fix for bug #1287259 : pep8ify the codebase, by Izidor Matušov
6 * Rework of test-suite, by Izidor Matušov
7 * Fix for bug #1027604: Deeper integeration of userdoc, by Sara Ribeiro
8+ * Fix for bug #1288560 : Parsing error when creating a task (via quick add entry) that contains a tag with "&" in it, by Sara Ribeiro
9
10 2013-11-24 Getting Things GNOME! 0.3.1
11 * Fix for bug #1024473: Have 'Show Main Window' in notification area, by Antonio Roquentin
12
13=== modified file 'GTG/tools/tags.py'
14--- GTG/tools/tags.py 2013-11-23 14:40:23 +0000
15+++ GTG/tools/tags.py 2014-03-14 05:36:47 +0000
16@@ -22,7 +22,7 @@
17
18 def extract_tags_from_text(text):
19 """ Given a string, returns a list of the @tags contained in that """
20- return re.findall(r'(?:^|[\s])(@[\w\/\.\-\:]*\w)', text)
21+ return re.findall(r'(?:^|[\s])(@[\w\/\.\-\:\&]*\w)', text)
22
23
24 def parse_tag_list(text):
25
26=== modified file 'tests/tools/test_tags.py'
27--- tests/tools/test_tags.py 2014-03-10 03:37:32 +0000
28+++ tests/tools/test_tags.py 2014-03-14 05:36:47 +0000
29@@ -71,6 +71,9 @@
30 def ignore_colon_at_end(self):
31 self.assertTags("@:a:b:c:", ["@:a:b:c"])
32
33+ def test_accepts_ampersand_in_tag(self):
34+ self.assertTags("@home&work", ["@home&work"])
35+
36
37 class TestParseTagList(TestCase):
38 """ parse_tag_list """

Subscribers

People subscribed via source and target branches

to status/vote changes: