Maintenance: Improve test stability.
This commit is contained in:
parent
56fc5859e6
commit
4c83541c21
2 changed files with 5 additions and 8 deletions
|
@ -34,6 +34,8 @@ RSpec.configure do |config|
|
||||||
wait.until_exists do
|
wait.until_exists do
|
||||||
current_login
|
current_login
|
||||||
end
|
end
|
||||||
|
|
||||||
|
await_empty_ajax_queue
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -959,14 +959,9 @@ RSpec.describe 'Ticket zoom', type: :system do
|
||||||
end
|
end
|
||||||
|
|
||||||
# https://github.com/zammad/zammad/issues/3335
|
# https://github.com/zammad/zammad/issues/3335
|
||||||
context 'ticket state sort order maintained when locale is de-de', authenticated_as: :authenticate do
|
context 'ticket state sort order maintained when locale is de-de', authenticated_as: :user do
|
||||||
def authenticate
|
|
||||||
user.preferences[:locale] = 'de-de'
|
|
||||||
user
|
|
||||||
end
|
|
||||||
|
|
||||||
context 'when existing ticket is open' do
|
context 'when existing ticket is open' do
|
||||||
let(:user) { create(:customer) }
|
let(:user) { create(:customer, preferences: { locale: 'de-de' }) }
|
||||||
let(:ticket) { create(:ticket, customer: user) }
|
let(:ticket) { create(:ticket, customer: user) }
|
||||||
|
|
||||||
it 'shows ticket state dropdown options in sorted translated alphabetically order' do
|
it 'shows ticket state dropdown options in sorted translated alphabetically order' do
|
||||||
|
@ -979,7 +974,7 @@ RSpec.describe 'Ticket zoom', type: :system do
|
||||||
end
|
end
|
||||||
|
|
||||||
context 'when a new ticket is created' do
|
context 'when a new ticket is created' do
|
||||||
let(:user) { create(:agent, groups: [permitted_group]) }
|
let(:user) { create(:agent, preferences: { locale: 'de-de' }, groups: [permitted_group]) }
|
||||||
let(:permitted_group) { create(:group) }
|
let(:permitted_group) { create(:group) }
|
||||||
|
|
||||||
it 'shows ticket state dropdown options in sorted order' do
|
it 'shows ticket state dropdown options in sorted order' do
|
||||||
|
|
Loading…
Reference in a new issue