diff options
| author | Vlatka Pavisic | 2017-04-11 15:35:01 +0200 |
|---|---|---|
| committer | Vlatka Pavisic | 2017-04-11 15:35:01 +0200 |
| commit | aa481c087b162bc775b4418e205f91c5b6bead19 (patch) | |
| tree | 914ba9b39e0338317bcc2bfd839f745647beda1a /spec/features | |
| parent | 8adf909694b52959483818bf839d6e180015eb99 (diff) | |
| download | chouette-core-aa481c087b162bc775b4418e205f91c5b6bead19.tar.bz2 | |
Refs #3047: Associate RoutingConstraintZone with StopPoints
Diffstat (limited to 'spec/features')
| -rw-r--r-- | spec/features/lines_spec.rb | 8 | ||||
| -rw-r--r-- | spec/features/routes_spec.rb | 4 |
2 files changed, 6 insertions, 6 deletions
diff --git a/spec/features/lines_spec.rb b/spec/features/lines_spec.rb index bbe3c757b..e7e1e601c 100644 --- a/spec/features/lines_spec.rb +++ b/spec/features/lines_spec.rb @@ -20,10 +20,10 @@ describe "Lines", :type => :feature do end it 'allows only R in CRUD' do - expect(page).to have_content(I18n.t('actions.show')) - expect(page).not_to have_content(I18n.t('actions.edit')) - expect(page).not_to have_content(I18n.t('actions.destroy')) - expect(page).not_to have_content(I18n.t('actions.add')) + expect(page).to have_link(I18n.t('actions.show')) + expect(page).not_to have_link(I18n.t('actions.edit'), href: edit_referential_line_path(referential, lines.first)) + expect(page).not_to have_link(I18n.t('actions.destroy'), href: referential_line_path(referential, lines.first)) + expect(page).not_to have_link(I18n.t('actions.add'), href: new_referential_line_path(referential)) end context 'filtering' do diff --git a/spec/features/routes_spec.rb b/spec/features/routes_spec.rb index 36d0e8f87..4b90a6ec6 100644 --- a/spec/features/routes_spec.rb +++ b/spec/features/routes_spec.rb @@ -102,7 +102,7 @@ describe "Routes", :type => :feature do it 'does not show edit buttons for routes' do @user.update_attribute(:permissions, []) visit referential_line_path(referential, line) - expect(page).not_to have_content(I18n.t('actions.edit')) + expect(page).not_to have_link(I18n.t('actions.edit'), href: edit_referential_line_route_path(referential, line, route)) end end @@ -136,7 +136,7 @@ describe "Routes", :type => :feature do it 'does not show destroy buttons for routes' do @user.update_attribute(:permissions, []) visit referential_line_path(referential, line) - expect(page).not_to have_content(I18n.t('actions.destroy')) + expect(page).not_to have_link(I18n.t('actions.destroy'), href: referential_line_route_path(referential, line, route)) end end end |
