Cloud Computing Web applications: Analyzing translation Verification tests and selenium IDE features

Source: Internet
Author: User
Keywords Cloud computing Web applications Selenium translation validation testing

&http://www.aliyun.com/zixun/aggregation/37954.html ">nbsp; demonstrates how to quickly build a reusable base test script by introducing a layered testing framework and combining examples (test case) and to implement a 863.html "> Automated test process that can be reused," through the correlation of test scripts with the test suite. At the same time, some extended applications of Selenium IDE and analysis of its advantages and disadvantages are introduced. Finally, introduce a small tool implemented by the author to help resolve the problem that the Selenium IDE cannot run multiple test components at once.

Translation verification test means that after the product integrates the translation document, the professional translator examines whether the translation is accurate in the context of the product and whether it is convenient for the end user to understand and use. Taking into account the proficiency and cost of the translator's product operations, the product department usually provides a screenshot of the language to the translator for inspection. The test of Software Product translation verification is very important to improve the satisfaction of the language users and to bring the products to the international market better. However, for the following reasons, screenshots of the translation validation tests are often not easy to automate:

to release the product as soon as possible, the time interval between the translation of the product and the final release of the product is usually very short, which limits the time to prepare and execute the automated script for the translation verification test; The automated scripts for language products often rely on existing translations that may change in each version, Dramatically increases the volatility of automated script execution; Translation validation tests focus on new or changing features that are inherently unstable, and the ability to prepare automated scripts for them increases the cost of modification and maintenance, as well as translation validation tests that focus on new or changing features, Previously prepared automated scripts are not easily reused;

As we can see from the above introduction, it is not appropriate to prepare powerful automated tests for translation validation tests. However, translation testing needs to be repeated over multiple languages (usually at least 20 + languages), with the same steps and the need for automated methods to improve efficiency. Is there a lightweight automated approach that can be used to translate validation tests? For web-based applications, the answer is yes. The good test framework combines Selenium IDE scripts to easily achieve this goal.

Layered Testing Framework

Before introducing the layered test framework, we will first describe the relationship between the test suite and the test script in the Selenium IDE. The test script contains a variety of operational commands, as well as command-related target objects and parameters, which are the smallest unit of complete testing in the Selenium IDE. A test component is a collection of multiple test scripts that run a test component that can run multiple test scripts that it contains continuously. Figure 1 shows the diagram of the test components and test scripts in the Selenium IDE.

Figure 1. Selenium the relationship between test components and test scripts in the IDE

If you use a test script in the translation verification test to intercept multiple screenshots of the task, the screenshot speed can be improved, but because the test script is the Selenium IDE in the complete test of the smallest unit, a screenshot of the problem caused by a screen step will cause the execution of the entire script failed, This results in the subsequent screenshot steps being affected. In addition, because the translation verification test will intercept the validation specific software interface according to the change of the translation at various stages of the test, if multiple screenshots are performed in a test script, it will not be convenient to specify the scope of the screenshot and the execution of the extra steps will also affect the efficiency of the test. More importantly, if a test script is used to intercept more than one picture, there are many of the same steps in the process, and if a step needs to be modified it may need to be modified several times in multiple scripts, which can greatly increase the difficulty of modifying and maintaining the automation script.

To implement reusable automation scripts, we need to decompose the process of automating test screenshots: The smallest part is the most basic operation of the user (for example, clicking on the "Login" button), a complete reusable test process consisting of several basic operations as a test script (for example, user admin The process of logging into the main interface or intercepting a picture with a number 001, and finally using a test component to correlate multiple test scripts to form the complete process of intercepting a picture in a translation verification test. So each test script can be invoked by multiple test components, and only one test script needs to be modified to make the change reflected in all the test components that called the test script. Figure 2 shows a diagram of multiple test components calling the same test script.

Figure 2. Diagram of multiple test components calling the same test script

Through the above analysis, we form the test basic architecture as shown in the following figure.

The lowest Selenium IDE command statement, for example, opening a page (command "open"), typing characters (command "type"), and so on, are the basis for the proper completion of the test steps, and the previous layer is the basic operation of the test execution, such as entering a username and password, which must be done through the The Selenium IDE command statement completes; the previous layer is a test script that can be invoked by multiple test components, the smallest unit of a single test consisting of multiple basic operations; The last layer is the test component that can run multiple test scripts at a time. In the translation verification test we will use it as a unit to intercept a picture.

Figure 3. Test the bus diagram of the basic architecture

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.