gravaty 9.0.1 → 10.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG +10 -0
- data/Gemfile +1 -1
- data/ISSUES.md +2 -2
- data/README.md +119 -105
- data/Rakefile +1 -1
- data/acknowledgements.md +2 -2
- data/authors.md +2 -2
- data/copyright.md +4 -4
- data/examples/avatar.rb +1 -1
- data/examples/basics.rb +1 -1
- data/examples/cacert.pem +142 -77
- data/examples/profile.rb +1 -1
- data/examples/xmlrpc.rb +3 -3
- data/gravaty.gemspec +9 -9
- data/html/CHANGELOG.html +19 -6
- data/html/COPYING_md.html +7 -6
- data/html/Gemfile.html +8 -7
- data/html/Gravaty.html +12 -12
- data/html/Gravaty/Gravaty.html +121 -121
- data/html/Gravaty/ParsableDuckType.html +8 -5
- data/html/Gravaty/Parser.html +21 -21
- data/html/Gravaty/Parsers.html +7 -4
- data/html/Gravaty/Parsers/Avatar.html +12 -12
- data/html/Gravaty/Parsers/Callback.html +13 -13
- data/html/Gravaty/Parsers/Default.html +21 -21
- data/html/Gravaty/Parsers/Force.html +13 -13
- data/html/Gravaty/Parsers/Format.html +13 -13
- data/html/Gravaty/Parsers/Pixelsize.html +13 -13
- data/html/Gravaty/Parsers/Rating.html +13 -13
- data/html/Gravaty/Parsers/Secure.html +12 -12
- data/html/Gravaty/Parsers/Type.html +13 -13
- data/html/Gravaty/Utils.html +9 -9
- data/html/Gravaty/Utils/Downloader.html +7 -4
- data/html/Gravaty/Utils/Downloader/Downloader.html +7 -4
- data/html/Gravaty/Utils/Raisers.html +21 -21
- data/html/Gravaty/Utils/Rfc5322.html +7 -4
- data/html/Gravaty/Utils/RpcConnector.html +9 -9
- data/html/Gravaty/Utils/RpcConnector/RpcConnector.html +29 -26
- data/html/ISSUES_md.html +9 -8
- data/html/Object.html +17 -4
- data/html/README_md.html +18 -18
- data/html/Rakefile.html +9 -8
- data/html/acknowledgements_md.html +9 -8
- data/html/authors_md.html +9 -8
- data/html/copyright_md.html +226 -202
- data/html/created.rid +55 -56
- data/html/css/rdoc.css +35 -6
- data/html/examples/cacert_pem.html +47 -25
- data/html/index.html +18 -18
- data/html/js/darkfish.js +22 -99
- data/html/js/navigation.js +4 -40
- data/html/js/navigation.js.gz +0 -0
- data/html/js/search.js +32 -31
- data/html/js/search_index.js +1 -1
- data/html/js/search_index.js.gz +0 -0
- data/html/js/searcher.js +6 -6
- data/html/js/searcher.js.gz +0 -0
- data/html/table_of_contents.html +16 -10
- data/lib/gravaty.rb +4 -3
- data/lib/gravaty/application.rb +4 -5
- data/lib/gravaty/constants.rb +1 -1
- data/lib/gravaty/locales/en.yml +1 -1
- data/lib/gravaty/locales/it.yml +1 -1
- data/lib/gravaty/locales/ja.yml +1 -1
- data/lib/gravaty/parser.rb +2 -3
- data/lib/gravaty/parsers/avatar.rb +2 -3
- data/lib/gravaty/parsers/callback.rb +2 -3
- data/lib/gravaty/parsers/default.rb +4 -5
- data/lib/gravaty/parsers/force.rb +2 -3
- data/lib/gravaty/parsers/format.rb +2 -3
- data/lib/gravaty/parsers/pixelsize.rb +2 -3
- data/lib/gravaty/parsers/rating.rb +2 -3
- data/lib/gravaty/parsers/secure.rb +2 -3
- data/lib/gravaty/parsers/type.rb +2 -3
- data/lib/gravaty/utils/downloader.rb +4 -4
- data/lib/gravaty/utils/raisers.rb +3 -5
- data/lib/gravaty/utils/rfc5322.rb +1 -1
- data/lib/gravaty/utils/rpc_connector.rb +2 -3
- data/lib/gravaty/version.rb +2 -2
- data/test/gravaty/locales/test_locales.rb +11 -11
- data/test/gravaty/parsers/test_avatar.rb +3 -3
- data/test/gravaty/parsers/test_callback.rb +3 -3
- data/test/gravaty/parsers/test_default.rb +10 -10
- data/test/gravaty/parsers/test_force.rb +3 -3
- data/test/gravaty/parsers/test_format.rb +6 -6
- data/test/gravaty/parsers/test_pixelsize.rb +7 -7
- data/test/gravaty/parsers/test_rating.rb +6 -6
- data/test/gravaty/parsers/test_secure.rb +3 -3
- data/test/gravaty/parsers/test_type.rb +3 -3
- data/test/gravaty/test_application.rb +22 -38
- data/test/gravaty/test_avatar.rb +15 -29
- data/test/gravaty/test_parser.rb +5 -5
- data/test/gravaty/test_profile.rb +11 -15
- data/test/gravaty/utils/test_downloader.rb +38 -14
- data/test/gravaty/utils/test_raisers.rb +5 -6
- data/test/gravaty/utils/test_rfc5322.rb +4 -4
- data/test/gravaty/utils/test_rpc_connector.rb +10 -13
- data/test/test_gravaty.rb +5 -9
- data/test/test_helper.rb +1 -1
- metadata +26 -28
- data/html/gravaty_gemspec.html +0 -169
- data/html/js/jquery.js +0 -4
data/lib/gravaty.rb
CHANGED
@@ -1,5 +1,6 @@
|
|
1
|
+
#--
|
1
2
|
# gravaty
|
2
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
3
4
|
#
|
4
5
|
# This file is part of gravaty.
|
5
6
|
#
|
@@ -15,6 +16,7 @@
|
|
15
16
|
#
|
16
17
|
# You should have received a copy of the GNU General Public License
|
17
18
|
# along with gravaty. If not, see <http://www.gnu.org/licenses/>.
|
19
|
+
#++
|
18
20
|
|
19
21
|
require 'digest/md5'
|
20
22
|
require 'i18n'
|
@@ -33,8 +35,7 @@ require_relative 'gravaty/parsers/secure'
|
|
33
35
|
require_relative 'gravaty/parsers/type'
|
34
36
|
|
35
37
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
36
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
37
|
-
# 2019 Marco Bresciani
|
38
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
38
39
|
# License:: GNU General Public License version 3
|
39
40
|
module Gravaty
|
40
41
|
|
data/lib/gravaty/application.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -35,8 +35,7 @@ module Gravaty
|
|
35
35
|
# profiles or for XML-RPC APi calls. The only needed parameter to
|
36
36
|
# create a Gravaty object is the reference +email+ address.
|
37
37
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
38
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
39
|
-
# 2019 Marco Bresciani
|
38
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
40
39
|
# License:: GNU General Public License version 3
|
41
40
|
class Gravaty
|
42
41
|
include Comparable
|
@@ -179,7 +178,7 @@ module Gravaty
|
|
179
178
|
@parser.parse('format', format) + build_query_string(array)
|
180
179
|
end
|
181
180
|
|
182
|
-
# See profile method. This banged version saves the resulting
|
181
|
+
# See profile method. This banged version saves the resulting string
|
183
182
|
# as internal state.
|
184
183
|
def profile!(args = {})
|
185
184
|
@gravaty = profile(args)
|
@@ -336,7 +335,7 @@ module Gravaty
|
|
336
335
|
parameters = nil
|
337
336
|
|
338
337
|
unless params_array.nil?
|
339
|
-
parameters = params_array.reject {|p| p.nil? or p.empty?}
|
338
|
+
parameters = params_array.reject { |p| p.nil? or p.empty? }
|
340
339
|
.join('&')
|
341
340
|
end
|
342
341
|
|
data/lib/gravaty/constants.rb
CHANGED
data/lib/gravaty/locales/en.yml
CHANGED
data/lib/gravaty/locales/it.yml
CHANGED
data/lib/gravaty/locales/ja.yml
CHANGED
data/lib/gravaty/parser.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -26,8 +26,7 @@ module Gravaty
|
|
26
26
|
# parameters for gravaty.
|
27
27
|
#
|
28
28
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
29
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
30
|
-
# 2019 Marco Bresciani
|
29
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
31
30
|
# License:: GNU General Public License version 3
|
32
31
|
class Parser
|
33
32
|
attr_reader :parsers
|
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -26,8 +26,7 @@ module Gravaty
|
|
26
26
|
# boolean, with +true+ for avatar.
|
27
27
|
#
|
28
28
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
29
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
30
|
-
# 2019 Marco Bresciani
|
29
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
31
30
|
# License:: GNU General Public License version 3
|
32
31
|
class Avatar
|
33
32
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -26,8 +26,7 @@ module Gravaty
|
|
26
26
|
# callback +String+ name.
|
27
27
|
#
|
28
28
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
29
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
30
|
-
# 2019 Marco Bresciani
|
29
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
31
30
|
# License:: GNU General Public License version 3
|
32
31
|
class Callback
|
33
32
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -30,8 +30,7 @@ module Gravaty
|
|
30
30
|
# default option.
|
31
31
|
#
|
32
32
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
33
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
34
|
-
# 2019 Marco Bresciani
|
33
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
35
34
|
# License:: GNU General Public License version 3
|
36
35
|
class Default
|
37
36
|
|
@@ -39,7 +38,7 @@ module Gravaty
|
|
39
38
|
def parse(value = nil)
|
40
39
|
unless value.nil? or value.empty?
|
41
40
|
unless DEFAULT_OPTIONS.include? value
|
42
|
-
valid = %w(http https).index {|scheme| valid?(value, scheme)}
|
41
|
+
valid = %w(http https).index { |scheme| valid?(value, scheme) }
|
43
42
|
|
44
43
|
raise ArgumentError, I18n.t('error.uri', value: value) if valid.nil?
|
45
44
|
end
|
@@ -77,7 +76,7 @@ module Gravaty
|
|
77
76
|
|
78
77
|
#rule 3
|
79
78
|
allowed = IMAGES_FORMATS
|
80
|
-
.index {|format| an_uri.path.end_with? format}
|
79
|
+
.index { |format| an_uri.path.end_with? format }
|
81
80
|
return false if allowed.nil?
|
82
81
|
|
83
82
|
#rule 4
|
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -26,8 +26,7 @@ module Gravaty
|
|
26
26
|
# boolean, with +true+ for forced.
|
27
27
|
#
|
28
28
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
29
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
30
|
-
# 2019 Marco Bresciani
|
29
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
31
30
|
# License:: GNU General Public License version 3
|
32
31
|
class Force
|
33
32
|
# The parsable duck type interface to every parser usage.
|
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -29,8 +29,7 @@ module Gravaty
|
|
29
29
|
# profile format.
|
30
30
|
#
|
31
31
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
32
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
33
|
-
# 2019 Marco Bresciani
|
32
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
34
33
|
# License:: GNU General Public License version 3
|
35
34
|
class Format
|
36
35
|
include Utils::Raisers
|
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -29,8 +29,7 @@ module Gravaty
|
|
29
29
|
# size.
|
30
30
|
#
|
31
31
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
32
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
33
|
-
# 2019 Marco Bresciani
|
32
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
34
33
|
# License:: GNU General Public License version 3
|
35
34
|
class Pixelsize
|
36
35
|
include Utils::Raisers
|
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -29,8 +29,7 @@ module Gravaty
|
|
29
29
|
# rating type.
|
30
30
|
#
|
31
31
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
32
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
33
|
-
# 2019 Marco Bresciani
|
32
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
34
33
|
# License:: GNU General Public License version 3
|
35
34
|
class Rating
|
36
35
|
include Utils::Raisers
|
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -26,8 +26,7 @@ module Gravaty
|
|
26
26
|
# a boolean, with +true+ for secure.
|
27
27
|
#
|
28
28
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
29
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
30
|
-
# 2019 Marco Bresciani
|
29
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
31
30
|
# License:: GNU General Public License version 3
|
32
31
|
class Secure
|
33
32
|
# The parsable duck type interface to every parser usage.
|
data/lib/gravaty/parsers/type.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -29,8 +29,7 @@ module Gravaty
|
|
29
29
|
# avatar format.
|
30
30
|
#
|
31
31
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
32
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
33
|
-
# 2019 Marco Bresciani
|
32
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
34
33
|
# License:: GNU General Public License version 3
|
35
34
|
class Type
|
36
35
|
include Utils::Raisers
|
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -96,7 +96,7 @@ module Gravaty
|
|
96
96
|
cert_file = ENV['SSL_CERT_FILE'].dup
|
97
97
|
cert_file.gsub!(File::ALT_SEPARATOR, File::SEPARATOR) if File::ALT_SEPARATOR
|
98
98
|
end
|
99
|
-
if cert_file && File.
|
99
|
+
if cert_file && File.exist?(cert_file)
|
100
100
|
http.ca_file = cert_file
|
101
101
|
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
|
102
102
|
http.verify_depth = @max_ca_verify_depth
|
@@ -136,7 +136,7 @@ A file of bundled public CA certs may be downloaded from:
|
|
136
136
|
output
|
137
137
|
|
138
138
|
temp_file.close
|
139
|
-
File.unlink full_path if File.
|
139
|
+
File.unlink full_path if File.exist?(full_path)
|
140
140
|
FileUtils.mkdir_p File.dirname(full_path)
|
141
141
|
FileUtils.mv temp_file.path, full_path, force: true
|
142
142
|
else
|
@@ -145,7 +145,7 @@ A file of bundled public CA certs may be downloaded from:
|
|
145
145
|
end
|
146
146
|
|
147
147
|
rescue Exception => e
|
148
|
-
File.unlink full_path if File.exists
|
148
|
+
File.unlink full_path if File.exists(full_path)
|
149
149
|
output "ERROR: #{e.message}"
|
150
150
|
raise 'Failed to download file'
|
151
151
|
end
|
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -27,8 +27,7 @@ module Gravaty
|
|
27
27
|
# methods...
|
28
28
|
#
|
29
29
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
30
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
31
|
-
# 2019 Marco Bresciani
|
30
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
32
31
|
# License:: GNU General Public License version 3
|
33
32
|
module Utils
|
34
33
|
|
@@ -36,8 +35,7 @@ module Gravaty
|
|
36
35
|
# to (possibly) common conditions.
|
37
36
|
#
|
38
37
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
39
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
40
|
-
# 2019 Marco Bresciani
|
38
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
41
39
|
# License:: GNU General Public License version 3
|
42
40
|
module Raisers
|
43
41
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -28,8 +28,7 @@ module Gravaty
|
|
28
28
|
# This module contains the XML-RPC connector class.
|
29
29
|
#
|
30
30
|
# Author:: {Marco Bresciani}[mailto:marcobresciani_1974@libero.it]
|
31
|
-
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018,
|
32
|
-
# 2019 Marco Bresciani
|
31
|
+
# Copyright:: Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
33
32
|
# License:: GNU General Public License version 3
|
34
33
|
module RpcConnector
|
35
34
|
|
data/lib/gravaty/version.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -20,5 +20,5 @@
|
|
20
20
|
|
21
21
|
module Gravaty
|
22
22
|
# Current version number for Gravaty gem.
|
23
|
-
VERSION = '
|
23
|
+
VERSION = '10.0.0'
|
24
24
|
end
|
@@ -1,6 +1,6 @@
|
|
1
1
|
#--
|
2
2
|
# gravaty
|
3
|
-
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Marco Bresciani
|
3
|
+
# Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Marco Bresciani
|
4
4
|
#
|
5
5
|
# This file is part of gravaty.
|
6
6
|
#
|
@@ -31,16 +31,16 @@ describe Gravaty::Gravaty do
|
|
31
31
|
RELATIVE_PATH, '*.yml')]
|
32
32
|
end
|
33
33
|
|
34
|
-
subject {I18n.available_locales}
|
34
|
+
subject { I18n.available_locales }
|
35
35
|
|
36
36
|
it 'shall return at least one available locale' do
|
37
|
-
subject.wont_be_nil
|
38
|
-
subject.wont_be_empty
|
37
|
+
_(subject).wont_be_nil
|
38
|
+
_(subject).wont_be_empty
|
39
39
|
end
|
40
40
|
|
41
41
|
it 'shall contain at least English and Italiano' do
|
42
|
-
subject.must_include :en
|
43
|
-
subject.must_include :it
|
42
|
+
_(subject).must_include :en
|
43
|
+
_(subject).must_include :it
|
44
44
|
end
|
45
45
|
|
46
46
|
it 'shall contain a test.test signpost for each available locale' do
|
@@ -56,13 +56,13 @@ describe Gravaty::Gravaty do
|
|
56
56
|
I18n.locale = locale
|
57
57
|
|
58
58
|
translation = load_yaml_file(locale)
|
59
|
-
translation["#{locale}"]['test']['test'].wont_be_nil
|
59
|
+
_(translation["#{locale}"]['test']['test']).wont_be_nil
|
60
60
|
|
61
61
|
a_string = I18n.t('test.test')
|
62
|
-
a_string.wont_be_nil
|
63
|
-
a_string.wont_be_empty
|
64
|
-
a_string.wont_include 'translation missing'
|
65
|
-
a_string.must_equal translation["#{locale}"]['test']['test']
|
62
|
+
_(a_string).wont_be_nil
|
63
|
+
_(a_string).wont_be_empty
|
64
|
+
_(a_string).wont_include 'translation missing'
|
65
|
+
_(a_string).must_equal translation["#{locale}"]['test']['test']
|
66
66
|
end
|
67
67
|
end
|
68
68
|
end
|