Maintenance: Stabilize ticket history test.
This commit is contained in:
parent
e6aec87df1
commit
170bfc6e59
1 changed files with 3 additions and 6 deletions
|
@ -2,10 +2,10 @@
|
||||||
|
|
||||||
require 'rails_helper'
|
require 'rails_helper'
|
||||||
|
|
||||||
RSpec.describe 'Ticket history', type: :system, time_zone: 'Europe/London' do
|
RSpec.describe 'Ticket history', type: :system, time_zone: 'Europe/London', authenticated_as: :admin_de do
|
||||||
let(:group) { Group.find_by(name: 'Users') }
|
let(:group) { create(:group) }
|
||||||
let(:ticket) { create(:ticket, group: group) }
|
let(:ticket) { create(:ticket, group: group) }
|
||||||
let!(:session_user) { User.find_by(login: 'admin@example.com') }
|
let(:admin_de) { create(:admin, :groupable, preferences: { locale: 'de-de' }, group: group) }
|
||||||
|
|
||||||
before do
|
before do
|
||||||
freeze_time
|
freeze_time
|
||||||
|
@ -35,9 +35,6 @@ RSpec.describe 'Ticket history', type: :system, time_zone: 'Europe/London' do
|
||||||
|
|
||||||
travel_back
|
travel_back
|
||||||
|
|
||||||
session_user.preferences[:locale] = 'de-de'
|
|
||||||
session_user.save!
|
|
||||||
|
|
||||||
# Suppress the modal dialog that invites to contributions for translations that are < 95% as this breaks the tests for de-de.
|
# Suppress the modal dialog that invites to contributions for translations that are < 95% as this breaks the tests for de-de.
|
||||||
page.evaluate_script "App.LocalStorage.set('translation_support_no', true, App.Session.get('id'))"
|
page.evaluate_script "App.LocalStorage.set('translation_support_no', true, App.Session.get('id'))"
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue