twitter-text 1.1.1 → 1.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/Rakefile +1 -1
- data/TODO +0 -1
- data/lib/hithighlighter.rb +6 -0
- data/spec/hithighlighter_spec.rb +4 -0
- metadata +9 -18
data/Rakefile
CHANGED
@@ -9,7 +9,7 @@ require 'digest'
|
|
9
9
|
|
10
10
|
spec = Gem::Specification.new do |s|
|
11
11
|
s.name = "twitter-text"
|
12
|
-
s.version = "1.1.
|
12
|
+
s.version = "1.1.2"
|
13
13
|
s.authors = ["Matt Sanford", "Patrick Ewing", "Ben Cherry", "Britt Selvitelle"]
|
14
14
|
s.email = ["matt@twitter.com", "patrick.henry.ewing@gmail.com", "bcherry@gmail.com", "bs@brittspace.com"]
|
15
15
|
s.homepage = "http://twitter.com"
|
data/TODO
CHANGED
data/lib/hithighlighter.rb
CHANGED
data/spec/hithighlighter_spec.rb
CHANGED
@@ -75,6 +75,10 @@ describe Twitter::HitHighlighter do
|
|
75
75
|
it "should highlight around a link" do
|
76
76
|
@highlighter.hit_highlight("test <a>test</a> test", [[3, 11]]).should == "tes<em>t <a>test</a> t</em>est"
|
77
77
|
end
|
78
|
+
|
79
|
+
it "should fail gracefully with bad hits" do
|
80
|
+
@highlighter.hit_highlight("test test", [[5, 20]]).should == "test <em>test</em>"
|
81
|
+
end
|
78
82
|
|
79
83
|
end
|
80
84
|
|
metadata
CHANGED
@@ -1,12 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: twitter-text
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
|
5
|
-
segments:
|
6
|
-
- 1
|
7
|
-
- 1
|
8
|
-
- 1
|
9
|
-
version: 1.1.1
|
4
|
+
version: 1.1.2
|
10
5
|
platform: ruby
|
11
6
|
authors:
|
12
7
|
- Matt Sanford
|
@@ -17,21 +12,19 @@ autorequire: ""
|
|
17
12
|
bindir: bin
|
18
13
|
cert_chain: []
|
19
14
|
|
20
|
-
date: 2010-
|
15
|
+
date: 2010-05-11 00:00:00 -07:00
|
21
16
|
default_executable:
|
22
17
|
dependencies:
|
23
18
|
- !ruby/object:Gem::Dependency
|
24
19
|
name: actionpack
|
25
|
-
|
26
|
-
|
20
|
+
type: :runtime
|
21
|
+
version_requirement:
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
27
23
|
requirements:
|
28
24
|
- - ">="
|
29
25
|
- !ruby/object:Gem::Version
|
30
|
-
segments:
|
31
|
-
- 0
|
32
26
|
version: "0"
|
33
|
-
|
34
|
-
version_requirements: *id001
|
27
|
+
version:
|
35
28
|
description: A gem that provides text handling for Twitter
|
36
29
|
email:
|
37
30
|
- matt@twitter.com
|
@@ -77,20 +70,18 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
77
70
|
requirements:
|
78
71
|
- - ">="
|
79
72
|
- !ruby/object:Gem::Version
|
80
|
-
segments:
|
81
|
-
- 0
|
82
73
|
version: "0"
|
74
|
+
version:
|
83
75
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
84
76
|
requirements:
|
85
77
|
- - ">="
|
86
78
|
- !ruby/object:Gem::Version
|
87
|
-
segments:
|
88
|
-
- 0
|
89
79
|
version: "0"
|
80
|
+
version:
|
90
81
|
requirements: []
|
91
82
|
|
92
83
|
rubyforge_project:
|
93
|
-
rubygems_version: 1.3.
|
84
|
+
rubygems_version: 1.3.5
|
94
85
|
signing_key:
|
95
86
|
specification_version: 3
|
96
87
|
summary: Twitter text handling library
|