garydgregory commented on PR #1888: URL: https://github.com/apache/commons-lang/pull/1888#issuecomment-6991496907
@AmarGhugare The bug is real, and the two-line fix is correct. Before committing it, I wanted to complete the documentation and broaden the regression coverage. This is in commit 5551df00882bc5e6a70ccc730cc321e527529bf7. This PR leaves two gaps: - The getter Javadoc does not document the `null`/`0` results after starting a session, or explain how splitting, suspending, and resuming affect the recorded timestamp. It also incorrectly describes an `Instant` as being “in milliseconds.” - The tests cover restarting after stopping and after suspending then stopping, but omit resetting directly from suspension or after either `split()` overload. Commit 5551df00882bc5e6a70ccc730cc321e527529bf7 retains your implementation, corrects the Javadoc, and covers all five restart paths. The tests also verify that getters reject the reset-but-unstarted state, previous split state is cleared, and stopping the restarted watch records a timestamp consistent with `getStopTime()`. All five regression tests fail against the original implementation and pass with the fix. The full Maven build also passes, including tests, Javadoc, coverage, and static checks. These additions make the behavior clearer and better protected against regressions; they do not change the substance of your fix. Closing, you are credited in `changes.xml`. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
