2.0.0 • Published 6 years ago

@gigster/module-loopback-jest v2.0.0

Weekly downloads
24
License
UNLICENSED
Repository
-
Last release
6 years ago

loopback-jest

RoleNameEmailSlack
Product OwnerRyan Borkerborker@gigster.com@borker
MaintainerMark Miyashitamark.miyashita@gigster.com@mark

Overview

Adds the jest testing framework to a Loopback API. This module generates the base infrastructure to use jest with a Loopback API and optionally generates tests for the default API.

Usage

Specification

NameStatusDescription
generateTeststrue/falseSet to true if you would like generated tests to be created for you for the API.

Dependencies

This module is dependent on jest version 21.2.1.

Examples

There are two examples for this package:

  1. with-tests - This example is generated with generateTests: true so it has the infrastructure as well as generated tests.
  2. without-tests - This example is generated with generateTests: false so it only has the base infrastructure and does not contain tests.

Troubleshooting

Testing

Module tests are defined using a test/scenarios.yaml file. This file defines the set of example gigs that we generate as part of integration testing. To run all tests, run yarn test at the root of this module.

Each scenario is generated in test/scenario/<name> which you can then cd into and run the actual app. For a scenario called default, this is done via:

cd test/scenario/default
yarn install

# Run tests.
yarn test

# Start the app.
yarn start
2.0.0

6 years ago

1.3.7

6 years ago

1.3.6

6 years ago

1.3.5

6 years ago

1.3.4

6 years ago

1.3.3

6 years ago

1.3.2

6 years ago

1.3.1

6 years ago

1.3.0

6 years ago

1.2.1

6 years ago

1.2.0

6 years ago

1.1.8

6 years ago

1.1.7

6 years ago

1.1.6

6 years ago

1.1.5

6 years ago

1.1.4

6 years ago

1.1.3

6 years ago

1.1.2

6 years ago

1.1.1

6 years ago

1.1.0

6 years ago

1.1.0-alpha.2

6 years ago

1.1.0-alpha.1

6 years ago

1.0.0

6 years ago