Improve regexp that matches functional tests

The regexp was added by @semanticart in a7024ef12b7c1fe362918267f4ed1d1.

This patch improves the regular expression in two ways:

1.  It adds escape characters (`/`) before the curly braces (`{`, `}`).
2.  It removes unnecessary question marks (`?`).

In regular expressions, curly braces are meta-characters used to specify
the amount of repetition, so they need to be escaped. The Ruby regular
expression engine is smart enough to figure out what to do in this case,
but it outputs the following warnings on that line:

    warning: regexp has invalid interval
    warning: regexp has `}' without escape

The question marks are not necessary, since dot star (`.*`) matches zero
or more of any character.