chicken-sloths / bangazon-api-sprint1

API for a mock Amazon + Etsy platform providing developers access to the company's employee & product data
0 stars 0 forks source link

put now works on nonexistent computer ids #99

Closed kenziebottoms closed 6 years ago

kenziebottoms commented 6 years ago

Description

When PUTting, if you hit an id that a computer doesn't already own, it creates a new one

Related Ticket(s)

97

Steps to Test Solution

  1. npm checkout kb-computer-put
  2. npm run db:generate
  3. comment out non-computer routes
  4. postman: PUT http://localhost:8080/api/v1/computers/25
    {"mac_address":"as:u:wish","purchase_date":"2016-10-08T13:17:00.534Z","decommission_date":"2017-06-22T09:18:52.019Z"}
  5. GET http://localhost:8080/api/v1/computers/25 should now give you the above data
jordan-castelloe commented 6 years ago

testing!

DavidLarsKetch commented 6 years ago

testing