Sha256: 889cc1d273e8325fa1260377b1ab7c9a891eab8dbdb4855bc52fbecc6ffef16b

Contents?: true

Size: 332 Bytes

Versions: 1

Compression:

Stored size: 332 Bytes

Contents

# encoding: utf-8

require 'spec_helper'

describe Time, '#pred' do
  subject { object.pred }

  let(:object) { described_class.now }

  it { should be_kind_of(described_class) }

  it 'returns the time 1 second ago' do
    should == (object - 1)
  end

  it 'is the inverse of #succ' do
    subject.succ.should == object
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
veritas-0.0.4 spec/unit/time/pred_spec.rb