babelish 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (66) hide show
  1. checksums.yaml +15 -0
  2. data/.babelish.sample +26 -0
  3. data/.gitignore +30 -0
  4. data/.hound.yml +4 -0
  5. data/.travis.yml +13 -0
  6. data/Gemfile +8 -0
  7. data/LICENSE.txt +20 -0
  8. data/README.md +43 -0
  9. data/Rakefile +17 -0
  10. data/babelish.gemspec +41 -0
  11. data/bin/android2csv +13 -0
  12. data/bin/babelish +6 -0
  13. data/bin/csv2android +13 -0
  14. data/bin/csv2json +13 -0
  15. data/bin/csv2php +13 -0
  16. data/bin/csv2strings +14 -0
  17. data/bin/json2csv +13 -0
  18. data/bin/php2csv +13 -0
  19. data/bin/strings2csv +13 -0
  20. data/lib/babelish/android2csv.rb +25 -0
  21. data/lib/babelish/base2csv.rb +98 -0
  22. data/lib/babelish/commandline.rb +114 -0
  23. data/lib/babelish/csv2android.rb +36 -0
  24. data/lib/babelish/csv2base.rb +148 -0
  25. data/lib/babelish/csv2json.rb +22 -0
  26. data/lib/babelish/csv2php.rb +24 -0
  27. data/lib/babelish/csv2strings.rb +30 -0
  28. data/lib/babelish/google_doc.rb +36 -0
  29. data/lib/babelish/json2csv.rb +20 -0
  30. data/lib/babelish/language.rb +25 -0
  31. data/lib/babelish/php2csv.rb +30 -0
  32. data/lib/babelish/strings2csv.rb +47 -0
  33. data/lib/babelish/version.rb +3 -0
  34. data/lib/babelish.rb +27 -0
  35. data/test/babelish/commands/test_command_android2csv.rb +60 -0
  36. data/test/babelish/commands/test_command_csv2android.rb +35 -0
  37. data/test/babelish/commands/test_command_csv2strings.rb +60 -0
  38. data/test/babelish/commands/test_command_strings2csv.rb +95 -0
  39. data/test/babelish/test_android2csv.rb +35 -0
  40. data/test/babelish/test_base2csv.rb +43 -0
  41. data/test/babelish/test_bins.rb +24 -0
  42. data/test/babelish/test_csv2android.rb +26 -0
  43. data/test/babelish/test_csv2base.rb +40 -0
  44. data/test/babelish/test_csv2json.rb +26 -0
  45. data/test/babelish/test_csv2php.rb +26 -0
  46. data/test/babelish/test_csv2strings.rb +20 -0
  47. data/test/babelish/test_json2csv.rb +35 -0
  48. data/test/babelish/test_php2csv.rb +74 -0
  49. data/test/babelish/test_strings2csv.rb +114 -0
  50. data/test/data/android-en.xml +8 -0
  51. data/test/data/android-fr.xml +8 -0
  52. data/test/data/android.xml +8 -0
  53. data/test/data/genstrings.strings +0 -0
  54. data/test/data/json.json +6 -0
  55. data/test/data/php_lang.php +8 -0
  56. data/test/data/test_data.csv +3 -0
  57. data/test/data/test_data.strings +2 -0
  58. data/test/data/test_data_multiple_langs.csv +3 -0
  59. data/test/data/test_en.strings +2 -0
  60. data/test/data/test_fr.strings +2 -0
  61. data/test/data/test_utf16.strings +0 -0
  62. data/test/data/test_with_nil.csv +3 -0
  63. data/test/data/test_with_nil.strings +4 -0
  64. data/test/data/xcode_empty.strings +7 -0
  65. data/test/test_helper.rb +17 -0
  66. metadata +248 -0
@@ -0,0 +1,35 @@
1
+ require 'test_helper'
2
+ class TestAndroid2CSV < Test::Unit::TestCase
3
+
4
+ def test_load_strings_with_wrong_file
5
+ assert_raise(Errno::ENOENT) do
6
+ output = Babelish::Android2CSV.new.load_strings "file that does not exist.strings"
7
+ end
8
+ end
9
+
10
+ def test_load_strings
11
+ expected_output = {"app_name" => "android2csv", "action_greetings" => "Hello", "ANOTHER_STRING" => "testEN", "empty" => ""}
12
+ output = Babelish::Android2CSV.new.load_strings "test/data/android.xml"
13
+ assert_equal expected_output, output
14
+ end
15
+
16
+ def test_initialize
17
+ csv_filename = "file.csv"
18
+ filenames = %w{"french.strings english.strings"}
19
+ headers = %w{"constants french english"}
20
+ converter = Babelish::Android2CSV.new({
21
+ :csv_filename => csv_filename,
22
+ :headers => headers,
23
+ :filenames => filenames
24
+ })
25
+
26
+ assert_equal csv_filename, converter.csv_filename
27
+ assert_equal headers, converter.headers
28
+ assert_equal filenames, converter.filenames
29
+ end
30
+
31
+ def test_initialize_with_default_values
32
+ converter = Babelish::Android2CSV.new
33
+ assert_not_nil converter.csv_filename
34
+ end
35
+ end
@@ -0,0 +1,43 @@
1
+ require 'test_helper'
2
+ class TestBase2Csv < Test::Unit::TestCase
3
+
4
+ def test_load_strings
5
+ expected_output = {}
6
+ output = Babelish::Base2Csv.new.send :load_strings, nil
7
+ assert_equal expected_output, output
8
+ end
9
+
10
+ def test_create_csv_file
11
+ keys = ["ERROR_HANDLER_WARNING_DISMISS", "ANOTHER_STRING"]
12
+ filename = "test_data"
13
+ strings = {filename => {"ERROR_HANDLER_WARNING_DISMISS" => "OK", "ANOTHER_STRING" => "hello"}}
14
+
15
+ converter = Babelish::Base2Csv.new(:headers => %w{variables english}, :filenames => [filename])
16
+
17
+ converter.send :create_csv_file, keys, strings
18
+ assert File.exist?(converter.csv_filename)
19
+
20
+ #clean up
21
+ system("rm -rf ./" + converter.csv_filename)
22
+ end
23
+
24
+ def test_initialize
25
+ csv_filename = "file.csv"
26
+ filenames = %w{"french.strings english.strings"}
27
+ headers = %w{"constants french english"}
28
+ converter = Babelish::Base2Csv.new({
29
+ :csv_filename => csv_filename,
30
+ :headers => headers,
31
+ :filenames => filenames
32
+ })
33
+
34
+ assert_equal csv_filename, converter.csv_filename
35
+ assert_equal headers, converter.headers
36
+ assert_equal filenames, converter.filenames
37
+ end
38
+
39
+ def test_initialize_with_default_values
40
+ converter = Babelish::Base2Csv.new
41
+ assert_not_nil converter.csv_filename
42
+ end
43
+ end
@@ -0,0 +1,24 @@
1
+ require 'test_helper'
2
+ class TestBins < Test::Unit::TestCase
3
+
4
+ def test_csv2strings_with_google_doc
5
+ omit if ENV['TRAVIS']
6
+ assert_nothing_raised do
7
+ system("./bin/csv2strings --fetch --filename test.csv")
8
+ end
9
+ assert_equal $?.exitstatus, 0
10
+ end
11
+
12
+ def test_csv2strings_with_config_file
13
+ system("cp .babelish.sample .babelish")
14
+
15
+ assert_nothing_raised NameError do
16
+ system("./bin/csv2strings")
17
+ end
18
+ assert_equal $?.exitstatus, 0
19
+ end
20
+
21
+ def teardown
22
+ system("rm -f .babelish")
23
+ end
24
+ end
@@ -0,0 +1,26 @@
1
+ require "test_helper"
2
+ class TestCSV2Android < Test::Unit::TestCase
3
+
4
+ def test_converting_csv_to_xml
5
+ csv_file = "test/data/test_data.csv"
6
+ converter = Babelish::CSV2Android.new(csv_file, 'English' => "en")
7
+ converter.convert
8
+ assert File.exists?("values-en/strings.xml"), "the ouptut file does not exist"
9
+
10
+ #clean up
11
+ system("rm -rf ./values-en")
12
+ end
13
+
14
+ def test_converting_csv_to_dotstrings_one_output_option
15
+ csv_file = "test/data/test_data.csv"
16
+ single_file = 'myApp.xml'
17
+ converter = Babelish::CSV2Android.new(csv_file,
18
+ {'English' => "en"},
19
+ :output_file => single_file)
20
+ converter.convert
21
+ assert File.exists?(single_file), "the ouptut file does not exist"
22
+
23
+ #clean up
24
+ system("rm -rf ./" + single_file)
25
+ end
26
+ end
@@ -0,0 +1,40 @@
1
+ require 'test_helper'
2
+ class TestCsv2Base < Test::Unit::TestCase
3
+
4
+ def test_initialize
5
+ csv_filename = "file.csv"
6
+ excluded_states = ["German"]
7
+ state_column = "Local"
8
+ keys_column = 23
9
+ converter = Babelish::Csv2Base.new(csv_filename, {"English" => ["en"]}, {
10
+ :excluded_states => excluded_states,
11
+ :state_column => state_column,
12
+ :keys_column => keys_column
13
+ })
14
+
15
+ assert_equal csv_filename, converter.csv_filename
16
+ assert_equal excluded_states, converter.excluded_states
17
+ assert_equal state_column, converter.state_column
18
+ assert_equal keys_column, converter.keys_column
19
+ end
20
+
21
+ def test_initialize_with_default_values
22
+ converter = Babelish::Csv2Base.new("file.csv", {"English" => ["en"]})
23
+ assert_not_nil converter.csv_filename
24
+ end
25
+
26
+ def test_create_file_from_path
27
+ test_file = "test_file.txt"
28
+ Babelish::Csv2Base.new("file.csv", {"English" => ["en"]}).create_file_from_path test_file
29
+ assert File.exist?(test_file)
30
+
31
+ #clean up
32
+ system("rm -rf ./" + test_file)
33
+ end
34
+
35
+ def test_get_row_format
36
+ expected_output = "\"test_key\" = \"test_value\""
37
+ output = Babelish::Csv2Base.new("file.csv", {"English" => ["en"]}).get_row_format("test_key", "test_value")
38
+ assert_equal expected_output, output
39
+ end
40
+ end
@@ -0,0 +1,26 @@
1
+ require 'test_helper'
2
+ class TestCSV2JSON < Test::Unit::TestCase
3
+
4
+ def test_converting_csv_to_dotstrings
5
+ csv_file = "test/data/test_data.csv"
6
+ converter = Babelish::CSV2JSON.new(csv_file, 'English' => "en")
7
+ converter.convert
8
+ assert File.exists?("en.js"), "the ouptut file does not exist"
9
+
10
+ #clean up
11
+ system("rm -rf en.js")
12
+ end
13
+
14
+ def test_converting_csv_to_dotstrings_one_output_option
15
+ csv_file = "test/data/test_data.csv"
16
+ single_file = 'myfile.js'
17
+ converter = Babelish::CSV2JSON.new(csv_file,
18
+ {'English' => "en"},
19
+ :output_file => single_file)
20
+ converter.convert
21
+ assert File.exists?(single_file), "the ouptut file does not exist"
22
+
23
+ #clean up
24
+ system("rm -rf ./" + single_file)
25
+ end
26
+ end
@@ -0,0 +1,26 @@
1
+ require "test_helper"
2
+ class TestCSV2Php < Test::Unit::TestCase
3
+
4
+ def test_converting_csv_to_dotstrings
5
+ csv_file = "test/data/test_data.csv"
6
+ converter = Babelish::CSV2Php.new(csv_file, 'English' => "en")
7
+ converter.convert
8
+ assert File.exists?("en/lang.php"), "the ouptut file does not exist"
9
+
10
+ #clean up
11
+ system("rm -rf ./en")
12
+ end
13
+
14
+ def test_converting_csv_to_dotstrings_one_output_option
15
+ csv_file = "test/data/test_data.csv"
16
+ single_file = 'myApp.php'
17
+ converter = Babelish::CSV2Php.new(csv_file,
18
+ {'English' => "en"},
19
+ :output_file => single_file)
20
+ converter.convert
21
+ assert File.exists?(single_file), "the ouptut file does not exist"
22
+
23
+ #clean up
24
+ system("rm -rf ./" + single_file)
25
+ end
26
+ end
@@ -0,0 +1,20 @@
1
+ require 'test_helper'
2
+ class TestCSV2Strings < Test::Unit::TestCase
3
+
4
+ def test_converting_csv_to_dotstrings
5
+ csv_file = "test/data/test_data.csv"
6
+ converter = Babelish::CSV2Strings.new(csv_file, 'English' => [:en])
7
+ converter.convert
8
+ assert File.exists?("en.lproj/Localizable.strings"), "the ouptut file does not exist"
9
+ end
10
+
11
+ def test_converting_csv_to_dotstrings_one_output_option
12
+ csv_file = "test/data/test_data.csv"
13
+ single_file = 'myApp.strings'
14
+ converter = Babelish::CSV2Strings.new(csv_file,
15
+ {'English' => [:en]},
16
+ :output_file => single_file)
17
+ converter.convert
18
+ assert File.exists?(single_file), "the ouptut file does not exist"
19
+ end
20
+ end
@@ -0,0 +1,35 @@
1
+ require 'test_helper'
2
+ class JSON2CSVTest < Test::Unit::TestCase
3
+
4
+ def test_load_strings_with_wrong_file
5
+ assert_raise(Errno::ENOENT) do
6
+ output = Babelish::JSON2CSV.new.load_strings "file that does not exist.strings"
7
+ end
8
+ end
9
+
10
+ def test_load_strings
11
+ expected_output = {"app_name" => "json2csv", "action_greetings" => "hello", "ANOTHER_STRING" => "testEN", "empty" => ""}
12
+ output = Babelish::JSON2CSV.new.load_strings "test/data/json.json"
13
+ assert_equal expected_output, output
14
+ end
15
+
16
+ def test_initialize
17
+ csv_filename = "file.csv"
18
+ filenames = %w{"french.strings english.strings"}
19
+ headers = %w{"constants french english"}
20
+ converter = Babelish::JSON2CSV.new({
21
+ :csv_filename => csv_filename,
22
+ :headers => headers,
23
+ :filenames => filenames
24
+ })
25
+
26
+ assert_equal csv_filename, converter.csv_filename
27
+ assert_equal headers, converter.headers
28
+ assert_equal filenames, converter.filenames
29
+ end
30
+
31
+ def test_initialize_with_default_values
32
+ converter = Babelish::JSON2CSV.new
33
+ assert_not_nil converter.csv_filename
34
+ end
35
+ end
@@ -0,0 +1,74 @@
1
+ require 'test_helper'
2
+ class TestPhp2CSV < Test::Unit::TestCase
3
+
4
+ def test_parse_dotstrings_line_with_good_string
5
+ input = String.new(<<-EOS)
6
+ $lang['MY_CONSTANT'] = "This is ok";
7
+ EOS
8
+ expected_output = {"MY_CONSTANT" => "This is ok"}
9
+
10
+ output = Babelish::Php2CSV.new.parse_dotstrings_line input
11
+ assert_equal output, expected_output
12
+ end
13
+
14
+ def test_parse_dotstrings_line_with_single_quote
15
+ input = String.new(<<-EOS)
16
+ $lang['MY_CONSTANT'] = "This 'is' ok";
17
+ EOS
18
+ expected_output = {"MY_CONSTANT" => "This 'is' ok"}
19
+
20
+ output = Babelish::Php2CSV.new.parse_dotstrings_line input
21
+ assert_equal output, expected_output
22
+ end
23
+
24
+ def test_parse_dotstrings_line_with_double_quotes
25
+ input = String.new(<<-EOS)
26
+ $lang['MY_CONSTANT'] = "This "is" ok";
27
+ EOS
28
+ expected_output = {"MY_CONSTANT" => "This \"is\" ok"}
29
+
30
+ output = Babelish::Php2CSV.new.parse_dotstrings_line input
31
+ assert_equal output, expected_output
32
+ end
33
+
34
+ def test_parse_dotstrings_line_with_wrong_string
35
+ input = String.new(<<-EOS)
36
+ $lang['MY_CONSTANT'] = "wrong syntax"
37
+ EOS
38
+
39
+ output = Babelish::Php2CSV.new.parse_dotstrings_line input
40
+ assert_nil output, "output should be nil with wrong syntax"
41
+ end
42
+
43
+ def test_load_strings_with_wrong_file
44
+ assert_raise(Errno::ENOENT) do
45
+ output = Babelish::Php2CSV.new.load_strings "file that does not exist.strings"
46
+ end
47
+ end
48
+
49
+ def test_load_strings
50
+ expected_output = {"app_name" => "php2csv", "action_greetings" => "Hello", "ANOTHER_STRING" => "testEN", "empty" => ""}
51
+ output = Babelish::Php2CSV.new.load_strings "test/data/php_lang.php"
52
+ assert_equal expected_output, output
53
+ end
54
+
55
+ def test_initialize
56
+ csv_filename = "file.csv"
57
+ filenames = %w{"french.php english.php"}
58
+ headers = %w{"constants french english"}
59
+ converter = Babelish::Php2CSV.new({
60
+ :csv_filename => csv_filename,
61
+ :headers => headers,
62
+ :filenames => filenames
63
+ })
64
+
65
+ assert_equal csv_filename, converter.csv_filename
66
+ assert_equal headers, converter.headers
67
+ assert_equal filenames, converter.filenames
68
+ end
69
+
70
+ def test_initialize_with_default_values
71
+ converter = Babelish::Php2CSV.new
72
+ assert_not_nil converter.csv_filename
73
+ end
74
+ end
@@ -0,0 +1,114 @@
1
+ require 'test_helper'
2
+ class TestStrings2CSV < Test::Unit::TestCase
3
+
4
+ def test_parse_dotstrings_line_with_good_string
5
+ input = String.new(<<-EOS)
6
+ "MY_CONSTANT" = "This is ok";
7
+ EOS
8
+ expected_output = {"MY_CONSTANT"=>"This is ok"}
9
+
10
+ output = Babelish::Strings2CSV.new.parse_dotstrings_line input
11
+ assert_equal output, expected_output
12
+ end
13
+
14
+ def test_parse_dotstrings_line_with_single_quote
15
+ input = String.new(<<-EOS)
16
+ "MY_CONSTANT" = "This 'is' ok";
17
+ EOS
18
+ expected_output = {"MY_CONSTANT"=>"This 'is' ok"}
19
+
20
+ output = Babelish::Strings2CSV.new.parse_dotstrings_line input
21
+ assert_equal output, expected_output
22
+ end
23
+
24
+ def test_parse_dotstrings_line_with_double_quotes
25
+ input = String.new(<<-EOS)
26
+ "MY_CONSTANT" = "This "is" ok";
27
+ EOS
28
+ expected_output = {"MY_CONSTANT"=>"This \"is\" ok"}
29
+
30
+ output = Babelish::Strings2CSV.new.parse_dotstrings_line input
31
+ assert_equal output, expected_output
32
+ end
33
+
34
+ def test_parse_dotstrings_line_with_wrong_string
35
+ input = String.new(<<-EOS)
36
+ "MY_CONSTANT" = "wrong syntax"
37
+ EOS
38
+
39
+ output = Babelish::Strings2CSV.new.parse_dotstrings_line input
40
+ assert_nil output, "output should be nil with wrong syntax"
41
+ end
42
+
43
+ def test_load_strings_with_wrong_file
44
+ assert_raise(Errno::ENOENT) do
45
+ output = Babelish::Strings2CSV.new.load_strings "file that does not exist.strings"
46
+ end
47
+ end
48
+
49
+ def test_load_strings
50
+ expected_output = {"ERROR_HANDLER_WARNING_DISMISS" => "OK", "ANOTHER_STRING" => "hello"}
51
+ output = Babelish::Strings2CSV.new.load_strings "test/data/test_data.strings"
52
+ assert_equal expected_output, output
53
+ end
54
+
55
+ def test_load_strings_with_empty_lines
56
+ assert_nothing_raised do
57
+ output = Babelish::Strings2CSV.new.load_strings "test/data/test_with_nil.strings"
58
+ end
59
+ end
60
+
61
+ def test_load_strings_with_empty_lines_and_comments
62
+ assert_nothing_raised do
63
+ output = Babelish::Strings2CSV.new.load_strings "test/data/xcode_empty.strings"
64
+ end
65
+ end
66
+
67
+ def test_load_strings_with_genstrings_file
68
+ assert_nothing_raised do
69
+ output = Babelish::Strings2CSV.new.load_strings "test/data/genstrings.strings"
70
+ end
71
+ end
72
+
73
+ def test_dotstrings_to_csv
74
+ converter = Babelish::Strings2CSV.new(:filenames => ["test/data/test_data.strings"])
75
+ keys, strings = converter.convert(false)
76
+ assert_equal ["ERROR_HANDLER_WARNING_DISMISS", "ANOTHER_STRING"], keys
77
+
78
+ end
79
+
80
+ def test_create_csv_file
81
+ keys = ["ERROR_HANDLER_WARNING_DISMISS", "ANOTHER_STRING"]
82
+ filename = "test_data"
83
+ strings = {filename => {"ERROR_HANDLER_WARNING_DISMISS" => "OK", "ANOTHER_STRING" => "hello"}}
84
+
85
+ converter = Babelish::Strings2CSV.new(:headers => %w{variables english}, :filenames => [filename])
86
+
87
+ converter.send :create_csv_file, keys, strings
88
+ assert File.exist?(converter.csv_filename)
89
+
90
+ #clean up
91
+ system("rm -rf ./" + converter.csv_filename)
92
+ end
93
+
94
+ def test_initialize
95
+ csv_filename = "file.csv"
96
+ filenames = %w{"french.strings english.strings"}
97
+ headers = %w{"constants french english"}
98
+ converter = Babelish::Strings2CSV.new({
99
+ :csv_filename => csv_filename,
100
+ :headers => headers,
101
+ :filenames => filenames
102
+ })
103
+
104
+ assert_equal csv_filename, converter.csv_filename
105
+ assert_equal headers, converter.headers
106
+ assert_equal filenames, converter.filenames
107
+ end
108
+
109
+ def test_initialize_with_default_values
110
+ converter = Babelish::Strings2CSV.new
111
+ assert_not_nil converter.csv_filename
112
+ end
113
+
114
+ end
@@ -0,0 +1,8 @@
1
+ <resources>
2
+
3
+ <string name="app_name">android2csv</string>
4
+ <string name="action_greetings">Hello</string>
5
+ <string name="ANOTHER_STRING">testEN</string>
6
+ <string name="empty"></string>
7
+
8
+ </resources>
@@ -0,0 +1,8 @@
1
+ <resources>
2
+
3
+ <string name="app_name">android2csv</string>
4
+ <string name="action_greetings">Bonjour</string>
5
+ <string name="ANOTHER_STRING">testFR</string>
6
+ <string name="empty"></string>
7
+
8
+ </resources>
@@ -0,0 +1,8 @@
1
+ <resources>
2
+
3
+ <string name="app_name">android2csv</string>
4
+ <string name="action_greetings">Hello</string>
5
+ <string name="ANOTHER_STRING">testEN</string>
6
+ <string name="empty"></string>
7
+
8
+ </resources>
Binary file
@@ -0,0 +1,6 @@
1
+ {
2
+ "app_name": "json2csv",
3
+ "action_greetings": "hello",
4
+ "ANOTHER_STRING": "testEN",
5
+ "empty": ""
6
+ }
@@ -0,0 +1,8 @@
1
+ <?php
2
+
3
+ $lang['app_name'] = "php2csv";
4
+ $lang['action_greetings'] = "Hello";
5
+ $lang['ANOTHER_STRING'] = "testEN";
6
+ $lang['empty'] = "";
7
+
8
+ ?>
@@ -0,0 +1,3 @@
1
+ variables,English
2
+ ERROR_HANDLER_WARNING_DISMISS,OK
3
+ ANOTHER_STRING,hello
@@ -0,0 +1,2 @@
1
+ "ERROR_HANDLER_WARNING_DISMISS" = "OK";
2
+ "ANOTHER_STRING" = "hello";
@@ -0,0 +1,3 @@
1
+ variables,English,German,French,Spanish
2
+ GREETINGS,Hello,Hallo,Salut,Buenos dias
3
+ ANOTHER_STRING,testEN,,,
@@ -0,0 +1,2 @@
1
+ "GREETINGS" = "Hello";
2
+ "ANOTHER_STRING" = "testEN";
@@ -0,0 +1,2 @@
1
+ "GREETINGS" = "Bonjour";
2
+ "ANOTHER_STRING" = "testFR";
Binary file
@@ -0,0 +1,3 @@
1
+ Variables,test/data/test_with_nil.strings
2
+ GREETINGS,Hello
3
+ ANOTHER_STRING,testEN
@@ -0,0 +1,4 @@
1
+ "GREETINGS" = "Hello";
2
+
3
+ "ANOTHER_STRING" = "testEN";
4
+
@@ -0,0 +1,7 @@
1
+ /*
2
+ Localized.strings
3
+ testLocalization
4
+
5
+ Created by François Benaiteau on 14/04/14.
6
+ Copyright (c) 2014 SinnerSchrader Mobile. All rights reserved.
7
+ */
@@ -0,0 +1,17 @@
1
+ begin
2
+ require 'simplecov'
3
+ require 'coveralls'
4
+
5
+ SimpleCov.formatter = Coveralls::SimpleCov::Formatter
6
+ SimpleCov.start do
7
+ add_filter '/test/'
8
+ end
9
+ rescue LoadError
10
+ puts 'Coverage disabled, enable by installing simplecov'
11
+ end
12
+
13
+ require 'test/unit'
14
+
15
+ require 'babelish'
16
+
17
+ require "babelish/commandline"