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

Carets -- Guillermina and Kayla #25

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

Conversation

murog
Copy link

@murog murog commented Nov 13, 2017

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. The baseline requirements reflected in the seed data did not have any relationships that we saw. However, moving onto optional requirements, we had to adjust our ERD model to include a 'rentals' table. Rentals belonged to a customer and a movie.
Describe a set of positive and negative test cases you implemented for a model. Looking through our model test cases, we mostly had negative test cases...uh oh! We spent most of our time in controller testing. However, in the customer model test we checked whether a new instance of a customer was invalid until it was given a name.
Describe a set of positive and negative test cases you implemented for a controller. We checked whether the count of Movie objects does not change when posting to the create path with invalid data and that it increases when posting to the create path with valid data.
How does your API respond when bad data is sent to it? It responds with bad request and a hash that only includes ok: false.
Describe one of your custom model methods and why you chose to wrap that functionality into a method. Originally, we checked whether a movie had available inventory in the rentals controller. However, we moved this to the movie model. Any movie is then able to give a boolean value of true or false indicating whether it has available inventory. In the rental model, we have a method that validates creation of an object that checks whether its movie is available or not. If the movie is not available, then the rental is not able to be saved. This could have extended to a method that decrements the associated movie's available inventory after creation but we did not get that far.
Do you have any recommendations on how we could improve this project for the next cohort? We enjoyed the project! Worked well as a pair project.
Link to Trello https://trello.com/b/sZPApTdv/video-store-api
Link to ERD We forgot to take a photo of our whiteboard ERD )-: Sorry!

Kayla Ecker and others added 30 commits November 6, 2017 12:39
…check movie inventory before creating a new rental, passing tests
@tildeee
Copy link

tildeee commented Nov 17, 2017

Video Store

What We're Looking For

Feature Feedback
Core Requirements
Git hygiene to kayla: let's get together and check out your git config, I think there's something up with your login info
Comprehension questions x
General
Business Logic in Models x
All 3 required endpoints return expected JSON data x
Requests respond with appropriate HTTP Status Code x
Errors are reported x
Testing
Passes all Smoke Tests x
Model Tests - all relations, validations, and custom functions test positive & negative cases didn't completely test custom functions like rental#movie_available?
Controller Tests - URI parameters and data in the request body have positive & negative cases x
Optionals
POST routes use URI parameter and request body to add a new record to the database x
GET /customers shows how many movies are checked out by a customer
GET /movies/:title shows updated inventory
Overall

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