This repository was archived by the owner on Sep 19, 2018. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +13
-2
lines changed
Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -162,9 +162,9 @@ <h1>{{ event.title }}</h1>
162162 < p >
163163 {% for tag in event.tags.all %}
164164 {% if forloop.last %}
165- {{ tag.name }}
165+ < a href =" {% url 'web.search_events' %}?q={{ tag.name|urlencode }}" > {{ tag.name }} </ a >
166166 {% else %}
167- {{ tag.name }},
167+ < a href =" {% url 'web.search_events' %}?q={{ tag.name|urlencode }}" > {{ tag.name }} </ a > ,
168168 {% endif %}
169169 {% endfor %}
170170 </ p >
Original file line number Diff line number Diff line change 1+ # coding=utf-8
2+
13import datetime
24import pytest
35import StringIO
@@ -60,6 +62,15 @@ def test_search_events_with_search_query(self):
6062 self .assertEquals (1 ,response .context ['events' ].count ())
6163 self .assertEquals ('SI' , response .context ['country' ])
6264
65+ def test_search_events_with_unicode_tag_in_search_query (self ):
66+ ApprovedEventFactory .create (tags = ["jabolčna čežana" ,"José" , "Django" ])
67+ response = self .client .get (reverse ('web.search_events' ), {'q' :'čežana' }, REMOTE_ADDR = '93.103.53.11' )
68+
69+ self .assertEquals (1 ,response .context ['events' ].count ())
70+ self .assertEquals ('SI' , response .context ['country' ])
71+
72+
73+
6374 def test_search_events_with_search_query_multiple_events (self ):
6475 approved1 = ApprovedEventFactory .create (title = "Event Arglebargle - Approved" , country = "SI" )
6576 approved2 = ApprovedEventFactory .create (title = "Event Arglebargle - Approved" , country = "AT" )
You can’t perform that action at this time.
0 commit comments