Sha256: 7e3e2d80eb49be37874307cc7899fe96b284c321a8cee02b4e194d7f290412e4

Contents?: true

Size: 623 Bytes

Versions: 7

Compression:

Stored size: 623 Bytes

Contents

# encoding: utf-8

require 'spec_helper'

describe Github::Repos::Statistics, '#participation' do
  let(:user) { 'peter-murach' }
  let(:repo) { 'github' }
  let(:request_path) { "/repos/#{user}/#{repo}/stats/participation" }

  before {
    stub_get(request_path).to_return(:body => body)
  }

  context "resource found" do
    let(:body) { fixture('repos/participation.json') }
    let(:status) { 200 }

    it { expect { subject.participation }.to raise_error(ArgumentError) }

    it "should get the resources" do
      subject.participation user, repo
      a_get(request_path).should have_been_made
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
github_api-0.11.3 spec/github/repos/statistics/participation_spec.rb
github_api-0.11.2 spec/github/repos/statistics/participation_spec.rb
github_api-0.11.1 spec/github/repos/statistics/participation_spec.rb
github_api-0.11.0 spec/github/repos/statistics/participation_spec.rb
github_api-0.10.2 spec/github/repos/statistics/participation_spec.rb
github_api-0.10.1 spec/github/repos/statistics/participation_spec.rb
github_api-0.10.0 spec/github/repos/statistics/participation_spec.rb