karatelabs / karate

Test Automation Made Simple

Home Page:https://karatelabs.github.io/karate

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Improvement] Rename "request" keyword ?

harmin-parra opened this issue · comments

I have noticed that Karate uses the request keyword in POST and PUT requests in order to refer to the payload.

Given url 'http://localhost:8097/user/create'
And request { id: '1234' , name: 'John Smith'}
When method POST
Then status 200

The word request is not very "natural "

Wouldn't be better to replace request by payload, body or data ?

@harmin-parra yes I've thought about it. but I think it's fine, 90% of the time, you don't worry about headers, or cookies and you care only about the body. you are the first ever to bring this up in 7 years by the way :)

the JS API introduced recently does a more "coder friendly" design F Y I: https://github.com/karatelabs/karate/wiki/Karate-JavaScript-Mocks

closing as won't fix