Closed kylef closed 7 years ago
URI Template variables may only contain ALPHA / DIGIT / "_" / pct-encoded as per the URI Template specification (RFC 6570 section 2.3):
ALPHA / DIGIT / "_" / pct-encoded
2.3. Variables variable-list = varspec *( "," varspec ) varspec = varname [ modifier-level4 ] varname = varchar *( ["."] varchar ) varchar = ALPHA / DIGIT / "_" / pct-encoded
2.3. Variables
variable-list = varspec *( "," varspec ) varspec = varname [ modifier-level4 ] varname = varchar *( ["."] varchar ) varchar = ALPHA / DIGIT / "_" / pct-encoded
As such, when we generated URI Template variable names they should be correctly escaped as pointed out in https://github.com/apiaryio/dredd/issues/799. This pull request adds this escaping.
Looks good but tests failing.
@pksunkara I've fixed the code linting failure.
URI Template variables may only contain
ALPHA / DIGIT / "_" / pct-encoded
as per the URI Template specification (RFC 6570 section 2.3):As such, when we generated URI Template variable names they should be correctly escaped as pointed out in https://github.com/apiaryio/dredd/issues/799. This pull request adds this escaping.