Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

karate - how to validate that param is string and having max length

Tags:

karate

In karate, how to check if in the response, name field is string type and having max length upto 35. I know how to validate, string, but don't know how to check the length at same time.

name: '#string',

like image 827
Renu Avatar asked Sep 14 '25 20:09

Renu


1 Answers

you are pretty close,

"#string? _.length <= 35"

_ means self in expressions

refer 'self' validation expressions

like image 120
Babu Sekaran Avatar answered Sep 17 '25 19:09

Babu Sekaran