resque-scheduler 1.9.1 → 1.9.2

Sign up to get free protection for your applications and to get access to all the features.
data/HISTORY.md CHANGED
@@ -1,3 +1,7 @@
1
+ ## 1.9.2 (2010-06-16)
2
+
3
+ * Fixing issue with redis gem 2.0.1 and redis server 1.2.6 (dbackeus)
4
+
1
5
  ## 1.9.1 (2010-06-04)
2
6
 
3
7
  * Fixing issue with redis server 1.2.6 and redis gem 2.0.1
@@ -64,7 +64,7 @@ module ResqueScheduler
64
64
 
65
65
  # Returns an array of timestamps based on start and count
66
66
  def delayed_queue_peek(start, count)
67
- redis.zrange(:delayed_queue_schedule, start, start+count).collect{|x| x.to_i}
67
+ Array(redis.zrange(:delayed_queue_schedule, start, start+count)).collect{|x| x.to_i}
68
68
  end
69
69
 
70
70
  # Returns the size of the delayed queue schedule
@@ -1,3 +1,3 @@
1
1
  module ResqueScheduler
2
- Version = '1.9.1'
2
+ Version = '1.9.2'
3
3
  end
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{resque-scheduler}
8
- s.version = "1.9.1"
8
+ s.version = "1.9.2"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Ben VandenBos"]
12
- s.date = %q{2010-06-04}
12
+ s.date = %q{2010-06-17}
13
13
  s.description = %q{Light weight job scheduling on top of Resque.
14
14
  Adds methods enqueue_at/enqueue_in to schedule jobs in the future.
15
15
  Also supports queueing jobs on a fixed, cron-like schedule.}
@@ -43,7 +43,7 @@ Gem::Specification.new do |s|
43
43
  s.homepage = %q{http://github.com/bvandenbos/resque-scheduler}
44
44
  s.rdoc_options = ["--charset=UTF-8"]
45
45
  s.require_paths = ["lib"]
46
- s.rubygems_version = %q{1.3.5}
46
+ s.rubygems_version = %q{1.3.7}
47
47
  s.summary = %q{Light weight job scheduling on top of Resque}
48
48
  s.test_files = [
49
49
  "test/delayed_queue_test.rb",
@@ -56,7 +56,7 @@ Gem::Specification.new do |s|
56
56
  current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
57
57
  s.specification_version = 3
58
58
 
59
- if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
59
+ if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
60
60
  s.add_runtime_dependency(%q<redis>, [">= 2.0.1"])
61
61
  s.add_runtime_dependency(%q<resque>, [">= 1.8.0"])
62
62
  s.add_runtime_dependency(%q<rufus-scheduler>, [">= 0"])
@@ -60,6 +60,10 @@ class Resque::DelayedQueueTest < Test::Unit::TestCase
60
60
  assert_equal(2, Resque.redis.llen("delayed:#{timestamp.to_i}"), "should have 2 items in the timestamp queue")
61
61
  end
62
62
 
63
+ def test_empty_delayed_queue_peek
64
+ assert_equal([], Resque.delayed_queue_peek(0,20))
65
+ end
66
+
63
67
  def test_delayed_queue_peek
64
68
  t = Time.now
65
69
  expected_timestamps = (1..5).to_a.map do |i|
@@ -63,4 +63,10 @@ class Resque::SchedulerTest < Test::Unit::TestCase
63
63
  assert_equal(1, Resque::Scheduler.rufus_scheduler.all_jobs.size)
64
64
  end
65
65
 
66
+ def test_adheres_to_lint
67
+ assert_nothing_raised do
68
+ Resque::Plugin.lint(Resque::Scheduler)
69
+ end
70
+ end
71
+
66
72
  end
metadata CHANGED
@@ -1,7 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: resque-scheduler
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.1
4
+ hash: 55
5
+ prerelease: false
6
+ segments:
7
+ - 1
8
+ - 9
9
+ - 2
10
+ version: 1.9.2
5
11
  platform: ruby
6
12
  authors:
7
13
  - Ben VandenBos
@@ -9,69 +15,97 @@ autorequire:
9
15
  bindir: bin
10
16
  cert_chain: []
11
17
 
12
- date: 2010-06-04 00:00:00 -07:00
18
+ date: 2010-06-17 00:00:00 -07:00
13
19
  default_executable:
14
20
  dependencies:
15
21
  - !ruby/object:Gem::Dependency
16
22
  name: redis
17
- type: :runtime
18
- version_requirement:
19
- version_requirements: !ruby/object:Gem::Requirement
23
+ prerelease: false
24
+ requirement: &id001 !ruby/object:Gem::Requirement
25
+ none: false
20
26
  requirements:
21
27
  - - ">="
22
28
  - !ruby/object:Gem::Version
29
+ hash: 13
30
+ segments:
31
+ - 2
32
+ - 0
33
+ - 1
23
34
  version: 2.0.1
24
- version:
35
+ type: :runtime
36
+ version_requirements: *id001
25
37
  - !ruby/object:Gem::Dependency
26
38
  name: resque
27
- type: :runtime
28
- version_requirement:
29
- version_requirements: !ruby/object:Gem::Requirement
39
+ prerelease: false
40
+ requirement: &id002 !ruby/object:Gem::Requirement
41
+ none: false
30
42
  requirements:
31
43
  - - ">="
32
44
  - !ruby/object:Gem::Version
45
+ hash: 55
46
+ segments:
47
+ - 1
48
+ - 8
49
+ - 0
33
50
  version: 1.8.0
34
- version:
51
+ type: :runtime
52
+ version_requirements: *id002
35
53
  - !ruby/object:Gem::Dependency
36
54
  name: rufus-scheduler
37
- type: :runtime
38
- version_requirement:
39
- version_requirements: !ruby/object:Gem::Requirement
55
+ prerelease: false
56
+ requirement: &id003 !ruby/object:Gem::Requirement
57
+ none: false
40
58
  requirements:
41
59
  - - ">="
42
60
  - !ruby/object:Gem::Version
61
+ hash: 3
62
+ segments:
63
+ - 0
43
64
  version: "0"
44
- version:
65
+ type: :runtime
66
+ version_requirements: *id003
45
67
  - !ruby/object:Gem::Dependency
46
68
  name: jeweler
47
- type: :development
48
- version_requirement:
49
- version_requirements: !ruby/object:Gem::Requirement
69
+ prerelease: false
70
+ requirement: &id004 !ruby/object:Gem::Requirement
71
+ none: false
50
72
  requirements:
51
73
  - - ">="
52
74
  - !ruby/object:Gem::Version
75
+ hash: 3
76
+ segments:
77
+ - 0
53
78
  version: "0"
54
- version:
79
+ type: :development
80
+ version_requirements: *id004
55
81
  - !ruby/object:Gem::Dependency
56
82
  name: mocha
57
- type: :development
58
- version_requirement:
59
- version_requirements: !ruby/object:Gem::Requirement
83
+ prerelease: false
84
+ requirement: &id005 !ruby/object:Gem::Requirement
85
+ none: false
60
86
  requirements:
61
87
  - - ">="
62
88
  - !ruby/object:Gem::Version
89
+ hash: 3
90
+ segments:
91
+ - 0
63
92
  version: "0"
64
- version:
93
+ type: :development
94
+ version_requirements: *id005
65
95
  - !ruby/object:Gem::Dependency
66
96
  name: rack-test
67
- type: :development
68
- version_requirement:
69
- version_requirements: !ruby/object:Gem::Requirement
97
+ prerelease: false
98
+ requirement: &id006 !ruby/object:Gem::Requirement
99
+ none: false
70
100
  requirements:
71
101
  - - ">="
72
102
  - !ruby/object:Gem::Version
103
+ hash: 3
104
+ segments:
105
+ - 0
73
106
  version: "0"
74
- version:
107
+ type: :development
108
+ version_requirements: *id006
75
109
  description: |-
76
110
  Light weight job scheduling on top of Resque.
77
111
  Adds methods enqueue_at/enqueue_in to schedule jobs in the future.
@@ -115,21 +149,27 @@ rdoc_options:
115
149
  require_paths:
116
150
  - lib
117
151
  required_ruby_version: !ruby/object:Gem::Requirement
152
+ none: false
118
153
  requirements:
119
154
  - - ">="
120
155
  - !ruby/object:Gem::Version
156
+ hash: 3
157
+ segments:
158
+ - 0
121
159
  version: "0"
122
- version:
123
160
  required_rubygems_version: !ruby/object:Gem::Requirement
161
+ none: false
124
162
  requirements:
125
163
  - - ">="
126
164
  - !ruby/object:Gem::Version
165
+ hash: 3
166
+ segments:
167
+ - 0
127
168
  version: "0"
128
- version:
129
169
  requirements: []
130
170
 
131
171
  rubyforge_project:
132
- rubygems_version: 1.3.5
172
+ rubygems_version: 1.3.7
133
173
  signing_key:
134
174
  specification_version: 3
135
175
  summary: Light weight job scheduling on top of Resque