XTS test method, apparatus and device, and computer readable storage medium

By analyzing and automatically retrying the test results of terminal equipment, the problems of test interruptions and manual intervention in the existing XTS test suite are solved, and automated testing is realized, improving testing efficiency and timeliness.

CN119292848APending Publication Date: 2025-01-10SHENZHEN SDMC TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411431531.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-14
Publication Date
2025-01-10

AI Technical Summary

Technical Problem

The existing XTS test suite is often interrupted due to factors such as the large number of test modules, large number of test cases, long test time, and unstable network environment. It requires human intervention and recovery, which extends the test time, and the tester cannot be timely. Understand the abnormalities in the equipment.

Method used

An XTS testing method and device is provided to achieve an automated testing process without intervention by obtaining the test results of the terminal device, analyzing and sending instructions to automatically retry the test until the test is completed. The specific steps include executing the l r command to obtain the test results, analyzing and sending the corresponding instructions to obtain the final test results, and completing the test through the run retry command.

Benefits of technology

It greatly improves testing efficiency, reduces manual intervention, promptly notify test abnormalities, shortens testing time, and realizes a more complete automatic testing function.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119292848A_ABST
    Figure CN119292848A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides an XTS test method and device, equipment and a computer readable storage medium. The method comprises the following steps: acquiring a first test result of executing an lr command after the terminal equipment performs an XTS test; analyzing the first test result, and if the first test result is not null, obtaining values of a first field and a second field in the first test result; if the value of the first field is not 0 and the value of the second field meets a preset requirement, sending a first instruction to the terminal device; receiving a second test result fed back by the terminal device in response to the first instruction; if the second test result is null, sending a second instruction to the terminal equipment; and receiving a final test result fed back by the terminal equipment in response to the second instruction and executing a run return-return id command, and completing the XTS test on the current terminal equipment. In this way, the test efficiency is greatly improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Embodiments of the present application relate to the field of data processing, and in particular, to an XTS test method, apparatus, device, and computer-readable storage medium. Background Art

[0002] Currently, the GMS (Google MobileService) test suite released by Google based on ATV (Android TV) and GTV (Google TV) includes six types: CTS, GSI, VTS, STS, TVTS, and GTS, referred to as the XTS test suite tool. Although this set of tools is used for automatic item testing, due to the large number of test modules, the large number of test cases, the long test time, the unstable network environment, the test cache and other factors, the test process is often interrupted and cannot pass the test in one go. As a result, when XTS performs automatic item testing, human intervention is often required, such as restoring factory settings, reconnecting to the network, etc., and because the test is usually conducted in the computer room, the test host is separated from the tester's work computer. When the device stops testing, the tester does not know the abnormal test situation and cannot immediately re-suspend it, which prolongs the test time.

[0003] In addition, although the test suite has a retry command that allows the test to continue based on the last result, the tester needs to manually execute the retry command to continue the test. When the test process is interrupted, the test cannot continue. Summary of the invention

[0004] According to an embodiment of the present application, an XTS testing solution is provided. After the tester suspends the device during XTS testing on the terminal server, even if the test is interrupted, the test can be automatically retried based on the result of the previous test report if the device is still connected until the test is completed, thereby greatly improving the test efficiency.

[0005] In a first aspect of the present application, an XTS testing method is provided. The method comprises:

[0006] Obtain the first test result of executing the lr command after the terminal device performs the XTS test;

[0007] Analyze the first test result, and if it is not null, obtain the values ​​of the first field and the second field in the first test result; if the value of the first field is not 0 and the value of the second field meets the preset requirements, send a first instruction to the terminal device;

[0008] receiving a second test result fed back by the terminal device in response to the first instruction; if the second test result is null, sending a second instruction to the terminal device;

[0009] The terminal device responds to the second instruction and executes the final test result fed back by the run retry--retry id command, thereby completing the XTS test on the current terminal device.

[0010] Further, the analyzing the first test result, if it is not null, obtaining the values ​​of the first field and the second field in the first test result includes:

[0011] Analyze the first test result, and if it is not null, obtain the session id;

[0012] According to the session id, values ​​of the first field and the second field in the first test result are obtained.

[0013] Furthermore, the first instruction includes a li command.

[0014] Furthermore, the first field includes a Fail field.

[0015] Furthermore, the second field includes a Modules Complete field.

[0016] Furthermore, it also includes:

[0017] The final test result is verified.

[0018] Further, the verifying the final test result includes:

[0019] After the receiving terminal device executes the run retry --retry id command, it executes the third test result fed back by the lr command again;

[0020] The final test result is verified according to the Fail field and the Modules Complete field in the third test result.

[0021] In a second aspect of the present application, an XTS testing device is provided. The device comprises:

[0022] An acquisition module, used to acquire a first test result of executing an lr command after the terminal device performs an XTS test;

[0023] a first determination module, configured to analyze the first test result, and if it is not null, obtain the values ​​of the first field and the second field in the first test result; and if the value of the first field is not 0 and the value of the second field meets the preset requirement, send a first instruction to the terminal device;

[0024] A second judgment module is used to receive a second test result fed back by the terminal device in response to the first instruction; if the second test result is null, send a second instruction to the terminal device;

[0025] The test module is used to receive the final test result fed back by the terminal device executing the run retry--retryid command in response to the second instruction, and complete the XTS test on the current terminal device.

[0026] In a third aspect of the present application, an electronic device is provided, which includes a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the program, the method described above is implemented.

[0027] In a fourth aspect of the present application, a computer-readable storage medium is provided, on which a computer program is stored, and when the program is executed by a processor, the method according to the first aspect of the present application is implemented.

[0028] The XTS test method provided in the embodiment of the present application obtains the first test result of the terminal device after the terminal device suspends the device by performing the XTS test and executing the lr command; analyzes the first test result, and if it is not null, obtains the values ​​of the first field and the second field in the first test result; if the value of the first field is not 0 and the value of the second field meets the preset requirements, sends a first instruction to the terminal device; receives the second test result fed back by the terminal device in response to the first instruction; if the second test result is null, sends a second instruction to the terminal device; receives the final test result fed back by the run retry--retry id command executed by the terminal device in response to the second instruction, completes the XTS test on the current terminal device, and greatly improves the test efficiency.

[0029] It should be understood that the contents described in the Summary of the Invention are not intended to limit the key or important features of the embodiments of the present application, nor are they intended to limit the scope of the present application. Other features of the present application will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0030] The above and other features, advantages and aspects of the embodiments of the present application will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. In the accompanying drawings, the same or similar reference numerals represent the same or similar elements, wherein:

[0031] Figure 1 is a flow chart of an XTS testing method according to an embodiment of the present application;

[0032] Figure 2is a judgment logic flow chart of the XTS test method according to an embodiment of the present application;

[0033] Figure 3 is a block diagram of an XTS test device according to an embodiment of the present application;

[0034] Figure 4 It is a schematic diagram of the structure of a terminal device or a server suitable for implementing the embodiments of the present application. DETAILED DESCRIPTION

[0035] In order to make the purpose, technical solution and advantages of the embodiments of the present disclosure clearer, the technical solution in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present disclosure.

[0036] In addition, the term "and / or" in this article is only a description of the association relationship between the associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.

[0037] Figure 1 A flow chart of an XTS testing method according to an embodiment of the present disclosure is shown. The method comprises:

[0038] S110, obtaining a first test result of executing the lr command after the terminal device performs an XTS test.

[0039] In some embodiments, a first test result fed back after the terminal device performs an XTS test and executes an lr command is obtained.

[0040] S120, analyzing the first test result, if it is not null, obtaining the values ​​of the first field and the second field in the first test result; if the value of the first field is not 0 and the value of the second field meets the preset requirements, sending a first instruction to the terminal device.

[0041] In some embodiments, the first test result is analyzed. If the result is null, it means that there is no test result and no retry is required. If the result is not null, the largest session id in the first test result is obtained, and the corresponding Fail field and Modules Complete field values ​​are obtained according to the session id. If Fail=0&&ModulesComplete=x of x (for example, 100of100, indicating that all 100 modules have been run; 90of100 means that only 90 modules out of 100 modules have been run), the test is completed and no retry is required. Otherwise, a first instruction is sent to the terminal device. The first instruction includes a li command.

[0042] S130, receiving a second test result fed back by the terminal device in response to the first instruction; if the second test result is null, sending a second instruction to the terminal device.

[0043] In some embodiments, after receiving the first instruction, the terminal device executes the li command and uploads the result after executing the li command, i.e., the second test result, to the server. The second test result is analyzed. If the result is null, it means that there is no test process at this time, and a retry operation can be performed. At this time, a second instruction is sent to the terminal device; the second instruction includes the run retry--retry id command; if the result is not null, it means that there is a test process at this time and the device is still being tested, then the li command can be executed by polling to check the test status until the result is null; for example, the li command is executed by polling every 10 minutes.

[0044] S140, receiving the final test result fed back by the terminal device executing the run retry --retry id command in response to the second instruction, and completing the XTS test on the current terminal device.

[0045] In some embodiments, after receiving the second instruction, the terminal device initializes id=maximum session id+1, executes the run retry--retry id command, and uploads the test result after executing the run retry--retry id command. That is, the terminal device (test device) can perform a retry test based on the last test result.

[0046] Furthermore, it also includes:

[0047] The final test result is verified.

[0048] Specifically, after the terminal device executes the run retry--retry id command, it executes the lr command again and uploads the result of executing the lr command to the server. The server determines whether the test is abnormal based on the uploaded result (retry result). If the Fail and Modules Complete fields of the maximum session id are equal to the Fail and ModulesComplete fields of the maximum session id-1, it means that the retry result is invalid and a test abnormality occurs. At this time, the terminal device can send a test abnormality notification to the tester's work host (server). If the retry result is valid, the li command can be executed in a polling manner to check the test status until the result is null, and the above steps are executed repeatedly until the test is completed.

[0049] According to the embodiments of the present disclosure, the following technical effects are achieved:

[0050] refer to Figure 2 , it can determine whether a retry operation is needed based on whether the current test situation is completed, and in the absence of abnormalities, it can determine whether a retry operation is needed based on the Fail and Modules Complete fields from the maximum session id, thereby executing the run retry--retry id command to implement an automatic retry solution.

[0051] When the retry test is abnormal, if the retry results are the same twice, it means that the retry is invalid, and a test abnormality notification is sent to the tester. It can achieve a more complete automatic testing function than the original XTS test suite, and achieve uninterrupted testing through automatic retry. By sending an abnormality notification, the tester can re-suspend the device in the first time, thereby shortening the test time and reducing manual intervention, greatly improving the test efficiency.

[0052] It should be noted that, for the aforementioned method embodiments, for the sake of simplicity, they are all expressed as a series of action combinations, but those skilled in the art should be aware that the present application is not limited by the described order of actions, because according to the present application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all optional embodiments, and the actions and modules involved are not necessarily required by the present application.

[0053] The above is an introduction to the method embodiment. The following is a further explanation of the scheme described in this application through an apparatus embodiment.

[0054] Figure 3 A block diagram 300 of an XTS test device according to an embodiment of the present application is shown. Figure 3 Shown include:

[0055] An acquisition module 310 is used to acquire a first test result of executing an lr command after the terminal device performs an XTS test;

[0056] A first determination module 320 is configured to analyze the first test result, and if it is not null, obtain the values ​​of the first field and the second field in the first test result; if the value of the first field is not 0 and the value of the second field meets the preset requirement, send a first instruction to the terminal device;

[0057] A second judgment module 330 is configured to receive a second test result fed back by the terminal device in response to the first instruction; if the second test result is null, send a second instruction to the terminal device;

[0058] The testing module 340 is used to receive the final test result fed back by the terminal device executing the run retry--retry id command in response to the second instruction, and complete the XTS test on the current terminal device.

[0059] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the described module can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.

[0060] Figure 4 A schematic diagram of the structure of a terminal device or server suitable for implementing an embodiment of the present application is shown.

[0061] like Figure 4 As shown, the terminal device or server includes a central processing unit (CPU) 401, which can perform various appropriate actions and processes according to the program stored in the read-only memory (ROM) 402 or the program loaded from the storage part 408 into the random access memory (RAM) 403. In the RAM 403, various programs and data required for the operation of the terminal device or server are also stored. The CPU 401, the ROM 402, and the RAM 403 are connected to each other via a bus 404. An input / output (I / O) interface 405 is also connected to the bus 404.

[0062] The following components are connected to the I / O interface 405: an input section 406 including a keyboard, a mouse, etc.; an output section 407 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 408 including a hard disk, etc.; and a communication section 409 including a network interface card such as a LAN card, a modem, etc. The communication section 409 performs communication processing via a network such as the Internet. A drive 410 is also connected to the I / O interface 405 as needed. A removable medium 411, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 410 as needed, so that a computer program read therefrom is installed into the storage section 408 as needed.

[0063] In particular, according to an embodiment of the present application, the above method flow steps can be implemented as a computer software program. For example, an embodiment of the present application includes a computer program product, which includes a computer program carried on a machine-readable medium, and the computer program includes a program code for executing the method shown in the flow chart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 409, and / or installed from the removable medium 411. When the computer program is executed by the central processing unit (CPU) 401, the above-mentioned functions defined in the system of the present application are executed.

[0064] It should be noted that the computer-readable medium shown in the present application may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present application, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present application, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.

[0065] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each box in the flow chart or block diagram can represent a module, a program segment or a part of the code, and the aforementioned module, program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flow chart, and the combination of the boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0066] The units or modules involved in the embodiments described in the present application may be implemented by software or hardware. The units or modules described may also be arranged in a processor. The names of these units or modules do not, in some cases, constitute limitations on the units or modules themselves.

[0067] As another aspect, the present application further provides a computer-readable storage medium, which may be included in the electronic device described in the above embodiment; or may exist independently without being assembled into the electronic device. The above computer-readable storage medium stores one or more programs, and when the above programs are used by one or more processors to execute the method described in the present application.

[0068] The above description is only a preferred embodiment of the present application and an explanation of the technical principles used. Those skilled in the art should understand that the scope of application involved in the present application is not limited to the technical solution formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the aforementioned application concept. For example, the above features are replaced with (but not limited to) technical features with similar functions applied in the present application.

Claims

1. An XTS testing method, characterized in that: include: Obtain the first test result of executing the lr command after the terminal device performs the XTS test; Analyze the first test result, and if it is not null, obtain the values ​​of the first field and the second field in the first test result; If the value of the first field is not 0 and the value of the second field meets the preset requirement, sending a first instruction to the terminal device; receiving a second test result fed back by the terminal device in response to the first instruction; If the second test result is null, sending a second instruction to the terminal device; The terminal device responds to the second instruction and executes the final test result fed back by the run retry--retry id command, thereby completing the XTS test on the current terminal device.

2. The method according to claim 1, characterized in that The analyzing the first test result, if it is not null, obtaining the values ​​of the first field and the second field in the first test result includes: Analyze the first test result, and if it is not null, obtain the sessionid; According to the sessionid, values ​​of the first field and the second field in the first test result are obtained.

3. The method according to claim 2, characterized in that The first instruction includes a li command.

4. The method according to claim 3, characterized in that The first field includes a Fail field.

5. The method according to claim 4, characterized in that The second field includes a Modules Complete field.

6. The method according to claim 5, characterized in that Also includes: The final test result is verified.

7. The method according to claim 6, characterized in that The verifying of the final test result comprises: After the receiving terminal device executes the run retry --retryid command, it executes the third test result fed back by the lr command again; The final test result is verified according to the Fail field and the Modules Complete field in the third test result.

8. An XTS testing device, characterized in that: include: An acquisition module, used for acquiring a first test result of executing an lr command after the terminal device performs an XTS test to suspend the device; A first determination module is used to analyze the first test result, and if it is not null, obtain the values ​​of the first field and the second field in the first test result; If the value of the first field is not 0 and the value of the second field meets the preset requirement, sending a first instruction to the terminal device; A second judgment module is used to receive a second test result fed back by the terminal device in response to the first instruction; If the second test result is null, sending a second instruction to the terminal device; The test module is used to receive the final test result fed back by the terminal device executing the run retry--retryid command in response to the second instruction, and complete the XTS test on the current terminal device.

9. An electronic device comprising a memory and a processor, wherein a computer program is stored in the memory, wherein: When the processor executes the computer program, the method according to any one of claims 1 to 7 is implemented.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.