In the testing world we always have lots of possibilities when making a test on an application or web page, but referring to the mobile testing we have 3 different tools.
- Real Devices
But what are these?
- Real Device: this is a device that you can actually touch (hardware), such as Apple, Samsung, Huawei, LG, and Sony products.
- Simulated Device: this a virtual device (Software) that allows you to reproduce a digital device of our real one; It imitates the behavior of inputs and outputs of information, therefore this software ‘creates’ the behavior of a real device.
- Emulated Device: this a virtual device that allows you to mimic the behaviors of a real device in a real environment, but in this case the software mirrors the results of the real one; so it helps you reproduce the behaviors of a hardware with very accurate results, just like if you were using a real device.
Some important differences between a simulated device and an emulated device:
|It tries to imitate real devices' behaviors.||Mirrors the behavior of real devices.|
|It’s more difficult to debug||Better for debugging|
|xCode uses simulators, extensions and mobile view (inspect mode)||Android Studio uses emulators.|
For example, you can use the mobile view when you press f12 on chrome, then you toggle the device toolbar and change from responsive to device design.
Some advantages and disadvantages of simulators/emulators vs real devices.
|Don’t have a cost. Easy access to the behaviors of tons of devices.||Expensive and tons of devices.|
|Don’t get broken (software).||They can be broken, after a while, you have to change them for the newest devices.|
|You can’t test them in real situations. (Gestures, illumination, etc.)||You get real outputs.|
|Software installed in your pc||If there are a lot of people testing at the same time, you are going to spend some time waiting until your teammate hands you over the device.|
|It’s not recommended to use them for performance testing.||Best results for performance testing.|
|You don’t need to wait for a build, you can always clone/pull the repository.||Test it in a real environments sacrificing time per build.|
|You can't improve interoperability Testing. (Test with external devices)||Recommended if your app requires interoperability testing.|
|They depend on your computer system.||Real/Original performance.|
|Better for debugging.||You must plug in your device.|
Using real devices gives us access to a lot of testing types, such as functional, performance, unity, interface, etc. Nevertheless, these devices are expensive, they depreciate over time and you will need various devices with different features such as screen sizes, hardware, and software.
While simulators and emulators give us a 24/7 workable time for testing (excluding some kind of testing), you can test your app in tons of virtual devices without spending a cent, even if those devices got deprecated.
As we already noticed, each device (simulator, emulator or real one) has different advantages than the other ones in specific aspects, therefore the best thing to do is to embrace them all and make our test cases using them when convenient. By using them balancedly we get better confiability tests, especially if you need to do regression testing, performance testing, interoperability testing, sanity testing or smoke testing.