prefetch-rspec 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.1
1
+ 0.1.2
@@ -270,6 +270,7 @@ module PrefetchRspec
270
270
  end
271
271
 
272
272
  def listen
273
+ ENV['PRSPEC'] = 'true'
273
274
  detect_load_config
274
275
 
275
276
  begin
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{prefetch-rspec}
8
- s.version = "0.1.1"
8
+ s.version = "0.1.2"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Yuichi Tateno"]
12
- s.date = %q{2010-12-11}
12
+ s.date = %q{2010-12-13}
13
13
  s.description = %q{ }
14
14
  s.email = %q{hotchpotch@gmail.com}
15
15
  s.executables = ["prspecd", "prspec"]
@@ -157,6 +157,20 @@ describe PrefetchRspec do
157
157
  err_io.read.should_not match(/Can't connect to prspecd/)
158
158
  end
159
159
 
160
+ it "set ENV['PRSPEC']" do
161
+ hooks = double('hooks')
162
+ hooks.should_receive('prefetch')
163
+ hooks.should_receive('before_run')
164
+ hooks.should_receive('after_run')
165
+ server.prefetch { hooks.prefetch if ENV['PRSPEC'] }
166
+ server.before_run { hooks.before_run if ENV['PRSPEC'] }
167
+ server.after_run { hooks.after_run if ENV['PRSPEC'] }
168
+ listen
169
+ r = runner { ENV.has_key? 'PRSPEC' }
170
+ r.run.should be_true
171
+ sleep 0.1
172
+ end
173
+
160
174
  it "wait prefetch" do
161
175
  hooks = double('hooks')
162
176
  hooks.should_receive('prefetch')
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: prefetch-rspec
3
3
  version: !ruby/object:Gem::Version
4
- hash: 25
4
+ hash: 31
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 1
10
- version: 0.1.1
9
+ - 2
10
+ version: 0.1.2
11
11
  platform: ruby
12
12
  authors:
13
13
  - Yuichi Tateno
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-12-11 00:00:00 +09:00
18
+ date: 2010-12-13 00:00:00 +09:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency