Maestro UI test run after this error printing?

600 Views Asked by At

I am UI tesrting with maestro UI test automation tools for flutter app, but after running a test this error occurred:

i@is-MacBook-Pro samples % maestro test android-flow.yaml 
Exception in thread "main" java.lang.NoSuchMethodError: java.io.InputStream.readAllBytes()[B
    at maestro.cli.device.ios.Simctl.list(Simctl.kt:14)
    at maestro.cli.device.DeviceService.listIOSDevices(DeviceService.kt:164)
    at maestro.cli.device.DeviceService.listDevices(DeviceService.kt:124)
    at maestro.cli.device.DeviceService.listConnectedDevices(DeviceService.kt:114)
    at maestro.cli.device.PickDeviceInteractor.pickDeviceInternal(PickDeviceInteractor.kt:33)
    at maestro.cli.device.PickDeviceInteractor.pickDevice(PickDeviceInteractor.kt:14)
    at maestro.cli.util.MaestroFactory.createMaestro(MaestroFactory.kt:35)
    at maestro.cli.command.TestCommand.call(TestCommand.kt:63)
    at maestro.cli.command.TestCommand.call(TestCommand.kt:31)
    at picocli.CommandLine.executeUserObject(CommandLine.java:1933)
    at picocli.CommandLine.access$1200(CommandLine.java:145)
    at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2332)
    at picocli.CommandLine$RunLast.handle(CommandLine.java:2326)
    at picocli.CommandLine$RunLast.handle(CommandLine.java:2291)
    at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2159)
    at picocli.CommandLine.execute(CommandLine.java:2058)
    at maestro.cli.AppKt.main(App.kt:97)

i@is-MacBook-Pro samples % maestro test android-flow.yaml

1

There are 1 best solutions below

0
On BEST ANSWER

It seems to me that you currently have two JDK versions, for Maestro it works fine if you install JDK 11 and delete the other versions and then check