(
index: number,
label: string,
identifier: string,
origin: { x: number; y: number },
permission = false,
parentIndex = 0,
)
| 78 | } |
| 79 | |
| 80 | function button( |
| 81 | index: number, |
| 82 | label: string, |
| 83 | identifier: string, |
| 84 | origin: { x: number; y: number }, |
| 85 | permission = false, |
| 86 | parentIndex = 0, |
| 87 | ): RawSnapshotNode { |
| 88 | const packageName = permission ? 'com.google.android.permissioncontroller' : 'com.example.app'; |
| 89 | const id = permission ? `com.android.permissioncontroller:id/${identifier}` : identifier; |
| 90 | return node(index, 'android.widget.Button', { |
| 91 | label, |
| 92 | identifier: id, |
| 93 | bundleId: packageName, |
| 94 | parentIndex, |
| 95 | rect: { ...origin, width: 128, height: 52 }, |
| 96 | hittable: true, |
| 97 | }); |
| 98 | } |
no test coverage detected
searching dependent graphs…