diff --git a/src/main/java/io/github/ashwith/flutter/FlutterFinder.java b/src/main/java/io/github/ashwith/flutter/FlutterFinder.java index e3b66fa..5bf4d54 100644 --- a/src/main/java/io/github/ashwith/flutter/FlutterFinder.java +++ b/src/main/java/io/github/ashwith/flutter/FlutterFinder.java @@ -85,8 +85,8 @@ public FlutterElement byText(String input) { public FlutterElement byAncestor(FlutterElement of, FlutterElement matching, boolean matchRoot, boolean firstMatchOnly) { Map matchIdentifier = new HashMap<>(ImmutableMap.of( FINDER_TYPE, "Ancestor", - "matchRoot", matchRoot, - "firstMatchOnly", firstMatchOnly + "matchRoot", Boolean.toString(matchRoot), + "firstMatchOnly", Boolean.toString(firstMatchOnly) )); matchIdentifier.put("of", of.getRawMap()); matchIdentifier.put("matching", matching.getRawMap()); @@ -100,8 +100,8 @@ public FlutterElement byAncestor(FlutterElement of, FlutterElement matching, boo public FlutterElement byDescendant(FlutterElement of, FlutterElement matching, boolean matchRoot, boolean firstMatchOnly) { Map matchIdentifier = new HashMap<>(ImmutableMap.of( FINDER_TYPE, "Descendant", - "matchRoot", matchRoot, - "firstMatchOnly", firstMatchOnly + "matchRoot", Boolean.toString(matchRoot), + "firstMatchOnly", Boolean.toString(firstMatchOnly) )); matchIdentifier.put("of", of.getRawMap()); matchIdentifier.put("matching", matching.getRawMap()); @@ -139,4 +139,4 @@ public FlutterElement bySemanticsLabel(Pattern label) { public FlutterElement pageBack() { return new FlutterElement(ImmutableMap.of(FINDER_TYPE, "PageBack")); } -} \ No newline at end of file +}