DonalEvans opened a new pull request, #7624: URL: https://github.com/apache/geode/pull/7624
ClearDuringNetSearchOplogRegressionTest uses an await statement to allow the timing of a region clear to be correct. An invocation of CacheObserver.afterSettingDiskRef() is used as the trigger for the await to pass and allow the clear to begin. The test was failing due to CacheObserver.afterSettingDiskRef() being invoked more than once in the await statement, but this method is expected to be invoked multiple times during the test, so occasionally the await would check and find 0 invocations,then check again and find 2 or more, causing the test to fail. Replacing the times(1) in the assertion with atLeast(1) allows the test to pass while preserving the intended behaviour of the await. Some incidental code clean-up was also done in the test to remove compiler warnings. Authored-by: Donal Evans <doev...@vmware.com> <!-- Thank you for submitting a contribution to Apache Geode. --> <!-- In order to streamline the review of the contribution we ask you to ensure the following steps have been taken: --> ### For all changes: - [x] Is there a JIRA ticket associated with this PR? Is it referenced in the commit message? - [x] Has your PR been rebased against the latest commit within the target branch (typically `develop`)? - [x] Is your initial contribution a single, squashed commit? - [x] Does `gradlew build` run cleanly? - [x] Have you written or updated unit tests to verify your changes? - [N/A] If adding new dependencies to the code, are these dependencies licensed in a way that is compatible for inclusion under [ASF 2.0](http://www.apache.org/legal/resolved.html#category-a)? <!-- Note: Please ensure that once the PR is submitted, check Concourse for build issues and submit an update to your PR as soon as possible. If you need help, please send an email to d...@geode.apache.org. --> -- 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: notifications-unsubscr...@geode.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org