File tree Expand file tree Collapse file tree 3 files changed +26
-2
lines changed Expand file tree Collapse file tree 3 files changed +26
-2
lines changed Original file line number Diff line number Diff line change @@ -51,7 +51,7 @@ Get the latest version from `https://pub.dev/packages/appium_flutter_server/inst
5151
5252 ``` yaml
5353 dev_dependencies :
54- appium_flutter_server : 0.0.27
54+ appium_flutter_server : 0.0.28
5555 ` ` `
5656
57572. Create a directory called ` integration_test` in the root of your Flutter project.
Original file line number Diff line number Diff line change 55 " appium" ,
66 " flutter"
77 ],
8- "version" : " 1.1.4 " ,
8+ "version" : " 1.1.5 " ,
99 "author" : " " ,
1010 "license" : " MIT License" ,
1111 "repository" : {
Original file line number Diff line number Diff line change @@ -137,6 +137,13 @@ export class AppiumFlutterDriver extends BaseDriver<FlutterDriverConstraints> {
137137 required : [ 'imageId' ] ,
138138 } ,
139139 } ,
140+ 'flutter: renderTree' : {
141+ command : 'renderTree' ,
142+ params : {
143+ required : [ ] ,
144+ optional : [ 'widgetType' , 'text' , 'key' ] ,
145+ } ,
146+ } ,
140147 } ;
141148
142149 async doubleClick ( origin : any , offset : any , locator : any ) {
@@ -430,4 +437,21 @@ export class AppiumFlutterDriver extends BaseDriver<FlutterDriverConstraints> {
430437 } ) ;
431438 return activateAppResponse ;
432439 }
440+
441+ async renderTree ( widgetType ?: string , text ?: string , key ?: string ) {
442+ const body : Record < string , string > = { } ;
443+
444+ if ( widgetType !== undefined ) {
445+ body [ 'widgetType' ] = widgetType ;
446+ }
447+ if ( text !== undefined ) {
448+ body [ 'text' ] = text ;
449+ }
450+ if ( key !== undefined ) {
451+ body [ 'key' ] = key ;
452+ }
453+
454+ const url = `/session/${ this . sessionId } /element/render_tree` ;
455+ return this . proxy ?. command ( url , 'POST' , body ) ;
456+ }
433457}
You can’t perform that action at this time.
0 commit comments