Test information generation method and related equipment

By using the target model to generate test data matching the element structure of the test script on a low-code platform, the time-consuming and labor-intensive problem of manually writing test scripts is solved, and efficient and reliable automated test script code generation is achieved, which improves testing efficiency and security.

CN119847932APending Publication Date: 2025-04-18LENOVO (BEIJING) LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411997089.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-31
Publication Date
2025-04-18

AI Technical Summary

Technical Problem

In the prior art, manual writing of test scripts and automated test script codes is time-consuming and labor-intensive, which can easily lead to reduced testing reliability and efficiency. When demand changes, you need to wait for the development of the test script to pass before writing new automated test script codes, affecting the progress of automated tests.

Method used

By obtaining the target requirements, inputting them into the target model, using the system configuration information of the low-code platform to generate test data, matching the test script element structure, and calling the application call interface of the low-code platform to generate automated test script code and test script.

Benefits of technology

It greatly reduces the workload and errors of manual scripting and test code, improves the reliability and accuracy of test data, allows for the immediate generation of test scripts and automated test script codes that meet target needs, improves testing efficiency and automated test progress, and eliminates the need to access test products, protects private data and improves security.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119847932A_ABST
    Figure CN119847932A_ABST
Patent Text Reader

Abstract

The invention discloses a test information generation method and related equipment, and relates to the technical field of software development, and the method comprises the steps: inputting an obtained target demand into a target model, and generating test data for the target demand according to system configuration information of a low-code platform; the test data is matched with an element structure required by the test script, the element structure represents elements forming the test script and an organization mode among the elements, then an application program calling interface of the low-code platform can be called, and the test data is utilized to realize the test of the low-code platform. And generating an automatic test script code and a test script which meet the target requirement.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of software development technology, and in particular to a test information generation method and related equipment. Background Art

[0002] In the software development process, testers usually write test scripts based on the requirements analysis results, that is, design the software testing process according to the requirements. After the test passes, the test developers write automated test script codes according to the required application scenarios to realize automated testing of the application scenario requirements.

[0003] However, this method of manually writing test scripts and automated test script codes is time-consuming and laborious, and it is also easy to reduce test reliability and efficiency due to manual writing errors. In addition, when software development requirements change, test developers often need to wait for the test script development and test to pass before they can write new automated test script codes, which affects the progress of automated testing. Summary of the invention

[0004] In view of the above problems, this application provides the following solutions:

[0005] A first aspect of the present application provides a test information generating method, the method comprising:

[0006] Obtain target requirements;

[0007] The target requirements are input into the target model, and test data for the target requirements is generated according to the system configuration information of the low-code platform; the test data matches the element structure required by the test script, and the element structure represents the elements constituting the test script and the organization between the elements;

[0008] Call the application calling interface of the low-code platform, and use the test data to generate automated test script code and test scripts that meet the target requirements.

[0009] In a possible implementation, inputting the target requirement into the target model and generating test data for the target requirement based on the system configuration information of the low-code platform includes:

[0010] Input the target requirement into the target model to obtain the test element of the target requirement;

[0011] Obtaining element configuration information of each of the test elements through the target model according to the system configuration information of the low-code platform;

[0012] According to the element structure required by the test script, the element configuration information is used to generate test data for the target requirement.

[0013] In a possible implementation, the method further includes:

[0014] Outputting the test data;

[0015] In response to a calibration operation on the test data, outputting calibrated test data;

[0016] In response to the test information generation instruction for the calibrated test data, the application calling interface of the low-code platform is called up in the execution step, and the test data is used to generate automated test script code and test scripts that meet the target requirements.

[0017] In a possible implementation, obtaining the target requirement includes:

[0018] Output demand input interface;

[0019] In response to an input operation on the demand input interface, displaying the input target demand on the demand input interface;

[0020] In response to the submission operation of the target requirement, the triggering step is to input the target requirement into the target model, and generate test data for the target requirement based on the system configuration information of the low-code platform.

[0021] In a possible implementation, the method further includes:

[0022] Outputting a test information processing interface, and displaying the automated test script code on the test information processing interface;

[0023] In response to the integration operation on the automated test script code, the automated test script code is integrated with the existing automated test script code for the target requirement to obtain a target automated test script code that meets the target requirement;

[0024] Execute the target automated test script code and output the test results for the target requirements.

[0025] In a possible implementation, the using the test data to generate automated test script code and a test script that meet the target requirements includes:

[0026] Parsing the test data to generate automated test script code that meets the target requirements;

[0027] The test data is input into the target model for natural language processing to obtain a test script generated by the target model that meets the target requirements.

[0028] A second aspect of the present application provides a test information generating device, the device comprising:

[0029] A target demand acquisition module is used to acquire target demand;

[0030] A test data generation module is used to input the target requirements into the target model, and generate test data for the target requirements based on the system configuration information of the low-code platform; the test data matches the element structure required by the test script, and the element structure represents the elements constituting the test script and the organization between the elements;

[0031] A test information generation module is used to call the application calling interface of the low-code platform and use the test data to generate automated test script code and test scripts that meet the target requirements.

[0032] A third aspect of the present application provides a computer program product, including computer-readable instructions, which, when executed on an electronic device, enable the electronic device to implement the following steps:

[0033] Obtain target requirements;

[0034] The target requirements are input into the target model, and test data for the target requirements is generated according to the system configuration information of the low-code platform; the test data matches the element structure required by the test script, and the element structure represents the elements constituting the test script and the organization between the elements;

[0035] Call the application calling interface of the low-code platform, and use the test data to generate automated test script code and test scripts that meet the target requirements.

[0036] A fourth aspect of the present application provides an electronic device, the electronic device comprising: at least one communication element, at least one memory and at least one processor, wherein:

[0037] The communication element is used to obtain target requirements and system configuration information of the low-code platform;

[0038] The processor is used to load and execute the computer program stored in the memory to implement the following steps:

[0039] The target requirements are input into the target model, and test data for the target requirements is generated according to the system configuration information of the low-code platform; the test data matches the element structure required by the test script, and the element structure represents the elements constituting the test script and the organization between the elements;

[0040] Call the application calling interface of the low-code platform, and use the test data to generate automated test script code and test scripts that meet the target requirements.

[0041] A fifth aspect of the present application provides a computer-readable storage medium, on which a plurality of computer instructions are stored, and the plurality of computer instructions are executed by a processor to implement the following steps:

[0042] Obtain target requirements;

[0043] The target requirements are input into the target model, and test data for the target requirements is generated according to the system configuration information of the low-code platform; the test data matches the element structure required by the test script, and the element structure represents the elements constituting the test script and the organization between the elements;

[0044] Call the application calling interface of the low-code platform, and use the test data to generate automated test script code and test scripts that meet the target requirements. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. Throughout the accompanying drawings, the same or similar reference numerals represent the same or similar elements. It should be understood that the drawings are schematic and the originals and elements are not necessarily drawn to scale.

[0046] Figure 1 A flowchart of a test information generating method proposed in Embodiment 1 of the present application;

[0047] Figure 2 A flowchart of a test information generating method proposed in Embodiment 2 of the present application;

[0048] Figure 3 A flowchart of a test information generating method proposed in Embodiment 3 of the present application;

[0049] Figure 4 A schematic diagram of a requirement input interface in a test information generating method proposed in an embodiment of the present application;

[0050] Figure 5 A schematic diagram of a test data calibration interface in a test information generating method proposed in an embodiment of the present application;

[0051] Figure 6 A schematic diagram of a test information processing interface in a test information generating method proposed in an embodiment of the present application;

[0052] Figure 7A schematic diagram of the structure of a test information generating device provided in an embodiment of the present application;

[0053] Figure 8 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0054] The embodiments of the present application are described below in conjunction with the drawings in the embodiments of the present application. The terms used in the implementation mode of the present application are only used to explain the specific embodiments of the present application and are not intended to limit the present application. The embodiments of the present application are described below in conjunction with the drawings. It is known to those of ordinary skill in the art that with the development of technology and the emergence of new scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.

[0055] The terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and need not be used to describe a specific order or sequential order. It should be understood that the terms used in this way can be interchangeable under appropriate circumstances, which is only to describe the distinction mode adopted by the objects of the same attributes when describing in the embodiments of the present application. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, so that the process, method, system, product or equipment comprising a series of units need not be limited to those units, but may include other units that are not clearly listed or inherent to these processes, methods, products or equipment.

[0056] In view of the description in the background technology section, in order to solve the problems existing in the manual writing of test scripts and the automated test script code method, it is proposed to use a recording tool to record the user's operations on the test interface, such as clicking buttons, filling out forms, and selecting drop-down menus, etc., to identify the element identifiers of the test interface (such as the ID (address) / name (name) / class (category) / XPath (XML path language, to locate elements) / CSS (Cascading Style Sheets) selector, etc. of the HTML (Hyper Text Markup Language) element, and generate the corresponding automated test code in combination with the recorded operation process. However, this recording method is very time-consuming, and the test script must be generated after the development is completed. It is very likely to generate invalid scripts, and it takes a lot of effort to organize the test scripts, and then continuously debug the organized test scripts, which is time-consuming and laborious. Once the element position of the test interface is adjusted, it is necessary to regenerate and debug a new test script according to the above method, which greatly reduces the efficiency of test information generation.

[0057] In order to solve the above problems, an embodiment of the present application provides a test information generation method, which proposes to use the natural language understanding ability of the target model, and analyze the target requirements provided by the user, such as test requirements and scenario descriptions, according to the system configuration information of the low-code platform (such as Power Platform-D365 and other software development tools), and generate test data for the target requirements. After that, the public front-end API (Application Programming Interface) of the low-code platform (such as Power Platform-D365 and other software development tools) can be used to use the test data through the target model to automatically generate automated test script code that meets the target requirements, as well as test scripts used by testers, greatly reducing the workload and errors of manually writing scripts and test codes, and there is no need for test developers to wait for the development test to pass before generating test script code, which greatly improves the test efficiency and ensures the progress of automated testing. The entire process does not require the target model to access the system, which protects the privacy data of the system and improves security.

[0058] Among them, the target model used in this application learns the characteristics and laws of input information by training a large amount of diverse data. It usually has model parameters of hundreds of millions to hundreds of billions (model parameters are variables that control the behavior of the target model, so as to continuously adjust during the training process to improve model performance), and can capture complex relationships and patterns in the input information, such as analyzing the test scripts and test script codes corresponding to different input requirements (which can be different product development test requirements, scenario descriptions, etc., such as user interface testing (UI testing) requirements, etc.), determining the test structured data (such as Json (JavaScript Object Notation, JavaScript object representation) data) used to generate the corresponding test scripts and test script codes, using the system configuration information of the low-code platform as background knowledge, learning the relationship between different input requirements and corresponding test structured data, so as to improve the accuracy of the target model to generate test structured data for actual needs, that is, the test scripts and test script codes generated using the test structured data can reliably meet actual needs and ensure test efficiency and reliability.

[0059] In the actual application of the present application, the target model used to implement the test information generation method proposed in the present application can be a generative model (generative models) or a generative language model (generative language models, GMS), etc. For example, it can specifically include large language models (LLMS), GPT (Generative Pre-trained Transformer), visual large models, multimodal large models, etc. It should be understood that the model involved in the embodiment of the present application can be a general large model, or it can be an expert large model obtained after fine-tuning based on demand, such as fine-tuning the target model with the system configuration information of the low-code platform as background knowledge to improve the performance of the target model in product development test applications based on the low-code platform, etc. The embodiment of the present application does not limit this. The test information generation method of the embodiment of the present application is described in detail below in conjunction with the accompanying drawings.

[0060] Reference Figure 1 , is a flow chart of a test information generation method proposed in the first embodiment of the present application. The method can be applied to electronic devices, such as laptop computers, desktop computers, ultra-mobile personal computers (UMPCs), and other terminal devices or at least one server. According to processing needs, the terminal device and the server can cooperate to implement the test information generation method proposed in the present application. The present application does not limit the system environment of the test information generation method, which can be determined according to the situation. Based on this, Figure 1 , the test information generation method proposed in the embodiment of the present application may include:

[0061] Step S11, obtaining target demand;

[0062] In an embodiment of the present application, the target demand may be a development and testing demand for a product during the development of a product such as an application or a page, such as a user interface testing (UI testing) demand in software development and design. The test developer may determine the content to be tested based on the detailed design description provided by the developer (such as the entire solution design IT Solution Design proposed to solve a specific business problem or meet a business need), and then describe it in natural language to obtain the corresponding target demand, i.e., the target demand description information. Afterwards, the test developer may use input devices such as a mouse, a hand-controlled pen, a finger, or a pickup to input the target demand, so that the electronic device obtains the target demand and automatically executes subsequent processing steps. The present application does not limit the input method of the target demand.

[0063] Among them, if the electronic device executing the test information generation method is a terminal device, according to but not limited to the method described above, the terminal device can directly obtain the corresponding target demand in response to the input operation of the input device. If the electronic device is a server, the terminal device can obtain the target demand according to the method described above and send it to the server through network communication. This application does not limit the implementation method of the electronic device obtaining the target demand.

[0064] Step S12: input the target requirements into the target model, and generate test data for the target requirements based on the system configuration information of the low-code platform; the test data matches the element structure required by the test script, and the element structure represents the elements constituting the test script and the organization between the elements;

[0065] In combination with the above description of the target model, in order to solve the problems existing in manually writing test scripts and improve testing efficiency and reliability, the present application proposes to use the target model's natural language understanding ability of target requirements, the ability to understand and reason about test logic and steps based on target requirements, the ability to generate required test data based on understood target requirements and reasoned test logic and steps, the ability to recognize images of user interface elements required for testing in UI testing, as well as the ability to flexibly adapt to different testing frameworks and tools and the ability to prevent and control risk requirements, etc., to automatically generate test data for target requirements, so that the test data can be used to generate test scripts and automated test script codes that meet the target requirements, thereby avoiding the impact of low efficiency and error-prone manual writing on test reliability and efficiency.

[0066] In an embodiment of the present application, the test data to be generated must match the element structure required by the test script. The element structure is used to illustrate how the various elements required by the test script are interrelated and function collaboratively to achieve automated testing. That is to say, the element structure represents the various elements that constitute the test script and the organization of the various elements. For example, in order to ensure the integrity and effectiveness of the test, the element structure contents such as the test framework, test cases and their execution order / dependencies, test reports, assertions, exception handling, logging, test configuration, test coverage, and test environment can be determined based on actual conditions.

[0067] Among them, in order to improve development and testing efficiency, maintainability, real-time monitoring and fault recovery, reduce dependence on professional skills, etc., this application proposes the use of a low-code platform (Low-Code Platform, LCDP, a development tool that can quickly generate applications through visual programming and a small amount of code, which can. By abstracting and minimizing manual coding, users can quickly build applications through a graphical user interface and drag-and-drop components, thereby significantly reducing the cost of software development, configuration, deployment and training) to achieve product development testing, and the test data that needs to be generated must meet the low-code platform operation requirements. If a general large model is used as the target model, and the target model's own knowledge base is relied upon to understand and analyze the target requirements, the generated test data may not meet the low-code platform operation requirements, and further conversion and other processing are required, affecting processing efficiency.

[0068] In order to improve the above problems, this application proposes that in the process of generating test data from the target model, the system configuration information of the low-code platform is used as background knowledge to understand and analyze the target requirements, ensuring that the target model generates test data that matches the element structure that meets the test script requirements of the low-code platform. The test data can be processed directly subsequently without the need for format conversion and other processing steps that are not related to the test script and test script code, thereby simplifying the test information generation steps.

[0069] Among them, the system configuration information of the low-code platform can be the basic information of the low-code system table, which is the core component of the data structure and storage mechanism for building development products in the low-code development environment, such as data tables, fields, records, forms, views, associations, permissions, indexes, data models, and API interfaces, etc., which can automatically generate data structures and business logic defined by data models, so that ordinary users can also manage and operate data through a graphical interface, and quickly build and deploy development products. This application does not limit the content of the system configuration information of the low-code platform. It should be understood that as the system of the low-code platform is upgraded, the corresponding system configuration information can be updated synchronously, so that the target model generates test data for the target needs based on the updated system configuration information.

[0070] In some embodiments, the target model can also be fine-tuned based on the system configuration information of the low-code platform and the element structure required by the test script, such as the generative pre-trained model or large language model listed above, so that the test data generated by the fine-tuned target model in the test information generation task proposed in this application is more accurate and reliable. This application does not describe the fine-tuning implementation process in detail.

[0071] Combined with the above analysis, in practical applications, in order to enable the target model to generate test data according to the method described above, the prompt word engineering can be implemented in combination with the target model. That is to say, the present application can pre-configure a prompt word (prompt) template (which can be recorded as the first prompt word template for convenience of description) for guiding the target model to understand and analyze the input target requirements based on the system configuration information of the low-code platform, and generate test data for the target requirements. The electronic device can input the user requirements and the prompt word template into the target model to generate test data for the target requirements in the above manner. Alternatively, the user requirements are written into the corresponding field in the first prompt word template to obtain the corresponding task prompt information, and the task prompt information is input into the target model to generate test data for the target requirements, etc. The present application does not limit the specific implementation process of step S12, which can be determined according to the circumstances.

[0072] Step S13, call the application call interface of the low-code platform, and use the test data to generate automated test script code and test scripts that meet the target requirements.

[0073] In the embodiment of the present application, the test data for the target requirements generated efficiently and reliably using the target model can be structured data, such as Json format strings, etc., which can be determined according to the test script requirements of the low-code platform, and the present application does not restrict its data format. Afterwards, based on the public front-end API of the low-code platform, the location of the element can be obtained efficiently and reliably, such as building a JavaScript object that associates the front-end with the data model of the low-code platform, so that it can locate and control the front-end components through the data model to convert the test data into executable automated test script code and natural semantic test scripts. The implementation process is not described in detail in this application.

[0074] It can be seen that the present application uses the target model to automatically generate test data for the input target requirements, which saves time and effort without manual writing, and improves the reliability and accuracy of the test data. Afterwards, the test data is directly used to generate test scripts and automated test script codes that meet the target requirements. There is no need for test developers to wait for the development test to be completed (such as the tester writes the test script and the test passes) before generating the automated test script code, which reduces the waiting time for development and testing, improves the efficiency of testers and test developers, and ensures the progress of automated testing. Since the present application only needs to input the target requirements into the target model, and does not require the target model to access the development and testing products, the resulting privacy data leakage is avoided, data security is improved, and the application call interface API of the low-code platform can easily and accurately locate elements, ensuring that the test data is used to generate practical automated test script code to improve test efficiency and reliability.

[0075] Reference Figure 2 , is a flow chart of a test information generation method proposed in Embodiment 2 of the present application. This embodiment can describe in detail an optional implementation process of using the target model proposed above to generate test data for target requirements, such as Figure 2 As shown, in combination with the description of other processing steps of the test information generating method in the above embodiment, the implementation process of the above step S12 may include but is not limited to the following steps:

[0076] Step S21, obtaining target demand;

[0077] Step S22, inputting the target requirement into the target model to obtain the test element of the target requirement;

[0078] Step S23, obtaining element configuration information of each test element according to the system configuration information of the low-code platform through the target model;

[0079] Step S24, generating test data for target requirements using element configuration information according to the element structure required by the test script;

[0080] Combined with the above description of the target model, the powerful capabilities of the target model can be used to perform natural language understanding of the input target requirements, and extract the various test elements that constitute the entire test framework from the target requirements. These may be some activities and related test components that meet the functional and performance requirements defined in the requirement specification (such as the above-mentioned IT Solution Design), which may include the test environment, test objectives (which may be the purpose and expected results of the test, such as the functions, performance, and compatibility to be verified), test scope, specific fields that need to be tested (such as the cash comment field in the requirement to verify whether specific fields in the "UFA Refund Request Form" meet the expected behavior, etc.) and specific expected behavior content and conditions, test tools, test criteria, and test levels. This application does not limit the content of the test elements, which may be determined as appropriate.

[0081] Based on the test elements described above, this application can use the system configuration information of the low-code platform to process the contents of each test element indicated by the target requirements to obtain the corresponding element configuration information suitable for the low-code platform, such as a Json string of the configuration content of the test environment such as hardware, software and network configuration that meets the target requirements and is suitable for the low-code platform, the test tool identification / configuration information in the low-code platform selected or specified to achieve the target requirements, the low-code platform system configuration information required to achieve the test scope such as test software functions and modules represented by the target requirements, etc. The element configuration information of each test element comes from the system configuration information of the low-code platform.

[0082] Compared with manually selecting or configuring the element configuration information of each test element, this application uses the target model to analyze the relationship between the system configuration information of the low-code platform and each test element, and determines the element configuration information of each test element used to achieve the target requirements. After that, the element configuration information of each test element can be processed according to the element structure required by the test script applicable to the low-code platform to generate test data for the target requirements.

[0083] Optionally, the above-mentioned element configuration information acquisition rules and test data generation rules can also be configured as corresponding second prompt word templates to guide the target model to analyze the system configuration information of the low-code platform and the test elements of the target requirements, determine the element configuration information of each test element, and then generate test data that matches the element structure required by the test script, such as structured data. In one possible implementation, the second prompt word template can be a part of the above-mentioned first prompt word template, so that after the target model obtains the test element, it directly generates test data for the target requirement based on the second prompt word template.

[0084] Of course, the first prompt word template may include rules for obtaining element configuration information and test data generation rules, so that after inputting the target requirements and the first prompt word template into the target model, the target model is guided by the first prompt word template to obtain each test element, and the contents of step S23 and step S24 are automatically executed. Of course, different rules may be configured as one-to-one corresponding prompt word templates, so that at different processing stages, the corresponding prompt word template is input into the target model or the target model executes the input corresponding prompt word template until the test data for the target requirements is generated, and the implementation process is not described in detail in this application.

[0085] In some embodiments, for the test data generated by the target model, the present application can also output the test data so that the test developers can calibrate it based on their professional knowledge. In response to the calibration operation on the test data, the calibrated test data can be output, and then subsequent operations can be triggered, that is, in response to the test information generation instruction for the calibrated test data, the application call interface of the low-code platform is called, and the calibrated test data is used to generate automated test script code and test scripts that meet the target requirements, thereby solving the problem of the reliability and accuracy of the automated test script code and test scripts generated by the target model due to inaccurate test data, thereby improving the test reliability and accuracy.

[0086] Step S25, calling the application calling interface of the low-code platform, parsing the test data, and generating automated test script code that meets the target requirements;

[0087] Step S26, input the test data into the target model for natural language processing to obtain a test script generated by the target model that meets the target requirements.

[0088] In the embodiment of the present application, the test data (such as UI test structured data corresponding to UI test requirements, which can be a test script Json string, etc.) can be converted into executable automated test script code (such as automated UI test code that meets UI test requirements) based on the public front-end API of the low-code platform. Compared with the implementation method of directly using the target model to access the test product indicated by the target requirement (such as a web page, etc.), the present application example uses the public front-end API of the low-code platform to automatically and accurately determine the position of each test element in the page, so as to reliably generate practical automated test script code. Since the present application does not require manual positioning of elements, even after the position of the test element in the page is updated, there is no need for the tester to rewrite the script, which saves time and effort and greatly improves the test efficiency and maintainability.

[0089] Moreover, this application can generate automated test script code that meets the target requirements without waiting for the test script development and testing to be completed, which improves efficiency and ensures the progress of automated testing. It can also use the natural language processing capabilities of the target model to automatically generate natural semantic test scripts using test data, reducing the workload of testers and test developers and improving test efficiency. The entire test information generation process does not require the target model to access the test product specified by the target requirement, avoiding the back leakage of private data and improving data security.

[0090] Reference Figure 3 , is a flow chart of a test information generating method proposed in Embodiment 3 of the present application, which method can be applied to a terminal device with a display screen, such as Figure 3 As shown, the test information generation method proposed in this embodiment may include:

[0091] Step S31, outputting a demand input interface;

[0092] Step S32, in response to an input operation on the demand input interface, displaying the input target demand on the demand input interface;

[0093] Step S33, in response to the submission operation of the target requirement, the target requirement is input into the target model, and test data for the target requirement is generated according to the system configuration information of the low-code platform;

[0094] Combined with the target requirements acquisition method described above, after the test developer logs into the test system, he can enter Figure 4The requirement input interface shown directly uses natural language to describe the target requirement. After confirming that there is no problem, click "Submit" to input the target requirement into the target model to generate test data for the target requirement. The generation process can refer to the description of Example 2 above.

[0095] In practical applications, since the computing resources and memory resources required for the operation of the target model are large, when the terminal device resources are limited, the target model can be deployed to the server. In this case, the terminal device responds to the submission operation of the target demand and can send the submitted target model to the server through the network. The server inputs the received target demand into the target model to generate test data.

[0096] In some embodiments, after receiving the target requirements, the target model can automatically analyze the low-code system main table based on the system configuration information of the low-code platform, load and identify the field information in the table for the target requirements, and obtain structured data that meets the low-code platform, that is, test data for the target requirements. In order to facilitate the test developers to check and correct the test data, Figure 5 The test data calibration interface diagram shown in FIG. 1 can be displayed in a visual interface, such as Figure 5 The UI test structured data shown.

[0097] Test developers can check the test data generated by the target model displayed on the visual interface based on professional knowledge and target requirements to determine whether it is complete and correct, and can be used to generate test scripts and automated test script codes that meet the target requirements. If an error is detected, the error information displayed on the visual interface can be modified directly, such as using the mouse or any suitable object such as fingers, joints, stylus, etc. to operate on the error information displayed on the touch screen or near the error information displayed on the touch screen. This application does not limit the implementation method of modifying the test data. After that, if it is determined that the modified test data is complete and correct, you can click the "Generate Code" button to continue with the subsequent steps.

[0098] It should be noted that the output methods of target requirements and test data include but are not limited to Figure 4 and Figure 5 The interface shown can be flexibly configured according to actual conditions, and this application only uses this as an example for illustration. It can be seen that this application can use a visual interface to output target requirements and test data, which can facilitate test developers to flexibly modify and ensure that the test data used to generate test scripts and automated test script codes is correct, thereby improving the reliability of test information generation.

[0099] Step S34, calling the application calling interface of the low-code platform, and using the test data to generate automated test script code and test scripts that meet the target requirements;

[0100] Step S35, outputting a test information processing interface, displaying the automated test script code on the test information processing interface;

[0101] Step S36, in response to the integration operation on the automated test script code, the automated test script code is integrated with the existing automated test script code for the target requirement to obtain the target automated test script code that meets the target requirement;

[0102] Step S37, execute the target automated test script code and output the test results for the target requirements.

[0103] In some embodiments, the automated test script code and test script generated this time can still be verified by the test developer based on personal professional knowledge, and the terminal device can output the following: Figure 6 In the visual test information processing interface shown, when it is determined that the generated automated test script code and the test script are correct, you can click the "Integrate" button to integrate the automated test script code with the previously generated automated test script code for the target requirements, and obtain a complete target automated test script code that meets the target requirements, so as to realize the testing of the target requirements.

[0104] Among them, if this embodiment is the first time to generate automated test script code for the target requirements, if it is incomplete, such as the automated test script code generated this time is for partial verification content of the target requirements, the automated test script code can be stored first, and the test information generation method proposed in this application can be continued to generate automated test script code for other verification content of the target requirements, determine the complete target automated test script code that meets the target requirements, and then integrate it into the target automated test script code to complete the test of the target requirements.

[0105] Combined with the above analysis, in a possible implementation, for Figure 4 The target requirements in the requirement input interface shown can be analyzed by the target model to identify the part of the requirements that need to be verified this time, and then input it into the target model to generate test data for this part of the requirements, and then use the test data to obtain the automated test script code that meets this part of the requirements, but it is not limited to this acquisition method. It should be noted that the application can also directly generate a complete automated test script code that meets the target requirements according to the test information generation method proposed in the application.

[0106] It can be seen from this that for the test product indicated by the target requirements, when some of the functions or modules in its design change, the requirements for these new functions or modules can be obtained. According to the method described above, the automated test script code required for implementing the testing of some new functions or modules is generated, and it is integrated with the automated test script code that has been generated before for the test product to implement other functions or module tests. After the target automated test script code for implementing all functions and module tests of the test product is obtained, it is executed to reliably obtain complete test results.

[0107] A test information generating method provided in an embodiment of the present application is introduced above, and a device for executing the above test information generating method will be introduced below.

[0108] according to Figure 7 , is a schematic diagram of the structure of a test information generating device provided in an embodiment of the present application. Figure 7 As shown, the test information generating device comprises:

[0109] The target demand acquisition module 71 is used to acquire the target demand;

[0110] A test data generation module 72 is used to input the target requirements into the target model, and generate test data for the target requirements according to the system configuration information of the low-code platform; the test data matches the element structure required by the test script, and the element structure represents the elements constituting the test script and the organization between the elements;

[0111] The test information generation module 73 is used to call the application calling interface of the low-code platform and use the test data to generate automated test script code and test scripts that meet the target requirements.

[0112] In a possible implementation, the test data generating module 72 may include:

[0113] A test element acquisition unit, used for inputting the target requirement into a target model to acquire the test element of the target requirement;

[0114] An element configuration information acquisition unit, used to acquire element configuration information of each of the test elements according to the system configuration information of the low-code platform through the target model;

[0115] The test data generating unit is used to generate test data for the target requirement according to the element structure required by the test script and using the element configuration information.

[0116] In some embodiments, the test information generating device proposed in the present application may further include:

[0117] A test data output module, used for outputting the test data;

[0118] A test data calibration module, configured to output calibrated test data in response to a calibration operation on the test data;

[0119] A test information generation trigger module is used to respond to a test information generation instruction for calibrated test data, trigger the test information generation module 73 to call the application call interface of the low-code platform, and use the test data to generate automated test script code and test scripts that meet the target requirements.

[0120] In a possible implementation, the target demand acquisition module 71 may include:

[0121] A demand input interface output unit, used for outputting the demand input interface;

[0122] a target requirement input unit, configured to display the input target requirement on the requirement input interface in response to an input operation on the requirement input interface;

[0123] The target requirement submission unit is used to trigger the test data generation module 72 to input the target requirement into the target model in response to the submission operation of the target requirement, and generate test data for the target requirement based on the system configuration information of the low-code platform.

[0124] In some embodiments, the test information generating device proposed in the present application may further include:

[0125] A test information processing interface output module, used for outputting a test information processing interface and displaying the automated test script code on the test information processing interface;

[0126] An integration module, for integrating the automated test script code with an existing automated test script code for the target requirement in response to an integration operation for the automated test script code, to obtain a target automated test script code that meets the target requirement;

[0127] The execution module is used to execute the target automated test script code and output the test results for the target requirements.

[0128] In a possible implementation, the test information generating module 73 may include:

[0129] A first generating unit, configured to parse the test data and generate an automated test script code that meets the target requirements;

[0130] The second generating unit is used to input the test data into the target model for natural language processing to obtain a test script generated by the target model that meets the target requirements.

[0131] An embodiment of the present application also provides a computer program product including computer-readable instructions. When the computer-readable instructions are executed on an electronic device, the electronic device implements any test information generating method provided in the embodiment of the present application.

[0132] A computer-readable storage medium is also provided in an embodiment of the present application. The storage medium carries one or more computer instructions. When the one or more computer instructions are executed by a processor, the processor can implement any test information generation method provided in an embodiment of the present application.

[0133] Reference Figure 8 , is a schematic diagram of the hardware structure of an electronic device proposed in an embodiment of the present application, such as Figure 8 As shown, the electronic device may include: at least one communication element 81, at least one memory 82 and at least one processor 83, wherein:

[0134] At least one communication element 81, at least one memory 82 and at least one processor 83 can communicate with each other via a bus. The bus can be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 8 Only one bidirectional line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.

[0135] The communication element 81 can be used to obtain target requirements and system configuration information of the low-code platform. It can also be used to realize data or instruction transmission between internal components of the electronic device.

[0136] In the embodiment of the present application, the communication element 81 may include a communication element corresponding to wireless communication methods such as wifi, Bluetooth, 5G / 6G and other mobile communications, so that the electronic device can realize data transmission with other devices through the communication element, and may also include one or more interfaces supporting wired communication methods, such as a general-purpose input / output (GPIO) interface, a USB interface, a universal asynchronous receiver / transmitter (UART) interface, etc., to realize data transmission between various components inside the electronic device. The present application does not limit the composition structure of the communication element 81 to realize this function and its corresponding communication transmission mechanism, which can be determined according to the circumstances.

[0137] The memory 82 can be used to store a computer program that implements the test information generation method proposed in the embodiment of the present application; the processor 83 can load and execute the computer program stored in the memory 82 to implement the various steps of the test information generation method proposed in the embodiment of the present application. The implementation process can refer to the description of the corresponding part of the method embodiment above.

[0138] In the embodiment of the present application, the memory 82 may include storage media such as a floppy disk, a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk. The processor 81 may include any one or more of a central processing unit (CPU), a graphics processing unit (GPU), a microprocessor (MP), a digital signal processor (DSP), an application specific integrated circuit (ASIC) or a field-programmable gate array (FPGA).

[0139] It should be understood that Figure 8 The structure of the electronic device shown does not constitute a limitation on the electronic device in the embodiment of the present application. In practical applications, the electronic device may include Figure 8More or fewer components as shown, or a combination of certain components, such as when the electronic device is a terminal device, may also include microphones, speakers, displays, various sensors, antennas, power modules, RF components, external ports and other input / output components, etc., which can be determined based on processing function requirements, and this application does not give detailed examples one by one.

[0140] It should also be noted that the device embodiments described above are merely schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed over multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. In addition, in the drawings of the device embodiments provided by the present application, the connection relationship between the modules indicates that there is a communication connection between them, which may be specifically implemented as one or more communication buses or signal lines.

[0141] Through the description of the above implementation mode, in the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from a website site, a computer, a training device or a data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, training device or data center. The computer-readable storage medium can be any available medium that a computer can store or a data storage device such as a training device, a data center, etc. that contains one or more available media integrated. The available medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a DVD), or a semiconductor medium (eg, a solid state disk (SSD)).

[0142] In addition, the various embodiments in this specification are described in a progressive or parallel manner, and each embodiment focuses on the differences from other embodiments, and the same or similar parts between the various embodiments can be referred to each other. For the devices, electronic devices, products and media disclosed in the embodiments, since they correspond to the methods disclosed in the embodiments, the description is relatively simple, and the relevant parts can be referred to the method part description.

Claims

1. A method for generating test information, the method comprising: Obtain target requirements; The target requirements are input into the target model, and test data for the target requirements is generated according to the system configuration information of the low-code platform; the test data matches the element structure required by the test script, and the element structure represents the elements constituting the test script and the organization between the elements; Call the application calling interface of the low-code platform, and use the test data to generate automated test script code and test scripts that meet the target requirements.

2. According to the method of claim 1, the step of inputting the target requirement into a target model and generating test data for the target requirement based on the system configuration information of the low-code platform comprises: Input the target requirement into the target model to obtain the test element of the target requirement; Obtaining element configuration information of each of the test elements through the target model according to the system configuration information of the low-code platform; According to the element structure required by the test script, the element configuration information is used to generate test data for the target requirement.

3. The method according to claim 1 or 2, further comprising: Outputting the test data; In response to a calibration operation on the test data, outputting calibrated test data; In response to the test information generation instruction for the calibrated test data, the application calling interface of the low-code platform is called up in the execution step, and the test data is used to generate automated test script code and test scripts that meet the target requirements.

4. The method according to claim 1 or 2, wherein obtaining target requirements comprises: Output demand input interface; In response to an input operation on the demand input interface, displaying the input target demand on the demand input interface; In response to the submission operation of the target requirement, the triggering step is to input the target requirement into the target model, and generate test data for the target requirement based on the system configuration information of the low-code platform.

5. The method according to claim 1 or 2, further comprising: Outputting a test information processing interface, and displaying the automated test script code on the test information processing interface; In response to the integration operation on the automated test script code, the automated test script code is integrated with the existing automated test script code for the target requirement to obtain a target automated test script code that meets the target requirement; Execute the target automated test script code and output the test results for the target requirements.

6. The method according to claim 1 or 2, wherein the step of utilizing the test data to generate automated test script code and test scripts that meet the target requirements comprises: Parsing the test data to generate automated test script code that meets the target requirements; The test data is input into the target model for natural language processing to obtain a test script generated by the target model that meets the target requirements.

7. A test information generating device, the device comprising: A target demand acquisition module is used to acquire target demand; A test data generation module is used to input the target requirements into the target model, and generate test data for the target requirements based on the system configuration information of the low-code platform; the test data matches the element structure required by the test script, and the element structure represents the elements constituting the test script and the organization between the elements; A test information generation module is used to call the application calling interface of the low-code platform and use the test data to generate automated test script code and test scripts that meet the target requirements.

8. A computer program product, comprising computer-readable instructions, which, when executed on an electronic device, cause the electronic device to implement the following steps: Obtain target requirements; The target requirements are input into the target model, and test data for the target requirements is generated according to the system configuration information of the low-code platform; the test data matches the element structure required by the test script, and the element structure represents the elements constituting the test script and the organization between the elements; Call the application calling interface of the low-code platform, and use the test data to generate automated test script code and test scripts that meet the target requirements.

9. An electronic device, comprising: at least one communication element, at least one memory, and at least one processor, wherein: The communication element is used to obtain target requirements and system configuration information of the low-code platform; The processor is used to load and execute the computer program stored in the memory to implement the following steps: The target requirements are input into the target model, and test data for the target requirements is generated according to the system configuration information of the low-code platform; the test data matches the element structure required by the test script, and the element structure represents the elements constituting the test script and the organization between the elements; Call the application calling interface of the low-code platform, and use the test data to generate automated test script code and test scripts that meet the target requirements.

10. A computer-readable storage medium having a plurality of computer instructions stored thereon, wherein the plurality of computer instructions are executed by a processor to implement the following steps: Obtain target requirements; The target requirements are input into the target model, and test data for the target requirements is generated according to the system configuration information of the low-code platform; the test data matches the element structure required by the test script, and the element structure represents the elements constituting the test script and the organization between the elements; Call the application calling interface of the low-code platform, and use the test data to generate automated test script code and test scripts that meet the target requirements.