forwardemail / forwardemail/supertest

EADDRINUSE on multiple test suites or test cases.

Open
#597 3 comments 1 reaction 0 assignees View on GitHub
Dominant language
JavaScript
Stars
14.4k
Forks
782
PR merge metrics
No merged PRs in 30d

Description

Similiar to https://github.com/visionmedia/supertest/issues/568.

One caveat is use _request.agent(app.listen())_ (on search for solutions), other is use describe sections.

Other method is requiring the app on each iteration:
```js
beaforeEach(() => {
require('../index.js')
})
```

But this isn't a option due to load all server configurations and route handlers, but could be a solution.
Some tests fail cause doesn't start the server because the port already in use.

Tested every solution proposed.

--
Jest version: 24.5
Node: 10.4
OS: GNU/Linux

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.