Five of the best open source automation tools for Android and iOS testing

This article mainly introduces the five best open source automation tools for Android and iOS. Here is a collection of relevant information. I hope it can help friends who test software. Take a look if necessary.

Automated testing plays a very important role in product testing. There are many positive ways to achieve test automation, including minimizing test execution time; ensuring greater coverage in less time during the critical release phase; running reliably and reproducibly to ensure that during the product development phase No regression problems are introduced. Minimize the risk of human error and oversight during repetitive regression testing loops.

There are many tools available on the market, open source or paid. While both paid and open source tools have their pros and cons, the latter are widely used in the automation testing community. Choosing the right automation tool based on project needs can be tricky.

Here are the 5 best open source automation tools for iOS and Android.

1.Calabash (available for Android and iOS)

Calabash is an open source acceptance testing framework.

Supports Android and iOS automation. Calabash provides a separate library for Android and iOS automated testing. This is a cross-platform framework that supports Cucumber. Cucumber allows you to express the behavior of your app in natural English language and implement BDD (Behavior Driven Development).

Calabash provides a bridge that allows Cucumber tests to be run and validated against iOS and Android. Cucumber tests are written using a list of statements that form a number of test scenarios. All statements in Cucumber are defined using Ruby.

In Calabash, Cucumber statements can only be defined once, but can be reused in different scenarios in Cucumber scripts.

The actual tests are written in Gherkin, backed by Ruby code, and run in the context of the Cucumber framework.

advantage:

◆Large community support.

◆Simple, English-like test statement.

◆Supports all actions on the screen, such as sliding, zooming, rotating, tapping, etc.

◆Large and enthusiastic community.

◆Cross-platform development support (the same code works in both Android and iOS devices).

shortcoming:

◆After the test step fails, all subsequent steps will be skipped. This can result in more serious product issues being missed.

◆Take time to test because it always installs the app by default first. However, this setting can be overridden by configuring a hook in the code.

◆Calabash framework needs to be installed in the ipa file of ios.

◆We must have iOS app code.

◆Except Ruby, it is not friendly to other languages.

2.Appium (Android and iOS)

Appium is an open source automated testing framework produced by Sauce Labs for native, hybrid and mobile web apps. The Appium library functions within the framework call the Appium server, which runs in the background while operating the connected device. It uses JSONWireProtocol internally to interact with iOS and Android apps using Selenium's WebDriver.

Unlike Calabash, which only supports Ruby development, when using Appium within the framework, you can choose from Java, Python, and Ruby, as well as all other languages ​​supported by Selenium WebDriver.

Appium server is hosted on Node server. You can start the Appium server by triggering a set of Node commands. Using the Appium Standalone Application as the server (downloaded from the Appium website), the Inspector tool provides the ability to find/identify/operate on all locators of the app.

advantage:

◆Support multiple languages.

◆No access to source code required.

◆Cross-platform script development.

◆Large community support.

◆Supports script recording on Mac.

◆Extract the identifier using the Inspector tool of the Appium Server application.

◆Built-in support for Selendroid through Appium Server's desktop application.

◆It also uses frameworks provided by vendors: UIAutomation for iOS, UIAutomator and Selendroid for Android 4.2+ and 2.3+ respectively.

◆Support physical devices and emulators.

◆Supports native, hybrid and mobile web automation applications.

shortcoming:

◆The release of Appium Server desktop applications is often unstable.

◆Script recording does not apply to Application Server for desktop applications on Windows OS.

3.Robotium(Android)

Robotium is an open source testing framework for developing functional, system, and acceptance testing scenarios. It is very similar to Selenium, except Robotium is only available for Android. It is registered under the Apache License 2.0.

It is widely popular in the automation testing community because of its simplicity and ability to create powerful and reliable automation scenarios.

It uses runtime binding to GUI components. It installs a suite of test cases as an application on an Android device or emulator and provides a real environment for executing tests.

advantage:

◆Easy to write test scripts in the shortest time.

◆Pre-installed automation apps are possible.

◆Automatically follow the current activity.

◆Because the runtime is bound to GUI components, its test execution is faster and more powerful than Appium.

◆You can work without accessing the code or knowing the app implementation.

◆Supports Activities, Dialogs, Toasts, Menus, Context Menus and other Android SDK controls.

shortcoming:

◆Cannot handle flash and web components.

◆Support Java development.

◆It will become very slow on old devices.

◆Since iOS devices are not supported, when the automated test covers both android and iOS, the test will be interrupted.

◆There is no built-in recording and playback function. Using the recording function requires paid tools such as TestDroid and Robotium Recorder.

4.Frank(iOS)

Frank is an automation framework for iOS apps that allows you to write test scenarios with structured English sentences using Cucumber.

Frank requires that testing be compiled inside the application, which means changes to the source code are mandatory. This is a tool that uses Cucumber and JSON to combine commands that are sent to a server running inside a local application and utilizes UISpec to run the commands.

advantage:

◆Test scenarios are written in understandable English sentences with the help of Cucumber.

◆Symbiote - includes real-time inspection tools.

◆It is also valid if the team has experience with web selenium and cucumber automation frameworks.

◆Active community support.

◆Continuously expanding library.

shortcoming:

◆Limited support for gestures.

◆It is a bit difficult to run tests on the device.

◆Modifying the configuration file needs to be run on the actual device.

◆The recording function is not available.

5.UIAutomator(Android)

UIAutomator is a testing framework provided by Google that provides advanced UI testing of native Android apps and games. This is a Java library that contains an API for creating functional UI tests, as well as an execution engine to run the tests. This library comes with Android SDK. There are many tutorials for beginners to get started. The advantage is that it gives JUnit test case privileges when running in a different process. While this is nice and simpler for native automation apps, it has very limited or almost no support for web automation views. It only supports devices using API level 16 and above, but this is not a big factor because most apps now support API level 19 and above.

advantage:

◆Easy to follow tutorial.

◆The library is supported and maintained by the Google community.

◆Third-party payment integrates cloud computing-based test management.

shortcoming:

◆Only supports android 4.1 and above.

◆Script recording is not supported.

◆The focus of support is Java.

◆You cannot get current activity or instrumentation.

◆ Currently web view is not supported, so it is a hybrid app.

◆The library supports using Java, so if someone wants to mix with cucumber using Ruby, it will be difficult. However, Java has its own BDD framework, although it is not used much in practice.

The above is the collection of information on Android and IOS automated testing. I will continue to add relevant information in the future. Thank you everyone for your support!

Finally, I would like to thank everyone who reads my article carefully. Reciprocity is always necessary. Although it is not a very valuable thing, if you can use it, you can take it directly:

Insert image description here

This information should be the most comprehensive and complete preparation warehouse for [software testing] friends. This warehouse has also accompanied tens of thousands of test engineers through the most difficult journey. I hope it can also help you!   

Guess you like

Origin blog.csdn.net/YLF123456789000/article/details/132831935