-
-
Notifications
You must be signed in to change notification settings - Fork 978
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
Implement WakeLock so that the system does not enter sleep #2670
base: master
Are you sure you want to change the base?
Conversation
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.
I appreciate all the tests! Do any other OSes besides Windows need this treatment?
e3eb631
to
242589b
Compare
242589b
to
d774258
Compare
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.
LGTM! I would like a second review before merging this new functionality, though. @adamsitnik or @AndreyAkinshin may have different opinions on what the default should be.
…hmarks are running
Co-authored-by: Tim Cassell <[email protected]>
d774258
to
75b75c9
Compare
Implement WakeLock so that the system does not enter sleep while benchmarks are running.
As a happy user of BDN, I was annoyed by the fact that long running benchmarks were not completed when I returned to my system. All because my system enters sleep, after not being touched for a while.
The test code needs to enumerate power requests. I decided not to pinvoke undocumented api as maintenance is difficult if it changes in future windows version. It gave me a chance to learn more about parsers in general 😂. Imo, maintaining the parser when
powercfg /requests
output would change is less difficult.In case you prefer usage of Superpower library to parse, I'm willing to change that.
All test code is in integration tests, since
powercfg
needs elevation. I imagine developers dislike failing unit tests when they run those locally.