Skip to content
代码片段 群组 项目
未验证 提交 ed1225ba 编辑于 作者: Imre Farkas's avatar Imre Farkas 提交者: smriti
浏览文件

Improvements to admin/users feature specs

上级 6deb6ecb
No related branches found
No related tags found
无相关合并请求
......@@ -53,7 +53,7 @@
it 'does not show impersonate button for admin itself' do
subject
expect(page).not_to have_content('Impersonate')
expect(page).to have_no_content('Impersonate')
end
end
......@@ -66,7 +66,7 @@
end
context 'for user with expired password' do
let(:user_to_visit) do
let_it_be(:user_to_visit) do
another_user.update!(password_expires_at: Time.zone.now - 5.minutes)
another_user
end
......@@ -113,7 +113,7 @@
it 'does not show impersonate button' do
subject
expect(page).not_to have_content('Impersonate')
expect(page).to have_no_content('Impersonate')
end
end
end
......@@ -145,7 +145,6 @@
let_it_be(:another_user) { create(:user, :unconfirmed) }
let(:warning_alert) { page.find(:css, '[data-testid="alert-warning"]') }
let(:expected_styling) { { 'pointer-events' => 'none', 'cursor' => 'default' } }
context 'with an email that does not contain HTML' do
before do
......
......@@ -16,8 +16,10 @@
it 'shows user identities', :aggregate_failures do
visit admin_user_identities_path(user)
expect(page).to have_content(user.name)
expect(page).to have_content('twitter')
expect(page).to(
have_content(user.name)
.and(have_content('twitter'))
)
end
end
......
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册