Skip to content

Conversation

@srishanbhattarai
Copy link
Owner

@srishanbhattarai srishanbhattarai commented Apr 6, 2022

Changes

  • Reject B.S. dates (via the Date() function) that would have normalized. (fixes Month max day not validated #79)
  • Add upper bound checks for date limits, don't know why this wasn't
    there already
  • Go' iota based enums are very loosely typed so a nepcal.Month value of
    64 was possible since they are just ints. Added a check for this.

Notes

There is more to #79 than may initially seem. (Read #81)

- Reject B.S. dates (via the Date() function) that would have normalized.
- Add upper bound checks for date limits, don't know why this wasn't
  there already
- Go' iota based enums are very loosely typed so a nepcal.Month value of
  64 was possible since they are just ints. Added a check for this.
@coveralls
Copy link

Pull Request Test Coverage Report for Build 304

  • 23 of 31 (74.19%) changed or added relevant lines in 3 files are covered.
  • 2 unchanged lines in 1 file lost coverage.
  • Overall coverage decreased (-0.7%) to 78.409%

Changes Missing Coverage Covered Lines Changed/Added Lines %
nepcal/util.go 12 14 85.71%
cmd/nepcal/cli.go 0 6 0.0%
Files with Coverage Reduction New Missed Lines %
nepcal/nepcal.go 2 75.27%
Totals Coverage Status
Change from base Build 302: -0.7%
Covered Lines: 345
Relevant Lines: 440

💛 - Coveralls

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Month max day not validated

3 participants