Testing the GET order feature

Let's create a brand new package in a different project. Why a different project? We have explored the idea that the API deserves its own set of features and that we should decouple it from the core layer using a well-defined interface that we will mock. Since it is a different problem domain, we should create a different package. This way, we can develop them and manage their life cycles in an independent fashion.


For a simple project like this, it is OK if you prefer to simply put both layers in the same package.

So, let's create a mycafe-api/ folder with the same project layout we have been using so far. Initialize the project by creating a basic package.json file, and then, run the following commands to install ...

Get Learning Behavior-driven Development with JavaScript now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.