Questions tagged [mountebank]

Mountebank is the tool used for cross-platform, multi-protocol test doubles over the wire. Written in javascript, currently supporting http, https, smtp, tcp

Mountebank is the tool (https://github.com/bbyars/mountebank) used for cross-platform, multi-protocol test doubles over the wire. Written in javascript, currently supporting http, https, smtp, tcp

docs on http://www.mbtest.org/

50 questions
1
vote
0 answers

docker asp.net log configuration to enable log error too

the application uses Microsoft.Extensions.Logging _logger.LogError _logger.LogInformation this is configured in appsettings.json "Logging": { "IncludeScopes": false, "Console": { "LogLevel": { "Default": "Information" …
user2201789
  • 1,083
  • 2
  • 20
  • 45
1
vote
1 answer

[ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received type undefined, Mountebank

npm start Giving me error whenever running mountebank server with ^2.0.0 version of mountebank TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received type undefined at validateString…
karan kural
  • 25
  • 1
  • 1
  • 5
1
vote
1 answer

Using Mountebank, is it possible for an imposter to perform some logic after returning a response to the client?

My app has a workflow where it calls out to an external service and receives a response. Sometime after that, the external service will eventually call an endpoint in my app. For integration testing, is it possible to setup an imposter with…
lancekf
  • 133
  • 1
  • 5
1
vote
1 answer

What are the advantages of Mountebank over Rest Assured?

I'm started reading the Mountebank framework for our project which uses Microservices. Based on my learning on few days, Mountebank is mainly based on testing micro services using a concept of service virtualization. To test the Rest APIs we can use…
irs102info
  • 526
  • 1
  • 6
  • 16
1
vote
2 answers

node.js mysql result into a variable

I've been using mountebank to do some stubbing for performance testing and its an awesome tool. The functional teams have asked if it can be repurposed to support functional testing and I'd said i'd have a look. What I want to achieve is to select…
Bob Ruub
  • 21
  • 1
  • 4
1
vote
1 answer

Regex Pattern Matching for similar URL

I need to send different Response for different urls. But the Regex that I am using is not working. The two Regex in question is "/v1/users/[^/]+/permissions/domain/HTTP/" (Eg:…
user2208533
  • 37
  • 2
  • 5
1
vote
1 answer

Unable to create mocks on post request with content-type : application/x-www-form-urlencoded

I am working with mountebank to create mocks for an External REST API which is a POST request with content-type : application/x-www-form-urlencoded. The API is of format https:///dpay/MPmt and data payload is passed in format…
nikki
  • 13
  • 5
1
vote
1 answer

Stub ODATA service

We will be building a Java/JS client that reads data from a server through ODATA. What will be the easiest way to setup a stubbed ODATA server for our development and testing purposes. In the REST world I would have gone with MounteBank. Even this…
Prasanna
  • 10,956
  • 2
  • 28
  • 40
1
vote
1 answer

How to start Mountebank in Docker?

How can I use Docker to start Mountebank as a server? I am following this tutorial but I can't make it work. This error appears: warn: [mb:2525] dry running injection, use the isDryRun request field in your JavaScript to ignore... error: [mb:2525]…
ridermansb
  • 10,779
  • 24
  • 115
  • 226
0
votes
0 answers

Using Mountebank with Node.js - Invoking methods from another class inside predicates

I made a connection to a database successfully, but I don't understand how I can invoke the method that brings me the information when the conditions of any of the predicates I made are met. This is my first time virtualizing services with…
Ivan92
  • 5
  • 2
0
votes
1 answer

Add common CORS headers in Mountebank responses

React app that is using mounteback as mock server, I am getting this error Access to fetch at 'http://localhost:8080/xxx/api/secured/policies' from origin 'http://localhost:3000' has been blocked by CORS policy: No 'Access-Control-Allow-Origin'…
Carlos Jaime C. De Leon
  • 2,476
  • 2
  • 37
  • 53
0
votes
1 answer

How to deploy mountebank in Azure?

just worked through the basic mountebank tutorial. worked great!! next step is to deploy mountebank in Azure. i am wondering if anyone has successfully deployed mountebank into azure? which PAAS/SAAS did you use?
0
votes
0 answers

Unable to return integer type when injecting responses via CSV lookup in Mountebank stub

I have a simple Mountebank stub declaration that based on a given URL with certain format, it matches the ID and returns the corresponding record from a comma-separated values file: // imposters.json { "name": "characters-api.imposter", "port":…
x80486
  • 6,627
  • 5
  • 52
  • 111
0
votes
1 answer

Domain name is not loading the response but localhost works

I am using mountebank for mocking responses which is running in Docker on port 2525. Stubs are created on port 443. The response is successful when I use localhost but not with the domain name. The domain names are redirected in hosts file. OS:…
Dhivya V
  • 1
  • 1
0
votes
1 answer

How to create multiple imposters in mountebank?

I am new to mountebank and i seeing if i can create multiple imposters in a single post request? i am using the following request { "imposters": [ { "port": 5150, "protocol": "http", "recordRequests": true, "_links": { …
Krishna
  • 186
  • 2
  • 9