# HG changeset patch # User Marcin Kuzminski # Date 2016-06-27 22:14:31 # Node ID f422c79f31ae58aa29ec3b5da39ead68af820c66 # Parent 7f18164f356d188c58e05bfdd85bb7a58758ef28 tests: fixed home tests with cached values 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 @@ -110,10 +110,12 @@ class TestHomeController(TestController) def test_index_show_version(self, autologin_user, name, state): version_string = 'RhodeCode Enterprise %s' % rhodecode.__version__ - show = SettingsModel().get_setting_by_name('show_version') - show.app_settings_value = state - Session().add(show) + sett = SettingsModel().create_or_update_setting( + 'show_version', state, 'bool') + Session().add(sett) Session().commit() + SettingsModel().invalidate_settings_cache() + response = self.app.get(url(controller='home', action='index')) if state is True: response.mustcontain(version_string)