Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
### 2.2.1 (Next)
### 2.3.0 (Next)

* [#87](https://github.com/dblock/strava-ruby-client/pull/87): Prepares v2.3.0 by improving the event specs - [@simonneutert](https://github.com/simonneutert).
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd remove this, it doesn't tell much :)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

something is required, else DangerBot will be unhappy 🤷‍♂️

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's not fatal though.

* [#86](https://github.com/dblock/strava-ruby-client/pull/86): Add description to club event model - [@tobiaszwaszak](https://github.com/tobiaszwaszak).
* Your contribution here.

Expand Down
2 changes: 1 addition & 1 deletion lib/strava/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module Strava
VERSION = '2.2.1'
VERSION = '2.3.0'
end
12 changes: 10 additions & 2 deletions spec/strava/api/client/endpoints/clubs/club_events_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,27 @@
include_context 'with API client'
it 'returns club events' do
club_events = client.club_events('456773')
expect(club_events.size).to eq 107
expect(club_events).to be_a Enumerable
event = club_events.first
expect(club_events.size).to eq 107
event = club_events.find { |e| e.id == 340_487 }
expect(event.id).to be_a Integer
expect(event.id).to eq(340_487)
expect(event.women_only).to be_a FalseClass
expect(event.private).to be_a FalseClass
expect(event.description).to be_a String
expect(event.description.size).to eq(546)
expect(event.description).to start_with('Damit die Fahrt stattfindet wird')
expect(event.resource_state).to be_a Integer
expect(event.resource_state).to eq(2)
expect(event.club_id).to be_a Integer
expect(event.club_id).to eq(456_773)
expect(event.skill_levels).to be_a Integer
expect(event.skill_levels).to eq(1)
expect(event.terrain).to be_a Integer
expect(event.route_id).to be_a(Integer).or(be_nil)
expect(event.upcoming_occurrences).to be_a Enumerable
expect(event.upcoming_occurrences.first).to be_a Time
expect(event.upcoming_occurrences.first).to eq(Time.new(2018, 6, 23, 8, 30, 0, '+00:00'))
expect(event).to be_a Strava::Models::ClubEvent
end
end