i18n-debug 1.1.0 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 70d7f6a748196e4de908ae5202aeed3a72cc6f0c
4
- data.tar.gz: 31399b819b4e6d25c4ca20a0b1d947d21ac50122
2
+ SHA256:
3
+ metadata.gz: 66e5026571047fdd6c3e5dfee0b8571845366a280df61f58bff56ec512a27641
4
+ data.tar.gz: 7a1bd1418dbb415728b75f3c03c2a849c2f36f4ad0fbfb2d5b021968583007f5
5
5
  SHA512:
6
- metadata.gz: 16c9898163fbd402c99110bd4de352bb40663c10efce343df2e56e62e0053b66bb0c6731d81d48506675f61c48b6f5791819a46d2276473e8128d00fc93d6aa1
7
- data.tar.gz: d9c004565cf75c236ef0d6a94b68e48694beeea570b89c1ac6f9cc01d45a7ef67d3ac65e1c4448c0de519a3847a08074c6c386c373387cd291b9ad17ebf7e45a
6
+ metadata.gz: 302db3d0a8271dd5cf85d883befd10256025680cc24a6b03fb683f9ee3f504c2ec3b606a0f04c9b6433eb33ce9993202eb65a087a6f3cc775dae457d182dcfe7
7
+ data.tar.gz: 10d0decc417a8867dfa2a2325d32a639d24a28e3c144d4c12b69ebfc66028634ac87d5f193a23dcc786786d9be11fa66d754d51b41257a52569b9f7f717cb800
data/.travis.yml CHANGED
@@ -3,6 +3,5 @@ language: ruby
3
3
  cache: bundler
4
4
  script: "bundle exec rake test"
5
5
  rvm:
6
- - 2.2.2
7
- - jruby-9.0.0.0
8
- - rbx-2
6
+ - 2.4.3
7
+ - 2.5.0
data/CHANGELOG.md CHANGED
@@ -1,5 +1,14 @@
1
1
  # Changelog
2
2
 
3
+ # 1.2.0
4
+
5
+ - Don't change method visibility of `#lookup` (#8, @aleksandrs-ledovskis)
6
+
7
+ ## 1.1.1
8
+
9
+ - Update i18n version
10
+ - Make Rails logger check more robust
11
+
3
12
  ## 1.1.0
4
13
 
5
14
  - Use `Module#prepend` instead of aliasing methods.
data/README.md CHANGED
@@ -36,7 +36,7 @@ Thus, place it inside the `development` group.
36
36
  gem 'i18n-debug', group: :development
37
37
  ```
38
38
 
39
- If you need support for ruby < 2, make sure to use version 1.0.0.
39
+ If you need support for ruby <= 2.0, make sure to use version 1.0.0.
40
40
 
41
41
  ## Usage
42
42
 
@@ -66,9 +66,6 @@ end
66
66
 
67
67
  ## Additional Information
68
68
 
69
- This gem was inspired by a similar gem called
70
- [rails-i18n-debug](https://github.com/256dpi/rails-i18n-debug).
71
-
72
69
  ### Dependencies
73
70
 
74
71
  - [i18n](https://github.com/svenfuchs/i18n)
data/i18n-debug.gemspec CHANGED
@@ -15,5 +15,5 @@ Gem::Specification.new do |spec|
15
15
  spec.add_development_dependency 'bundler', '~> 1.7'
16
16
  spec.add_development_dependency 'rake', '~> 10.0'
17
17
  spec.add_development_dependency 'minitest', '~> 5.8'
18
- spec.add_dependency 'i18n', '< 1'
18
+ spec.add_dependency 'i18n', '< 2'
19
19
  end
@@ -1,5 +1,5 @@
1
1
  module I18n
2
2
  module Debug
3
- VERSION = '1.1.0'
3
+ VERSION = '1.2.0'
4
4
  end
5
5
  end
data/lib/i18n/debug.rb CHANGED
@@ -13,7 +13,7 @@ module I18n
13
13
 
14
14
  def logger
15
15
  @logger ||=
16
- if defined?(::Rails)
16
+ if defined?(::Rails) and ::Rails.respond_to?(:logger)
17
17
  ::Rails.logger
18
18
  else
19
19
  require 'logger'
@@ -28,6 +28,8 @@ module I18n
28
28
  end
29
29
 
30
30
  module Hook
31
+ protected
32
+
31
33
  def lookup(*args)
32
34
  super.tap do |result|
33
35
  options = args.last.is_a?(Hash) ? args.pop : {}
@@ -19,6 +19,10 @@ class TestI18nDebug < Minitest::Test
19
19
  end
20
20
  end
21
21
 
22
+ def test_does_not_alter_default_i18n_lookup_method_visibility
23
+ assert I18n.backend.class.protected_method_defined?(:lookup)
24
+ end
25
+
22
26
  def test_logger_invoked
23
27
  assert_output(/en\.foo\.bar => "baz"/) do
24
28
  I18n.t('foo.bar')
metadata CHANGED
@@ -1,72 +1,73 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: i18n-debug
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Philipe Fatio
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-08-21 00:00:00.000000000 Z
11
+ date: 2018-10-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
+ name: bundler
14
15
  requirement: !ruby/object:Gem::Requirement
15
16
  requirements:
16
17
  - - "~>"
17
18
  - !ruby/object:Gem::Version
18
19
  version: '1.7'
19
- name: bundler
20
- prerelease: false
21
20
  type: :development
21
+ prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
26
  version: '1.7'
27
27
  - !ruby/object:Gem::Dependency
28
+ name: rake
28
29
  requirement: !ruby/object:Gem::Requirement
29
30
  requirements:
30
31
  - - "~>"
31
32
  - !ruby/object:Gem::Version
32
33
  version: '10.0'
33
- name: rake
34
- prerelease: false
35
34
  type: :development
35
+ prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
40
  version: '10.0'
41
41
  - !ruby/object:Gem::Dependency
42
+ name: minitest
42
43
  requirement: !ruby/object:Gem::Requirement
43
44
  requirements:
44
45
  - - "~>"
45
46
  - !ruby/object:Gem::Version
46
47
  version: '5.8'
47
- name: minitest
48
- prerelease: false
49
48
  type: :development
49
+ prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
54
  version: '5.8'
55
55
  - !ruby/object:Gem::Dependency
56
+ name: i18n
56
57
  requirement: !ruby/object:Gem::Requirement
57
58
  requirements:
58
59
  - - "<"
59
60
  - !ruby/object:Gem::Version
60
- version: '1'
61
- name: i18n
62
- prerelease: false
61
+ version: '2'
63
62
  type: :runtime
63
+ prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "<"
67
67
  - !ruby/object:Gem::Version
68
- version: '1'
69
- description: Ever wondered which translations are being looked up by Rails, a gem, or simply your app? Wonder no more!
68
+ version: '2'
69
+ description: Ever wondered which translations are being looked up by Rails, a gem,
70
+ or simply your app? Wonder no more!
70
71
  email: me@phili.pe
71
72
  executables: []
72
73
  extensions: []
@@ -87,7 +88,7 @@ homepage: https://github.com/fphilipe/i18n-debug
87
88
  licenses:
88
89
  - MIT
89
90
  metadata: {}
90
- post_install_message:
91
+ post_install_message:
91
92
  rdoc_options: []
92
93
  require_paths:
93
94
  - lib
@@ -102,10 +103,11 @@ required_rubygems_version: !ruby/object:Gem::Requirement
102
103
  - !ruby/object:Gem::Version
103
104
  version: '0'
104
105
  requirements: []
105
- rubyforge_project:
106
- rubygems_version: 2.4.8
107
- signing_key:
106
+ rubyforge_project:
107
+ rubygems_version: 2.7.6
108
+ signing_key:
108
109
  specification_version: 4
109
- summary: Ever wondered which translations are being looked up by Rails, a gem, or simply your app? Wonder no more!
110
+ summary: Ever wondered which translations are being looked up by Rails, a gem, or
111
+ simply your app? Wonder no more!
110
112
  test_files:
111
113
  - test/test_i18n_debug.rb