delayer-deferred 1.0.3 → 1.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/delayer-deferred.gemspec +1 -1
- data/lib/delayer/deferred/thread.rb +2 -1
- data/lib/delayer/deferred/version.rb +1 -1
- data/test/thread_test.rb +17 -0
- metadata +4 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e7ac95be8514c4cce712ba5be5f9959daefdf012
|
4
|
+
data.tar.gz: b63a1e2ef68c15092edd125c28a7d3a68e92a43f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 85b360491e8385fccdf2b5aa5b7679dff0d57f36f9b988e26675f1cc8759a4c3ad23adf2bae933766f330633b9d0da6ce896d18489dc12ccd566ee043b5239df
|
7
|
+
data.tar.gz: 8dcb697c132e1ecefb19923988fdac533e63aa176e1346117d11e3e8ee86536209abe2558730ca69c478be1e8ce578da4ec2e4676c6a7ec6b7a946557f24649f
|
data/delayer-deferred.gemspec
CHANGED
@@ -10,7 +10,7 @@ Gem::Specification.new do |spec|
|
|
10
10
|
spec.email = ["toshi.alternative@gmail.com"]
|
11
11
|
spec.summary = %q{Deferred for Delayer}
|
12
12
|
spec.description = %q{Deferred for Delayer.}
|
13
|
-
spec.homepage = ""
|
13
|
+
spec.homepage = "https://github.com/toshia/delayer-deferred"
|
14
14
|
spec.license = "MIT"
|
15
15
|
|
16
16
|
spec.files = `git ls-files -z`.split("\x0")
|
data/test/thread_test.rb
CHANGED
@@ -9,6 +9,23 @@ describe(Thread) do
|
|
9
9
|
Delayer.default = Delayer.generate_class
|
10
10
|
end
|
11
11
|
|
12
|
+
describe 'Generic thread operation' do
|
13
|
+
describe 'Exception in thread' do
|
14
|
+
before do
|
15
|
+
@error = Class.new(RuntimeError)
|
16
|
+
@thread = Thread.new {
|
17
|
+
raise @error
|
18
|
+
}
|
19
|
+
end
|
20
|
+
|
21
|
+
it 'should takes the exception' do
|
22
|
+
assert_raises(@error) do
|
23
|
+
@thread.value
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
28
|
+
|
12
29
|
it "defer with Deferred#next" do
|
13
30
|
thread = succeed = result = false
|
14
31
|
uuid = SecureRandom.uuid
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: delayer-deferred
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Toshiaki Asai
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-07-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: delayer
|
@@ -98,7 +98,7 @@ files:
|
|
98
98
|
- test/helper.rb
|
99
99
|
- test/testutils.rb
|
100
100
|
- test/thread_test.rb
|
101
|
-
homepage:
|
101
|
+
homepage: https://github.com/toshia/delayer-deferred
|
102
102
|
licenses:
|
103
103
|
- MIT
|
104
104
|
metadata: {}
|
@@ -118,7 +118,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
118
118
|
version: '0'
|
119
119
|
requirements: []
|
120
120
|
rubyforge_project:
|
121
|
-
rubygems_version: 2.
|
121
|
+
rubygems_version: 2.5.1
|
122
122
|
signing_key:
|
123
123
|
specification_version: 4
|
124
124
|
summary: Deferred for Delayer
|
@@ -128,4 +128,3 @@ test_files:
|
|
128
128
|
- test/helper.rb
|
129
129
|
- test/testutils.rb
|
130
130
|
- test/thread_test.rb
|
131
|
-
has_rdoc:
|