node-mocks-http

Mock 'http' objects for testing Express routing functions (by eugef)

Node-mocks-http Alternatives

Similar projects and alternatives to node-mocks-http

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a better node-mocks-http alternative or higher similarity.

node-mocks-http reviews and mentions

Posts with mentions or reviews of node-mocks-http. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2022-07-19.
  • Hi im having trouble building my api tests
    2 projects | /r/node | 19 Jul 2022
    Yes, but when every function handler is separate from the router, then you can use node-mocks-http to test each handler, to test the router is simpler to use supertest to write integration tests, for E2E tests I personally recommend [pactum](pactumjs.github.io/)
  • Test interceptor
    4 projects | /r/Nestjs_framework | 8 Jul 2022
    It depends of how you mock the request and response that you passed to ExecutionContext because the response should be modified. I recommend you to use node-mocks-http

Stats

Basic node-mocks-http repo stats
3
738
6.9
2 months ago

eugef/node-mocks-http is an open source project licensed under GNU General Public License v3.0 or later which is an OSI approved license.

The primary programming language of node-mocks-http is JavaScript.

Power Real-Time Data Analytics at Scale
Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
www.influxdata.com