@@ -44,7 +44,7 @@ public class ScreenshotState {
44
44
* screen area to be verified for similarity.
45
45
* This lambda method is NOT called upon class creation.
46
46
* One has to invoke {@link #remember()} method in order to call it.
47
- * <p>
47
+ *
48
48
* <p>Examples of provider function with Appium driver:
49
49
* <code>
50
50
* () -> {
@@ -152,8 +152,8 @@ private ScreenshotState checkState(Function<Double, Boolean> checkerFunc, long t
152
152
do {
153
153
final BufferedImage currentState = stateProvider .get ();
154
154
score = getOverlapScore (this .previousScreenshot
155
- .orElseThrow (() -> new ScreenshotComparisonError ("Initial screenshot state is not set. " +
156
- "Nothing to compare" )), currentState , resizeMode );
155
+ .orElseThrow (() -> new ScreenshotComparisonError ("Initial screenshot state is not set. "
156
+ + "Nothing to compare" )), currentState , resizeMode );
157
157
if (checkerFunc .apply (score )) {
158
158
return this ;
159
159
}
@@ -162,7 +162,8 @@ private ScreenshotState checkState(Function<Double, Boolean> checkerFunc, long t
162
162
} catch (InterruptedException e ) {
163
163
throw new ScreenshotComparisonError (e );
164
164
}
165
- } while (System .currentTimeMillis () - started <= timeoutMs );
165
+ }
166
+ while (System .currentTimeMillis () - started <= timeoutMs );
166
167
throw new ScreenshotComparisonTimeout (
167
168
String .format ("SScreenshot comparison timed out after %s ms. Actual similarity score: %.5f" ,
168
169
timeoutMs , score ), score );
@@ -264,7 +265,7 @@ private static Mat resizeFirstMatrixToSecondMatrixResolution(Mat first, Mat seco
264
265
265
266
/**
266
267
* A shortcut to {@link #getOverlapScore(BufferedImage, BufferedImage, ResizeMode)} method
267
- * for the case if both reference and template images are expected to have the same dimensions
268
+ * for the case if both reference and template images are expected to have the same dimensions.
268
269
*
269
270
* @param refImage reference image
270
271
* @param tplImage template
0 commit comments