-
Describe the request-response cycle. Start with the client making a request.
-
Explain when each of these HTTP verbs would be used: GET, POST, PUT, DELETE.
-
What are all of the necessary routes for full CRUD functionality in Sinatra app? Why do we need seven routes when there are only four CRUD actions?
-
Describe the function of models in the MVC structure.
-
Describe the function of views in the MVC structure.
-
Describe the function of controllers in the MVC structure.
-
What is the difference between model tests, feature tests, and controller tests? Give an example of functionality tested using a model test, functionality tested in a feature test, and functionality tested in a controller test.
-
What does ActiveRecord do? Why do we use ORMs like ActiveRecord?
/week-2-diagnostic.markdown Secret
Created
December 11, 2015 16:15
-
-
Save brantwellman/0b82a85c1880358bc103 to your computer and use it in GitHub Desktop.
Week 2 Diagnostic
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
A client makes a response to the Resolving Name Server...if the RNS doesn't know the ip address instead of request it goes to the Root Name Server...if the RNS doesn't know the address it tells the Resolving NS the address of the Top Level Domain Server. If the TLD doesn't know the IP address it tells the RNS the address of the Name Server. The Name Server should know the IP address of the requested site and returns this to the RNS which then returns the ip address to the client, which then (finally) goes to the requested server. That server then processes the request and sends back the appropriate response - Headers, Body, and Response Code.
GET - Request from the client requesting information from the server.
POST - Request from the client to add new information to the server database.
PUT - Request from the client to update information already on the database associated with that user.
DELETE - Request from the client to delete information already on the database associated with that user.
/tasks - GET - Read - view list of objects(tasks)
/tasks/:id - GET - Read - view specific object(task) with given :id
/tasks/new - GET - Create - view form to submit information to create new object(task)
/tasks - POST - Create - Submit information to create new object(task)
/tasks/:id/edit - GET - Update - View form to submit information to edit existing object(task)
/tasks/:id - PUT - Update - Submit information to edit existing object(task)
/tasks/:id - DELETE - Delete - Delete existing object(task)
Controller Tests - Test that the proper response codes are sent to the client - when not 200s. Test that the proper routes are being used.
Model Tests - Test business logic is being handled properly. Test that Ruby objects are being created properly from the database.