diff --git a/rhodecode/tests/functional/test_admin_repos.py b/rhodecode/tests/functional/test_admin_repos.py --- a/rhodecode/tests/functional/test_admin_repos.py +++ b/rhodecode/tests/functional/test_admin_repos.py @@ -251,8 +251,7 @@ class TestAdminReposController(TestContr response = self.app.delete(url('repo', repo_name=repo_name)) - self.assertTrue('''Deleted repository %s''' % (repo_name) in - response.session['flash'][0]) + self.checkSessionFlash(response, 'Deleted repository %s' % (repo_name)) response.follow() @@ -299,8 +298,7 @@ class TestAdminReposController(TestContr response = self.app.delete(url('repo', repo_name=repo_name)) - self.assertTrue('''Deleted repository %s''' % (repo_name) in - response.session['flash'][0]) + self.checkSessionFlash(response, 'Deleted repository %s' % (repo_name)) response.follow() diff --git a/rhodecode/tests/functional/test_admin_settings.py b/rhodecode/tests/functional/test_admin_settings.py --- a/rhodecode/tests/functional/test_admin_settings.py +++ b/rhodecode/tests/functional/test_admin_settings.py @@ -85,8 +85,7 @@ class TestAdminSettingsController(TestCo rhodecode_ga_code=new_ga_code )) - self.assertTrue('Updated application settings' in - response.session['flash'][0][1]) + self.checkSessionFlash(response, 'Updated application settings') self.assertEqual(RhodeCodeSetting .get_app_settings()['rhodecode_ga_code'], new_ga_code) diff --git a/rhodecode/tests/functional/test_admin_users.py b/rhodecode/tests/functional/test_admin_users.py --- a/rhodecode/tests/functional/test_admin_users.py +++ b/rhodecode/tests/functional/test_admin_users.py @@ -150,8 +150,7 @@ class TestAdminUsersController(TestContr .filter(User.username == username).one() response = self.app.delete(url('user', id=new_user.user_id)) - self.assertTrue("""Successfully deleted user""" in - response.session['flash'][0]) + self.checkSessionFlash(response, 'Successfully deleted user') def test_delete_browser_fakeout(self): response = self.app.post(url('user', id=1),