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

Melissa : Edges : Muncher #35

Open
wants to merge 11 commits into
base: master
Choose a base branch
from

Conversation

melicious-dish
Copy link

API Muncher

Congratulations! You're submitting your assignment!

Comprehension Questions

Question Answer
How did you go about exploring the Edamam API, and how did you try querying the API? I used the Edamam API docs as well as Postman to figure out how to navigate it
What is an API Wrapper? Why is it in lib? How would your project change if you needed to interact with more than one API (aka more than just the Edamam API)? API wrapper is the way place we interact with or call the API. It's in the lib folder so we can call it across the program - to the controller, etc. If we wanted to change the API we were looking through, the code in the controller wouldn't change, we would make a new wrapper in the lib folder.
Describe your API wrapper, the methods you created in it, and why you decided to create those methods/how they were helpful I have 3 methods in the API wrapper: list_recipes takes the query (search from the user) and places it it the url structure that Edamam uses. The gem HTTParty querys Edamam and translates that into Ruby code that is then placed in an array and prints out the results. Show_details method takes the URI from Edmamam and returns the info from that specific recipe. Create_recipe is a helper method to take the api params from Edamam and create a new instance of a recipe
What was an edge case or failure case test you wrote for your API Wrapper? What was a nominal case?
How does VCR aid in testing an API? It records one search query and uses that info for the rest of the tests. That way we don't need to get info from Edmam every time we test
What is the Heroku URL of your deployed application? https://munchie-munchie.herokuapp.com

@droberts-sea
Copy link

API Muncher

What We're Looking For

Feature Feedback
Core Requirements
Git hygiene yes
Comprehension questions yes
General
Rails fundamentals (RESTful routing, use of named paths) routing as used by your site is RESTful, but your routes file is a bit messy - see inline
Semantic HTML yes
Errors are reported to the user some - A search with no hits results in a polite message, but mangling the URI on the show page results in an exception rather than a polite error message. Getting a good handle on error handling is not just good for your users, it will also make your life easier as a developer.
API Wrapper to handle the API requests yes
Controller testing no
Lib testing no
Search Functionality yes
List Functionality yes
Show individual item functionality yes
Styling
List view shows 10 items at a time and/or has pagination yes
Attractive and usable UI yes
API Features
The App attributes Edamam yes
The VCR cassettes do not contain the API key yes
External Resources
Link to deployed app on Heroku yes
Overall This is a good start. I am definitely disappointed not to see tests - the work around mocking the external dependency with VCR is an important learning goal for this assignment, and not something we'll have the opportunity to come back to. Make sure you understand how and why we do that. However, the site is attractive and functional, and it is clear to me that the learning goals around working with an API and building non-model classes for a Rails app were met. I've left a few inline comments below, but other than the lack of tests I'm pretty happy with what I see. Keep up the hard work!

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