This commit is contained in:
Mir Bhatia
2026-04-01 09:27:51 +02:00
parent 42620b5af2
commit 027c006bba
2 changed files with 7 additions and 1 deletions
+1 -1
View File
@@ -47,7 +47,7 @@ See COPYRIGHT and LICENSE files for more details.
mobile_icon: :pencil,
mobile_label: t(:button_edit),
size: :medium,
href: edit_project_news_path(@news),
href: edit_project_news_path(@project, @news),
aria: { label: I18n.t(:button_edit) },
title: I18n.t(:button_edit)
) do |button|
+6
View File
@@ -103,6 +103,12 @@ RSpec.describe NewsController do
expect(response).to be_not_found
end
it "renders edit link with correct project identifier" do
get :show, params: { project_id: news.project_id, id: news.id }
expect(response.body).to include edit_project_news_path(project, news)
end
end
end