From 22ed15cbbf1fdaafaec3a95d20fb982501bd1766 Mon Sep 17 00:00:00 2001 From: ulferts Date: Mon, 23 Sep 2019 13:15:40 +0200 Subject: [PATCH] attempt to fix flickering spec --- .../spec/features/my/assigned_to_me_spec.rb | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/modules/my_page/spec/features/my/assigned_to_me_spec.rb b/modules/my_page/spec/features/my/assigned_to_me_spec.rb index 8582f9bf34..b95b1fa872 100644 --- a/modules/my_page/spec/features/my/assigned_to_me_spec.rb +++ b/modules/my_page/spec/features/my/assigned_to_me_spec.rb @@ -176,16 +176,6 @@ describe 'Assigned to me embedded query on my page', type: :feature, js: true do # exists as default assigned_area.expect_to_exist - sleep(0.5) - - assigned_area.resize_to(1, 2) - - sleep(0.1) - - assigned_area.expect_to_span(1, 1, 2, 3) - # has been moved down by resizing - created_area.expect_to_span(2, 2, 3, 3) - within assigned_area.area do expect(page) .to have_selector('.subject', text: assigned_work_package.subject) @@ -199,5 +189,13 @@ describe 'Assigned to me embedded query on my page', type: :feature, js: true do expect(page) .to have_selector('.subject', text: assigned_work_package_2.subject) end + + assigned_area.resize_to(1, 2) + + my_page.expect_notification(message: I18n.t('js.notice_successful_update')) + + assigned_area.expect_to_span(1, 1, 2, 3) + # has been moved down by resizing + created_area.expect_to_span(2, 2, 3, 3) end end