Subito-it / SBTUITestTunnelHost

Add Mac host tunnel to your XCTests

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Execute errors on multiple commands in one string

mgrene opened this issue · comments

Hello!

I am trying to use the execute command to change the directory and run yarn for my program. When I tried to use two separate commands, the directory is reverted back to Desktop when the second command is executed, so I've written both commands in one line. I'm using the host.execute() to run cd ~/myfolder && yarn dev. However, I get the following error when I run my code:

ApplicationUITests-Runner[16052:2645083] Task <9C40B131-AB3C-4779-84CD-158E244C0A70>.<2> finished with error 
[-1001] Error Domain=NSURLErrorDomain Code=-1001 "The request timed out." UserInfo={_kCFStreamErrorCodeKey=-2102, 
NSUnderlyingError=0x600001877180 {Error Domain=kCFErrorDomainCFNetwork Code=-1001 "(null)" UserInfo=
{_kCFStreamErrorCodeKey=-2102, _kCFStreamErrorDomainKey=4}}, 
_NSURLErrorFailingURLSessionTaskErrorKey=LocalDataTask <9C40B131-AB3C-4779-84CD-158E244C0A70>.<2>, 
_NSURLErrorRelatedURLSessionTaskErrorKey=( "LocalDataTask <9C40B131-AB3C-4779-84CD-158E244C0A70>.<2>"), 
NSLocalizedDescription=The request timed out., NSErrorFailingURLStringKey=http://localhost:8667/exec, 
NSErrorFailingURLKey=http://localhost:8667/exec, _kCFStreamErrorDomainKey=4} 

Assertion failure in -[SBTUITunneledHost performAction:data:app:], SBTUITunneledHost.m:128

Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: '[SBTUITestTunnelHost] Failed to get 
http response for action exec'
  1. Is this a limitation on the execute command? If so, is there a known workaround?

  2. Is it possible to change the path that it points to without using cd or editing executablesBasePath?

Did you try cd ~/myfolder; yarn dev