Is it possible to create a variable shared beetween stubs?

40 views
Skip to first unread message

Duarte Ferreira

unread,
May 23, 2024, 11:39:24 AM5/23/24
to mountebank-discuss
I my current project I need to create a variable shared beetween my stubs like "state", is it possible ? 

Like:

"responses": [
    {
      "is": {
        "statusCode": 200,
"headers": {
"Access-Control-Allow-Credentials": "true"
},
              "concurrencyStamp": $ concurrencyStamp  
      }
    }
  ]
}

Is it possible ? how can I do it?

Noel Yap

unread,
Jun 26, 2024, 4:23:21 PM6/26/24
to mountebank-discuss
It looks like https://www.mbtest.org/docs/api/injection is the way to go about doing what you want. I'm in the early stages of doing something like this myself.
Reply all
Reply to author
Forward
0 new messages