Skip to content

Commit

Permalink
Merge pull request #258 from epimorphics/spike/resolve-search-error
Browse files Browse the repository at this point in the history
Hotfix: Resolves `uninitialized constant SearchController::RoutingError`
  • Loading branch information
jonrandahl authored Oct 9, 2024
2 parents bdfec9e + 353d229 commit f8a0229
Show file tree
Hide file tree
Showing 7 changed files with 95 additions and 9 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ This app allows the user to explore HMLR price-paid open linked data.

## Changelog

## 1.7.11 - 2024-10

- (JOn) Cleans up erroneous make commands
- (Jon) Resolves failing tests for summary comparison due to updated copy
- (Jon) Resolves `uninitialized constant SearchController::RoutingError` error

## 1.7.10 - 2024-10

- (Jon) Updated the message reported to the error page while in development mode
Expand Down
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -416,4 +416,4 @@ DEPENDENCIES
yajl-ruby

BUNDLED WITH
2.4.8
2.4.4
3 changes: 0 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ ${GITHUB_TOKEN}:
all: image

assets: auth
@./bin/bundle config set --local without 'development test'
@./bin/bundle install
@./bin/rails assets:clean assets:precompile

Expand Down Expand Up @@ -98,8 +97,6 @@ tag:
test: assets
@echo "Running tests ..."
@./bin/rails test
@echo "Running system tests ..."
@./bin/rails test:system

vars:
@echo "Docker: ${REPO}:${TAG}"
Expand Down
2 changes: 0 additions & 2 deletions app/controllers/search_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,6 @@ def create # rubocop:disable Metrics/MethodLength
# Determine status symbol to pass to the error page
def rescue_standard_error(err)
status = case err
when RoutingError, MissingTemplate
:not_found
when MalformedSearchError, ArgumentError
:bad_request
else
Expand Down
2 changes: 1 addition & 1 deletion app/lib/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
module Version
MAJOR = 1
MINOR = 7
PATCH = 10
PATCH = 11
SUFFIX = nil
VERSION = "#{MAJOR}.#{MINOR}.#{PATCH}#{SUFFIX && ".#{SUFFIX}"}"
end
2 changes: 1 addition & 1 deletion test/controllers/search_controller_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class SearchControllerTest < ActionDispatch::IntegrationTest
match = query_command
.search_results
.summarise
.match(/Showing (\d+) transactions \(from (\d*) matching transactions\) for (\d+) properties/)
.match(/Showing (\d+) transactions \(from (\d*) or more matching transactions\) for (\d+) properties/)

_(query_command.size).must_equal 10

Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit f8a0229

Please sign in to comment.