Interface testing method, device, equipment, medium and program product

By creating candidate front-end interfaces on low-code platforms and using generative large language models to simulate configuration of back-end interface collections, the problem of front-end development waiting for back-end APIs to be completed is solved, and development efficiency and comprehensive testing is improved.

CN119718946APending Publication Date: 2025-03-28INDUSTRIAL AND COMMERCIAL BANK OF CHINA
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411869743.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-18
Publication Date
2025-03-28

AI Technical Summary

Technical Problem

In the front-end and back-end separation architecture, front-end development needs to wait for the back-end API interface to be developed, resulting in low development efficiency and existing testing methods cannot fully cover all potential test scenarios, and the testing efficiency is not high.

Method used

Create candidate front-end interfaces through low-code platforms, and use a generative large language model to simulate and configure the back-end interface collection, generate interface test cases, and realize automated interface testing.

Benefits of technology

It improves the efficiency of front-end development and the comprehensiveness and efficiency of interface testing, can be tested independently of the back-end development progress, and optimizes the front-end collaborative development process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119718946A_ABST
    Figure CN119718946A_ABST
Patent Text Reader

Abstract

The invention provides an interface testing method, and relates to the field of artificial intelligence. The method comprises the following steps: creating a candidate front-end interface of a target application based on a low-code platform; simulating and configuring a back-end interface set of N interaction components in the candidate front-end interface, wherein N is an integer greater than or equal to 1; inputting data of the candidate front-end interface and the back-end interface set into a generative large language model to obtain an interface test case; and according to test data obtained by executing the test case, obtaining an interface test result of the target application. The invention further provides an interface testing device and equipment, a storage medium and a program product.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of artificial intelligence, and more specifically, to an interface testing method, device, equipment, medium and program product. Background Art

[0002] Front-end and back-end separation is an architectural pattern that can separate the front-end interface of a software application from the back-end business logic, so that the front-end and back-end of a software application can be independently developed and deployed. In a front-end and back-end separation architecture, testing is usually required after the front-end and back-end are developed together. For example, a complete software application can only be formed after both the front-end and back-end are developed, and then enter the subsequent testing phase.

[0003] In the process of implementing the disclosed invention concept, the inventors found that during the development phase, the front-end may need to wait for the back-end API interface to be developed, which affects the front-end development and overall testing efficiency. During the testing phase, manual testing mainly relies on static code analysis and API documentation, which may not cover all potential test scenarios, resulting in incomplete testing, low testing efficiency, and inability to quickly respond to iterative changes in the development process. Summary of the invention

[0004] In view of the above problems, the present disclosure provides an interface testing method, apparatus, device, medium and program product.

[0005] According to the first aspect of the present disclosure, an interface testing method is provided, including: creating a candidate front-end interface of a target application based on a low-code platform; simulating the configuration of a back-end interface set of N interactive components in the candidate front-end interface, where N is an integer greater than or equal to 1; inputting data of the candidate front-end interface and the back-end interface set into a generative large language model to obtain an interface test case; and obtaining an interface test result for the target application based on the test data obtained by executing the test case.

[0006] According to an embodiment of the present disclosure, the creation of a candidate front-end interface of a target application based on a low-code platform includes: generating interface parameters of the candidate front-end interface in response to a user's generation indication of the candidate front-end interface; recommending M candidate components in the low-code platform based on the interface parameters, wherein the M candidate components include the N interactive components, and M is an integer greater than or equal to N; and based on the generation indication, visually arranging at least part of the M candidate components to obtain the candidate front-end interface.

[0007] According to an embodiment of the present disclosure, obtaining the candidate front-end interface includes: performing intent recognition on the generation indication; based on the result of the intent recognition, determining the N interactive components and the position of each interactive component from the M candidate components; and visually arranging the N interactive components according to the position of each interactive component to obtain the candidate front-end interface.

[0008] According to an embodiment of the present disclosure, the step of inputting the data of the candidate front-end interface and the back-end interface set into a generative large language model to obtain an interface test case includes: obtaining a functional description of the candidate front-end interface, specification information of each interface in the back-end interface set, and a test target; and inputting pre-built prompt words, the functional description, the specification information of each interface, and the test target into the generative large language model to obtain the interface test case.

[0009] According to an embodiment of the present disclosure, the test target includes at least one of a functional test target, a performance test target and a security test target of each interface in the process of executing the target financial business.

[0010] According to an embodiment of the present disclosure, the simulation configuration of the backend interface set of N interactive components in the candidate front-end interface includes: determining at least one backend interface associated with each of the N interactive components; and using interface mock technology to simulate the configuration of the backend interface set.

[0011] According to an embodiment of the present disclosure, before obtaining the interface test result of the target application based on the test data obtained by executing the test case, the method also includes: simulating user interaction behavior to execute the interface test case on the candidate front-end interface; using the interface mock technology to receive a request for at least one interface in the back-end interface set; inputting the parameters of the target financial business and the request into the generative large language model to obtain a response from the interface, wherein the test data includes the request and the response.

[0012] According to an embodiment of the present disclosure, the candidate front-end interface includes some functions of the target front-end interface. After obtaining the interface test results of the target application, the method also includes: when the interface test results do not meet the expected conditions, inputting the data of the candidate front-end interface and the interface test results into the generative large language model; obtaining the reconstructed data of the generative large language model based on the candidate front-end interface; creating the target front-end interface on the low-code platform based on the reconstructed data; and performing interface testing on the target front-end interface and the set of back-end interfaces that simulate its configuration.

[0013] Another aspect of an embodiment of the present disclosure provides an interface testing device, including: a low-code module, used to create a candidate front-end interface of a target application based on a low-code platform; an interface simulation module, used to simulate the configuration of a back-end interface set of N interactive components in the candidate front-end interface, where N is an integer greater than or equal to 1; a test case module, used to input data of the candidate front-end interface and the back-end interface set into a generative large language model to obtain an interface test case; and a test result module, used to obtain an interface test result for the target application based on the test data obtained by executing the test case.

[0014] Another aspect of an embodiment of the present disclosure provides an electronic device, including: one or more processors; and a memory for storing one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors execute the method described above.

[0015] Another aspect of an embodiment of the present disclosure provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the processor executes the method as described above.

[0016] Another aspect of an embodiment of the present disclosure provides a computer program product, including a computer program, which implements the above method when executed by a processor.

[0017] One or more of the above-mentioned embodiments have the following beneficial effects: by introducing a low-code development model and a front-end and back-end separation architecture, combined with generative large language model technology, while simplifying the front-end development process and improving development efficiency, the interface test cases generated by the model can be used to improve the comprehensiveness, efficiency and intelligence of the interface test, thereby achieving the effect of not relying on the back-end development progress, and optimizing the front-end and back-end collaborative development process. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] The above contents and other objects, features and advantages of the present disclosure will become more apparent through the following description of the embodiments of the present disclosure with reference to the accompanying drawings, in which:

[0019] Figure 1 The application scenario diagram of the interface test according to the embodiment of the present disclosure is schematically shown;

[0020] Figure 2 A flowchart of an interface testing method according to an embodiment of the present disclosure is schematically shown;

[0021] Figure 3 A flowchart for obtaining an interface test case according to an embodiment of the present disclosure is schematically shown;

[0022] Figure 4A flowchart of simulating configuration of a backend interface set according to an embodiment of the present disclosure is schematically shown;

[0023] Figure 5 A flowchart for obtaining test data according to an embodiment of the present disclosure is schematically shown;

[0024] Figure 6 A flowchart of an interface testing method according to another embodiment of the present disclosure is schematically shown;

[0025] Figure 7 The structure block diagram of the interface testing device according to the embodiment of the present disclosure is schematically shown;

[0026] Figure 8 A block diagram of an electronic device suitable for implementing an interface testing method according to an embodiment of the present disclosure is schematically shown. DETAILED DESCRIPTION

[0027] Hereinafter, embodiments of the present disclosure will be described with reference to the accompanying drawings. However, it should be understood that these descriptions are exemplary only and are not intended to limit the scope of the present disclosure. In the following detailed description, for ease of explanation, many specific details are set forth to provide a comprehensive understanding of the embodiments of the present disclosure. However, it is apparent that one or more embodiments may also be implemented without these specific details. In addition, in the following description, descriptions of known structures and technologies are omitted to avoid unnecessary confusion of the concepts of the present disclosure.

[0028] In the technical solution of the present disclosure, the user information (including but not limited to user personal information, user image information, user device information, such as location information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved are all information and data authorized by the user or fully authorized by all parties, and the collection, storage, use, processing, transmission, provision, disclosure and application of the relevant data comply with relevant laws, regulations and standards, take necessary confidentiality measures, do not violate public order and good morals, and provide corresponding operation entrances for users to choose to authorize or refuse.

[0029] In the scenario of using personal information for automated decision-making, the methods, devices, and systems provided by the embodiments of the present disclosure provide users with corresponding operation portals for users to choose to agree or reject the automated decision-making results; if the user chooses to reject, the expert decision-making process will be entered. The expression "automated decision-making" here refers to the activity of automatically analyzing and evaluating a person's behavioral habits, interests and hobbies, or economic, health, credit status, etc. through computer programs, and making decisions. The expression "expert decision-making" here refers to the activity of making decisions by people who specialize in a certain field, have specialized experience, knowledge and skills, and have reached a certain level of professionalism.

[0030] Figure 1 The following schematically shows an application scenario diagram of the interface test according to an embodiment of the present disclosure. It should be noted that: Figure 1 What is shown are merely examples to which the embodiments of the present disclosure can be applied, so as to help those skilled in the art understand the technical content of the present disclosure, but it does not mean that the embodiments of the present disclosure cannot be used in other devices, systems, environments or scenarios.

[0031] like Figure 1 As shown, the application scenario 100 according to this embodiment may include a first terminal device 101, a second terminal device 102, a third terminal device 103, a network 104 and a server 105. The network 104 is used to provide a medium for a communication link between the first terminal device 101, the second terminal device 102, the third terminal device 103 and the server 105. The network 104 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.

[0032] The user can use the first terminal device 101, the second terminal device 102, and the third terminal device 103 to interact with the server 105 through the network 104 to receive or send messages, etc. Various communication client applications can be installed on the first terminal device 101, the second terminal device 102, and the third terminal device 103, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social platform software, etc. (only for example).

[0033] The first terminal device 101, the second terminal device 102, and the third terminal device 103 may be various electronic devices having display screens and supporting web browsing, including but not limited to smart phones, tablet computers, laptop computers, desktop computers, and the like.

[0034] The server 105 may be a server that provides various services, such as a background management server that provides support for websites browsed by users using the first terminal device 101, the second terminal device 102, and the third terminal device 103 (for example only). The background management server may analyze and process the received data such as user requests, and feed back the processing results (such as web pages, information, or data obtained or generated according to user requests) to the terminal devices. For example, the server 105 may be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud computing, network services, and middleware services.

[0035] For example, a user can use the first terminal device 101, the second terminal device 102, and the third terminal device 103 to operate the low-code platform, or issue instructions to the generative large language model deployed in the server 105, so that the server 105 calls the interface of the low-code platform to create a front-end interface.

[0036] It should be noted that the interface testing method provided in the embodiment of the present disclosure can generally be executed by at least one of a terminal device or a server. Accordingly, the interface testing device provided in the embodiment of the present disclosure can generally be set in at least one of a terminal device or a server.

[0037] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to implementation requirements.

[0038] The following will be based on Figure 1 The scene described by Figure 2~Figure 6 The interface testing method of the embodiment of the present disclosure is described in detail.

[0039] Figure 2 The flowchart of the interface testing method according to the embodiment of the present disclosure is schematically shown.

[0040] like Figure 2 As shown, this embodiment includes:

[0041] In operation S210, a candidate front-end interface of the target application is created based on the low-code platform.

[0042] A low-code platform is a platform that can complete application development with a small amount of coding. Low-code platforms usually provide a visual editor, through which users can set the application's UI interface and the data displayed in the UI interface. Setting the data displayed in the UI interface can also be understood as event binding for the UI interface.

[0043] The candidate front-end interfaces include the UI interface of the target application and the data displayed in the UI interface, such as interactive components, as well as the borders, corners, background, text, etc. of the interface.

[0044] In operation S220, a backend interface set of N interactive components in the candidate frontend interface is simulated and configured, where N is an integer greater than or equal to 1.

[0045] Interactive components include interface elements that users can directly interact with the target application, such as buttons, input boxes, drop-down menus, etc. For example, the username and password input boxes in the login interface are two interactive components. The backend interface set includes a set of API interfaces provided by the backend service, which can be called by the front-end interactive components to realize data interaction. For example, the backend interface set of an e-commerce website may include interfaces such as user authentication, product query, and order creation.

[0046] For example, the simulation configuration may include setting up a test environment in a test server and exposing one or more backend interfaces to form a set. The test server can perform clear requests and return corresponding responses according to the preset request and response relationship. The mock service tool deployed in the backend test environment can be used to define the API specifications, including request methods, paths, parameters, request bodies, and response bodies. It can also generate simulated data responses, and dynamically generate response content based on request parameters.

[0047] For example, the mock configuration can include using the mock function of the front-end framework, first simulating the interface to write Mock rules, defining the matching conditions of the request and the response data, and then starting the Mock service in the local development environment to intercept the actual API request and return the simulated response.

[0048] For example, simulation configuration can also include using the mock service of the low-code platform, creating a simulated data model in the low-code platform, defining data structure and fields, configuring the request path and response data of the interface, and connecting the simulated back-end interface with the interactive components of the front-end interface so that the interactive components can call the Mock interface and display the simulated data.

[0049] In operation S230, data of the candidate front-end interface and the back-end interface set are input into a generative large language model to obtain interface test cases.

[0050] The generative large language model contains hundreds of millions of ultra-large-scale parameters, and can learn and understand a huge amount of data through machine learning and other technologies, and can process massive amounts of data to complete various complex generative tasks. In operation S230, the generative large language model can be trained through front-end interface samples, back-end interface samples, and test case samples.

[0051] An interface test case may refer to a set of test inputs, execution conditions, and expected results compiled for a specific purpose in order to verify whether a specific need is met. Interface test case information may include the interface identifier, access address and path, input parameters, output parameters, request method, and return parameters of the interface to be tested. Among them, the request method may include: upload (post), modify (put), delete (delete), and obtain (get). Interface test cases can be stored in a test case library.

[0052] For example, the data of the candidate front-end interface can be obtained by parsing the code tree or image recognition, and can include the text description, function description, location, color, shape, etc. of each interactive component. The data of the back-end interface set can include detailed specifications of each interface, such as the request method, request path, request parameters, request header, request body and expected response of each interface.

[0053] You can input prompt words into the generative large language model, so that the model can automatically generate test scripts based on the elements and interaction logic of the interface. Prompt words can include a variety of prompt contents, such as providing prompt words for interface elements, such as "button-submit-bottom of the page". Prompt words for interaction logic, such as "after clicking the submit button, check whether the response status code is 200". Prompt words for test scenarios, such as "test the user login function, enter the correct username and password". Prompt words for exception handling, such as "enter the wrong email format, check whether the error prompt is displayed".

[0054] In some embodiments, pre-recorded user operations may also be input into a generative large language model so that the model can modify the user operations in combination with a set of candidate front-end interfaces and back-end interfaces and output a generated interface test case.

[0055] In operation S240, an interface test result for the target application is obtained according to the test data obtained by executing the test case.

[0056] The interface test results can be divided into test success results and test failure results. Test success or test failure can be determined based on the interface return results and expected return results. Once the test succeeds, the entire test process ends; if the test fails, the interface or test script is adjusted and repaired, and the test is re-executed until the test succeeds.

[0057] For example, the target application includes mobile banking services. Through the low-code platform, a candidate front-end interface including components such as account query, transfer payment, and credit card management was quickly built. Then, corresponding back-end interfaces were configured for these components, such as account information acquisition, fund transfer processing, and credit card data services. This information was input into the generative large language model, and the model generated a series of interface test cases, including normal process tests, abnormal process tests, and performance tests. By executing these test cases, test data such as the response time and error rate of the interface were collected, thereby evaluating the performance and stability of the interface and ensuring the reliability of the mobile banking service.

[0058] According to the embodiments of the present disclosure, by introducing a low-code development model and a front-end and back-end separation architecture, combined with generative large language model technology, on the basis of simplifying the front-end development process and improving development efficiency, the interface test cases generated by the model can be used to improve the comprehensiveness, efficiency and intelligence of the interface test, so as to achieve the effect of not relying on the back-end development progress, and optimize the front-end and back-end collaborative development process.

[0059] In some embodiments, creating a candidate front-end interface for a target application based on a low-code platform includes: generating interface parameters of the candidate front-end interface in response to a user's generation indication of the candidate front-end interface; recommending M candidate components in the low-code platform based on the interface parameters, wherein the M candidate components include N interactive components, and M is an integer greater than or equal to N; based on the generation indication, visually arranging at least some of the M candidate components to obtain a candidate front-end interface.

[0060] For example, a chat interface for interacting with users can be provided on a low-code platform. Users can enter generation instructions in the chat interface. The generation instructions contain information such as the style, content, and functions of the candidate front-end interface that the user expects to obtain. Then, the generative large language model can be called to generate interface parameters. The generative large language model can be the same as or different from the model for generating interface test cases. Alternatively, several keywords can be extracted from the generation instructions, and these keywords can be matched with the description of the pre-stored interface template to obtain the matched interface template and extract the interface parameters from the template.

[0061] Interface parameters can include function descriptions, front-end interface layouts, styles, and behaviors, such as color, font, button size, etc. Based on the content of the interface parameters, M candidate components can be selected from all components provided by the low-code platform. For example, based on the interface parameters and the user's historical choices, a machine learning algorithm is used to recommend candidate components. For example, if the interface parameters include the content of an input box, several different styles of input box components may be recommended.

[0062] For example, a machine learning algorithm (such as a generative algorithm) can be used to generate an RPA (Robotic Process Automation) script based on generation instructions, interface parameters, and M candidate components. The RPA tool can be used to perform a visual arrangement of the M candidate components.

[0063] Among them, in the process of providing a chat interface using generative AI dialogue as mentioned above, intelligent development guidance can be provided. Through multiple rounds of dialogue iterations, users can be helped to describe specific needs through natural language, thereby reducing the need for professionalism and obtaining candidate front-end interfaces.

[0064] Although the low-code platform has reduced the difficulty of front-end interface development to a certain extent, when developing applications based on the low-code platform, when dealing with complex personalized needs, users still need to have a certain technical background and programming knowledge.

[0065] According to the embodiments of the present disclosure, the automated interface parameter generation and component selection reduces the time of manual configuration and speeds up the development process. In addition, the automated visual arrangement of components reduces human errors and improves the development quality.

[0066] In some embodiments, visually arranging M candidate components based on the generation indication to obtain a candidate front-end interface includes: identifying the intent of the generation indication; based on the result of the intent identification, determining N interactive components and the position of each interactive component from the M candidate components; and visually arranging the N interactive components according to the position of each interactive component to obtain a candidate front-end interface.

[0067] Natural language processing (NLP) technology can be used in combination with an intent recognition model to analyze the generation instructions of user input. Intent recognition is used to analyze the generation instructions of user input through natural language processing technology to determine the user's real needs and intentions. For example, the intent in "I want an interface that provides user registration" is identified as "create a user registration interface." For example, the position parameter of the "user name input box" can be determined as the top of the page, the position parameter of the "password input box" can be determined as below the "user name input box," and the position parameter of the "register button" can be determined as the bottom of the page. Then, based on the determined position parameters, the "user name input box," "password input box," and "register button" are arranged on the page according to preset layout rules to form a candidate user registration interface.

[0068] According to the embodiments of the present disclosure, user needs can be effectively understood, and the quality of the front-end interface can be improved while reducing development difficulty and improving development efficiency.

[0069] Figure 3 A flowchart for obtaining interface test cases according to an embodiment of the present disclosure is schematically shown.

[0070] like Figure 3 As shown, this embodiment is one of the embodiments of operation S230, including:

[0071] In operation S310, a functional description of a candidate front-end interface, specification information of each interface in a back-end interface set, and a test target are obtained.

[0072] The interface specification information includes the detailed specifications of each backend interface, including the request method, path, parameters, request header, request body, and expected response. The test objectives include the specific goals of the interface test, including which aspects of the interface are tested (such as performance, security, stability, etc.). For example, the test goal may be "verify the response time of the user authentication interface under high concurrency."

[0073] The functional description includes a textual description of the function of each component of the candidate front-end interface. For example, for a search box component, its functional description may be "allowing users to enter search keywords and submit search requests."

[0074] In operation S320, pre-built prompt words, function descriptions, specification information of each interface, and test objectives are input into a generative large language model to obtain interface test cases.

[0075] The prompt words can be for each interface definition, for example, including "generate test cases for the product query interface". The functional description of the product list display component, the specification information of the product query interface and the test objectives are input into the generative large language model, and a series of test cases can be generated, such as test cases including verification of interface response time, data accuracy and error handling.

[0076] According to the embodiments of the present disclosure, a generative large language model can automatically generate a series of test cases according to the complexity and functional requirements of the front-end user interface, reducing the time and cost of manually writing test cases and improving test efficiency. More test scenarios can be covered, such as including some edge cases, which improves the comprehensiveness of the test.

[0077] In some embodiments, the test target includes at least one of a functional test target, a performance test target, and a security test target for each interface in the process of executing the target financial business.

[0078] For example, implementation examples of functional testing objectives include: for a transfer interface of a financial service, write test cases to verify whether the interface can correctly handle transfer requests from user A's account to user B's account, including verifying whether the account balance is correctly updated after the transfer. Implementation examples of performance testing objectives include: for the transfer interface of the same financial service, write test cases to simulate 100 concurrent transfer requests, and use performance monitoring tools to record the response time of the interface and the usage of system resources to ensure that the system can still run stably under high load. Implementation examples of security testing objectives include: for the user authentication interface of a financial service, write test cases to simulate various security attacks, such as SQL injection attacks, by trying to enter maliciously constructed SQL statements as user names or passwords to verify whether the system can identify and prevent these attacks.

[0079] According to the embodiments of the present disclosure, through comprehensive interface testing, the stability and reliability of the financial business system in actual operation can be ensured, and the security of user data and funds can be ensured.

[0080] Figure 4 The flowchart of simulating the configuration of the backend interface set according to an embodiment of the present disclosure is schematically shown.

[0081] like Figure 4 As shown, this embodiment is one of the embodiments of operation S220, including:

[0082] In operation S410, at least one backend interface associated with each of the N interactive components is determined.

[0083] In operation S420, the backend interface set is simulated and configured using the interface mock technology.

[0084] Interface mock technology refers to the technology of simulating the response of the backend interface, which is used for front-end development and testing before the actual development of the backend service is completed. For example, determine the expected behavior of the backend interface to be developed, including the request method, request path, request parameters, expected response, etc. Configure one or more mock servers to simulate the real backend API interface. On the mock server, define the details of the mock API, including: request URL, request method, request header, request parameters, and response data. For example, use the Mock.js library to simulate the backend interface of a product list for use in front-end testing.

[0085] For example, interface mock technology can automatically generate simulation data based on the definition of the backend interface. Generative large language models can be trained to generate simulation data that is closer to the characteristics of real data, improving the efficiency of front-end development and the accuracy of testing; machine learning algorithms can also be used to analyze historical interface data and predict the response mode of the interface, thereby providing a more realistic and stable interface simulation environment during the mock process.

[0086] You can set response logic for the simulated API based on business logic, including static response, dynamic response, delayed response, etc.

[0087] According to the embodiments of the present disclosure, through the interface mock technology, the front-end development is no longer dependent on the back-end development progress, and testing can be performed in advance, thereby accelerating the overall development process.

[0088] Figure 5 The flowchart of obtaining test data according to an embodiment of the present disclosure is schematically shown.

[0089] like Figure 5 As shown, before obtaining the interface test result of the target application according to the test data obtained by executing the test case, the embodiment includes:

[0090] In operation S510, interface test cases are executed on the candidate front-end interface by simulating user interaction behavior.

[0091] User interaction behavior includes the interaction between the user and the software interface, such as clicking a button, entering text, selecting a drop-down menu, etc. For example, in a banking application, simulate the user clicking the "Transfer" button and simulate entering the payee information and amount. You can simulate the user's actual usage scenario by executing interface test cases.

[0092] In operation S520, a request for at least one interface in the backend interface set is received by using the interface mock technology.

[0093] In operation S530, the parameters and request of the target financial service are input into the generative large language model to obtain a response of the interface, wherein the test data includes the request and the response.

[0094] The request data and business parameters are input into the generative large language model, which generates simulated response data based on these inputs. For example, the parameters of the transfer request (such as the amount and the recipient information) are input into the model, and the model generates a simulated bank response that is successfully processed.

[0095] According to the embodiments of the present disclosure, by simulating real user operations and introducing a generative large language model, various user interactions and business scenarios, including abnormal situations, can be simulated, thereby enhancing the coverage of the test, being able to discover interface problems in a timely manner, reducing dependence on actual backend services, and reducing the cost and complexity of the test.

[0096] Figure 6 The flowchart of the interface testing method according to another embodiment of the present disclosure is schematically shown.

[0097] like Figure 6As shown, the operation S210 to the operation S240 of this embodiment are not repeated here. The interface testing method of this embodiment also includes:

[0098] In operation S610, when the interface test result does not meet the expected conditions, the data of the candidate front-end interface and the interface test result are input into the generative large language model.

[0099] The data of the candidate front-end interface includes interface layout, component attributes, style, etc. The interface test results include the results after the interface test is executed, including whether the test passes, interface response time, error code, etc. The expected conditions may include test success.

[0100] In operation S620 , reconstructed data of the generative large language model based on the candidate front-end interface is obtained.

[0101] Refactoring data includes interface parameters for creating new front-end interfaces, such as optimized interactive components and interface layouts for candidate front-end interfaces. For example, refactoring data includes improving the response speed of the API through code optimization, database optimization, etc.; through usability optimization, the API can run stably in various environments, such as different network conditions and server loads. Through user experience optimization, the usability of the API is improved, such as simplifying parameters and providing more friendly error messages.

[0102] In operation S630, a target front-end interface is created on a low-code platform based on the reconstructed data.

[0103] For example, based on the content of the restructured data, the layout of the product list component is changed from list view to grid view on the low-code platform.

[0104] In operation S640, interface testing is performed on the target front-end interface and the back-end interface set simulated and configured therefor.

[0105] For example, the target front-end interface may be used as a test object (a new candidate front-end interface), and operations S220 to S640 may be repeatedly performed until the test result meets the expected condition.

[0106] According to the disclosed embodiment, a generative large language model is introduced for iterative updating, and the front-end interface is iteratively developed while being tested without relying on the back-end development progress, thereby improving the testing efficiency and development speed.

[0107] Based on the above interface testing method, the present disclosure also provides an interface testing device. Figure 7 The device is described in detail.

[0108] Figure 7 The structural block diagram of the interface testing device according to the embodiment of the present disclosure is schematically shown.

[0109] like Figure 7 As shown, the interface testing device 700 of this embodiment includes a low-code module 710, an interface simulation module 720, a test case module 730 and a test result module 740.

[0110] The low-code module 710 can perform operation S210 to create a candidate front-end interface for the target application based on the low-code platform.

[0111] The interface simulation module 720 may perform operation S220 to simulate configuring a backend interface set of N interactive components in the candidate frontend interface, where N is an integer greater than or equal to 1.

[0112] The test case module 730 may perform operation S230 to input data of a candidate front-end interface and a set of back-end interfaces into a generative large language model to obtain an interface test case.

[0113] The test result module 740 may perform operation S240 to obtain an interface test result for the target application according to the test data obtained by executing the test case.

[0114] In some embodiments, the low-code module 710 can also be used to generate interface parameters of a candidate front-end interface in response to a user's generation indication of a candidate front-end interface; recommend M candidate components in the low-code platform based on the interface parameters; and based on the generation indication, visually arrange at least some of the M candidate components to obtain a candidate front-end interface.

[0115] In some embodiments, the low-code module 710 can also be used to identify the intent of generating instructions; based on the results of the intent identification, determine N interactive components and the positions of each interactive component from M candidate components; visually arrange the N interactive components according to the positions of each interactive component to obtain a candidate front-end interface.

[0116] In some embodiments, the test case module 730 can also be used to obtain the functional description of the candidate front-end interface, the specification information of each interface in the back-end interface set, and the test objectives; input the pre-built prompt words, functional description, specification information of each interface and test objectives into the generative large language model to obtain the interface test case.

[0117] In some embodiments, the interface simulation module 720 may also perform operations S410 to S420, which will not be described in detail herein.

[0118] In some embodiments, the test result module 740 may also be used to perform operations S510 to S530, which will not be described in detail herein.

[0119] In some embodiments, the interface testing device 700 may further include an iterative development module, which is used to perform operations S610 to S640, which will not be described in detail herein.

[0120] For the parts not mentioned in the device part, they can be understood with reference to the various embodiments of the above method. That is, the device part includes modules for executing the various steps of any one of the method embodiments described above. In addition, the implementation methods, technical problems solved, functions implemented, and technical effects achieved of each module / unit / subunit, etc. in the device part embodiment are respectively the same or similar to the implementation methods, technical problems solved, functions implemented, and technical effects achieved of each corresponding step in the method part embodiment, and will not be repeated here.

[0121] According to an embodiment of the present disclosure, any multiple modules among the low-code module 710, the interface simulation module 720, the test case module 730, and the test result module 740 can be combined into one module for implementation, or any one of the modules can be split into multiple modules. Alternatively, at least part of the functions of one or more of these modules can be combined with at least part of the functions of other modules and implemented in one module.

[0122] According to an embodiment of the present disclosure, at least one of the low-code module 710, the interface simulation module 720, the test case module 730, and the test result module 740 can be at least partially implemented as a hardware circuit, such as a field programmable gate array (FPGA), a programmable logic array (PLA), a system on a chip, a system on a substrate, a system on a package, an application-specific integrated circuit (ASIC), or can be implemented by hardware or firmware such as any other reasonable way of integrating or packaging the circuit, or implemented in any one of the three implementation methods of software, hardware, and firmware, or in an appropriate combination of any of them. Alternatively, at least one of the low-code module 710, the interface simulation module 720, the test case module 730, and the test result module 740 can be at least partially implemented as a computer program module, and when the computer program module is run, the corresponding function can be performed.

[0123] Figure 8 A block diagram of an electronic device suitable for implementing an interface testing method according to an embodiment of the present disclosure is schematically shown.

[0124] like Figure 8As shown, the electronic device 800 according to an embodiment of the present disclosure includes a processor 801, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 802 or a program loaded from a storage part 808 to a random access memory (RAM) 803. The processor 801 may include, for example, a general-purpose microprocessor (e.g., a CPU), an instruction set processor and / or a related chipset and / or a dedicated microprocessor (e.g., an application-specific integrated circuit (ASIC)), etc. The processor 801 may also include an onboard memory for caching purposes. The processor 801 may include a single processing unit or multiple processing units for performing different actions of the method flow according to an embodiment of the present disclosure.

[0125] In RAM 803, various programs and data required for the operation of electronic device 800 are stored. Processor 801, ROM 802 and RAM 803 are connected to each other via bus 804. Processor 801 performs various operations of the method flow according to the embodiment of the present disclosure by executing the program in ROM 802 and / or RAM 803. It should be noted that the program can also be stored in one or more memories other than ROM 802 and RAM 803. Processor 801 can also perform various operations of the method flow according to the embodiment of the present disclosure by executing the program stored in one or more memories.

[0126] According to an embodiment of the present disclosure, the electronic device 800 may further include an input / output (I / O) interface 805, which is also connected to the bus 804. The electronic device 800 may further include one or more of the following components connected to the input / output (I / O) interface 805: an input portion 806 including a keyboard, a mouse, etc.; an output portion 807 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage portion 808 including a hard disk, etc.; and a communication portion 809 including a network interface card such as a LAN card, a modem, etc. The communication portion 809 performs communication processing via a network such as the Internet. A drive 810 is also connected to the input / output (I / O) interface 805 as needed. A removable medium 811, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 810 as needed, so that the computer program read therefrom is installed into the storage portion 808 as needed.

[0127] The present disclosure also provides a computer-readable storage medium, which may be included in the device / apparatus / system described in the above embodiments; or may exist independently without being assembled into the device / apparatus / system. The above computer-readable storage medium carries one or more programs, and when the above one or more programs are executed, the method according to the embodiment of the present disclosure is implemented.

[0128] According to an embodiment of the present disclosure, the computer-readable storage medium may be a non-volatile computer-readable storage medium, for example, it may include but is not limited to: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program, which may be used by or in combination with an instruction execution system, an apparatus or a device. For example, according to an embodiment of the present disclosure, the computer-readable storage medium may include the ROM 802 and / or RAM 803 described above and / or one or more memories other than ROM 802 and RAM 803.

[0129] The embodiment of the present disclosure also includes a computer program product, which includes a computer program, and the computer program contains program code for executing the method shown in the flowchart. When the computer program product is run in a computer system, the program code is used to enable the computer system to implement the method provided by the embodiment of the present disclosure.

[0130] The above functions defined in the system / device of the embodiment of the present disclosure are executed when the computer program is executed by the processor 801. According to the embodiment of the present disclosure, the system, device, module, unit, etc. described above can be implemented by a computer program module.

[0131] In one embodiment, the computer program may rely on tangible storage media such as optical storage devices, magnetic storage devices, etc. In another embodiment, the computer program may also be transmitted and distributed in the form of signals on a network medium, and downloaded and installed through the communication part 809, and / or installed from a removable medium 811. The program code contained in the computer program may be transmitted using any appropriate network medium, including but not limited to: wireless, wired, etc., or any suitable combination of the above.

[0132] In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 809, and / or installed from the removable medium 811. When the computer program is executed by the processor 801, the above functions defined in the system of the embodiment of the present disclosure are performed. According to the embodiment of the present disclosure, the system, device, means, module, unit, etc. described above can be implemented by a computer program module.

[0133] According to an embodiment of the present disclosure, the program code for executing the computer program provided by the embodiment of the present disclosure can be written in any combination of one or more programming languages. Specifically, these computing programs can be implemented using high-level process and / or object-oriented programming languages, and / or assembly / machine languages. Programming languages ​​include, but are not limited to, Java, C++, python, "C" language or similar programming languages. The program code can be executed entirely on the user computing device, partially on the user device, partially on the remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device can be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computing device (for example, using an Internet service provider to connect through the Internet).

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

[0135] It will be appreciated by those skilled in the art that the features described in the various embodiments of the present disclosure may be combined and / or combined in a variety of ways, even if such combinations or combinations are not explicitly described in the present disclosure. In particular, without departing from the spirit and teachings of the present disclosure, the features described in the various embodiments of the present disclosure may be combined and / or combined in a variety of ways. All of these combinations and / or combinations fall within the scope of the present disclosure.

[0136] The embodiments of the present disclosure are described above. However, these embodiments are only for illustrative purposes and are not intended to limit the scope of the present disclosure. Although the embodiments are described above separately, this does not mean that the measures in the various embodiments cannot be used in combination to advantage. The scope of the present disclosure is defined by the attached claims and their equivalents. Without departing from the scope of the present disclosure, those skilled in the art may make a variety of substitutions and modifications, which should all fall within the scope of the present disclosure.

Claims

1. An interface testing method, comprising: Create candidate front-end interfaces for target applications based on the low-code platform; Simulate the configuration of a backend interface set of N interactive components in the candidate frontend interface, where N is an integer greater than or equal to 1; Inputting data of the candidate front-end interface and the back-end interface set into a generative large language model to obtain interface test cases; According to the test data obtained by executing the test case, an interface test result for the target application is obtained.

2. The method according to claim 1, characterized in that The candidate front-end interfaces for creating the target application based on the low-code platform include: In response to a user's instruction to generate the candidate front-end interface, generate interface parameters of the candidate front-end interface; Recommending M candidate components in the low-code platform based on the interface parameters, wherein the M candidate components include the N interactive components, and M is an integer greater than or equal to N; Based on the generation indication, at least some of the M candidate components are visually arranged to obtain the candidate front-end interface.

3. The method according to claim 2, characterized in that The obtaining of the candidate front-end interface comprises: performing intent recognition on the generating instruction; Based on the result of the intention recognition, determining the N interactive components and the position of each interactive component from the M candidate components; The N interactive components are visually arranged according to the positions of the various interactive components to obtain the candidate front-end interface.

4. The method according to claim 1, characterized in that The step of inputting the data of the candidate front-end interface and the back-end interface set into a generative large language model to obtain an interface test case comprises: Obtaining a functional description of the candidate front-end interface, specification information of each interface in the back-end interface set, and a test target; The pre-constructed prompt words, the functional description, the specification information of each interface and the test target are input into the generative large language model to obtain the interface test case.

5. The method according to claim 4, characterized in that The test objectives include at least one of a functional test objective, a performance test objective, and a security test objective for each interface in the process of executing a target financial business.

6. The method according to claim 5, characterized in that The set of backend interfaces of the N interactive components in the candidate frontend interface for simulating the configuration includes: Determine at least one backend interface associated with each of the N interactive components; The interface mock technology is used to simulate the configuration of the backend interface set.

7. The method according to claim 6, characterized in that Before obtaining the interface test result of the target application according to the test data obtained by executing the test case, the method further includes: Simulating user interaction behavior to execute the interface test case on the candidate front-end interface; Receive a request for at least one interface in the backend interface set using the interface mock technology; The parameters of the target financial business and the request are input into the generative large language model to obtain a response of the interface, wherein the test data includes the request and the response.

8. The method according to claim 1, characterized in that The candidate front-end interface includes part of the functions of the target front-end interface. After obtaining the interface test result of the target application, the method further includes: In the case where the interface test result does not meet the expected conditions, inputting the data of the candidate front-end interface and the interface test result into the generative large language model; Obtaining reconstruction data of the generative large language model based on the candidate front-end interface; Creating the target front-end interface on the low-code platform based on the reconstructed data; Interface testing is performed on the target front-end interface and the back-end interface set of its simulated configuration.

9. An interface testing device, comprising: A low-code module, used to create candidate front-end interfaces of target applications based on the low-code platform; An interface simulation module, used to simulate and configure a set of back-end interfaces of N interactive components in the candidate front-end interface, where N is an integer greater than or equal to 1; A test case module, used for inputting data of the candidate front-end interface and the back-end interface set into a generative large language model to obtain an interface test case; The test result module is used to obtain the interface test result of the target application according to the test data obtained by executing the test case.

10. An electronic device comprising: one or more processors; a memory for storing one or more computer programs, It is characterized in that the one or more processors execute the one or more computer programs to implement the steps of the method according to any one of claims 1 to 8.

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

12. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 8 are implemented.