Sha256: 3577c9add11900fc4a9af4262cfd1bc39fdf84902184074c9f2c79c5ef947875

Contents?: true

Size: 732 Bytes

Versions: 7

Compression:

Stored size: 732 Bytes

Contents

require 'spec_helper'

describe SportsDataApi::Mlb::Team, vcr: {
    cassette_name: 'sports_data_api_mlb_team',
    record: :new_episodes,
    match_requests_on: [:host, :path]
} do
  let(:teams) do
    SportsDataApi.set_key(:mlb, api_key(:mlb))
    SportsDataApi.set_access_level(:mlb, 't')
    SportsDataApi::Mlb.teams(2014)
  end

  context 'results from teams fetch' do
    subject { teams.first }
    it { should be_an_instance_of(SportsDataApi::Mlb::Team) }
    its(:id) { should eq "ef64da7f-cfaf-4300-87b0-9313386b977c" }
    its(:alias) { should eq 'LA' }
    its(:league) { should eq 'NL' }
    its(:division) { should eq 'W' }
    its(:market) { should eq 'Los Angeles' }
    its(:name) { should eq 'Dodgers' }
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
sports_data_api-0.10.1 spec/lib/sports_data_api/mlb/team_spec.rb
sports_data_api-0.10.0 spec/lib/sports_data_api/mlb/team_spec.rb
sports_data_api-0.9.2 spec/lib/sports_data_api/mlb/team_spec.rb
sports_data_api-0.2.4 spec/lib/sports_data_api/mlb/team_spec.rb
sports_data_api-0.2.3 spec/lib/sports_data_api/mlb/team_spec.rb
sports_data_api-0.2.2 spec/lib/sports_data_api/mlb/team_spec.rb
sports_data_api-0.2.1 spec/lib/sports_data_api/mlb/team_spec.rb