Sha256: 7463b48fadc3cc83fcd01702055770aa7709fc7d6a6af84b5a49f1814536d728

Contents?: true

Size: 274 Bytes

Versions: 8

Compression:

Stored size: 274 Bytes

Contents

require 'spec_helper'

describe 'Coercion Examples' do
  let(:entry) { vcr('entry') { create_client.entry 'nyancat' } }

  it 'converts contentful to ruby DateTime objects' do
    expect(entry.created_at).to be_a DateTime
    expect(entry.created_at.day).to eq 27
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
contentful-0.10.0 spec/coercions_spec.rb
contentful-0.9.0 spec/coercions_spec.rb
contentful-0.8.0 spec/coercions_spec.rb
contentful-0.7.0 spec/coercions_spec.rb
contentful-0.6.0 spec/coercions_spec.rb
contentful-0.5.0 spec/coercions_spec.rb
contentful-0.4.0 spec/coercions_spec.rb
contentful-0.3.5 spec/coercions_spec.rb