Sha256: 58a5816a27c63b5be4fb3bfe1b92a01bddb4edcbcbd56ab12cca72b630597c26
Contents?: true
Size: 475 Bytes
Versions: 6
Compression:
Stored size: 475 Bytes
Contents
# coding: utf-8 require 'spec_helper' RSpec.describe Verse::Sanitizer, '.sanitize' do subject(:sanitizer) { described_class.new } { "\e[20h" => '', "\e[?1h" => '', "\e[20l" => '', "\e[?9l" => '', "\eO" => '', "\e[m" => '', "\e[0m" => '', "\eA" => '', "\e[0;33;49;3;9;4m\e[0m" => '' }.each do |code, expected| it "strips #{code} from string" do expect(sanitizer.sanitize(code)).to eq(expected) end end end
Version data entries
6 entries across 6 versions & 1 rubygems