Sha256: d796f1d90183b0f4f5874e1c1dbafa372c0ba8801f39706c0dc6d5b0590a3d58

Contents?: true

Size: 496 Bytes

Versions: 1

Compression:

Stored size: 496 Bytes

Contents

require 'spec_helper'

describe GitWakaTime::RequestBuilder do
  subject(:subject) { described_class.new(3.days.ago, Time.now).call }

  it 'returns a array of hashes' do
    expect(subject).to be_a(Array)
    expect(subject.first).to be_a(Hash)
  end

  it 'has a hash per day' do
    expect(subject.size).to eq(4)
  end

  it 'has a first hash will be for 3 days ago' do
    expect(subject.first).to eq(
      date: 3.days.ago.to_date,
      show: 'file,branch,project,time,id'
    )
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
gitwakatime-0.4.0 spec/request_builder_spec.rb