haml-i18n-extractor 0.5.0 → 0.5.1
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.
@@ -6,7 +6,7 @@ module Haml
|
|
6
6
|
module StringHelpers
|
7
7
|
|
8
8
|
# do not pollute the key space it will make it invalid yaml
|
9
|
-
NOT_ALLOWED_IN_KEYNAME = %w( ~ ` ! @ # $ % ^ & * - ( ) , ? { } = ' " : \ / )
|
9
|
+
NOT_ALLOWED_IN_KEYNAME = %w( ~ ` ! @ # $ % ^ & * - ( ) , ? { } = ' " : \ / . )
|
10
10
|
# limit the number of chars
|
11
11
|
LIMIT_KEY_NAME = 30
|
12
12
|
|
data/test/text_replacer_test.rb
CHANGED
@@ -60,7 +60,7 @@ module Haml
|
|
60
60
|
end
|
61
61
|
|
62
62
|
def test_it_does_not_allow_weird_characters_in_the_keyname
|
63
|
-
weird_line = "thi:s = (is \"' `ch@
|
63
|
+
weird_line = "thi:s = (is \"' `ch@ract.er ~ ma?dne{}ss!"
|
64
64
|
replacer = Haml::I18n::Extractor::TextReplacer.new(weird_line, weird_line, :plain, "/path/to/doesntmatter.haml")
|
65
65
|
assert_equal replacer.replace_hash, { :modified_line => "= t('.this_is_chracter_madness')",
|
66
66
|
:t_name => "this_is_chracter_madness", :replaced_text => weird_line, :path => "/path/to/doesntmatter.haml" }
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: haml-i18n-extractor
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 9
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 5
|
9
|
-
-
|
10
|
-
version: 0.5.
|
9
|
+
- 1
|
10
|
+
version: 0.5.1
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Shai Rosenfeld
|