Permalink
Browse files

Removing timecop dev dep and all tests now passing on ruby 1.9.

  • Loading branch information...
1 parent 91f4148 commit 79865f0c643e8fa655d428ef13e1adbeda7dad57 @jnunemaker committed Jun 2, 2010
Showing with 2 additions and 7 deletions.
  1. +0 −1 bin.gemspec
  2. +2 −5 spec/bin/store_spec.rb
  3. +0 −1 spec/helper.rb
View
1 bin.gemspec
@@ -15,5 +15,4 @@ Gem::Specification.new do |s|
s.add_dependency 'mongo', '~> 1.0.1'
s.add_dependency 'activesupport', '<= 2.3.8'
s.add_development_dependency 'rspec', '~> 1.3.0'
- s.add_development_dependency 'timecop', '>= 0.3.4'
end
View
7 spec/bin/store_spec.rb
@@ -21,7 +21,6 @@
describe "#write" do
before(:each) do
- Timecop.freeze(Time.utc(2009, 5, 10, 1, 1 ,1))
store.write('foo', 'bar')
end
let(:document) { collection.find_one(:_id => 'foo') }
@@ -35,10 +34,8 @@
end
it "sets expires_at if expires_in provided" do
- Timecop.freeze(Time.utc(2009, 5, 10, 1, 1, 1)) do
- store.write('foo', 'bar', :expires_in => 5.seconds)
- end
- document['expires_at'].should == Time.utc(2009, 5, 10, 1, 1, 6)
+ store.write('foo', 'bar', :expires_in => 5.seconds)
+ document['expires_at'].to_i.should == (Time.now.utc + 5.seconds).to_i
end
end
View
1 spec/helper.rb
@@ -4,7 +4,6 @@
require 'bin'
require 'spec'
-require 'timecop'
connection = Mongo::Connection.new
DB = connection.db('bin-store-test')

0 comments on commit 79865f0

Please sign in to comment.