Sha256: aeefcbc07f8d5d7c41f0870bf52e85f0f79f2152758b629bfe864e9d8d10855a
Contents?: true
Size: 312 Bytes
Versions: 125
Compression:
Stored size: 312 Bytes
Contents
module Gherkin module Formatter module Escaping # Escapes a pipes and backslashes: # # * | becomes \| # * \ becomes \\ # # This is used in the pretty formatter. def escape_cell(s) s.gsub(/\|/, "\\|").gsub(/\\(?!\|)/, "\\\\\\\\") end end end end
Version data entries
125 entries across 125 versions & 2 rubygems