[#7042] Fix test
Signed-off-by: Tim Van Steenburgh <tvansteenburgh@gmail.com>
diff --git a/Allura/allura/tests/functional/test_user_profile.py b/Allura/allura/tests/functional/test_user_profile.py
index 6f01e6a..0dbbe77 100644
--- a/Allura/allura/tests/functional/test_user_profile.py
+++ b/Allura/allura/tests/functional/test_user_profile.py
@@ -164,7 +164,8 @@
return m
eps = map(ep, ['a', 'b', 'c', 'd'])
order = {'user_profile_sections.order': 'b, d,c , f '}
- delattr(type(app), '_sections')
+ if hasattr(type(app), '_sections'):
+ delattr(type(app), '_sections')
with mock.patch('allura.lib.helpers.iter_entry_points') as iep:
with mock.patch.dict(tg.config, order):
iep.return_value = eps