mkreiser / ESPN-Fantasy-Football-API

Connect to ESPN's fantasy football API via this JS API client for web and NodeJS. Available as an npm package.
http://espn-fantasy-football-api.s3-website.us-east-2.amazonaws.com/
GNU Lesser General Public License v3.0
304 stars 76 forks source link

Add ability to retrieve basic matchup scores for a season #157

Closed jamesshaw1987 closed 10 months ago

jamesshaw1987 commented 4 years ago

Would like to have changed the Boxscore class to extend the MatchupScore class, but not sure it would improve readability or reduce duplication, so left it alone.

Integration tests are currently failing as the snapshot in the repo is out of date. Not certain what needs doing to update the snapshot.

jamesshaw1987 commented 4 years ago

Integration tests are currently failing as the snapshot in the repo is out of date.

Doesn't look like this is the reason for failing actually. All the tests that use the seasonId parameter are failing with a 400 response.

Edit: Or maybe it's just because I wasn't setting the leagueId and authentication cookies when running the tests...

jamesshaw1987 commented 4 years ago

Also added in the ability to fetch basic team data for a season, without including roster data.

jamesshaw1987 commented 4 years ago

These Code Climate failures are very annoying. At some point some level of duplication is fine! Any suggestions on what else to do to get it to accept the code?

codecov-commenter commented 4 years ago

Codecov Report

Merging #157 into master will not change coverage. The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##            master      #157   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           13        14    +1     
  Lines          181       203   +22     
  Branches        25        28    +3     
=========================================
+ Hits           181       203   +22     
Impacted Files Coverage Δ
src/client/client.js 100.00% <100.00%> (ø)
src/matchup-score/matchup-score.js 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update ead02ed...04cfbe8. Read the comment docs.