Permalink
Browse files

Merge branch 'master' of github.com:bcg/em-mongo into bcg_buffer_perf

  • Loading branch information...
2 parents 6932aa6 + 657c30a commit e0a9fd834a5f1e32dfcdcc25cf07aff381703397 @bcg committed Sep 13, 2011
Showing with 3 additions and 5 deletions.
  1. +3 −4 Rakefile
  2. +0 −1 em-mongo.gemspec
View
@@ -15,18 +15,17 @@ task :default => 'spec:integration:default'
class MongoRunner
def self.run(options={})
auth = "--auth" if options[:auth]
- dir = Dir.tmpdir
- FileUtils.rm_r Dir.glob("#{dir}/*") unless options[:noclean]
+ dir = Dir.tmpdir + "/em-mongo-tests-#$$"
+ FileUtils.mkdir dir
pidf = "#{dir}/mongod.pid"
logf = "#{dir}/mongo.log"
begin
- #puts "mongod run #{auth} --fork -vvvvvvv --dbpath #{dir} --pidfilepath #{pidf} --logpath #{logf} >> /dev/null "
system "mongod run #{auth} --fork -vvvvvvv --dbpath #{dir} --pidfilepath #{pidf} --logpath #{logf} >> /dev/null "
yield if block_given?
ensure
if File.exists?(pidf) and File.read(pidf).to_i != 0
Process.kill("KILL", File.read(pidf).to_i)
- FileUtils.rm_r Dir.glob("#{dir}/*") unless options[:noclean]
+ FileUtils.rm_r dir unless options[:noclean]
end
end
end
View
@@ -24,6 +24,5 @@ Gem::Specification.new do |s|
s.add_dependency 'eventmachine', ['>= 0.12.10']
s.add_dependency 'bson', ['>= 1.1.3']
- s.add_dependency 'bson_ext', ['>= 1.1.3']
end

0 comments on commit e0a9fd8

Please sign in to comment.