Automatic testing method and device, electronic equipment and storage medium

Through automated testing methods, the upper-level testing software is used to capture and modify configuration parameters, and automatically trigger the underlying testing software to execute the test project, solving the problem of time-consuming manual writing of test project files in the existing technology, and improving the chip testing efficiency and automation level .

CN119149319AActive Publication Date: 2024-12-17HANGZHOU CHANGCHUAN TECH CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202411622276.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-14
Publication Date
2024-12-17
Estimated Expiration
2044-11-14

AI Technical Summary

Technical Problem

During the chip testing process, the existing technology requires users to manually write and maintain a large number of test engineering files, resulting in high human resources consumption and low testing efficiency, especially when mass chip testing.

Method used

Run the initial test project through the upper computer testing software, grab and modify the full configuration parameters as the target configuration parameters, and automatically trigger the underlying test software to execute the test project to be executed, realizing continuous and automatic execution of batch test projects, reducing the user's manual writing of the test project Document requirements.

Benefits of technology

It improves chip testing efficiency, reduces human resource consumption, realizes automatic execution of batch testing, and reduces storage resource usage.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119149319A_ABST
    Figure CN119149319A_ABST
Patent Text Reader

Abstract

The invention provides an automatic test method and device, electronic equipment and a storage medium, and the method comprises the steps: operating a project file of an initial test project through upper computer test software, and controlling bottom layer test software to carry out primary initial configuration on full-quantity configuration parameters of a to-be-tested chip in each test scene; in the operation process of the initial test project, the first data packet which is sent to the underlying test software by the upper computer test software and is used for indicating the underlying test software to perform parameter configuration can be captured, and subsequently, the first data packet can be directly utilized to perform parameter resetting based on the target configuration parameter corresponding to the test project to be executed; according to the method, the bottom layer test software is automatically triggered to execute the corresponding test project, continuous and automatic execution of batch test projects can be realized, a user does not need to manually write and operate a test project file corresponding to each test scene, and the chip test efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the fields of automation technology and chip testing technology, and in particular to an automated testing method, device, electronic device and storage medium. Background Art

[0002] In the process of chip testing using automatic test equipment (ATE), it is necessary to configure the corresponding test parameters for each test project in the host computer, such as configuring the input and output, voltage, current, upper and lower limits, binary values ​​(Binary, BIN value) of the tested chip pins.

[0003] Currently, all types of ATE provide host computer editing software. Users can use the host computer editing software to manually write test engineering files for various chips, various test scenarios, etc., and manually trigger the controls in the host computer editing software to control the execution of the test programs corresponding to each test engineering file, so that the underlying software and chip driver hardware can perform testing.

[0004] However, the testing process in the related art requires users to manually write complete test project files for each test project; when performing batch chip testing, a large number of test project files need to be manually written and maintained, which requires high human resources and has low testing efficiency. Summary of the invention

[0005] The embodiments of the present disclosure provide an automated testing method, device, electronic device, and storage medium, which can realize continuous and automatic execution of batch testing projects and improve chip testing efficiency.

[0006] One aspect of an embodiment of the present disclosure provides an automated testing method, including: Run the engineering file of the initial test project through the upper computer test software, and control the underlying test software to execute the initial test project, wherein the initial test project is used to initialize all configuration parameters of the chip under test in each test scenario; During the execution of the initial test project, capturing a first data packet sent by the upper computer test software to the underlying test software, wherein the first data packet includes the full configuration parameters; The first data packet is used to reset parameters, the full configuration parameters are modified to target configuration parameters corresponding to the test project to be executed, and the underlying test software is triggered to execute the test project to be executed.

[0007] Optionally, resetting parameters by using the first data packet, modifying the full configuration parameters to target configuration parameters corresponding to the test project to be executed, and triggering the underlying test software to execute the test project to be executed, includes: Receiving a parameter modification operation through a data packet modification tool, and modifying the full configuration parameters in the first data packet to the target configuration parameters based on the parameter type and parameter value of the target configuration parameters indicated by the parameter modification operation; sending the first data packet with the modified parameters to the underlying test software to trigger the underlying test software to execute the test project to be executed; or, Run the test script file, and based on the parameter type and parameter value of the target configuration parameters indicated by the test script file, modify the full configuration parameters in the first data packet to the target configuration parameters; send the first data packet with modified parameters to the underlying test software to trigger the underlying test software to execute the test project to be executed.

[0008] Optionally, sending the first data packet with modified parameters to the underlying test software includes: Capturing a second data packet sent by the bottom-level test software to the upper-computer test software, the second data packet including a response message, the response message being used to indicate that the test project is successfully executed or that an abnormality exists in the test process; In response to the response message indicating that the current test project to be executed is successfully executed, the first data packet corresponding to the next test project to be executed is sent to the underlying test software.

[0009] Optionally, after resetting parameters by using the first data packet, modifying the full configuration parameters to target configuration parameters corresponding to the test project to be executed, and triggering the underlying test software to execute the test project to be executed, the method includes: Parse the software log of the host computer test software, obtain the test result information corresponding to each test project to be executed from the software log, and generate a test report based on the test result information, wherein the test result information includes at least one of the test object, the target configuration parameters, the test result value and abnormal alarm information.

[0010] Optionally, resetting parameters by using the first data packet, modifying the full configuration parameters to target configuration parameters corresponding to the test project to be executed, and triggering the underlying test software to execute the test project to be executed, includes: Parse the interface call information in the first data packet to obtain the interface service called by the host computer test software during the execution of the initial test project and the configuration parameter type corresponding to each interface service, wherein the interface service is a service in the underlying test software for performing parameter configuration on the chip under test; Based on the configuration parameter type corresponding to each interface service, the target configuration parameter is transferred into the corresponding interface service and the interface service is re-called, triggering the underlying test software to execute the test project to be executed.

[0011] Optionally, after resetting parameters using the first data packet, modifying the full configuration parameters to target configuration parameters corresponding to the test project to be executed, and triggering the underlying test software to execute the test project to be executed, the method further includes: Listen to the response message body corresponding to the interface service, and obtain the response message generated by the interface service, wherein the response message is used to indicate that the test project is executed successfully or there is an abnormality in the test process; A test report is generated based on the response message.

[0012] Optionally, the host computer test software communicates with the bottom layer test software via a remote procedure call (RPC) framework, and the first data packet includes an RPC framework data packet; Capturing a first data packet sent by the upper computer test software to the underlying test software includes: The first data packet is obtained by capturing data packets on the port monitored by the RPC framework server in the preset network card.

[0013] Another aspect of the present disclosure provides an automated testing device, including: An initialization module is used to run the engineering file of the initial test project through the host computer test software, and control the underlying test software to execute the initial test project, wherein the initial test project is used to initialize the full configuration parameters of the chip under test in each test scenario; An acquisition module, used for capturing a first data packet sent by the upper computer test software to the lower-level test software during the execution of the initial test project, wherein the first data packet includes the full configuration parameters; The test module is used to use the first data packet to reset parameters, modify the full configuration parameters to target configuration parameters corresponding to the test project to be executed, and trigger the underlying test software to execute the test project to be executed.

[0014] Another aspect of the present disclosure provides an electronic device, including: Memory for storing computer programs; The processor is used to execute the computer program stored in the memory, and when the computer program is executed, the method described in the above aspects is implemented.

[0015] Another aspect of the embodiments of the present disclosure provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method described in the above aspects is implemented.

[0016] Another aspect of the embodiments of the present disclosure provides a computer program, including computer program instructions, which implement the methods described in the above aspects when executed by a processor.

[0017] Based on the embodiments of the present disclosure, the project file of the initial test project is run by the upper computer test software, and the underlying test software is controlled to first initialize the configuration of all configuration parameters of the chip to be tested in each test scenario. During the running of the initial test project, the first data packet sent by the upper computer test software to the underlying test software for instructing the underlying test software to configure the parameters can be captured. Subsequently, based on the target configuration parameters corresponding to the test project to be executed, the first data packet can be directly used to reset the parameters, and the underlying test software can be automatically triggered to execute the corresponding test project. The continuous and automatic execution of batch test projects can be realized without the need for users to manually write and run the test project files corresponding to each test scenario, thereby improving the chip testing efficiency.

[0018] The technical solution of the present disclosure is further described in detail below through the accompanying drawings and embodiments. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] The accompanying drawings, which constitute a part of the specification, illustrate embodiments of the present disclosure and, together with the description, serve to explain the principles of the present disclosure.

[0020] The present disclosure may be more clearly understood from the following detailed description with reference to the accompanying drawings, in which: Figure 1 A flowchart of an embodiment of the automated testing method disclosed herein; Figure 2 A flowchart of another embodiment of the automated testing method disclosed herein; Figure 3 A flowchart of another embodiment of the automated testing method disclosed herein; Figure 4 A schematic diagram of the structure of an embodiment of the automated testing device disclosed herein; Figure 5 It is a structural schematic diagram of another embodiment of the automatic testing device disclosed in the present invention; Figure 6 The figure is a schematic diagram of the structure of an application embodiment of the electronic device disclosed in the present invention. DETAILED DESCRIPTION

[0021] Various exemplary embodiments of the present disclosure will now be described in detail with reference to the accompanying drawings. It should be noted that the relative arrangement of components and steps, numerical expressions and numerical values ​​set forth in these embodiments do not limit the scope of the present disclosure unless otherwise specifically stated.

[0022] Those skilled in the art can understand that the terms "first" and "second" in the embodiments of the present disclosure are only used to distinguish different steps, devices or modules, etc., and neither represent any specific technical meaning nor indicate the necessary logical order between them.

[0023] It should also be understood that in the embodiments of the present disclosure, “plurality” may refer to two or more than two, and “at least one” may refer to one, two, or more than two.

[0024] It should also be understood that any component, data or structure mentioned in the embodiments of the present disclosure can generally be understood as one or more, unless explicitly limited or otherwise indicated in the context.

[0025] In addition, the term "and / or" in the present disclosure is only a description of the association relationship of associated objects, indicating that three relationships may exist. 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 the present disclosure generally indicates that the associated objects before and after are in an "or" relationship.

[0026] It should also be understood that the description of the various embodiments in the present disclosure focuses on the differences between the various embodiments, and the same or similar aspects thereof can be referenced to each other, and for the sake of brevity, they will not be described one by one.

[0027] At the same time, it should be understood that for the convenience of description, the sizes of the various parts shown in the drawings are not drawn according to the actual proportional relationship.

[0028] The following description of at least one exemplary embodiment is merely illustrative in nature and is in no way intended to limit the present disclosure, its application, or uses.

[0029] Technologies, methods, and equipment known to ordinary technicians in the relevant art may not be discussed in detail, but where appropriate, the technologies, methods, and equipment should be considered as part of the specification.

[0030] It should be noted that like reference numerals and letters refer to similar items in the following figures, and therefore, once an item is defined in one figure, it need not be further discussed in subsequent figures.

[0031] Figure 1The flowchart of the automated testing method provided by an exemplary embodiment of the present disclosure. The automated testing method of the embodiment of the present disclosure can be implemented by an electronic device running a host computer testing software and a bottom-level testing software. Figure 1 As shown, the method comprises the following steps: Step 101, running the project file of the initial test project through the upper computer test software, and controlling the bottom test software to execute the initial test project.

[0032] Among them, the initial test project is used to initialize the full configuration parameters of the chip under test in each test scenario. The full configuration parameters refer to all the parameters that need to be configured for various test scenarios of the chip under test. For example, the chip under test needs to be tested in two test scenarios. Scenario 1 requires the configuration of the pins (Pin), channels (Channel), power (Power), clock (Timing), mode (Pattern), and test cases (Test instance) of the chip under test. Scenario 2 requires the configuration of the pins (Pin), channels (Channel), power (Power), clock (Timing), mode (Pattern), and test cases (Test instance) of the chip under test. , Scenario 2 requires the configuration of the pins (Pin), channels (Channel), power (Power), pattern (Pattern), test instance, concurrent sequence (Concurrent Sequence), alternating current software requirement specification (Alternating Current Software Requirement Specification, AC SPEC), and direct current software requirement specification (Direct Current Software Requirement Specification, DC SPEC) of the chip under test. The full configuration parameters may include but are not limited to Pin, Channel, Power, Pattern, Timing, Pattern, Test instance, Concurrent Sequence, AC SPEC, and DC SPEC.

[0033] In one possible implementation, the host computer test software is responsible for receiving user operations (such as file editing operations, file running operations) and running project files through a graphical user interface (GUI). The host computer test software communicates with the underlying test software through a preset communication framework. In the process of running the project files, various instructions and data packets containing configuration parameters are sent to the underlying test software through the communication framework. The underlying test software is used to control the driver hardware to perform parameter configuration and chip testing on the chip to be tested based on the instructions and data packets sent by the host computer test software.

[0034] Step 102: during the execution of the initial test project, capture the first data packet sent by the upper computer test software to the lower computer test software.

[0035] The first data packet includes all configuration parameters configured for the above-mentioned initial test project.

[0036] In a possible implementation, while the host computer test software runs the engineering file of the initial test engineering, the first data packet sent by the host computer test software to the underlying test software can be captured from the network card. Indicatively, the first data packet can be captured using a packet capture tool such as TCPDump, wireshark, or Scapy.

[0037] Optionally, after capturing the first data packet, the first data packet may be stored in a memory or cache in a preset file format, such as a .pcap file or a .pcapng file. The first data packet records the parameter configuration request and corresponding parameter values ​​involved in the initial test project.

[0038] Step 103: Reset parameters using the first data packet, modify the full configuration parameters to target configuration parameters corresponding to the test project to be executed, and trigger the underlying test software to execute the test project to be executed.

[0039] In a possible implementation, the target configuration parameters corresponding to each test project to be executed can be obtained, and the parameters can be reset directly using the first data packet, and the underlying test software can be controlled to configure the parameters of the chip to be tested as the target configuration parameters and perform chip testing, so that the execution of the test project to be executed can be achieved without running the complete test project file corresponding to the test project to be executed. Optionally, the target configuration parameters can include some parameters in the full configuration parameters, or can include all parameters in the full configuration parameters.

[0040] Optionally, the values ​​of corresponding parameters in the first data packet can be modified based on the target configuration parameters and the modified first data packet can be resent to the underlying test software; alternatively, the interface of the underlying test software used for parameter configuration in the first data packet can be parsed, thereby directly calling the interface corresponding to the target configuration parameters to trigger the underlying test software to execute the test project to be executed.

[0041] Based on the embodiments of the present disclosure, the project file of the initial test project is run by the upper computer test software, and the underlying test software is controlled to first initialize the configuration of all configuration parameters of the chip to be tested in each test scenario. During the running of the initial test project, the first data packet sent by the upper computer test software to the underlying test software for instructing the underlying test software to configure the parameters can be captured. Subsequently, based on the target configuration parameters corresponding to the test project to be executed, the first data packet can be directly used to reset the parameters, and the underlying test software can be automatically triggered to execute the corresponding test project. The continuous and automatic execution of batch test projects can be realized without the need for users to manually write and run the test project files corresponding to each test scenario, thereby improving the chip testing efficiency.

[0042] In a possible implementation, the underlying test software may be triggered to execute the test project to be executed by modifying the value of the configuration parameter in the first data packet and resending the modified first data packet. Figure 2 A flowchart of an automated testing method provided by another exemplary embodiment of the present disclosure. The automated testing method of the embodiment of the present disclosure can be implemented by an electronic device running a host computer testing software and a bottom layer testing software. Figure 2 As shown, the method comprises the following steps: Step 201, running the project file of the initial test project through the upper computer test software, and controlling the bottom test software to execute the initial test project.

[0043] Step 202: during the execution of the initial test project, capture the first data packet sent by the upper computer test software to the lower computer test software.

[0044] The specific implementation of step 201 to step 202 can refer to the above-mentioned step 101 to step 102, and the embodiment of the present disclosure will not be repeated here.

[0045] Step 203: receive a parameter modification operation through a data packet modification tool, and based on the parameter type and parameter value of the target configuration parameters indicated by the parameter modification operation, modify all the configuration parameters in the first data packet to the target configuration parameters; or, run a test script file, and based on the parameter type and parameter value of the target configuration parameters indicated by the test script file, modify all the configuration parameters in the first data packet to the target configuration parameters.

[0046] In a possible implementation, the parameter modification operation can be received by a data packet modification tool, and based on the parameter modification operation, all configuration parameters in the first data packet are modified to target configuration parameters and saved as a new file. For example, the data packet modification tool can be a tool such as tcprewrite, editcap, or scapy.

[0047] Schematically, the test project to be executed needs to perform anomaly detection on the chip under test at different voltage values. The target configuration parameters include the target voltage value. The voltage value in the file 1.pcap corresponding to the first data packet can be modified to the target voltage value through the data packet modification tool. The remaining parameters can be deleted or remain unchanged or changed to the corresponding preset values ​​as required, and the modified file is saved as 2.pcap.

[0048] In another possible implementation, a pre-stored script file may be run, the script file including parameter types, parameter values, and data packet modification instructions of target configuration parameters corresponding to each test project to be executed. By running the script file, multiple test projects to be executed can be executed uninterruptedly and automatically. For example, a script file written by a user may be obtained through a code writing tool such as Python or shell.

[0049] Step 204: Send the first data packet with modified parameters to the underlying test software to trigger the underlying test software to execute the test project to be executed.

[0050] Optionally, a data packet sending tool may be used to resend the first data packet after the parameter modification to the underlying test software. For example, data packet sending tools such as tcpreplay and scapy may be used to perform data packet replay.

[0051] Step 205: Capture the second data packet sent by the bottom-layer test software to the upper-computer test software.

[0052] In one possible implementation, after the underlying test software executes the test project based on the first data packet sent by the upper computer test software, it will send a second data packet to the upper computer test software through the communication framework. The second data packet includes a response message, which is used to indicate that the test project was executed successfully or there was an abnormality in the test process.

[0053] Optionally, when there are multiple test projects to be executed, during the execution of each test project to be executed, a packet capture tool can be used to capture the second data packet sent by the underlying test software to the host test software, and based on the test status of the current test project to be executed, it can be determined whether to proceed to the next test project to be executed.

[0054] Step 206 , in response to the response message indicating that the current test project to be executed is executed successfully, sending a first data packet corresponding to the next test project to be executed to the underlying test software.

[0055] By parsing the response message in the second data packet, it can be determined whether the current test project to be executed is executed successfully. If the response message indicates that the current test project to be executed is executed successfully, the first data packet corresponding to the next test project to be executed is sent to the underlying test software to trigger the underlying test software to execute the next test project to be executed; if the response message indicates that there is an abnormality in the current test project to be executed, the first data packet can be stopped from being sent to the underlying test software and an alarm message can be generated, or an alarm message can be generated while sending the first data packet corresponding to the next test project to be executed to the underlying test software.

[0056] Based on the embodiments of the present disclosure, a data packet modification tool or a test script file is used to modify the full configuration parameters in the first data packet to the target configuration parameters, and the data packet is replayed to simulate the host computer test software sending the first data packet with modified parameters to the underlying test software, so as to trigger the underlying test software to execute the test project to be executed corresponding to the target configuration parameters. The user does not need to manually write a complete project file for each test project to be executed through the host computer test software, and the effect of automatic and uninterrupted chip parameter configuration and chip testing can be achieved, so that the user can get rid of the tedious operation of the host computer test software and can reduce the occupation of storage resources.

[0057] In one possible implementation, based on Figure 2 In the embodiment shown, after resetting parameters using the first data packet, modifying the full configuration parameters to target configuration parameters corresponding to the test project to be executed, and triggering the underlying test software to execute the test project to be executed, the method further includes the following steps: Parse the software log of the host computer test software, obtain the test result information corresponding to each test project to be executed from the software log, and generate a test report based on the test result information.

[0058] The test result information and the generated test report may include at least one of a test object, target configuration parameters, test result values, and abnormal alarm information. For example, the test object may include the model and identification of the chip to be tested, and the abnormal alarm information may include information such as the abnormal type and abnormal cause.

[0059] Optionally, the second data packet sent by the bottom-layer test software and the software log of the upper-computer test software may be analyzed to generate a test report.

[0060] In another possible implementation, the underlying test software may be triggered to execute the test project to be executed by directly calling the underlying test software interface. Figure 3 A flowchart of an automated testing method provided by another exemplary embodiment of the present disclosure. The automated testing method of the embodiment of the present disclosure can be implemented by an electronic device running a host computer testing software and a bottom layer testing software. Figure 3 As shown, the method comprises the following steps: Step 301, running the project file of the initial test project through the upper computer test software, and controlling the bottom test software to execute the initial test project.

[0061] Step 302: during the execution of the initial test project, capture the first data packet sent by the upper computer test software to the lower computer test software.

[0062] The specific implementation of step 301 to step 302 can refer to the above-mentioned step 101 to step 102, and the embodiment of the present disclosure will not be repeated here.

[0063] Step 303: parse the interface call information in the first data packet to obtain the interface services called by the host computer test software during the execution of the initial test project and the configuration parameter types corresponding to each interface service.

[0064] Among them, the interface service is a service used in the underlying test software to configure parameters of the chip under test.

[0065] Schematically, the host computer test software communicates with the underlying test software through a remote procedure call (RPC) framework, such as a gRPC framework. The framework uses Protocol Buffers as the interface definition language and data exchange format by default, and specifies the structure and interface service of the data by defining a .proto file. By parsing the interface call information in the first data packet, the interface service defined by the .proto file included therein is determined, that is, the interface service of the underlying test software called by the host computer test software is obtained, and the configuration parameter type corresponding to each interface service is determined. For example, the parameter corresponding to the interface service OpenProject called by the host computer test software is a.ctp, where ctp is the parameter type and a is the parameter value. If the subsequent test project to be executed needs to configure the parameter ctp, the interface service OpenProject can be called for configuration.

[0066] Step 304: based on the configuration parameter types corresponding to the various interface services, the target configuration parameters are transferred to the corresponding interface services and the interface services are re-invoked, triggering the underlying test software to execute the test project to be executed.

[0067] In one possible implementation, a compiler may be used in advance to compile the protocol file (e.g., .proto file) used to define the interface service in the communication framework into code corresponding to the target programming language, and obtain interface call codes corresponding to various interface services. For the test project to be executed, the configuration parameter type of its target configuration parameter is determined, and the interface call code of the interface service corresponding to the configuration parameter type is called to simulate the operation of the upper computer test software, thereby triggering the underlying test software to execute the test project to be executed.

[0068] For example, by parsing the first data packet, it is determined that the interface service OpenProject is called to configure parameter a.ctp. If the target configuration parameters in the next test project to be executed include b.ctp, the corresponding interface service can be called by running the interface call code corresponding to OpenProject and passing in the value b.

[0069] Step 305 , monitoring the response message body corresponding to the interface service, and obtaining the response message generated by the interface service. The response message is used to indicate that the test project is executed successfully or there is an exception in the test process.

[0070] In a possible implementation, the interface service corresponds to a response message body, and the interface service feeds back a response message, a response code, and other information through the corresponding response message body after the call is completed. The execution status of the test project to be executed can be determined through the response message body. For example, a response code of 0 indicates successful execution, and a response code of 1 indicates failed execution. The response message can contain specific result information such as the test result value or the exception type and exception cause.

[0071] Step 306: Generate a test report based on the response message.

[0072] Optionally, a test report may be generated based on the response message and a pre-stored test report template and sent to the host computer, thereby enabling the generation of a test report for the user to view even without the software log of the host computer test software.

[0073] Based on the embodiments of the present disclosure, by directly calling the underlying test software interface, the operation of the upper computer test software is simulated, and the underlying test software is triggered to execute the test project to be executed corresponding to the target configuration parameters. There is no need for the user to manually write a complete project file for each test project to be executed through the upper computer test software, and the effect of automatic and uninterrupted chip parameter configuration and chip testing can be achieved, so that the user can get rid of the tedious operation of the upper computer test software and can reduce the occupation of storage resources.

[0074] In a possible implementation, the upper computer test software communicates with the underlying test software via an RPC framework, the first data packet includes an RPC framework data packet, and the above step 102 may specifically include the following steps: The data packet is captured for the port monitored by the RPC framework server in the preset network card to obtain a first data packet.

[0075] Since multiple software are usually run in electronic devices, there are different types of data packets, so it is necessary to filter out the first data packet from various types of data packets based on data packet screening conditions. Optionally, the data packet screening conditions include a preset network card and a port monitored by the RPC framework server. That is, based on the network card and port corresponding to the communication framework of the upper computer test software and the underlying test software, data packets are captured to obtain the first data packet. Optionally, data packets are captured for the port monitored by the RPC framework server in the preset network card, and a second data packet can also be obtained.

[0076] Figure 4 The following is a block diagram of an automated testing device provided by an exemplary embodiment of the present disclosure. The device includes: Initialization module 401, used to run the engineering file of the initial test project through the host computer test software, and control the underlying test software to execute the initial test project, which is used to initialize the full configuration parameters of the chip under test in various test scenarios; The acquisition module 402 is used to capture the first data packet sent by the upper computer test software to the lower computer test software during the process of the initialization module 401 executing the initial test project, where the first data packet includes all configuration parameters; The testing module 403 is used to reset parameters using the first data packet obtained by the obtaining module 402, modify the full configuration parameters to target configuration parameters corresponding to the test project to be executed, and trigger the underlying testing software to execute the test project to be executed.

[0077] Optionally, in a possible implementation manner, the test module 403 may also be used to: Receiving a parameter modification operation through a data packet modification tool, and modifying all configuration parameters in the first data packet acquired by the acquisition module 402 to target configuration parameters based on the parameter type and parameter value of the target configuration parameter indicated by the parameter modification operation; sending the first data packet after the parameter modification to the underlying test software to trigger the underlying test software to execute the test project to be executed; or, Run the test script file, and based on the parameter type and parameter value of the target configuration parameters indicated by the test script file, modify the full configuration parameters in the first data packet acquired by the acquisition module 402 to the target configuration parameters; send the first data packet with modified parameters to the underlying test software to trigger the underlying test software to execute the test project to be executed.

[0078] Optionally, in a possible implementation manner, the test module 403 may also be used to: Capture a second data packet sent by the bottom-level test software to the upper-level test software, the second data packet including a response message, the response message being used to indicate that the test project is successfully executed or that an abnormality exists in the test process; In response to the response message indicating that the current test project to be executed is executed successfully, a first data packet corresponding to the next test project to be executed is sent to the underlying test software.

[0079] Optionally, in a possible implementation manner, as Figure 5 As shown, the device also includes: The first generation module 501 is used to parse the software log of the upper computer test software, obtain the test result information corresponding to each test project to be executed from the software log, and generate a test report based on the test result information, wherein the test result information includes at least one of the test object, target configuration parameters, test result value and abnormal alarm information.

[0080] Optionally, in a possible implementation manner, the test module 403 may also be used to: Parse the interface call information in the first data packet to obtain the interface service called by the host computer test software during the execution of the initial test project and the configuration parameter type corresponding to each interface service, wherein the interface service is a service used in the underlying test software to configure parameters of the chip under test; Based on the configuration parameter types corresponding to each interface service, the target configuration parameters are passed into the corresponding interface service and the interface service is called again, triggering the underlying test software to execute the test project to be executed.

[0081] Optionally, in a possible implementation manner, as Figure 5 As shown, the device also includes: The message acquisition module 502 is used to monitor the response message body corresponding to the interface service and obtain the response message generated by the interface service. The response message is used to indicate that the test project is executed successfully or there is an exception in the test process; The second generating module 503 is used to generate a test report based on the response message obtained by the message obtaining module.

[0082] Optionally, in a possible implementation manner, the upper computer test software communicates with the underlying test software via an RPC framework, and the first data packet includes an RPC framework data packet; The acquisition module 402 may also be used for: The data packet is captured for the port monitored by the RPC framework server in the preset network card to obtain a first data packet.

[0083] Each embodiment in this specification is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The parts of the same, similar or corresponding contents between the various embodiments can be referred to each other. Since the method, device, and equipment embodiments are basically corresponding, the relevant parts can be referred to the description of the corresponding parts. The methods, devices, and equipment of the embodiments of the present disclosure also correspond to each other in terms of specific implementation methods and beneficial technical effects. The relevant contents can be referred to each other and will not be repeated.

[0084] In addition, an embodiment of the present disclosure further provides an electronic device, including: Memory for storing computer programs; The processor is used to execute the computer program stored in the memory, and when the computer program is executed, the automated testing method described in any of the above embodiments of the present disclosure is implemented.

[0085] Figure 6 This is a schematic diagram of the structure of an application embodiment of the electronic device disclosed in the present invention. Figure 6 The electronic device according to the embodiment of the present disclosure is described. The electronic device may be any one or both of the first device and the second device, or a stand-alone device independent of them, and the stand-alone device may communicate with the first device and the second device to receive the collected input signals from them.

[0086] like Figure 6 As shown, the electronic device includes one or more processors and memory.

[0087] The processor may be a central processing unit (CPU) or other forms of processing units having data processing capabilities and / or instruction execution capabilities, and may control other components in the electronic device to perform desired functions.

[0088] The memory may include one or more computer program products, and the computer program product may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. The volatile memory may include, for example, a random access memory (RAM) and / or a cache memory (cache), etc. The non-volatile memory may include, for example, a read-only memory (ROM), a hard disk, a flash memory, etc. One or more computer program instructions may be stored on the computer-readable storage medium, and the processor may execute the program instructions to implement the automated testing method of each embodiment of the present disclosure described above and / or other desired functions.

[0089] In one example, the electronic device may further include: an input device and an output device, and these components are interconnected via a bus system and / or other forms of connection mechanisms (not shown).

[0090] In addition, the input device may also include, for example, a keyboard, a mouse, and the like.

[0091] The output device can output various information to the outside, including the determined distance information, direction information, etc. The output device can include, for example, a display, a speaker, a printer, a communication network and a remote output device connected thereto, and the like.

[0092] Of course, to simplify, Figure 6 Only some of the components related to the present disclosure in the electronic device are shown, and components such as a bus, an input / output interface, etc. are omitted. In addition, according to specific application situations, the electronic device may further include any other appropriate components.

[0093] In addition to the above-mentioned methods and devices, an embodiment of the present disclosure may also be a computer program product, which includes computer program instructions, which, when executed by a processor, enable the processor to execute the steps of the automated testing method according to various embodiments of the present disclosure described in the above part of this specification.

[0094] The computer program product may be written in any combination of one or more programming languages ​​to write program code for performing the operations of the disclosed embodiments, including object-oriented programming languages ​​such as Java, C++, etc., and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as a separate software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server.

[0095] In addition, an embodiment of the present disclosure may also be a computer-readable storage medium having computer program instructions stored thereon, which, when executed by a processor, enables the processor to execute the steps of the automated testing method according to various embodiments of the present disclosure described in the above part of this specification.

[0096] The computer readable storage medium can adopt any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium can include, for example, but is not limited to, a system, device or device of electricity, magnetism, light, electromagnetic, infrared, or semiconductor, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable 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.

[0097] A person of ordinary skill in the art can understand that all or part of the steps of implementing the above method embodiment can be completed by hardware related to program instructions, and the aforementioned program can be stored in a computer-readable storage medium. When the program is executed, it executes the steps of the above method embodiment; and the aforementioned storage medium includes: ROM, RAM, magnetic disk or optical disk, etc., various media that can store program codes.

[0098] The basic principles of the present disclosure are described above in conjunction with specific embodiments. However, it should be noted that the advantages, strengths, effects, etc. mentioned in the present disclosure are only examples and not limitations, and it cannot be considered that these advantages, strengths, effects, etc. are required by each embodiment of the present disclosure. In addition, the specific details disclosed above are only for the purpose of illustration and ease of understanding, and are not limitations. The above details do not limit the present disclosure to the necessity of adopting the above specific details to be implemented.

[0099] Each embodiment in this specification is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the embodiments can be referred to each other. For the system embodiment, since it basically corresponds to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

[0100] The block diagrams of the devices, apparatuses, equipment, and systems involved in this disclosure are only illustrative examples and are not intended to require or imply that they must be connected, arranged, and configured in the manner shown in the block diagrams. As will be appreciated by those skilled in the art, these devices, apparatuses, equipment, and systems can be connected, arranged, and configured in any manner. Words such as "including," "comprising," "having," and the like are open words, referring to "including but not limited to," and can be used interchangeably therewith. The words "or" and "and" used herein refer to the words "and / or," and can be used interchangeably therewith, unless the context clearly indicates otherwise. The word "such as" used herein refers to the phrase "such as but not limited to," and can be used interchangeably therewith.

[0101] The method and apparatus of the present disclosure may be implemented in many ways. For example, the method and apparatus of the present disclosure may be implemented by software, hardware, firmware, or any combination of software, hardware, and firmware. The above order of steps for the method is for illustration only, and the steps of the method of the present disclosure are not limited to the order specifically described above, unless otherwise specifically stated. In addition, in some embodiments, the present disclosure may also be implemented as a program recorded in a recording medium, which includes machine-readable instructions for implementing the method according to the present disclosure. Therefore, the present disclosure also covers a recording medium storing a program for executing the method according to the present disclosure.

[0102] It should also be noted that in the apparatus, device and method of the present disclosure, each component or each step can be decomposed and / or recombined. Such decomposition and / or recombination should be regarded as equivalent solutions of the present disclosure.

[0103] The above description of the disclosed aspects is provided to enable any person skilled in the art to make or use the present disclosure. Various modifications to these aspects will be readily apparent to those skilled in the art, and the general principles defined herein may be applied to other aspects without departing from the scope of the present disclosure. Therefore, the present disclosure is not intended to be limited to the aspects shown herein, but rather to the widest scope consistent with the principles and novel features disclosed herein.

[0104] The above description has been given for the purpose of illustration and description. In addition, this description is not intended to limit the embodiments of the present disclosure to the forms disclosed herein. Although multiple example aspects and embodiments have been discussed above, those skilled in the art will recognize certain variations, modifications, changes, additions and sub-combinations thereof.

Claims

1. An automated testing method, characterized in that: include: Run the engineering file of the initial test project through the upper computer test software, and control the underlying test software to execute the initial test project, wherein the initial test project is used to initialize all configuration parameters of the chip under test in each test scenario; During the execution of the initial test project, capturing a first data packet sent by the upper computer test software to the underlying test software, wherein the first data packet includes the full configuration parameters; The first data packet is used to reset parameters, the full configuration parameters are modified to target configuration parameters corresponding to the test project to be executed, and the underlying test software is triggered to execute the test project to be executed.

2. The method according to claim 1, characterized in that Resetting parameters by using the first data packet, modifying the full configuration parameters to target configuration parameters corresponding to the test project to be executed, and triggering the underlying test software to execute the test project to be executed, including: Receiving a parameter modification operation through a data packet modification tool, and modifying the full configuration parameters in the first data packet to the target configuration parameters based on the parameter type and parameter value of the target configuration parameters indicated by the parameter modification operation; sending the first data packet with the modified parameters to the underlying test software to trigger the underlying test software to execute the test project to be executed; or, Run the test script file, and based on the parameter type and parameter value of the target configuration parameters indicated by the test script file, modify the full configuration parameters in the first data packet to the target configuration parameters; send the first data packet with modified parameters to the underlying test software to trigger the underlying test software to execute the test project to be executed.

3. The method according to claim 2, characterized in that Sending the first data packet with modified parameters to the underlying test software includes: Capturing a second data packet sent by the bottom-level test software to the upper-computer test software, the second data packet including a response message, the response message being used to indicate that the test project is successfully executed or that an abnormality exists in the test process; In response to the response message indicating that the current test project to be executed is successfully executed, the first data packet corresponding to the next test project to be executed is sent to the underlying test software.

4. The method according to claim 2, characterized in that: After resetting parameters using the first data packet, modifying the full configuration parameters to target configuration parameters corresponding to the test project to be executed, and triggering the underlying test software to execute the test project to be executed, the method includes: Parse the software log of the host computer test software, obtain the test result information corresponding to each test project to be executed from the software log, and generate a test report based on the test result information, wherein the test result information includes at least one of the test object, the target configuration parameters, the test result value and abnormal alarm information.

5. The method according to claim 1, characterized in that Resetting parameters by using the first data packet, modifying the full configuration parameters to target configuration parameters corresponding to the test project to be executed, and triggering the underlying test software to execute the test project to be executed, including: Parse the interface call information in the first data packet to obtain the interface service called by the host computer test software during the execution of the initial test project and the configuration parameter type corresponding to each interface service, wherein the interface service is a service in the underlying test software for performing parameter configuration on the chip under test; Based on the configuration parameter type corresponding to each interface service, the target configuration parameter is transferred into the corresponding interface service and the interface service is re-called, triggering the underlying test software to execute the test project to be executed.

6. The method according to claim 5, characterized in that After resetting parameters using the first data packet, modifying the full configuration parameters to target configuration parameters corresponding to the test project to be executed, and triggering the underlying test software to execute the test project to be executed, the method further includes: Listen to the response message body corresponding to the interface service, and obtain the response message generated by the interface service, wherein the response message is used to indicate that the test project is executed successfully or there is an abnormality in the test process; A test report is generated based on the response message.

7. The method according to any one of claims 1 to 6, characterized in that: The host computer test software communicates with the bottom layer test software via a remote procedure call (RPC) framework, and the first data packet includes an RPC framework data packet; Capturing a first data packet sent by the upper computer test software to the underlying test software includes: The first data packet is obtained by capturing data packets on the port monitored by the RPC framework server in the preset network card.

8. An automated testing device, characterized in that: include: An initialization module is used to run the engineering file of the initial test project through the host computer test software, and control the underlying test software to execute the initial test project, wherein the initial test project is used to initialize the full configuration parameters of the chip under test in each test scenario; An acquisition module, used for capturing a first data packet sent by the upper computer test software to the lower-level test software during the execution of the initial test project, wherein the first data packet includes the full configuration parameters; The test module is used to use the first data packet to reset parameters, modify the full configuration parameters to target configuration parameters corresponding to the test project to be executed, and trigger the underlying test software to execute the test project to be executed.

9. An electronic device, characterized in that: include: Memory for storing computer programs; A processor is used to execute the computer program stored in the memory, and when the computer program is executed, the method described in 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 described in any one of claims 1 to 7 is implemented.

Citation Information

Patent Citations

  • Automatic test method and device

    CN111782556A

  • Chip batch test method and system

    CN112798942A

  • Automatic data comparison method and device, electronic equipment and storage medium

    CN114461717A

  • Software testing method and device, electronic equipment and storage medium

    CN115221029A

  • SoC automatic test system and test method based on test platform

    CN118569166A