Automated testing methods, apparatus, devices, and storage media

By recording at edge test nodes and deploying test resources in a distributed manner, the problem of not being able to achieve real-time video streaming and large-scale applications in existing technologies is solved. This enables transparency and traceability in mobile phone testing, supports large-scale device management and scheduling, and improves the accuracy and efficiency of testing.

CN119292950BActive Publication Date: 2026-04-07ASPIRE TECH (SHENZHEN) LTD
View PDF 3 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-09
Publication Date
2026-04-07

AI Technical Summary

Technical Problem

Existing mobile testing methods cannot achieve real-time video streaming and are difficult to apply on a large scale, limiting the transparency and traceability of testing, especially in large-scale remote testing.

Method used

The test tasks of the target device are recorded by the edge test nodes to generate video streams. Through the distributed architecture design, the test resources are distributed and deployed on the edge test nodes to realize the real-time video live broadcast function and support large-scale automated testing.

Benefits of technology

It enables real-time video streaming during the testing process, improving the transparency and traceability of testing, supporting large-scale equipment management and scheduling, and enhancing the accuracy and reliability of test results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119292950B_ABST
    Figure CN119292950B_ABST
Patent Text Reader

Abstract

This application provides an automated testing method, apparatus, device, and storage medium. The method includes: receiving a test instruction; the test instruction characterizing testing of a target device; responding to the test instruction, invoking an edge test node to execute a corresponding test task on the target device; the edge test node includes multiple devices under test and a task corresponding to each device under test; and invoking the edge test node to record a video stream generated during the execution of the corresponding test task by the target device. In this embodiment, during the automated testing of the target device, the video stream generated during the execution of the corresponding test task by the target device is recorded, thereby realizing real-time video streaming during the testing process. Through a distributed architecture design, test resources are deployed in a distributed manner on edge test nodes, which can effectively manage and schedule a large number of devices under test, realizing the large-scale application of automated testing.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of testing technology, and in particular to an automated testing method, apparatus, device, and storage medium. Background Technology

[0002] In existing technical solutions, mobile phone testing is mainly divided into two types: laboratory testing and simulator-based testing. Laboratory testing relies on real mobile devices and can simulate real user environments; simulator-based testing can be quickly deployed on computers. However, in the above testing processes, users cannot view the screen and operation of the mobile device in real time, which limits the transparency and traceability of the test. Moreover, these tools are usually suitable for local or small-scale network environments and are difficult to scale up to large-scale remote testing.

[0003] Therefore, how to provide a mobile testing method that enables real-time video streaming and can be applied on a large scale is a technical problem that needs to be solved in this field. Summary of the Invention

[0004] The main objective of this application is to provide an automated testing method, apparatus, computer equipment, and storage medium, aiming to solve the technical problem of how to provide a mobile phone testing method that can realize real-time video live streaming and be applied on a large scale.

[0005] To achieve the above objectives, this application provides an automated testing method, which includes:

[0006] Receive test instructions; the test instructions are used to characterize testing of the target device;

[0007] In response to the test command, an edge test node is invoked to execute the corresponding test task on the target device; the edge test node includes multiple devices to be tested and a task corresponding to each device to be tested.

[0008] The edge test node is invoked to record the video stream generated when the target device performs the corresponding test task.

[0009] Optionally, the step of invoking the edge test node to perform the corresponding test task on the target device includes:

[0010] The edge test node invokes the test resources associated with the test task;

[0011] The test resources control the target device to execute the corresponding test script, generating test results and log files; the test script is determined based on the test task, and the log files include logs generated by the target device executing the corresponding test script.

[0012] Store the test results and log files.

[0013] Optionally, the step of calling the edge test node to record the video stream generated during the execution of the corresponding test task by the target device includes:

[0014] The edge test node is invoked to capture the video generated during the execution of the corresponding test task by the target device;

[0015] The video is compressed and encoded to obtain the video stream.

[0016] Optionally, after calling the edge test node to record the video stream generated during the execution of the corresponding test task by the target device, the method further includes:

[0017] Receive access requests sent by the test terminal;

[0018] In response to the access request, the video stream is sent to the test terminal.

[0019] Optionally, sending the video stream to the test terminal includes:

[0020] The edge test node is invoked to encrypt the video stream, resulting in an encrypted video stream;

[0021] The encrypted video stream is sent to the test terminal.

[0022] Optionally, the step of invoking the edge test node to perform the corresponding test task on the target device includes:

[0023] Receive adjustment instructions sent by the test terminal;

[0024] In response to the adjustment instruction, the test task is adjusted;

[0025] The edge test node is invoked to perform the adjusted test task on the target device.

[0026] Optionally, the method further includes:

[0027] If a fault is detected during the testing of the target device, the test resources are backed up and the test task is interrupted.

[0028] If the aforementioned fault condition does not exist, restart the test resources to control the target device to retry the test task.

[0029] Furthermore, to achieve the above objectives, this application also provides an automated testing apparatus, the automated testing apparatus comprising:

[0030] The test management platform is used to receive test instructions; the test instructions are used to characterize the testing of the target device.

[0031] In response to the test command, the edge test node is invoked;

[0032] The edge test node is used to execute corresponding test tasks on the target device; the edge test node includes multiple devices to be tested and a corresponding task for each device to be tested;

[0033] Record the video stream generated when the target device performs the corresponding test task.

[0034] To address the aforementioned technical problems, this application also provides a computer device that employs the following technical solution:

[0035] The computer device includes a memory and a processor. The memory stores a computer program, and when the processor executes the computer program, it implements the steps of the automated testing method proposed in any of the embodiments of this application.

[0036] To address the aforementioned technical problems, this application also provides a computer-readable storage medium, employing the technical solution described below:

[0037] The computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps of the automated testing method proposed in any of the embodiments of this application.

[0038] Compared with the prior art, the embodiments of this application have the following main advantages:

[0039] This application provides an automated testing method, apparatus, device, and storage medium. The method includes: receiving a test instruction; the test instruction characterizing testing of a target device; responding to the test instruction, invoking an edge test node to execute a corresponding test task on the target device; the edge test node includes multiple devices under test and a task corresponding to each device under test; and invoking the edge test node to record a video stream generated during the execution of the corresponding test task by the target device. In this embodiment, during the automated testing of the target device, the video stream generated during the execution of the corresponding test task by the target device is recorded, thereby realizing real-time video streaming during the testing process. Through a distributed architecture design, test resources are deployed in a distributed manner on edge test nodes, which can effectively manage and schedule a large number of devices under test, realizing the large-scale application of automated testing. Attached Figure Description

[0040] To more clearly illustrate the solutions in this application, the accompanying drawings used in the description of the embodiments of this application will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0041] Figure 1 This is an exemplary system architecture diagram to which this application can be applied;

[0042] Figure 2 This is a flowchart of the automated testing method provided in the embodiments of this application;

[0043] Figure 3 This is an application flowchart of test task scheduling provided in the embodiments of this application;

[0044] Figure 4 This is an application flowchart of live video streaming provided in the embodiments of this application;

[0045] Figure 5 This is an application flowchart of the automated testing method provided in the embodiments of this application;

[0046] Figure 6 This is a schematic diagram of the structure of one embodiment of the automated testing device provided in this application;

[0047] Figure 7 This is a basic structural block diagram of a computer device provided in the embodiments of this application. Detailed Implementation

[0048] The automated testing method provided in this application is applied to an automated testing device. Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains. The terminology used herein is for the purpose of describing specific embodiments only and is not intended to limit this application. The terms "comprising" and "having," and any variations thereof, in the description, claims, and accompanying drawings of this application are intended to cover non-exclusive inclusion. The terms "first," "second," etc., in the description, claims, or accompanying drawings of this application are used to distinguish different objects, not to describe a specific order.

[0049] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.

[0050] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings.

[0051] like Figure 1 As shown, system architecture 100 may include terminal devices 101, 102, and 103, a network 104, and a server 105. Network 104 serves as the medium for providing communication links between terminal devices 101, 102, and 103 and server 105. Network 104 may include various connection types, such as wired or wireless communication links, or fiber optic cables, etc.

[0052] Users can use terminal devices 101, 102, and 103 to interact with server 105 via network 104 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 101, 102, and 103, such as web browser applications, shopping applications, search applications, instant messaging tools, email clients, and social online platform software.

[0053] Terminal devices 101, 102, and 103 can be various electronic devices with displays and support web browsing, including but not limited to smartphones, tablets, e-book readers, MP3 players (Moving Picture Experts Group Audio Layer III), MP4 players (Moving Picture Experts Group Audio Layer IV), laptops, and desktop computers, etc.

[0054] Server 105 can be a server that provides various services, such as a backend server that supports the pages displayed on terminal devices 101, 102, and 103.

[0055] It should be noted that the automated testing method provided in this application embodiment is generally executed by a server / terminal device, and correspondingly, the automated testing device is generally set in the server / terminal device.

[0056] It should be understood that Figure 1 The number of terminal devices, networks, and servers shown is merely illustrative. Depending on implementation needs, any number of terminal devices, networks, and servers can be included.

[0057] Please refer to Figure 2The diagram illustrates a flowchart of an embodiment of the automated testing method proposed in this application. This embodiment can acquire and process relevant data based on artificial intelligence technology.

[0058] In an optional application scenario, the automated testing method provided in this application embodiment can be applied to an automated testing device, which includes a test management platform, edge test nodes, a test terminal, and a target device. The test management platform is communicatively connected to both the edge test nodes and the test terminal; the test terminal is communicatively connected to both the test management platform and the edge test nodes; and the edge test nodes are communicatively connected to both the test management platform, the test terminal, and the target device, which is also referred to as the device under test.

[0059] The automated testing method provided in this application includes the following steps:

[0060] S210, receive test commands.

[0061] In this step, test instructions are received.

[0062] In one alternative implementation, the user performs a corresponding operation on the test management platform to generate a test instruction, and the test management platform receives the test instruction.

[0063] Another alternative implementation is that the test management platform receives test instructions sent by the test terminal.

[0064] Among them, the test command is used to characterize the testing of the target device.

[0065] S220, in response to the test instruction, invoke the edge test node to execute the corresponding test task on the target device.

[0066] After receiving a test instruction, the test management platform responds by calling the edge test node.

[0067] Edge test nodes execute corresponding test tasks on the target device. Each edge test node includes multiple devices under test and a corresponding task for each device. For detailed implementation methods, please refer to subsequent embodiments.

[0068] S230, the edge test node is invoked to record the video stream generated when the target device performs the corresponding test task.

[0069] In this step, during the process of calling the edge test node to execute the corresponding test task on the target device, the video stream generated during the execution of the corresponding test task on the target device is recorded.

[0070] In this embodiment of the application, during the automated testing of the target device, the video stream generated by the target device in executing the corresponding test task is recorded, thereby realizing the real-time video live streaming function during the testing process; through the distributed architecture design, the test resources are distributed and deployed on edge test nodes, which can effectively manage and schedule a large number of devices to be tested, and realize the large-scale application of automated testing.

[0071] In addition, the test management platform supports a variety of devices and test scripts, and has high platform compatibility and flexibility.

[0072] Furthermore, this embodiment of the application executes test tasks through target devices deployed on edge test nodes, ensuring that the test environment is as close to a real-world scenario as possible. Simultaneously, it leverages the data analysis and optimization capabilities of the test management platform to improve the accuracy and reliability of the test results.

[0073] Optionally, the step of invoking the edge test node to perform the corresponding test task on the target device includes:

[0074] The edge test node invokes the test resources associated with the test task;

[0075] The test resources control the target device to execute the corresponding test script, generating test results and log files; the test script is determined based on the test task, and the log files include logs generated by the target device executing the corresponding test script.

[0076] Store the test results and log files.

[0077] In this embodiment, the edge test node calls the test resources associated with the test task, controls the target device to execute the corresponding test script through the test resources, generates test results and log files, and stores the test results and log files.

[0078] In one optional implementation, the test terminal sends a corresponding instruction to the test management platform to retrieve the test results and log files, and the test management platform then sends the test results and log files back to the test terminal.

[0079] It should be understood that test scripts can be obtained by parsing test tasks. The aforementioned log files include logs generated when the target device executes the corresponding test script.

[0080] In this embodiment, test resources are distributed across edge test nodes, enabling effective management and scheduling of the devices under test. This allows the system to handle larger-scale testing demands, improving its scalability and flexibility. Efficient resource scheduling and load balancing algorithms are introduced, dynamically allocating test resources based on the needs of the test tasks and the current resource status. This ensures that test tasks are evenly distributed across edge test nodes, optimizing resource utilization, reducing test waiting time, and improving test efficiency.

[0081] For a better understanding of the technical solutions provided in this embodiment, please refer to [link / reference]. Figure 3 , Figure 3 The application flow shown includes the following steps: task submission, task analysis, resource scheduling, task execution, result summarization, test report generation, and sending the test report to the user. Each step is explained below:

[0082] Task Submission: Users submit test tasks through the test management platform's user interface or the test terminal. Submitted information includes key details such as the test script, target phone model, test duration, and expected results. The platform receives and stores this information for further processing.

[0083] Task Analysis: The test management platform performs a detailed analysis of the submitted test tasks. This analysis includes, but is not limited to, the target device model of the test script, the resource requirements for the test duration, and estimated network bandwidth. Based on the analysis results, the platform determines the specific resources required to execute the test task, such as the specific device model, the required number of devices, and the estimated network bandwidth.

[0084] Resource Scheduling: The platform queries the status of currently available test resources, including the device model, quantity, current load, and network status of edge test nodes. Based on the task analysis results and the current resource status, the platform performs dynamic resource scheduling. The scheduling result allocates test tasks to the most suitable edge test nodes, ensuring that test tasks can be executed efficiently.

[0085] Task Execution: After receiving the assigned test task, the edge test node starts the test execution engine. Test scripts are installed and run on the device to simulate user operations or automate test processes. Simultaneously, screen video streams are captured using the phone's system-level screen recording function or third-party applications. The captured video streams are then encoded in real-time to reduce data transmission bandwidth requirements. The encoded video streams are then transmitted in real-time to the test management platform and authorized test terminal users via low-latency network transmission protocols (such as WebSocket, RTMP, and WebRTC).

[0086] Results Summary: After the test task is completed, the edge test nodes collect test results and log information. This information is then uploaded to the test management platform, where the platform summarizes and analyzes the received data.

[0087] Generate test reports: Based on the test results and log information, the platform generates detailed test reports, including test success rate, reasons for failure, performance indicators, etc.

[0088] Sending test reports to users: Finally, the platform sends the test report to the test terminal via email, SMS, or platform notification.

[0089] Optionally, the step of calling the edge test node to record the video stream generated during the execution of the corresponding test task by the target device includes:

[0090] The edge test node is invoked to capture the video generated during the execution of the corresponding test task by the target device;

[0091] The video is compressed and encoded to obtain the video stream.

[0092] In this embodiment, during the process of calling the edge test node to perform the corresponding test task on the target device, the video generated by the target device in performing the corresponding test task is captured, and the video is compressed and encoded to obtain a video stream.

[0093] In an optional implementation, the edge test node can also send the video stream to the test management platform and the test terminal. Users can then parse the video stream on the test terminal to obtain the video and watch it.

[0094] In this embodiment, by integrating real-time video streaming technology, the testing process is visualized in real time. Users can remotely watch the device testing process, improving the transparency and traceability of the test. This not only enhances the user experience but also enables timely detection and localization of test problems, improving testing efficiency and accuracy.

[0095] For a better understanding of the technical solutions provided in this embodiment, please refer to [link / reference]. Figure 4 , Figure 4 The application flow shown includes the steps of video capture, video encoding, video transmission, video distribution, video playback, and video viewing. Each step is explained below:

[0096] Video capture: While the edge test node controls the target device to execute the test script, it can choose to record the screen at the system level or capture it through a third-party application. System-level recording is generally more stable, but may require additional permissions; while application-level recording is more flexible.

[0097] Video Encoding: The captured raw video stream data is enormous, and direct transmission would consume a lot of bandwidth. Therefore, a high-efficiency video encoder is needed to compress the video stream. The captured video stream is compressed by a high-efficiency video encoder, reducing the data transmission bandwidth requirements. The encoder supports adaptive encoding algorithms, which can dynamically adjust encoding parameters (such as bitrate, resolution, frame rate, etc.) according to network conditions to ensure the smoothness and image quality of the video stream.

[0098] Video transmission: The encoded video stream is sent to the cloud test management platform via a low-latency network transmission protocol.

[0099] Video distribution: The platform distributes the video stream to all authorized test terminals. Only authorized test terminals can receive and play the video stream.

[0100] Video playback: The test terminal receives and plays video streams via a player. The player supports multiple video decoding formats.

[0101] Video viewing: The test terminal can watch videos through a player to view the test process in real time.

[0102] Optionally, after calling the edge test node to record the video stream generated during the execution of the corresponding test task by the target device, the method further includes:

[0103] Receive access requests sent by the test terminal;

[0104] In response to the access request, the video stream is sent to the test terminal.

[0105] Optionally, sending the video stream to the test terminal includes:

[0106] The edge test node is invoked to encrypt the video stream, resulting in an encrypted video stream;

[0107] The encrypted video stream is sent to the test terminal.

[0108] In this embodiment, the test terminal sends an access request to the test management platform, and after receiving the access request, the test management platform sends a video stream to the test terminal.

[0109] In this embodiment, after generating the video stream, the edge test node encrypts the video stream to obtain an encrypted video stream. In this way, the test management platform sends the encrypted video stream to the test terminal.

[0110] Optionally, after generating the video stream, the edge test node sends the video stream to the test management platform, which encrypts the video stream and sends the encrypted video stream to the test terminal.

[0111] In this embodiment, encrypted data transmission is used to ensure user privacy and data security, thereby improving the security and reliability of automated testing.

[0112] Furthermore, the test management platform can assign different permissions to different test terminals, ensuring that only authorized terminals can perform specific test tasks and access real-time video streams. Simultaneously, the system records all user operation logs and access records for auditing and traceability when necessary.

[0113] To ensure high availability and scalability of the system, multiple instances are deployed on the cloud test management platform and edge test nodes to provide backup and redundancy support. Meanwhile, a load balancer distributes requests across different instances to achieve load balancing and failover.

[0114] By implementing the above technical solutions, the automated testing method provided in this application embodiment can improve testing efficiency, reduce testing costs, and enhance the accuracy and reliability of test results.

[0115] Optionally, the step of invoking the edge test node to perform the corresponding test task on the target device includes:

[0116] Receive adjustment instructions sent by the test terminal;

[0117] In response to the adjustment instruction, the test task is adjusted;

[0118] The edge test node is invoked to perform the adjusted test task on the target device.

[0119] In this embodiment, the test terminal can also send adjustment instructions to the edge test nodes. The edge test nodes respond to the adjustment instructions, adjust the test tasks, and execute the adjusted test tasks on the target device.

[0120] In this embodiment, the test terminal performs remote control operations in the manner described above, such as interrupting the test or adjusting test parameters, thereby achieving remote control of automated testing.

[0121] For a better understanding of the technical solutions provided in this embodiment, please refer to [link / reference]. Figure 5 ,exist Figure 5 In the application scenarios shown, the automated testing method provided in this application embodiment can be applied to an automated testing device, which includes a cloud testing management platform, edge testing nodes, testing terminals, and mobile devices.

[0122] Cloud-based test management platform: Deployed in the cloud, it is responsible for test task management, resource scheduling, data analysis, and report generation. This platform possesses powerful data processing and analysis capabilities, dynamically allocating test resources according to testing needs and tracking test progress and results in real time. Users can access and operate the platform through test terminals.

[0123] Edge test nodes: Clusters of mobile devices deployed at the network edge. Each node contains multiple mobile devices and a corresponding test execution engine. The nodes are responsible for receiving test tasks from the cloud test management platform, executing test scripts locally, and simultaneously capturing and encoding / transmitting the screen video streams of the mobile devices in real time.

[0124] Test Terminal: Users can access the cloud test management platform through the test terminal to view the status of test tasks, live video feeds, and final test results. The test terminal also allows for remote control operations, such as interrupting tests and adjusting test parameters.

[0125] Mobile devices: Mobile devices are used to simulate real user environments for testing, provide a running environment for mobile applications, work with edge testing nodes to complete the application operations corresponding to the test scripts, and provide support for capabilities such as mobile screen recording and remote mobile control.

[0126] The cloud test management platform mentioned above is also called a test management platform, and the test management platform provided in this application embodiment can be deployed in the cloud; the mobile device mentioned above is also called a target device, and the automated test method provided in this application embodiment can test electronic devices including mobile phones, tablets and other electronic devices.

[0127] Optionally, the method further includes:

[0128] If a fault is detected during the testing of the target device, the test resources are backed up and the test task is interrupted.

[0129] If the aforementioned fault condition does not exist, restart the test resources to control the target device to retry the test task.

[0130] It should be understood that the above-mentioned fault conditions include, but are not limited to, network faults and equipment faults.

[0131] In this embodiment, when a network failure, device failure, or other abnormal situation is detected, a recovery process is triggered, which involves backing up test resources and interrupting the test task. Once the fault disappears, the test resources are restarted, and the target device is controlled to retry the test task. This approach ensures that automated testing can continue even when a fault occurs, while also protecting data security.

[0132] Please see Figure 6This application provides an automated testing device 600, which includes:

[0133] Test management platform 610 is used to receive test instructions; the test instructions are used to characterize the testing of the target device;

[0134] In response to the test command, edge test node 620 is invoked;

[0135] The edge test node 620 is used to execute corresponding test tasks on the target device 630; the edge test node includes multiple devices to be tested and a task corresponding to each device to be tested.

[0136] Record the video stream generated when the target device 630 performs the corresponding test task.

[0137] Optionally, the edge test node 620 is also used to invoke the test resources associated with the test task;

[0138] The test resources control the target device 630 to execute the corresponding test script, generating test results and log files; the test script is determined based on the test task, and the log files include logs generated by the target device executing the corresponding test script.

[0139] Store the test results and log files.

[0140] Optionally, the edge test node 620 is also used to capture the video generated when the target device performs the corresponding test task;

[0141] The video is compressed and encoded to obtain the video stream.

[0142] Optionally, the automated testing device 600 further includes a testing terminal;

[0143] The test terminal is used to send access requests;

[0144] The test management platform 610 is also used to receive access requests sent by the test terminal;

[0145] In response to the access request, the video stream is sent to the test terminal.

[0146] Optionally, the edge test node 620 is further configured to encrypt the video stream to obtain an encrypted video stream;

[0147] The test management platform 610 is also used to send the encrypted video stream to the test terminal.

[0148] Optionally, the test terminal is also used to send adjustment instructions;

[0149] The edge test node 620 is also used to receive adjustment instructions sent by the test terminal;

[0150] In response to the adjustment instruction, the test task is adjusted;

[0151] The edge test node is invoked to perform the adjusted test task on the target device 630.

[0152] Optionally, the test management platform 610 is also used to back up test resources and interrupt the test task if a fault is detected during the testing of the target device 630.

[0153] If the aforementioned fault condition does not exist, restart the test resource control to retry the test task on the target device 630.

[0154] To address the aforementioned technical problems, embodiments of this application also provide a computer device. Please refer to [link / reference needed]. Figure 7 , Figure 7 This is a basic structural block diagram of the computer device in this embodiment.

[0155] The computer device 7 includes a memory 71, a processor 72, and a network interface 73 that are interconnected via a system bus. It should be noted that only the computer device 7 with components 71-73 is shown in the figure; however, it should be understood that it is not required to implement all the shown components, and more or fewer components can be implemented alternatively. Those skilled in the art will understand that the computer device described here is a device capable of automatically performing numerical calculations and / or information processing according to pre-set or stored instructions, and its hardware includes, but is not limited to, microprocessors, application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), digital signal processors (DSPs), embedded devices, etc.

[0156] The computer device can be a desktop computer, laptop, handheld computer, or cloud server, etc. The computer device can interact with the user via a keyboard, mouse, remote control, touchpad, or voice control.

[0157] The memory 71 includes at least one type of readable storage medium, including flash memory, hard disk, multimedia card, card-type memory (e.g., SD or DX memory), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, magnetic disk, optical disk, etc. In some embodiments, the memory 71 may be an internal storage unit of the computer device 7, such as the hard disk or memory of the computer device 7. In other embodiments, the memory 71 may also be an external storage device of the computer device 7, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc., equipped on the computer device 7. Of course, the memory 71 may include both the internal storage unit and its external storage device of the computer device 7. In this embodiment, the memory 71 is typically used to store the operating system and various application software installed on the computer device 7, such as program code for automated testing methods. In addition, the memory 71 can also be used to temporarily store various types of data that have been output or will be output.

[0158] In some embodiments, the processor 72 may be a central processing unit (CPU), a controller, a microcontroller, a microprocessor, or other data processing chip. The processor 72 is typically used to control the overall operation of the computer device 7. In this embodiment, the processor 72 is used to run program code stored in the memory 71 or process data, for example, to run the program code of the automated testing method.

[0159] The network interface 73 may include a wireless network interface or a wired network interface, which is typically used to establish communication connections between the computer device 7 and other electronic devices.

[0160] This application also provides another embodiment, namely, providing a computer-readable storage medium storing the automated test program, which can be executed by at least one processor to cause the at least one processor to perform the steps of the automated test method as described above.

[0161] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware online platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in the various embodiments of this application.

[0162] This application can be used in a wide variety of general-purpose or special-purpose computer system environments or configurations. Examples include: personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputers, mainframe computers, and distributed computing environments including any of the above systems or devices. This application can be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform specific tasks or implement specific abstract data types. This application can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.

[0163] Obviously, the embodiments described above are only some embodiments of this application, not all embodiments. The accompanying drawings show preferred embodiments of this application, but do not limit the patent scope of this application. This application can be implemented in many different forms; rather, the purpose of providing these embodiments is to provide a more thorough and comprehensive understanding of the disclosure of this application. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing specific embodiments, or make equivalent substitutions for some of the technical features. Any equivalent structures made using the content of this application's specification and drawings, directly or indirectly applied to other related technical fields, are similarly within the scope of patent protection of this application.

Claims

1. An automated testing method, characterized in that, include: Receive test instructions; the test instructions are used to characterize the testing of the target device and include the model and system version information of the target device; In response to the test command, the edge test nodes are invoked to execute corresponding test tasks on the target device, including: invoking test resources associated with the test task through the edge test nodes; wherein, the test resources are distributed among the edge test nodes and are adapted one-to-one with the devices to be tested and the dedicated tasks within the nodes; the edge test nodes are mobile device clusters deployed at the network edge, each node containing multiple mobile devices and a corresponding test execution engine, and the test execution engine is pre-installed with an automated test framework adapted to each mobile device; The edge test node includes multiple devices to be tested and a corresponding task for each device to be tested; The process involves calling the edge test node to record video streams generated during the execution of corresponding test tasks by the target device or screen video streams captured by third-party applications using the mobile phone's system-level screen recording function. This includes: selecting either the mobile phone system-level screen recording or third-party application capture mode based on test scenario requirements; calling the edge test node to capture the video generated during the execution of corresponding test tasks by the target device; dynamically adjusting encoding parameters according to network bandwidth to compress and encode the video to obtain the video stream; and automatically switching to the third-party application capture mode to continue recording if an anomaly is detected during recording. The video stream is sent to the cloud test management platform via a low-latency network transmission protocol. If a network interruption occurs during transmission, the unsent video stream segments will be automatically resumed after the network is restored. The cloud test management platform distributes the video stream to all authorized test terminals based on dual verification of the test terminal's device identifier and account permissions. Only authorized test terminals can receive and play the video stream. The test terminal receives and plays video streams through a player, and watches the video through the player to achieve live video streaming, so as to watch the test process in real time. The test terminal sends adjustment instructions to the edge test node, and the edge test node dynamically adjusts the test task in response to the adjustment instructions. If a fault is detected during the test, the edge test node automatically backs up the test resources and interrupts the test task. After the fault is eliminated, the test resources are restarted to control the target device to retry the test task and resume the transmission of the unsent video stream segments.

2. The method according to claim 1, characterized in that, Also includes: The test resources are used to control the target device to execute the corresponding test script, and generate test results and log files. The test script is determined based on the test task, and the log file includes logs generated when the target device executes the corresponding test script. Store the test results and log files.

3. The method according to claim 1, characterized in that, After the method calls the edge test node to record the video stream generated during the execution of the corresponding test task by the target device, the method further includes: Receive access requests sent by the test terminal; In response to the access request, the video stream is sent to the test terminal.

4. The method according to claim 3, characterized in that, Sending the video stream to the test terminal includes: The edge test node is invoked to encrypt the video stream, resulting in an encrypted video stream; The encrypted video stream is sent to the test terminal.

5. An automated testing device, characterized in that, include: The test management platform is used to receive test instructions; The test command is used to characterize the testing of the target device; In response to the test command, the edge test node is invoked; The edge test node is used to execute corresponding test tasks on the target device. The edge test node is also used to call the test resources associated with the test task. The test resources are distributed among the edge test nodes and are adapted one by one with the device to be tested and the dedicated task within the node. The edge test node is a cluster of mobile devices deployed at the network edge. Each node contains multiple mobile devices and a corresponding test execution engine. The test execution engine is pre-installed with an automated test framework adapted to each mobile device. The edge test node includes multiple devices to be tested and a corresponding task for each device to be tested; The system utilizes the mobile phone's system-level screen recording function to record video streams generated during the execution of corresponding test tasks on the target device, or screen video streams captured by third-party applications. The edge test node is further configured to select either the mobile phone system-level screen recording or third-party application capture mode based on test scenario requirements, capturing the video generated during the execution of corresponding test tasks on the target device. Encoding parameters are dynamically adjusted according to network bandwidth to compress and encode the video, obtaining the video stream. If an anomaly is detected during recording, the system automatically switches to the third-party application capture mode to continue recording. The video stream is sent to the cloud test management platform via a low-latency network transmission protocol. If a network interruption occurs during transmission, the unsent video stream segments will be automatically resumed after the network is restored. The cloud test management platform distributes the video stream to all authorized test terminals based on dual verification of the test terminal's device identifier and account permissions. Only authorized test terminals can receive and play the video stream. The test terminal receives and plays video streams through a player, and watches the video through the player to achieve live video streaming, so as to watch the test process in real time. The test terminal also sends adjustment instructions to the edge test nodes, and the edge test nodes dynamically adjust the test tasks in response to the adjustment instructions. The edge test node is used to automatically back up test resources and interrupt the test task if a fault is detected during the test. After the fault is eliminated, the test resources are restarted to control the target device to retry the test task and resume the transmission of the unsent video stream segments.

6. A computer device, characterized in that, It includes a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of the automated testing method as described in any one of claims 1 to 4.

7. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the steps of the automated testing method as described in any one of claims 1 to 4.

Citation Information

Patent Citations

  • Edge computing test method and device, equipment and readable storage medium

    CN111506508A

  • Terminal testing method and device, computer storage medium and electronic equipment

    CN113220562A

  • Terminal application testing method and device, electronic equipment and storage medium

    CN117519524A