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

Brenna & Alison's VideoStore API #10

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

Conversation

bcmdarroch
Copy link

Video Store API

Congratulations! You're submitting your assignment!
If you didn't get to the functionality the question is asking about, reply with what you would have done if you had completed it.

Comprehension Questions

Question Answer
Explain how you came up with the design of your ERD, based on the seed data. We wrote out the fields in each model, according to the guidelines in the README. We used our big brains to figure out relationships between the Customer, Movie, and Rental models. We decided on using a join table for the Rentals, similar to the OrderItems in betsy.
List all the completed endpoints of your application. Movies index, movies show, customer index, rentals checkout, rentals checkin, rentals overdue
Describe a set of positive and negative test cases you implemented for a model. We tested that a Rental was valid if its checkout and due dates were a week apart. We tested that a Rental was invalid if they were not a week apart.
Describe a set of positive and negative test cases you implemented for a controller. We tested that a Rental was successfully created if the correct input was provided. We tested that a Rental was not created if the provided input was invalid (like a negative customer ID number).
How does your API respond when bad data is sent to it? It returns JSON with error messages in a hash.
Describe one of your custom model methods and why you chose to wrap that functionality into a method. We wrote a custom validation in Rental to test if a new Rental's due date and checkout date were a week apart. It was something that strictly concerned the Rental model, and nothing else.
Do you have any recommendations on how we could improve this project for the next cohort? Seems great to us!
Link to Trello https://trello.com/b/S1AFYNlp/videostore
Link to ERD https://www.lucidchart.com/invitations/accept/fe8758c4-4489-4d65-9a6c-867abd8d2357

@kariabancroft
Copy link

Video Store

What We're Looking For

Feature Feedback
Core Requirements
Git hygiene Good
Comprehension questions Yes
General
Business Logic in Models Yes - mostly around Rental, though there is still opportunity to consolidate some of the rental controller logic into rental model method(s)
All 3 required endpoints return expected JSON data Yes
Requests respond with appropriate HTTP Status Code Yes
Errors are reported Yes
Testing
Passes all Smoke Tests Yes
Model Tests - all relations, validations, and custom functions test positive & negative cases Yes - looks good
Controller Tests - URI parameters and data in the request body have positive & negative cases Yes - nice job covering these tests, rentals look good with those more complex scenarios
Optionals
POST routes use URI parameter and request body to add a new record to the database Yes
GET /customers shows how many movies are checked out by a customer Yes
GET /movies/:title shows updated inventory N/A
Overall Nice job covering the major learning goals on this assignment

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.

5 participants