web_translate_it 2.5.2 → 2.5.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -2
- data/history.md +4 -0
- data/lib/web_translate_it/configuration.rb +1 -1
- data/spec/web_translate_it/term_spec.rb +8 -5
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,4 +1,7 @@
|
|
1
1
|
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 2f4da4e145e768d5dcebc04cb085be79182fa33af33ce4d5fa0b0c1598cef7b4
|
4
|
+
data.tar.gz: d565be12c309530ef0e55b1090804f5e1137b1f327bc08e278477448a4076701
|
2
5
|
SHA512:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c47cbf387a3557e67ea5d948a2a226d380bb60d3bc9b53755ab858d9ec3f315ae64737d9681c1a3fc4bc5ef29a23a93751ea710dce10576ec2ddfdcc0cd58b47
|
7
|
+
data.tar.gz: 85abf263f0112367bd8f5ae8af8d22e5cb2bdebbb4c31dcc532602b245f389999912bbad8869db0fcf870b7a5e02c7c3000e6fbb9fb89f8221a0ca94eaaeb371
|
data/history.md
CHANGED
@@ -25,7 +25,7 @@ module WebTranslateIt
|
|
25
25
|
self.after_pull = configuration['after_pull']
|
26
26
|
self.before_push = configuration['before_push']
|
27
27
|
self.after_push = configuration['after_push']
|
28
|
-
project_info = if RUBY_VERSION >= 3.1
|
28
|
+
project_info = if RUBY_VERSION >= '3.1.0'
|
29
29
|
YAML.safe_load WebTranslateIt::Project.fetch_info(api_key), permitted_classes: [Time]
|
30
30
|
else
|
31
31
|
YAML.load WebTranslateIt::Project.fetch_info(api_key)
|
@@ -53,8 +53,8 @@ describe WebTranslateIt::Term do
|
|
53
53
|
term.save
|
54
54
|
term_fetched = WebTranslateIt::Term.find(term.id)
|
55
55
|
term_fetched.translation_for("fr").should_not be_nil
|
56
|
-
term_fetched.translation_for("fr")[0].text.should == "
|
57
|
-
term_fetched.translation_for("fr")[1].text.should == "
|
56
|
+
term_fetched.translation_for("fr")[0].text.should == "Salut"
|
57
|
+
term_fetched.translation_for("fr")[1].text.should == "Bonjour"
|
58
58
|
term_fetched.translation_for("es").should be_nil
|
59
59
|
term.delete
|
60
60
|
end
|
@@ -75,8 +75,8 @@ describe WebTranslateIt::Term do
|
|
75
75
|
|
76
76
|
term_fetched = WebTranslateIt::Term.find(term.id)
|
77
77
|
term_fetched.translation_for("fr").should_not be_nil
|
78
|
-
term_fetched.translation_for("fr")[0].text.should == "
|
79
|
-
term_fetched.translation_for("fr")[1].text.should == "
|
78
|
+
term_fetched.translation_for("fr")[0].text.should == "Salut"
|
79
|
+
term_fetched.translation_for("fr")[1].text.should == "Bonjour"
|
80
80
|
term.delete
|
81
81
|
end
|
82
82
|
end
|
@@ -100,6 +100,9 @@ describe WebTranslateIt::Term do
|
|
100
100
|
describe "#find_all" do
|
101
101
|
it "should fetch many terms" do
|
102
102
|
WebTranslateIt::Connection.new(api_key) do
|
103
|
+
terms = WebTranslateIt::Term.find_all
|
104
|
+
count = terms.count
|
105
|
+
|
103
106
|
term1 = WebTranslateIt::Term.new({ "text" => "greeting 1" })
|
104
107
|
term1.save
|
105
108
|
term2 = WebTranslateIt::Term.new({ "text" => "greeting 2" })
|
@@ -108,7 +111,7 @@ describe WebTranslateIt::Term do
|
|
108
111
|
term3.save
|
109
112
|
|
110
113
|
terms = WebTranslateIt::Term.find_all
|
111
|
-
terms.count.should == 3
|
114
|
+
count - terms.count.should == 3
|
112
115
|
|
113
116
|
term1.delete
|
114
117
|
term2.delete
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: web_translate_it
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.5.
|
4
|
+
version: 2.5.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Edouard Briere
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-02-
|
11
|
+
date: 2022-02-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: multipart-post
|