Adjust accessibility spec

We currently don't have a full edit view.
pull/3563/head
Stefan Botzenhart 9 years ago
parent 218761bc19
commit 928d679cd1
  1. 24
      spec/features/accessibility/custom_fields_spec.rb

@ -31,7 +31,7 @@ require 'features/custom_fields/custom_fields_page'
require 'features/projects/project_settings_page'
require 'features/work_packages/work_packages_page'
describe 'Custom field accessibility', type: :feature do
RSpec.describe 'Custom field accessibility', type: :feature do
describe 'language tag' do
let(:custom_field) {
FactoryGirl.create(:work_package_custom_field,
@ -63,7 +63,9 @@ describe 'Custom field accessibility', type: :feature do
it { expect(element['lang']).to eq(lang_tag_locale) }
end
before do allow(User).to receive(:current).and_return current_user end
before do
allow(User).to receive(:current).and_return current_user
end
describe 'Custom Field Admin Page', js: true do
let(:custom_fields_page) { CustomFieldsPage.new }
@ -182,7 +184,7 @@ describe 'Custom field accessibility', type: :feature do
end
end
describe 'Work Package' do
describe 'Work Package', js: true do
let(:work_packages_page) { WorkPackagesPage.new(project) }
let!(:work_package) {
FactoryGirl.create(:work_package,
@ -191,7 +193,7 @@ describe 'Custom field accessibility', type: :feature do
custom_values: { custom_field.id => 'value' })
}
describe 'index', js: true do
describe 'index' do
shared_context 'index page with query' do
let!(:query) do
query = FactoryGirl.build(:query, project: project)
@ -240,7 +242,9 @@ describe 'Custom field accessibility', type: :feature do
describe 'show' do
shared_context 'work package show view' do
before { work_packages_page.visit_show work_package.id }
before do
work_packages_page.visit_show work_package.id
end
end
shared_examples_for 'attribute header lang' do
@ -369,9 +373,9 @@ describe 'Custom field accessibility', type: :feature do
include_context 'work package edit view'
it_behaves_like 'attribute header lang'
skip # it_behaves_like 'attribute header lang'
it_behaves_like 'attribute value lang'
skip # it_behaves_like 'attribute value lang'
end
context 'en' do
@ -380,9 +384,9 @@ describe 'Custom field accessibility', type: :feature do
include_context 'work package edit view'
it_behaves_like 'attribute header lang'
skip # it_behaves_like 'attribute header lang'
it_behaves_like 'attribute value lang'
skip # it_behaves_like 'attribute value lang'
end
describe 'default value language is different' do
@ -411,7 +415,7 @@ describe 'Custom field accessibility', type: :feature do
include_context 'work package edit view'
it_behaves_like 'attribute value lang'
skip # it_behaves_like 'attribute value lang'
end
end
end

Loading…
Cancel
Save