aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--app/views/routes/duplicate.html.slim9
-rw-r--r--spec/controllers/routes_controller_spec.rb10
2 files changed, 19 insertions, 0 deletions
diff --git a/app/views/routes/duplicate.html.slim b/app/views/routes/duplicate.html.slim
new file mode 100644
index 000000000..a5947049d
--- /dev/null
+++ b/app/views/routes/duplicate.html.slim
@@ -0,0 +1,9 @@
+= pageheader 'map-marker',
+ t('routes.new.title'),
+ ''
+
+.page_content
+ .container-fluid
+ .row
+ .col-lg-8.col-lg-offset-2.col-md-8.col-md-offset-2.col-sm-10.col-sm-offset-1
+ == render 'form'
diff --git a/spec/controllers/routes_controller_spec.rb b/spec/controllers/routes_controller_spec.rb
index cf12f00b1..5c17b78b8 100644
--- a/spec/controllers/routes_controller_spec.rb
+++ b/spec/controllers/routes_controller_spec.rb
@@ -75,4 +75,14 @@ RSpec.describe RoutesController, type: :controller do
end
end
+ describe "GET /duplicate" do
+ it "returns success" do
+ get :duplicate,
+ referential_id: route.line.line_referential_id,
+ line_id: route.line_id,
+ id: route.id
+
+ expect(response).to be_success
+ end
+ end
end