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

Pipes - Sara Frandsen - API Muncher #39

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

Conversation

frankienakama
Copy link

API Muncher

Congratulations! You're submitting your assignment!

Comprehension Questions

Question Answer
How did you go about exploring the Edamam API, how did you try querying the API? It was a real pain. I used Postman to find the base url of the query to the api and then the uri of a specific recipe to create an object id. I used HTTParty to find and evaluate the response from Edamam.
Describe your API Wrapper. How did you decide on the methods you created? I made so many methods: to return the base url from Edamam using the query term, the from index and the to index (from which recipe to which, to be displayed on the page), to create an array of all the recipes in the response (based on the "hits" key), to create an id by slicing the uri at the "_" and finding the unique string, and one to make sure the response code is 200 (if not, displays an error in the logs so we can see where we messed up).
Describe an edge case or failure case test you wrote for your API Wrapper. I tested that it would return an empty array if there are no results instead of raising an error, based on the "count" key
Explain how VCR aids in testing an API. It fakes a call to the API by recording one and replaying for future tests. Saves you from calling to the API too much and potentially hitting your limit!
What is the Heroku URL of your deployed application? https://sara-eff-muncher.herokuapp.com/

@PilgrimMemoirs
Copy link

API Muncher

What We're Looking For

Feature Feedback
Core Requirements
Git hygiene Well Done
Comprehension questions Well Done
General
Rails fundamentals (RESTful routing, use of named paths) Well Done
Semantic HTML Mostly Good - closing footer tag missing
Errors are reported to the user Well Done
API Wrapper to handle the API requests Some Improvement - Nice instinct of splitting up functionality into seperate methods. However, the organization of how the methods are getting called should be done in a way where the controller shouldn't need to call as many. Rather, have a single method the controller action will call and that method will call any other methods it needs to. In this case, there only should be two public methods (one to get a lit of recipes and the other to get a specific recipe). Any others should be private and called within those public methods.
Controller testing Not Complete
Lib testing Mostly Good - All methods should have their own set of at least one positive and one negative test
Search Functionality Well Done
List Functionality Well Done
Show individual item functionality (link to original recipe opens in new tab) Almost - link should open into a new tab
Styling
Foundation Styling for responsive layout Well Done
List View shows 10 items at a time/pagination Mostly Good - List should have title of recipe with images.
The app is styled to create an attractive user interface Mostly Good - some suggestions: have the 'next' and 'prev' links centered below the list. Show page should have site name as header, with link to root page.
API Features
The App attributes Edaman Well Done
The VCR casettes do not contain the API key Well Done
External Resources
Link to deployed app on Heroku Well Done
Overall
Areas for Improvement Controller testing, testing all custom methods of an API wrapper, and organizing method calls

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