Strange tests

Hi Jason !

I am slowly building a parser and found the following specs:

“should not include trailing double-asterisk in a word if the next
char is a space”:
src: "yow** "
htm: “yow”

“should not include trailing double-asterisk in a word if the next char
is EOF”:
src: “yow**”
htm: “yow”

“should include trailing asterisk in a word if the next char is a
double-asterisk”:
src: “yow***”
htm: “yow*”

“should include trailing double-asterisk in a word if the next char is
a double-asterisk”:
src: “yow****”
htm: “yow**”

I just don’t understand why we should eat the trailing “**”. This
sounds like over-engineering…

Please tell me the reason for this (conditional) stripping.

Gaspard

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs