utf8_validator 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +1 -1
- data/Gemfile.lock +2 -2
- data/VERSION +1 -2
- data/examples/fullstring.rb +1 -0
- data/test/test_utf8_validator.rb +11 -0
- data/utf8_validator.gemspec +9 -17
- metadata +44 -74
- data/.document +0 -5
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
@@ -2,7 +2,7 @@ GEM
|
|
2
2
|
remote: http://rubygems.org/
|
3
3
|
specs:
|
4
4
|
git (1.2.5)
|
5
|
-
jeweler (1.
|
5
|
+
jeweler (1.6.4)
|
6
6
|
bundler (~> 1.0.0)
|
7
7
|
git (>= 1.2.5)
|
8
8
|
rake
|
@@ -14,5 +14,5 @@ PLATFORMS
|
|
14
14
|
|
15
15
|
DEPENDENCIES
|
16
16
|
bundler (~> 1.0.0)
|
17
|
-
jeweler (
|
17
|
+
jeweler (>= 1.5.2)
|
18
18
|
rcov
|
data/VERSION
CHANGED
@@ -1,2 +1 @@
|
|
1
|
-
1.0.
|
2
|
-
|
1
|
+
1.0.1
|
data/examples/fullstring.rb
CHANGED
data/test/test_utf8_validator.rb
CHANGED
@@ -110,6 +110,17 @@ class TestUtf8Validator < Test::Unit::TestCase
|
|
110
110
|
end
|
111
111
|
end
|
112
112
|
|
113
|
+
# Interesting valid strings
|
114
|
+
def test_0080_interesting_valid_strings
|
115
|
+
test_data = [
|
116
|
+
"“Iñtërnâtiônàlizætiøn”", # A suggestion from the net
|
117
|
+
]
|
118
|
+
test_data.each do |string|
|
119
|
+
assert @validator.valid_encoding?(string), "interesting valid strings: #{string}"
|
120
|
+
assert string.force_encoding("UTF-8").valid_encoding?, "interesting valid strings 19: #{string}" if RUBY_VERSION =~ /1\.9/
|
121
|
+
end
|
122
|
+
end
|
123
|
+
|
113
124
|
#--
|
114
125
|
# Validation should fail for the following tests
|
115
126
|
#--
|
data/utf8_validator.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{utf8_validator}
|
8
|
-
s.version = "1.0.
|
8
|
+
s.version = "1.0.1"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
|
-
s.authors = [
|
12
|
-
s.date = %q{2011-
|
11
|
+
s.authors = [%q{Guy Allard}]
|
12
|
+
s.date = %q{2011-08-22}
|
13
13
|
s.description = %q{A State Machine implementation of a UTF-8 Encoding
|
14
14
|
Validation algorithm.}
|
15
15
|
s.email = %q{allard.guy.m@gmail.com}
|
@@ -18,7 +18,6 @@ Validation algorithm.}
|
|
18
18
|
"README.rdoc"
|
19
19
|
]
|
20
20
|
s.files = [
|
21
|
-
".document",
|
22
21
|
"Gemfile",
|
23
22
|
"Gemfile.lock",
|
24
23
|
"LICENSE.txt",
|
@@ -35,33 +34,26 @@ Validation algorithm.}
|
|
35
34
|
"utf8_validator.gemspec"
|
36
35
|
]
|
37
36
|
s.homepage = %q{http://github.com/gmallard/utf8_validator}
|
38
|
-
s.licenses = [
|
39
|
-
s.require_paths = [
|
40
|
-
s.rubygems_version = %q{1.
|
37
|
+
s.licenses = [%q{MIT}]
|
38
|
+
s.require_paths = [%q{lib}]
|
39
|
+
s.rubygems_version = %q{1.8.6.1}
|
41
40
|
s.summary = %q{A UTF-8 Encoding Validator.}
|
42
|
-
s.test_files = [
|
43
|
-
"examples/fullstring.rb",
|
44
|
-
"test/helper.rb",
|
45
|
-
"test/test_raise_request.rb",
|
46
|
-
"test/test_utf8_validator.rb"
|
47
|
-
]
|
48
41
|
|
49
42
|
if s.respond_to? :specification_version then
|
50
|
-
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
51
43
|
s.specification_version = 3
|
52
44
|
|
53
45
|
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
54
46
|
s.add_development_dependency(%q<bundler>, ["~> 1.0.0"])
|
55
|
-
s.add_development_dependency(%q<jeweler>, ["
|
47
|
+
s.add_development_dependency(%q<jeweler>, [">= 1.5.2"])
|
56
48
|
s.add_development_dependency(%q<rcov>, [">= 0"])
|
57
49
|
else
|
58
50
|
s.add_dependency(%q<bundler>, ["~> 1.0.0"])
|
59
|
-
s.add_dependency(%q<jeweler>, ["
|
51
|
+
s.add_dependency(%q<jeweler>, [">= 1.5.2"])
|
60
52
|
s.add_dependency(%q<rcov>, [">= 0"])
|
61
53
|
end
|
62
54
|
else
|
63
55
|
s.add_dependency(%q<bundler>, ["~> 1.0.0"])
|
64
|
-
s.add_dependency(%q<jeweler>, ["
|
56
|
+
s.add_dependency(%q<jeweler>, [">= 1.5.2"])
|
65
57
|
s.add_dependency(%q<rcov>, [">= 0"])
|
66
58
|
end
|
67
59
|
end
|
metadata
CHANGED
@@ -1,78 +1,57 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: utf8_validator
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
5
|
-
|
6
|
-
- 1
|
7
|
-
- 0
|
8
|
-
- 0
|
9
|
-
version: 1.0.0
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 1.0.1
|
5
|
+
prerelease:
|
10
6
|
platform: ruby
|
11
|
-
authors:
|
7
|
+
authors:
|
12
8
|
- Guy Allard
|
13
9
|
autorequire:
|
14
10
|
bindir: bin
|
15
11
|
cert_chain: []
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
dependencies:
|
20
|
-
- !ruby/object:Gem::Dependency
|
12
|
+
date: 2011-08-22 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
21
15
|
name: bundler
|
22
|
-
requirement: &
|
16
|
+
requirement: &25774980 !ruby/object:Gem::Requirement
|
23
17
|
none: false
|
24
|
-
requirements:
|
18
|
+
requirements:
|
25
19
|
- - ~>
|
26
|
-
- !ruby/object:Gem::Version
|
27
|
-
segments:
|
28
|
-
- 1
|
29
|
-
- 0
|
30
|
-
- 0
|
20
|
+
- !ruby/object:Gem::Version
|
31
21
|
version: 1.0.0
|
32
22
|
type: :development
|
33
23
|
prerelease: false
|
34
|
-
version_requirements: *
|
35
|
-
- !ruby/object:Gem::Dependency
|
24
|
+
version_requirements: *25774980
|
25
|
+
- !ruby/object:Gem::Dependency
|
36
26
|
name: jeweler
|
37
|
-
requirement: &
|
27
|
+
requirement: &21011640 !ruby/object:Gem::Requirement
|
38
28
|
none: false
|
39
|
-
requirements:
|
40
|
-
- -
|
41
|
-
- !ruby/object:Gem::Version
|
42
|
-
segments:
|
43
|
-
- 1
|
44
|
-
- 5
|
45
|
-
- 2
|
29
|
+
requirements:
|
30
|
+
- - ! '>='
|
31
|
+
- !ruby/object:Gem::Version
|
46
32
|
version: 1.5.2
|
47
33
|
type: :development
|
48
34
|
prerelease: false
|
49
|
-
version_requirements: *
|
50
|
-
- !ruby/object:Gem::Dependency
|
35
|
+
version_requirements: *21011640
|
36
|
+
- !ruby/object:Gem::Dependency
|
51
37
|
name: rcov
|
52
|
-
requirement: &
|
38
|
+
requirement: &25805300 !ruby/object:Gem::Requirement
|
53
39
|
none: false
|
54
|
-
requirements:
|
55
|
-
- -
|
56
|
-
- !ruby/object:Gem::Version
|
57
|
-
|
58
|
-
- 0
|
59
|
-
version: "0"
|
40
|
+
requirements:
|
41
|
+
- - ! '>='
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
version: '0'
|
60
44
|
type: :development
|
61
45
|
prerelease: false
|
62
|
-
version_requirements: *
|
63
|
-
description:
|
64
|
-
A State Machine implementation of a UTF-8 Encoding
|
65
|
-
Validation algorithm.
|
46
|
+
version_requirements: *25805300
|
47
|
+
description: ! "A State Machine implementation of a UTF-8 Encoding \nValidation algorithm."
|
66
48
|
email: allard.guy.m@gmail.com
|
67
49
|
executables: []
|
68
|
-
|
69
50
|
extensions: []
|
70
|
-
|
71
|
-
extra_rdoc_files:
|
51
|
+
extra_rdoc_files:
|
72
52
|
- LICENSE.txt
|
73
53
|
- README.rdoc
|
74
|
-
files:
|
75
|
-
- .document
|
54
|
+
files:
|
76
55
|
- Gemfile
|
77
56
|
- Gemfile.lock
|
78
57
|
- LICENSE.txt
|
@@ -87,41 +66,32 @@ files:
|
|
87
66
|
- test/test_raise_request.rb
|
88
67
|
- test/test_utf8_validator.rb
|
89
68
|
- utf8_validator.gemspec
|
90
|
-
has_rdoc: true
|
91
69
|
homepage: http://github.com/gmallard/utf8_validator
|
92
|
-
licenses:
|
70
|
+
licenses:
|
93
71
|
- MIT
|
94
72
|
post_install_message:
|
95
73
|
rdoc_options: []
|
96
|
-
|
97
|
-
require_paths:
|
74
|
+
require_paths:
|
98
75
|
- lib
|
99
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
76
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
100
77
|
none: false
|
101
|
-
requirements:
|
102
|
-
- -
|
103
|
-
- !ruby/object:Gem::Version
|
104
|
-
|
105
|
-
segments:
|
78
|
+
requirements:
|
79
|
+
- - ! '>='
|
80
|
+
- !ruby/object:Gem::Version
|
81
|
+
version: '0'
|
82
|
+
segments:
|
106
83
|
- 0
|
107
|
-
|
108
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
84
|
+
hash: -2635983573335272792
|
85
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
109
86
|
none: false
|
110
|
-
requirements:
|
111
|
-
- -
|
112
|
-
- !ruby/object:Gem::Version
|
113
|
-
|
114
|
-
- 0
|
115
|
-
version: "0"
|
87
|
+
requirements:
|
88
|
+
- - ! '>='
|
89
|
+
- !ruby/object:Gem::Version
|
90
|
+
version: '0'
|
116
91
|
requirements: []
|
117
|
-
|
118
92
|
rubyforge_project:
|
119
|
-
rubygems_version: 1.
|
93
|
+
rubygems_version: 1.8.6.1
|
120
94
|
signing_key:
|
121
95
|
specification_version: 3
|
122
96
|
summary: A UTF-8 Encoding Validator.
|
123
|
-
test_files:
|
124
|
-
- examples/fullstring.rb
|
125
|
-
- test/helper.rb
|
126
|
-
- test/test_raise_request.rb
|
127
|
-
- test/test_utf8_validator.rb
|
97
|
+
test_files: []
|