Reduce duplication of DTO code #288
Closed
bartekpacia
started this conversation in
Ideas
Replies: 1 comment
-
Done in #338! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
TL;DR Classes representing "commands", such as
TapCommand
,HandlePermissionCommand
, etc. are written 3 times: in Dart (not exactly, though), Kotlin, and Swift. We should fix that.Let's take a closer look at a very simple
grantPermissionWhenInUse
method. That's how it's implemented on the Dart side, inpatrol
:And in Kotlin:
And in Swift:
You can easily see how this can quickly become unmanageable when more
Command
s are added.I've seen that other new interesting mobile testing tools (Maestro by mobile.dev, convenient_test) use Protocol Buffers. I'm wondering if we could also use them to generate code in Dart, Swift, and Kotlin from protobuf.
cc @jakubfijalkowski
Beta Was this translation helpful? Give feedback.
All reactions