seatgeek / businesstime

A simple python utility for calculating business time aware timedeltas between two datetimes
BSD 2-Clause "Simplified" License
85 stars 36 forks source link

Fix bug where sometimes holidays aren't detected #29

Closed agans closed 6 years ago

agans commented 6 years ago

If you check if a later date is a holiday first using the business time calendar, it will not detect holidays that happen earlier in the year. I've fixed that issue here and added some tests pertaining to it. For an example + some more discussion, see issue https://github.com/seatgeek/businesstime/issues/25

josegonzalez commented 6 years ago

@erwaller you're up for your yearly quota of PR reviews.

erwaller commented 6 years ago

Looks good to me! I combined the two holidays tests into something that was a bit more explicit about testing an later holiday before an earlier one.

josegonzalez commented 6 years ago

@agans I can make a release if this is ready for that.