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

Added search form on the places index page. #751

Merged
merged 4 commits into from
Jul 1, 2015

Conversation

GabrielSandoval
Copy link
Contributor

image

places#show has a search form but places#index doesn't have. I added a search form in the index page of the 'places' so that the users may easily search the place they want to see.

@pozorvlak Sorry I messed up my last PR. Here is a new one. I left the gitignore untouched this time.

@pozorvlak
Copy link
Member

Looks good! However, it should be covered by a test. I would say "just copy the existing test for the Show page", but

  1. there isn't one
  2. the existing tests for the Show page are in a deprecated style.

So you'd need to write a whole new file of "feature" tests for the places-index page. Do you feel confident to do that? The good news is that feature tests are more straightforward to write - that's why we deprecated view and controller tests!

@GabrielSandoval
Copy link
Contributor Author

Thanks @pozorvlak! I'll start working on this as soon as I'm confident about testing. I'm at bit new to rails and I'm excited to try this one.

GabrielSandoval,
AELOGICA Intern

@GabrielSandoval
Copy link
Contributor Author

Hi @pozorvlak,

I added the feature test for the places search form. Please see if it's all good.

Thanks!

@@ -15,3 +15,16 @@
Geocoder.configure(:lookup => :nominatim)
end

Geocoder::Lookup::Test.add_stub(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you please move this to config/environments/test.rb along with the other Geocoder stubs?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi, I moved the stubs to config/environments/test.rb. Just tell me if there's anything more needed to be done.

@pozorvlak
Copy link
Member

Excellent - thanks!

pozorvlak added a commit that referenced this pull request Jul 1, 2015
Added search form on the places index page.
@pozorvlak pozorvlak merged commit 4648464 into Growstuff:dev Jul 1, 2015
@GabrielSandoval
Copy link
Contributor Author

Thanks @pozorvlak!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants