-
-
Notifications
You must be signed in to change notification settings - Fork 194
Description
Hello,
I'm automating a Flutter app using Appium FlutterDriver (Java). I'm able to scroll the main form and click on a dropdown, but I can't scroll inside the dropdown popup to select an option that’s not initially visible.
Problem:
Once the dropdown opens, it shows a scrollable list of options (e.g., "gst_rate_18"), but when I attempt to scroll using flutter:scrollUntilVisible, nothing happens or it fails silently.
Map<String, Object> scrollParams = new HashMap<>();
scrollParams.put("item", finder.byValueKey(targetKey)); // e.g., "gst_rate_18"
scrollParams.put("dxScroll", 0);
scrollParams.put("dyScroll", -25);
// Attempt to scroll within dropdown popup container
driver.executeScript("flutter:scrollUntilVisible", finder.byValueKey(containerKey), scrollParams);
I wait for the dropdown to appear, and I even retry locating the containerKey, which I assume is the dropdown list’s container.
Question:
How can I scroll inside a dropdown popup in Flutter to select an off-screen item (e.g., "gst_rate_18") using Appium Flutter Driver in Java?
Do Flutter dropdowns render with a widget that is not scrollable by default or not exposed to flutter:scrollUntilVisible?
Is there a recommended workaround or widget type I should target for such dropdowns?
Any help, sample code, or guidance is appreciated! Thanks in advance!