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

Queues - Danielle Birbal & Marisol Lopez - VideoStoreAPI #4

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

Conversation

marisol-lopez
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 talked about it, and we whiteboarded our ERD based on the requirements.

|
| List all the completed endpoints of your application. |

get '/customers', to: 'customers#index', as: 'customers'
get '/movies', to: 'movies#index', as: 'movies'
get '/movies/:title', to: 'movies#show', as: 'movie'
get '/rentals/overdue', to: 'customers#overdue', as: 'overdue'
post '/rentals/:title/check-out', to: 'movies#checkout', as: 'checkout'
post '/rentals/:title/check-in', to: 'movies#checkin', as: 'checkin'
|
| Describe a set of positive and negative test cases you implemented for a model. |
We mostly did associations and validations testing for the model, but we did do a test to make sure that an inventory of less than 0 could not be implemented.
|
| Describe a set of positive and negative test cases you implemented for a controller. |
We did a test case in the movies controller to check to make sure that the path for movies was valid and it would go to the correct controller action. As for a negative test case, we implemented a 404 test case for anyone trying to search for a title that did not exist.
|
| How does your API respond when bad data is sent to it? |
When certain bad data is sent you will either get an error message, a bad request HTTP code, or even an empty array.
|
| Describe one of your custom model methods and why you chose to wrap that functionality into a method. |
We didn't utilize any custom model methods.
|
| Do you have any recommendations on how we could improve this project for the next cohort? |
Clarify that the movies_checked_out_count and the available_inventory does not need to be apart of the table, because we did not realize that, and heard that was only clarified when specifically asking an instructor. Although, we were able to figure it out, it would've been way easier, to have written a method, because it did cause a lot of trouble when trying to complete that part of the assignment, especially with our database.
|
| Link to Trello | https://trello.com/b/BepwXIXV/videostoreapi |
| Link to ERD | https://www.lucidchart.com/invitations/accept/0f78b53b-e5b1-4bb3-bb2f-9cda3c9dd569 |

***Checked smoke tests for required and optional and all were fine.

@PilgrimMemoirs
Copy link

Video Store

What We're Looking For

Feature Feedback
Core Requirements
Git hygiene Well Done
Comprehension questions Mostly Good - Endpoints are only the '/movies' or '/movies/:title' part of the route. Be mindful of the format of the table, it's hard to read when it gets broken. You can preview how it'll look before you submit.
General
Business Logic in Models ❗️ WAY Too much logic in the controllers, especially with checkout and checkin
All 3 required endpoints return expected JSON data Well Done
Requests respond with appropriate HTTP Status Code Well Done
Errors are reported Well Done
Testing
Passes all Smoke Tests Well Done
Model Tests - all relations, validations, and custom functions test positive & negative cases Mostly Good - Missing positive cases for validations, should also test that each model is able to save when all required data is present and good.
Controller Tests - URI parameters and data in the request body have positive & negative cases Well Done
Optionals
POST routes use URI parameter and request body to add a new record to the database Well Done
GET /customers shows how many movies are checked out by a customer Well Done
GET /movies/:title shows updated inventory Well Done
Overall
Does your controller need instance methods? When were the only appropriate times to use them when we were building web apps? (for passing to views). If we dong have any views, do the variables in the controller methods have to be instance, or can/should they be local?
Does your controller need instance methods? When were the only appropriate times to use them when we were building web apps? (for passing to views). If we dong have any views, do the variables in the controller methods have to be instance, or can/should they be local?
Great work completing the required, and optional Post, to expectations! The biggest concerns are having too much logic in your controller, which also leads to not being able to test that logic. Model tests are also missing positive cases for validations.

@Hamled Hamled assigned Bella8 and ghost May 19, 2017
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.

4 participants