Skip to main content
Last updated

Running Tests

Unit testing

To run the unit tests:

sh
$ npm test
sh
$ npm test

To run single unit tests:

sh
$ npm test --single=[nameOfFile] where [nameOfFile] can be a regex
sh
$ npm test --single=[nameOfFile] where [nameOfFile] can be a regex

integration tests

Pactserver

To run integration tests against a pact server the following command can be used:

sh
$ npm test:integration:pactserver
sh
$ npm test:integration:pactserver

devnet

To run integration tests against devnet it requires starting devnet and exposing the pact endpoints at http://localhost:8080 . For more details, see instructions at the Devnet Github repository .

The following command can be used:

sh
$ npm test:integration:devnet
sh
$ npm test:integration:devnet

TODO make Pact server port configurable


Was this page helpful?

Receive important developer updates