jamesdbloom/mockserver-grunt

Adding callback to start_mockserver call

arturmkrtchyan opened this issue · 1 comments

What do you think of adding callback function to start_mockserver call to be able to define expectations once server is started ?

It will provide async capability to the end users.

Something like this:

mockserver.start_mockserver({
                serverPort: 1080,
                serverSecurePort: 1082,
                proxyPort: 1090,
                proxySecurePort: 1092,
                verbose: true
            }, function() {
                  console.log('Ready');
             });

If you are open to this I can apply it soon.

OK never mind just quickly checked and found that you use promise and we can use .then(function(){}).