I was using below function to set the body parameters in my feature file -
this.Given(/^I set body parameters (.*) and (.*)$/, function(bodyParamName, bodyParamVal, callback) {........
});
And calling it in my feature file as -
And I set body parameters grant_type and client_credentials
It was working fine previously but now give "TypeError" as -
"TypeError: this.apickli.addBodyParameters is not a function"
Can any please help to resolve it?
Solved! Go to Solution.
You can use Given I set body to grant_type=client_credentials which is already available in the framework
You can use Given I set body to grant_type=client_credentials which is already available in the framework
@Sai Saran Vaidyanathan Fantastic Sai !!! Thank you very much. It is working, Where can I see available functions in the framework?
I checked - node_modules/apickli/apickli-gherkin.js but could not find " Given I set body to grant_type=client_credentials ".
Kindly let me know where can I see all functions provide by the frame work.
Thanks
Raj
Yes - check this link
Just to make sure - as my understanding the function used for -
"Given I set body to grant_type=client_credentials " is -
Given(/^I set body to (.*)$/, function(bodyValue, callback) {
this.apickli.setRequestBody(bodyValue);
callback();
});
Please rectify me if I am wrong.
cheers
Raj
thats correct