-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[iOS] Tests stall in detox.init, error: [SRWebSocket sendString:error:]: unrecognized selector sent to instance #689
Comments
In your app, do you make use of SocketRocket? |
yeah, we use socket rocket |
Great, that explains your issue. I will look how to fix soon. |
Thanks @LeoNatan appreciate the help. Our dependency is
|
I added a fix. I have no way to test. Just know that 0.5.1 of Socket Rocket is very old and there is mode modern API. The people that manage it now seem to forgot to add some tags. Facebook is not strong on versioning 🙄 |
ah yeah, that makes sense. Maybe I'll try to compile it into our project how detox does it. Either way, knowing this, I'm sure I can find a work around until the next version of detox is released. Thanks! |
In case anyone else has this issue, for now I have added the following to my Podfile for getting tests running:
this commit is the same one that Detox points to. This fixes the |
verified fixed in 7.3.4 |
In either case, stick with the newer SocketRocket. |
I am not able to update my detox using command npm update detox can anyone help me ? |
@yogeshthanvi - did you try changing your project
And then run
|
@yogeshthanvi Please don't hijack issues for your problems. Also, GitHub issues is not the place for general usage questions. Please use Stack Overflow. This is the second time you do this in a very short time. Please abide by our community rules. |
Description
I set up detox using the recommended instructions. My project builds, and but running
detox test
fails with the information below. My app is a hybrid app, but the very first screen presented in the app is a view controller with a react native view. I'm not doing anything fancy with the React Native bridge, everything is mostly using React Native defaults, but I have built in custom nativeRCT_EXPORT_MODULE
plugins.I ran with the debugging tools, and when I do that, everything works (sigh).
Looking through the detox project issues, this resembles #155, and #615.
Detox output
Detox server output
detox.last_launch_app_log.err
When I run using detox 5.5.1, I get the exception below
Stack trace from
detox.last_launch_app_log.err
:2018-04-24 16:35:18.567 Debug[99937:1919393] ☣️ DETOX:: Detox Action Sent: login 2018-04-24 16:35:18.567 Debug[99937:1919393] -[SRWebSocket sendString:error:]: unrecognized selector sent to instance 0x7ff50d603ac0 2018-04-24 16:35:18.584 Debug[99937:1919393] Uncaught exception: -[SRWebSocket sendString:error:]: unrecognized selector sent to instance 0x7ff50d603ac0; Stack trace: 0 CoreFoundation 0x000000010f8201e6 __exceptionPreprocess + 294 1 libobjc.A.dylib 0x0000000114fea031 objc_exception_throw + 48 2 CoreFoundation 0x000000010f8a1784 -[NSObject(NSObject) doesNotRecognizeSelector:] + 132 3 CoreFoundation 0x000000010f7a2898 ___forwarding___ + 1432 4 CoreFoundation 0x000000010f7a2278 _CF_forwarding_prep_0 + 120 5 Detox 0x000000010e904d77 -[WebSocket sendAction:withParams:withMessageId:] + 357 6 Detox 0x000000010e905142 -[WebSocket webSocketDidOpen:] + 200 7 SocketRocket 0x000000011158a35e __36-[SRWebSocket _HTTPHeadersDidFinish]_block_invoke + 130 8 EarlGrey 0x0000000135aaa834 __60-[GREYDispatchQueueTracker grey_dispatchAsyncCallWithBlock:]_block_invoke + 36 9 libdispatch.dylib 0x000000011996673b _dispatch_call_block_and_release + 12
Steps to Reproduce
init.js
My test
Detox, Node, Device, Xcode and macOS Versions
Device and verbose Detox logs
My detox config:
The text was updated successfully, but these errors were encountered: