Changeset - 01abb838b7a8
[Not reviewed]
default
0 2 0
Thomas De Schampheleire - 11 years ago 2015-06-20 22:26:49
thomas.de.schampheleire@gmail.com
tests: remove hardcoded test_regular username
2 files changed with 5 insertions and 5 deletions:
0 comments (0 inline, 0 general)
kallithea/tests/functional/test_changeset_comments.py
Show inline comments
 
@@ -104,7 +104,7 @@ class TestChangeSetCommentsController(Te
 
        self.log_user()
 

	
 
        rev = '27cd5cce30c96924232dffcd24178a07ffeb5dfc'
 
        text = u'@test_regular check CommentOnRevision'
 
        text = u'@%s check CommentOnRevision' % TEST_USER_REGULAR_LOGIN
 

	
 
        params = {'text': text, '_authentication_token': self.authentication_token()}
 
        response = self.app.post(url(controller='changeset', action='comment',
 
@@ -127,7 +127,7 @@ class TestChangeSetCommentsController(Te
 
        users = [x.user.username for x in UserNotification.query().all()]
 

	
 
        # test_regular gets notification by @mention
 
        self.assertEqual(sorted(users), [TEST_USER_ADMIN_LOGIN, u'test_regular'])
 
        self.assertEqual(sorted(users), [TEST_USER_ADMIN_LOGIN, TEST_USER_REGULAR_LOGIN])
 

	
 
    def test_delete(self):
 
        self.log_user()
kallithea/tests/functional/test_login.py
Show inline comments
 
@@ -40,12 +40,12 @@ class TestLoginController(TestController
 

	
 
    def test_login_regular_ok(self):
 
        response = self.app.post(url(controller='login', action='index'),
 
                                 {'username': 'test_regular',
 
                                 {'username': TEST_USER_REGULAR_LOGIN,
 
                                  'password': 'test12'})
 

	
 
        self.assertEqual(response.status, '302 Found')
 
        self.assertEqual(response.session['authuser'].get('username'),
 
                         'test_regular')
 
                         TEST_USER_REGULAR_LOGIN)
 
        response = response.follow()
 
        response.mustcontain('/%s' % HG_REPO)
 

	
 
@@ -63,7 +63,7 @@ class TestLoginController(TestController
 

	
 
    def test_logout(self):
 
        response = self.app.post(url(controller='login', action='index'),
 
                                 {'username': 'test_regular',
 
                                 {'username': TEST_USER_REGULAR_LOGIN,
 
                                  'password': 'test12'})
 

	
 
        # Verify that a login session has been established.
0 comments (0 inline, 0 general)