Add multiple branch screen#2731
Merged
thomasiles merged 4 commits intomainfrom Apr 29, 2026
Merged
Conversation
We are mocking the path helpers in the view spec for pages/index.html.erb. But testing against the actual path helpers. This was covering an assertion that the view when there are no pages doesn't display the link to add a route. The page does display the link to add a route, whether there are pages or not. The current spec was passing because the test was using the real path helper which the mock didn't match. This commit removes the test. The "Add a route" link is always displayed. When the test was written it probably wasn't supposed to show. Following the link now shows a page explaining how to add a route.
Add a new placeholder view for showing the routes for a form.
Add a new route and controller for showing multiple branch routes. The controller returns a 404 if the feature is not enabled.
The page list view shows a link to add a route if the group has multiple branches enabled. If the feature flag is not set, the original link to current routing page is shown as normal.
|
🎉 A review copy of this PR has been deployed! You can reach it at: https://pr-2731.admin.review.forms.service.gov.uk/ It may take 5 minutes or so for the application to be fully deployed and working. If it still isn't ready For the sign in details and more information, see the review apps wiki page. |
lfdebrux
approved these changes
Apr 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add a placeholder routes page with link
Trello card: https://trello.com/c/d912GOE9/3068-add-new-routing-screen-to-admin
This PR adds a new route and page to show the routes for a form. The link on the question list page only shows if the feature is enabled for the form's group.
The controller returns 404 if the flag isn't enabeld.
The page:

The link:

Things to consider when reviewing