I am new to running unit tests in Xcode (with XCText). I created an empty iOS application and just tried running the tests (which should fail by default). The iOS simulator starts and the toolbar console just shows "testing..." and it just hangs forever. I don't see any error in the console. If I try running the tests on a device (iPhone 5 in my case), the tests run just fine.
I am using Xcode 5.1.1 and simulator 7.1
Any idea on what could be causing this?
Related
I am mainly facing an issue with running detox tests on android real device. The main problem I face is that await device.launchApp() just doesn't launch the app. After adding some log traces I see that android instrumentation command is the one that is not actually starting the app. Detox internally calls the command /Users/<uname>/Library/Android/sdk/platform-tools/adb -s 39bc3158 shell am instrument -w -r -e detoxServer ws://localhost:51414 -e detoxSessionId 5c04ed58-aa77-64bb-aa2b-3a008f21ac2b -e debug false com.realapp.app.test/androidx.test.runner.AndroidJUnitRunner. This command hangs and Process Times out after sometime and doesn't launch the app.
If I create an instrumentation test from android studio also I am seeing the same issue and this problem only occurs on a real device and not on a simulator. Simulator works absolutely fine and the test cases run smooth.
I have looked into different issues, used 4.1.2 android studio, Invalidated cached and restarted upgraded to latest beta android studio and nothing seems to help.
Also the instrumentation tests run fine on the real device if i open the app manually after starting the tests. The tests are just not launching the app automatically.
I have a piece of software I wrote using xcode 5. Since I upgraded to xcode 6, the app looks strange when I run it on a physical device using the emulator. Not entirely sure what is going on or how I could fix it. It's not respecting the full size of the screen.
I am testing on an iPhone 5s (NOT simulator -- the app looks fine in the iPhone 5s simulator). I am connecting my phone to my comp and running it via xCode.
I am having the same issue with another project I built using xcode 5 and trying to run again in xcode 6...
thoughts anyone?!
Here is a screenshot of what is going on:
I am trying to run XCTest on iphone device but Xcode show be following message.
"Logic Testing on iOS devices is not supported. You can run logic tests on the Simulator."
Is there any way by which I can run the XCTest on device?
Thanks,
Dev
Ok. I found that using GHUnit we can run unit tests on iphone device. Internally it uses xctest. Here is how you setup GHUnit.
I was able to follow the instructions and setup unit tests using xcode 5.
i'm using instrument 4.1 and i'm able to run my script but i'm not able to run the same script in instruments 4.2 it is throwing an exception target appears to have died .
Using command line i'm able to load the app but the script is not running.
thanks
Script will run only if it has any device / simulator belonging to your upgraded simulator version. If you have upgraded your ios simualator version from 4.X to 5.X, then it will not support and device / simulator belonging to 4.X. Try connecting a device / simulator as per your latest ios simulator version and your script will execute successfully.
In Eclipse, I want to test some java microedition network code -- javax.microedition.io.HttpConnection -- to see if the network connection is successful and get some cookie values. But running this code using a JRE on my development machine doesn't execute the method, unless I launch and test using a simulator.
Can I run BlackBerry code using a desktop JRE or will I always have to test using a simulator?
I've never heard of a way of running BB code without running the simulator. You can set a program to automatically start the simulator and "click" some buttons so you can run tests automatically, but I don't think this is what you're looking for...