redis-store 1.1.1 → 1.1.2

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of redis-store might be problematic. Click here for more details.

@@ -41,6 +41,10 @@ class Redis
41
41
  "#{super} with namespace #{@namespace}"
42
42
  end
43
43
 
44
+ def flushdb
45
+ del *keys
46
+ end
47
+
44
48
  private
45
49
  def namespace(key)
46
50
  yield interpolate(key)
@@ -1,5 +1,5 @@
1
1
  class Redis
2
2
  class Store < self
3
- VERSION = '1.1.1'
3
+ VERSION = '1.1.2'
4
4
  end
5
5
  end
@@ -23,6 +23,17 @@ describe "Redis::Store::Namespace" do
23
23
  @store.send(:interpolate, "#{@namespace}:rabbit").must_equal("#{@namespace}:rabbit")
24
24
  end
25
25
 
26
+ it "should ony delete namespaced keys" do
27
+ other_store = Redis::Store.new
28
+
29
+ other_store.set 'abc', 'cba'
30
+ @store.set 'def', 'fed'
31
+
32
+ @store.flushdb
33
+ @store.get('def').must_equal(nil)
34
+ other_store.get('abc').must_equal('cba')
35
+ end
36
+
26
37
  it "namespaces get"
27
38
  it "namespaces set"
28
39
  it "namespaces setnx"
@@ -33,7 +44,7 @@ describe "Redis::Store::Namespace" do
33
44
  it "namespaces incrby"
34
45
  it "namespaces decrby"
35
46
  it "namespaces mget"
36
-
47
+
37
48
  # it "should namespace get" do
38
49
  # @client.expects(:call).with([:get, "#{@namespace}:rabbit"]).once
39
50
  # @store.get("rabbit")
@@ -1,7 +1,7 @@
1
1
  require 'test_helper'
2
2
 
3
3
  describe Redis::Store::VERSION do
4
- it "must be equal to 1.1.1" do
5
- Redis::Store::VERSION.must_equal '1.1.1'
4
+ it "must be equal to 1.1.2" do
5
+ Redis::Store::VERSION.must_equal '1.1.2'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,137 +1,144 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: redis-store
3
- version: !ruby/object:Gem::Version
4
- version: 1.1.1
3
+ version: !ruby/object:Gem::Version
4
+ hash: 23
5
5
  prerelease:
6
+ segments:
7
+ - 1
8
+ - 1
9
+ - 2
10
+ version: 1.1.2
6
11
  platform: ruby
7
- authors:
12
+ authors:
8
13
  - Luca Guidi
9
14
  - Matt Horan
10
15
  autorequire:
11
16
  bindir: bin
12
17
  cert_chain: []
13
- date: 2012-06-26 00:00:00.000000000 Z
14
- dependencies:
15
- - !ruby/object:Gem::Dependency
16
- name: redis
17
- requirement: !ruby/object:Gem::Requirement
18
- none: false
19
- requirements:
20
- - - ! '>='
21
- - !ruby/object:Gem::Version
22
- version: 2.2.0
23
- type: :runtime
18
+
19
+ date: 2012-09-04 00:00:00 Z
20
+ dependencies:
21
+ - !ruby/object:Gem::Dependency
24
22
  prerelease: false
25
- version_requirements: !ruby/object:Gem::Requirement
23
+ type: :runtime
24
+ requirement: &id001 !ruby/object:Gem::Requirement
26
25
  none: false
27
- requirements:
28
- - - ! '>='
29
- - !ruby/object:Gem::Version
26
+ requirements:
27
+ - - ">="
28
+ - !ruby/object:Gem::Version
29
+ hash: 7
30
+ segments:
31
+ - 2
32
+ - 2
33
+ - 0
30
34
  version: 2.2.0
31
- - !ruby/object:Gem::Dependency
32
- name: rake
33
- requirement: !ruby/object:Gem::Requirement
35
+ name: redis
36
+ version_requirements: *id001
37
+ - !ruby/object:Gem::Dependency
38
+ prerelease: false
39
+ type: :development
40
+ requirement: &id002 !ruby/object:Gem::Requirement
34
41
  none: false
35
- requirements:
42
+ requirements:
36
43
  - - ~>
37
- - !ruby/object:Gem::Version
44
+ - !ruby/object:Gem::Version
45
+ hash: 63
46
+ segments:
47
+ - 0
48
+ - 9
49
+ - 2
38
50
  version: 0.9.2
39
- type: :development
51
+ name: rake
52
+ version_requirements: *id002
53
+ - !ruby/object:Gem::Dependency
40
54
  prerelease: false
41
- version_requirements: !ruby/object:Gem::Requirement
55
+ type: :development
56
+ requirement: &id003 !ruby/object:Gem::Requirement
42
57
  none: false
43
- requirements:
58
+ requirements:
44
59
  - - ~>
45
- - !ruby/object:Gem::Version
46
- version: 0.9.2
47
- - !ruby/object:Gem::Dependency
60
+ - !ruby/object:Gem::Version
61
+ hash: 13
62
+ segments:
63
+ - 1
64
+ - 1
65
+ version: "1.1"
48
66
  name: bundler
49
- requirement: !ruby/object:Gem::Requirement
50
- none: false
51
- requirements:
52
- - - ~>
53
- - !ruby/object:Gem::Version
54
- version: '1.1'
55
- type: :development
67
+ version_requirements: *id003
68
+ - !ruby/object:Gem::Dependency
56
69
  prerelease: false
57
- version_requirements: !ruby/object:Gem::Requirement
58
- none: false
59
- requirements:
60
- - - ~>
61
- - !ruby/object:Gem::Version
62
- version: '1.1'
63
- - !ruby/object:Gem::Dependency
64
- name: mocha
65
- requirement: !ruby/object:Gem::Requirement
66
- none: false
67
- requirements:
68
- - - ~>
69
- - !ruby/object:Gem::Version
70
- version: 0.10.0
71
70
  type: :development
72
- prerelease: false
73
- version_requirements: !ruby/object:Gem::Requirement
71
+ requirement: &id004 !ruby/object:Gem::Requirement
74
72
  none: false
75
- requirements:
73
+ requirements:
76
74
  - - ~>
77
- - !ruby/object:Gem::Version
75
+ - !ruby/object:Gem::Version
76
+ hash: 55
77
+ segments:
78
+ - 0
79
+ - 10
80
+ - 0
78
81
  version: 0.10.0
79
- - !ruby/object:Gem::Dependency
80
- name: minitest
81
- requirement: !ruby/object:Gem::Requirement
82
- none: false
83
- requirements:
84
- - - ~>
85
- - !ruby/object:Gem::Version
86
- version: 2.8.0
87
- type: :development
82
+ name: mocha
83
+ version_requirements: *id004
84
+ - !ruby/object:Gem::Dependency
88
85
  prerelease: false
89
- version_requirements: !ruby/object:Gem::Requirement
86
+ type: :development
87
+ requirement: &id005 !ruby/object:Gem::Requirement
90
88
  none: false
91
- requirements:
89
+ requirements:
92
90
  - - ~>
93
- - !ruby/object:Gem::Version
91
+ - !ruby/object:Gem::Version
92
+ hash: 47
93
+ segments:
94
+ - 2
95
+ - 8
96
+ - 0
94
97
  version: 2.8.0
95
- - !ruby/object:Gem::Dependency
96
- name: purdytest
97
- requirement: !ruby/object:Gem::Requirement
98
- none: false
99
- requirements:
100
- - - ~>
101
- - !ruby/object:Gem::Version
102
- version: 1.0.0
103
- type: :development
98
+ name: minitest
99
+ version_requirements: *id005
100
+ - !ruby/object:Gem::Dependency
104
101
  prerelease: false
105
- version_requirements: !ruby/object:Gem::Requirement
102
+ type: :development
103
+ requirement: &id006 !ruby/object:Gem::Requirement
106
104
  none: false
107
- requirements:
105
+ requirements:
108
106
  - - ~>
109
- - !ruby/object:Gem::Version
107
+ - !ruby/object:Gem::Version
108
+ hash: 23
109
+ segments:
110
+ - 1
111
+ - 0
112
+ - 0
110
113
  version: 1.0.0
111
- - !ruby/object:Gem::Dependency
112
- name: git
113
- requirement: !ruby/object:Gem::Requirement
114
- none: false
115
- requirements:
116
- - - ~>
117
- - !ruby/object:Gem::Version
118
- version: 1.2.5
119
- type: :development
114
+ name: purdytest
115
+ version_requirements: *id006
116
+ - !ruby/object:Gem::Dependency
120
117
  prerelease: false
121
- version_requirements: !ruby/object:Gem::Requirement
118
+ type: :development
119
+ requirement: &id007 !ruby/object:Gem::Requirement
122
120
  none: false
123
- requirements:
121
+ requirements:
124
122
  - - ~>
125
- - !ruby/object:Gem::Version
123
+ - !ruby/object:Gem::Version
124
+ hash: 21
125
+ segments:
126
+ - 1
127
+ - 2
128
+ - 5
126
129
  version: 1.2.5
127
- description: Namespaced Rack::Session, Rack::Cache, I18n and cache Redis stores for
128
- Ruby web frameworks.
129
- email:
130
+ name: git
131
+ version_requirements: *id007
132
+ description: Namespaced Rack::Session, Rack::Cache, I18n and cache Redis stores for Ruby web frameworks.
133
+ email:
130
134
  - me@lucaguidi.com
131
135
  executables: []
136
+
132
137
  extensions: []
138
+
133
139
  extra_rdoc_files: []
134
- files:
140
+
141
+ files:
135
142
  - Gemfile
136
143
  - MIT-LICENSE
137
144
  - README.md
@@ -161,39 +168,36 @@ files:
161
168
  - test/test_helper.rb
162
169
  homepage: http://jodosha.github.com/redis-store
163
170
  licenses: []
171
+
164
172
  post_install_message:
165
173
  rdoc_options: []
166
- require_paths:
174
+
175
+ require_paths:
167
176
  - lib
168
- required_ruby_version: !ruby/object:Gem::Requirement
177
+ required_ruby_version: !ruby/object:Gem::Requirement
169
178
  none: false
170
- requirements:
171
- - - ! '>='
172
- - !ruby/object:Gem::Version
173
- version: '0'
174
- required_rubygems_version: !ruby/object:Gem::Requirement
179
+ requirements:
180
+ - - ">="
181
+ - !ruby/object:Gem::Version
182
+ hash: 3
183
+ segments:
184
+ - 0
185
+ version: "0"
186
+ required_rubygems_version: !ruby/object:Gem::Requirement
175
187
  none: false
176
- requirements:
177
- - - ! '>='
178
- - !ruby/object:Gem::Version
179
- version: '0'
188
+ requirements:
189
+ - - ">="
190
+ - !ruby/object:Gem::Version
191
+ hash: 3
192
+ segments:
193
+ - 0
194
+ version: "0"
180
195
  requirements: []
196
+
181
197
  rubyforge_project: redis-store
182
- rubygems_version: 1.8.23
198
+ rubygems_version: 1.8.15
183
199
  signing_key:
184
200
  specification_version: 3
185
201
  summary: Redis stores for Ruby frameworks
186
- test_files:
187
- - test/config/node-one.conf
188
- - test/config/node-two.conf
189
- - test/config/redis.conf
190
- - test/redis/distributed_store_test.rb
191
- - test/redis/factory_test.rb
192
- - test/redis/store/interface_test.rb
193
- - test/redis/store/marshalling_test.rb
194
- - test/redis/store/namespace_test.rb
195
- - test/redis/store/ttl_test.rb
196
- - test/redis/store/version_test.rb
197
- - test/redis/store_test.rb
198
- - test/test_helper.rb
199
- has_rdoc:
202
+ test_files: []
203
+