diff options
| author | cedricnjanga | 2018-03-06 06:53:04 -0800 | 
|---|---|---|
| committer | cedricnjanga | 2018-03-09 08:48:56 -0800 | 
| commit | f6fd7707c0ae9f23769928da6ba180327915e74f (patch) | |
| tree | 995b7b9526e3480f146164cd08da3aae0a22584e /spec/features | |
| parent | a26a2e98b9552467d4a92ad6b5be22c3f3070efa (diff) | |
| download | chouette-core-f6fd7707c0ae9f23769928da6ba180327915e74f.tar.bz2 | |
Refs #5934 Remove destructive action links for route stop points in Routes#show
Diffstat (limited to 'spec/features')
| -rw-r--r-- | spec/features/routes_spec.rb | 38 | 
1 files changed, 0 insertions, 38 deletions
| diff --git a/spec/features/routes_spec.rb b/spec/features/routes_spec.rb index dbab2c0d2..d7578c729 100644 --- a/spec/features/routes_spec.rb +++ b/spec/features/routes_spec.rb @@ -90,44 +90,6 @@ describe "Routes", :type => :feature do          end        end -      def click_on_stop_point_dropdown_btn(num) -        find(:xpath, "(//div[contains(@class, 'btn') and contains(@class, 'dropdown-toggle')])[#{num}]").click -      end - -      context 'user does not have permission to edit stop areas' do -        it 'does not show edit links for stop areas' do -          @user.update_attribute(:permissions, []) -           -          expect(page).not_to have_content(I18n.t('stop_points.actions.edit'), visible: false) -          stop_points.each_with_index do |sp, i| -            click_on_stop_point_dropdown_btn(i + 1) -            expect(page).not_to have_link(I18n.t('stop_points.actions.edit'), href: edit_stop_area_referential_stop_area_path(stop_area_referential, sp)) -          end -        end -      end - -      context 'user has permission to edit stop areas' do -        xit 'shows edit links for stop areas' do -          @user.update_attribute(:permissions, ["stop_areas.update"]) -          visit referential_line_route_path(referential, line, route) -           -          stop_points.each_with_index do |sp, i| -            click_on_stop_point_dropdown_btn(i + 1) -            expect(page).to have_link(I18n.t('stop_points.actions.edit'), href: edit_stop_area_referential_stop_area_path(stop_area_referential, sp)) -          end -        end -      end - -      context 'user does not have permission to destroy stop areas' do -        it 'does not show destroy links for stop areas' do -          @user.update_attribute(:permissions, []) -          stop_points.each_with_index do |sp, i| -            click_on_stop_point_dropdown_btn(i + 1) -            expect(page).not_to have_link(I18n.t('stop_points.actions.destroy'), href: stop_area_referential_stop_area_path(sp.referential, sp)) -          end -        end -      end -        context 'user has permission to destroy journey patterns' do          xit 'shows destroy links for journey patterns' do            @user.update_attribute(:permissions, ["stop_areas.destroy"]) | 
