New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Correct logic of Scenario.years_active() #281
Conversation
Codecov Report
@@ Coverage Diff @@
## master #281 +/- ##
=========================================
+ Coverage 78.19% 78.2% +0.01%
=========================================
Files 13 13
Lines 1142 1138 -4
=========================================
- Hits 893 890 -3
+ Misses 249 248 -1
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully tested.
Note that the CI checks passed for cca6a25, then failed for 0022513. This seems to be the same symptom as noted here on #276. |
66d5b4d brings in the fix for this issue from |
Closes #278.
Closes #279.
Scenario.years_active()
and.vintage_and_active_years()
are improved.test_years_active()
is rewritten to be more explicit.test_years_active()
was incorrect. In this PR, the period '2050' is removed from the expected return value. See the inline comments:message_ix/tests/test_core.py
Lines 222 to 228 in 3585ab3
I have followed our documentation, specifically here where it reads:
IMO this is more confusing than it needs to be, and we should rename 'year' to 'period' to disambiguate.
PR checklist: