on xenial help sign in
tst_WindowResizeArea: Use default values for mouseFlick speed and iterations (LP: #1651580)

Approved by: Daniel d'Andrada, Unity8 CI Bot

commit19b53d4e3d481a0d98f701fe685a8cc17e2e07f3 authorAlbert Astals Cid <albert.astals@canonical.com> dateTue 10 Jan 2017, 14:45 (10 years ago) parent3881c971d48854
1 file changed+7−9
tests/qmltests/Stage/tst_WindowResizeArea.qml+7−9
tests/qmltests/Stage/tst_WindowResizeArea.qml+7−9
@@ -264,7 +264,7 @@ Item {
264264
265265 var startDragX = initialWindowX + initialWindowWidth + 1
266266 var startDragY = initialWindowY + initialWindowHeight + 1
267− mouseFlick(root, startDragX, startDragY, startDragX + data.dx, startDragY + data.dy, true, true, units.gu(.5), 10);
267+ mouseFlick(root, startDragX, startDragY, startDragX + data.dx, startDragY + data.dy);
268268
269269 tryCompare(fakeWindow, "width", Math.max(initialWindowWidth + data.dx, fakeWindow.resizeAreaMinWidth));
270270 tryCompare(fakeWindow, "height", Math.max(initialWindowHeight + data.dy, fakeWindow.resizeAreaMinHeight));
@@ -290,7 +290,7 @@ Item {
290290
291291 var startDragX = initialWindowX - 1
292292 var startDragY = initialWindowY - 1
293− mouseFlick(root, startDragX, startDragY, startDragX + data.dx, startDragY + data.dy, true, true, units.gu(.5), 10);
293+ mouseFlick(root, startDragX, startDragY, startDragX + data.dx, startDragY + data.dy);
294294
295295 tryCompare(fakeWindow, "width", Math.max(initialWindowWidth - data.dx, fakeWindow.resizeAreaMinWidth));
296296 tryCompare(fakeWindow, "height", Math.max(initialWindowHeight - data.dy, fakeWindow.resizeAreaMinHeight));
@@ -318,10 +318,10 @@ Item {
318318
319319 var startDragX = initialWindowX + data.startX
320320 var startDragY = initialWindowY + data.startY
321− mouseFlick(root, startDragX, startDragY, startDragX + data.dx, startDragY + data.dy, true, false, units.gu(.05), 10);
321+ mouseFlick(root, startDragX, startDragY, startDragX + data.dx, startDragY + data.dy, true, false);
322322 tryCompare(fakeWindow, "width", Math.max(initialWindowWidth - Math.abs(data.dx), fakeWindow.resizeAreaMinWidth));
323323 tryCompare(fakeWindow, "height", Math.max(initialWindowHeight - Math.abs(data.dy), fakeWindow.resizeAreaMinHeight));
324− mouseFlick(root, startDragX + data.dx, startDragY + data.dy, startDragX, startDragY, false, true, units.gu(.05), 10);
324+ mouseFlick(root, startDragX + data.dx, startDragY + data.dy, startDragX, startDragY, false, true);
325325 tryCompare(fakeWindow, "width", initialWindowWidth);
326326 tryCompare(fakeWindow, "height", initialWindowHeight);
327327 }
@@ -385,7 +385,7 @@ Item {
385385 windowRequestedHeightSpy.clear();
386386 verify(windowRequestedHeightSpy.valid);
387387
388− mouseFlick(root, startDragX, startDragY, startDragX + deltaX, startDragY + deltaY, true, true, units.gu(.5), 10);
388+ mouseFlick(root, startDragX, startDragY, startDragX + deltaX, startDragY + deltaY);
389389
390390 compare(windowRequestedWidthSpy.count, 1);
391391 compare(fakeWindow.width, initialWindowWidth + fakeWindow.widthIncrement);
@@ -416,8 +416,7 @@ Item {
416416 var endDragX = (fakeWindow.maximumWidth * 2) + 1;
417417 var endDragY = (fakeWindow.maximumHeight * 2) + 1;
418418
419− mouseFlick(fakeWindow, startDragX, startDragY, endDragX, endDragY,
420− true/*pressMouse*/, true/*releaseMouse*/, units.gu(.5)/*speed*/, 20/*iterations*/);
419+ mouseFlick(fakeWindow, startDragX, startDragY, endDragX, endDragY);
421420
422421 compare(fakeWindow.requestedWidth, fakeWindow.maximumWidth);
423422 compare(fakeWindow.requestedHeight, fakeWindow.maximumHeight);
@@ -446,8 +445,7 @@ Item {
446445 var endDragX = (fakeWindow.minimumWidth * 0.5) + 1;
447446 var endDragY = (fakeWindow.minimumHeight * 0.5) + 1;
448447
449− mouseFlick(fakeWindow, startDragX, startDragY, endDragX, endDragY,
450− true/*pressMouse*/, true/*releaseMouse*/, units.gu(.5)/*speed*/, 20/*iterations*/);
448+ mouseFlick(fakeWindow, startDragX, startDragY, endDragX, endDragY);
451449
452450 compare(fakeWindow.requestedWidth, fakeWindow.minimumWidth);
453451 compare(fakeWindow.requestedHeight, fakeWindow.minimumHeight);