提交 bac19f4c 编写于 作者: A Alfredo Sumaran

Fix failing test

Test was not waiting for the page to be fully loaded
上级 43252ccb
require 'spec_helper'
feature 'Create New Merge Request', feature: true, js: true do
include WaitForAjax
let(:user) { create(:user) }
let(:project) { create(:project, :public) }
......@@ -53,10 +55,11 @@ feature 'Create New Merge Request', feature: true, js: true do
expect(page.find_link('Side-by-side')[:class]).not_to match(/\bactive\b/)
click_link 'Side-by-side'
wait_for_ajax
click_link 'Changes'
expect(page.find_link('Inline')[:class]).not_to match(/\bactive\b/)
expect(page.find_link('Side-by-side')[:class]).to match(/\bactive\b/)
within '.merge-request' do
expect(page).not_to have_css('a.btn.active', text: 'Inline')
expect(page).to have_css('a.btn.active', text: 'Side-by-side')
end
end
end
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册