diff options
author | abcang <abcang1015@gmail.com> | 2017-05-24 22:36:10 +0900 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2017-05-24 15:36:10 +0200 |
commit | bbc3db8b200d4570df8a9129e51bbf09470f02f3 (patch) | |
tree | 78b7952c66cd35932def1fb15e25d80e3c53e3ee /spec | |
parent | f937cad68f5343d114475cf870df2cd25895a7db (diff) |
Add test when hashtag and URL are concatenated (#3279)
Diffstat (limited to 'spec')
-rw-r--r-- | spec/lib/formatter_spec.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/spec/lib/formatter_spec.rb b/spec/lib/formatter_spec.rb index 2e0f11110..ec61eaa43 100644 --- a/spec/lib/formatter_spec.rb +++ b/spec/lib/formatter_spec.rb @@ -165,6 +165,14 @@ RSpec.describe Formatter do expect(subject).to eq '<p>http://www\.google\.com</p>' end end + + context 'concatenates hashtag and URL' do + let(:local_text) { '#hashtaghttps://www.google.com' } + + it 'has valid hashtag' do + expect(subject).to match('/tags/hashtag" class="mention hashtag" rel="tag">#<span>hashtag</span></a>') + end + end end describe '#reformat' do |