diff --git a/rhodecode/controllers/journal.py b/rhodecode/controllers/journal.py
--- a/rhodecode/controllers/journal.py
+++ b/rhodecode/controllers/journal.py
@@ -70,8 +70,9 @@ class JournalController(BaseController):
return render('/journal.html')
def toggle_following(self):
-
- if request.POST.get('auth_token') == get_token():
+ cur_token = request.POST.get('auth_token')
+ token = get_token()
+ if cur_token == token:
scm_model = ScmModel()
user_id = request.POST.get('follows_user_id')
@@ -93,5 +94,5 @@ class JournalController(BaseController):
raise HTTPInternalServerError()
-
+ log.debug('token mismatch %s vs %s', cur_token, token)
raise HTTPInternalServerError()
diff --git a/rhodecode/tests/functional/test_home.py b/rhodecode/tests/functional/test_home.py
--- a/rhodecode/tests/functional/test_home.py
+++ b/rhodecode/tests/functional/test_home.py
@@ -6,6 +6,10 @@ class TestHomeController(TestController)
self.log_user()
response = self.app.get(url(controller='home', action='index'))
#if global permission is set
- assert 'ADD NEW REPOSITORY' in response.body, 'Wrong main page'
+ assert 'ADD NEW REPOSITORY' in response.body, 'No Button for add new repository'
assert 'href="/%s/summary"' % HG_REPO in response.body, ' mising repository in list'
# Test response...
+
+ assert """
""" in response.body, 'wrong info about type of repositry'
+ assert """
""" in response.body, 'wrong info about repository availabilty'
+ assert """r173:27cd5cce30c9""" in response.body, 'no info about tooltip'
diff --git a/rhodecode/tests/functional/test_journal.py b/rhodecode/tests/functional/test_journal.py
--- a/rhodecode/tests/functional/test_journal.py
+++ b/rhodecode/tests/functional/test_journal.py
@@ -1,7 +1,47 @@
from rhodecode.tests import *
+from rhodecode.model.db import UserFollowing, User, Repository
+from rhodecode.lib.helpers import get_token
class TestJournalController(TestController):
def test_index(self):
+ self.log_user()
response = self.app.get(url(controller='journal', action='index'))
# Test response...
+ assert """