Git Product home page Git Product logo

fff's Introduction

Travis CI: Build Status Better Code: BCH compliance Coveralls: Coverage Status

Features

  • Return a list of all orders on GET https://fast-food-fast-api.herokuapp.com/api/v1/orders
  • Return a single order on GET https://fast-food-fast-api.herokuapp.com/api/v1/orders/<orderID>
  • Post an order on POST https://fast-food-fast-api.herokuapp.com/api/v1/orders
  • Update the status of the order on PUT https://fast-food-fast-api.herokuapp.com/api/v1/orders/<orderID>

Testing

  • Install Git
  • Install Python 3
  • Install pytest in your virtualenv
  • Open console and run:

git clone https://github.com/CkCreative/fff.git cd fff && git checkout dev python run.py

  • On a new console window, cd to the /fff project directory and run:

pytest tests.py

  • You can also use Postman to test the endpoints.

Sample data to post with POST /api/v1/orders: { "id" : 11, "customer_id" : 1254, "status" : "" }

Sample data to update order status using PUT /api/v1/orders/<orderID>: { "status" : "Completed" }

Only valid JSON is accepted for POST and PUT To be able to test PUT, first POST and then try PUT to see the changes take effect.

fff's People

Contributors

ckcreative avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.