question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Android] Detox can't seem to connect to the test apps!

See original GitHub issue

What happened?

I am having a problem running detox on android. The app builds successfully on my emulator but for some reason all the tests fail. Below is the error I receive:

HINT: 

   Have you forgotten to call 'device.launchApp()' in the beginning of your test?
   Refer to our troubleshooting guide, for full details: https://wix.github.io/Detox/docs/troubleshooting/running-tests#tests-execution-hangs

   ---
   The following package could not be delivered:

  {
     type: 'invoke',
     params: [Object],
     messageId: 30
   }

I did some searching through your GitHub issues and noticed this person encountered the same issue as me: https://github.com/wix/Detox/issues/3233

I went ahead and updated the DetoxTest.java file and retriggered the test and I still am unable to successfully run tests on android.

What was the expected behaviour?

Detox should run successfully on Android

Was it tested on latest Detox?

  • I have tested this issue on the latest Detox release and it still reproduces.

Did your test throw out a timeout?

Help us reproduce this issue!

No response

In what environment did this happen?

Detox version: 19.6.5 React Native version: 0.66.3 Node version: 14.17.3 Device model: Android version: android 11 Test-runner (select one): jest-circus / jest+jasmine / mocha / other

Detox logs

Detox logs
paste logs here!

Device logs

Device logs
paste logs here!

More data, please!

No response

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:7 (1 by maintainers)

github_iconTop GitHub Comments

8reactions
github-actions[bot]commented, May 9, 2022

We use the issue tracker exclusively for bug reports and feature requests. This issue appears to be a general usage or support question. Instead, please ask a question on Stack Overflow with the detox tag.

Feel free to post your Stack Overflow question here for more visibility! We’ll take a look at it.

Refer to this discussion for more information about our policy on issues.

0reactions
d4vidicommented, May 9, 2022

@mkurczewski this is why -

15:35:56.250 detox[70425] TRACE: [SPAWN_STDOUT, #8, cpid=70438] INSTRUMENTATION_RESULT: shortMsg=Process crashed.
INSTRUMENTATION_CODE: 0

Your app crashes immediately. You might to check the device (emulator) logs using adb logcat.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Detox can't seem to connect to the test app on android[fixed]
The test app might have crashed prematurely, or has had trouble setting up the connection. Refer to our troubleshooting guide, for full details: ......
Read more >
Detox react-native build success, "Detox can't seem to connect ...
Detox react-native build success, "Detox can't seem to connect to the test app(s)!" (iOS) - Stack Overflow. Stack Overflow for Teams – Start ......
Read more >
React Native development tools - Part 3: Testing tools - Pusher
This is the third in a three part tutorial series on React Native development tools. In this part, look at testing with Jest...
Read more >
React Native Android Detox Tests Not Working
The main problem I can see is that detox is having problems interacting with the bitrise emulator. First of all, the swipes do...
Read more >
React Native end-to-end testing with Detox - LogRocket Blog
Demo running end-to-end tests in React Native with Detox, an end-to-end framework for mobile apps developed by Wix.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found