Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correct slug for asylum support tribunal documents #595

Merged
merged 2 commits into from
Nov 4, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/lib/specialist_publisher_wiring.rb
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@
}

define_singleton(:asylum_support_decision_finder_schema) {
FinderSchema.new(Rails.root.join("finders/schemas/asylum-support-decisions.json"))
FinderSchema.new(Rails.root.join("finders/schemas/asylum-support-tribunal-decisions.json"))
}

define_singleton(:utaac_decision_finder_schema) {
Expand Down
2 changes: 1 addition & 1 deletion app/models/document_factory_registry.rb
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ def asylum_support_decision_factory
AsylumSupportDecisionValidator.new(
AsylumSupportDecision.new(
SpecialistDocument.new(
SlugGenerator.new(prefix: "asylum-support-decisions"),
SlugGenerator.new(prefix: "asylum-support-tribunal-decisions"),
*args,
),
)
Expand Down
10 changes: 5 additions & 5 deletions features/step_definitions/asylum_support_decision_steps.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
When(/^I create a asylum support decision$/) do
@document_title = "Example asylum support decision"
@slug = "asylum-support-decisions/example-asylum-support-decision"
@slug = "asylum-support-tribunal-decisions/example-asylum-support-decision"
@document_fields = asylum_support_decision_fields(title: @document_title)

create_asylum_support_decision(@document_fields)
Expand Down Expand Up @@ -44,7 +44,7 @@

Given(/^a draft asylum support decision exists$/) do
@document_title = "Example asylum support decision"
@slug = "asylum-support-decisions/example-asylum-support-decision"
@slug = "asylum-support-tribunal-decisions/example-asylum-support-decision"
@document_fields = asylum_support_decision_fields(title: @document_title)
@rummager_fields = asylum_support_decision_rummager_fields(title: @document_title)

Expand Down Expand Up @@ -72,7 +72,7 @@
@document_title = "Example asylum support decision"
@attachment_title = "My attachment"

@slug = "asylum-support-decisions/example-asylum-support-decision"
@slug = "asylum-support-tribunal-decisions/example-asylum-support-decision"
@document_fields = asylum_support_decision_fields(title: @document_title)

create_asylum_support_decision(@document_fields, publish: true)
Expand All @@ -81,7 +81,7 @@

Given(/^a published asylum support decision exists$/) do
@document_title = "Example asylum support decision"
@slug = "asylum-support-decisions/example-asylum-support-decision"
@slug = "asylum-support-tribunal-decisions/example-asylum-support-decision"
@document_fields = asylum_support_decision_fields(title: @document_title)

create_asylum_support_decision(@document_fields, publish: true)
Expand Down Expand Up @@ -114,7 +114,7 @@

When(/^I publish a new asylum support decision$/) do
@document_title = "Example asylum support decision"
@slug = "asylum-support-decisions/example-asylum-support-decision"
@slug = "asylum-support-tribunal-decisions/example-asylum-support-decision"
@document_fields = asylum_support_decision_fields(title: @document_title)
@rummager_fields = asylum_support_decision_rummager_fields(title: @document_title)

Expand Down
2 changes: 1 addition & 1 deletion features/support/document_helpers.rb
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ def check_added_to_rummager(slug, fields)
document_type_slug_prefix_map = {
"cma-cases" => "cma_case",
"aaib-reports" => "aaib_report",
"asylum-support-decisions" => "asylum_support_decision",
"asylum-support-tribunal-decisions" => "asylum_support_decision",
"international-development-funding" => "international_development_fund",
"drug-safety-update" => "drug_safety_update",
"drug-device-alerts" => "medical_safety_alert",
Expand Down