kenpompy
kenpompy copied to clipboard
Enhancement: Add GitHub Actions CI/CD for pytest
This is a simple enhancement introducing a configuration for GitHub Actions to run pytest
on new pushes to the repository. There are just a few items to note that are a bit on the quirkier side over other repositories:
- The
strategy.max_parallel
had to be explicitly set to1
in this particular scenario because of the way sessions work on KenPom - essentially if more than one job runs in parallel and they both attempt to log in with the same credentials, the older of the two sessions is logged out and tests begin to fail (as the browser is redirected to the "sign up" page). - Since the tests require an active KenPom premium account, the repository must be preconfigured with encrypted secrets for both the
USERNAME
andPASSWORD
EVs corresponding to that account. I have them configured in my fork but more than happy to set up the same for this base repo.
As an aside, it occurred to me while testing this that the library itself now requires at least Python 3.8 on account of its use of the most recent version of pandas
. If there's a need to support older versions we can definitely use this as a good starting point to identify issues in previous versions, but considering 3.8 was released 14-Oct 2019 I'm hoping most everyone has migrated to >= 3.8 by now.