-
Notifications
You must be signed in to change notification settings - Fork 396
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
HotFix 7723 unit test #7726
HotFix 7723 unit test #7726
Conversation
@@ -503,7 +512,6 @@ namespace HVACVariableRefrigerantFlow { | |||
Real64 HRInitialEIRFrac; // Fractional cooling degradation at the start of heat recovery from cooling mode | |||
Real64 HREIRTC; // Time constant used to recover from initial degradation in cooling heat recovery | |||
static Real64 CurrentEndTime; // end time of current time step | |||
static Real64 CurrentEndTimeLast; // end time of last time step |
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.
This static local was causing unit test issue when run sequentially using energyplus_tests. Moved to namespace so that clear_state can reset.
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.
Hmm, these static variables here in CalcVRFCondenser
and again in InitVRF
and CalcVRFCondenser_FluidTCtrl
are troublesome. They should either be part of the component structs or should be module level variables. It seems at first glance if there's more than one VRF condenser these variables will be wrong, because CurrentEndTimeLast
will get updated for the first component and then it will be wrong for the next component? And then some of these variables are beings stored in ...HRTimer
and ...HRTime
So, an alternative hotfix may be to undo this change (leave the main code as-is for now) and use a higher DayOfSimulation on each successive unit test that relies on these times (just two of them at the moment if I'm following correctly) which should trigger a reset. And then post a new issue to refactor this timer stuff without using any static variables.
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.
Sorry, I don't have time for this right now. Maybe in a few days or next week.
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.
And yes I agree with you.
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.
Can't this be merged to get the unit tests running and then rework this when I or others have time? I'm just in a serious time crunch now to get the VRF in airloop/OAsys finished.
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.
No, I'll change it shortly.
HVACVRFFixture units tests now pass as a whole. Merge when CI completes. |
I don't see the 7th CI results (Windows). Seems no need to wait but I will check again when I get home tonight and merge regardless. |
Windows CI still lagging. Unit test coverage on x86_64-Linux-Ubuntu-18.04-gcc-7.4-UnitTestsCoverage shows 1271 unit tests pass and unit testing on local Windows machine shows the same. Merging this in. |
New unit test for #7723 failed when ran locally and sequentially.
Pull request overview
NOTE: ENHANCEMENTS MUST FOLLOW A SUBMISSION PROCESS INCLUDING A FEATURE PROPOSAL AND DESIGN DOCUMENT PRIOR TO SUBMITTING CODE
Pull Request Author
Add to this list or remove from it as applicable. This is a simple templated set of guidelines.
Reviewer
This will not be exhaustively relevant to every PR.