Task execution method and device, storage medium and electronic equipment
By dynamically updating the test case collection, and obtaining supplementary use cases from the sample use case library based on the application characteristics of the target application, the problem of low test coverage in the existing technology is solved, and more efficient business function testing and more stable system operation is achieved.
Patent Information
- Application Number
- CN202510236678.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-28
- Publication Date
- 2025-06-10
AI Technical Summary
In existing business systems, business function testing relies on historical experience and manual use cases, resulting in low test coverage, especially insufficient coverage of important business functions, posing potential risks to production and operations.
By obtaining the initial use case collection of target applications and when the use case conditions are not met, the sample use case collection is determined from the sample use case library according to the application characteristics of the target application, and the initial use case collection is updated to form the target use case collection for execution of test tasks.
It improves business test coverage, optimizes the functional regression testing process, enhances the testing effectiveness, ensures that business functions can be fully verified after software upgrades or function changes, and improves system stability and user experience.
Smart Images

Figure CN120123243A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computers, and in particular, to a method and apparatus for executing tasks, a storage medium, and an electronic device. Background Art
[0002] In the current business system, the testing of various business functions often only relies on historical experience, and manual setting of mandatory test cases. However, this method does not fully consider the commonalities and differences of applications of the same type in different business subsystems, resulting in a low test coverage rate, especially insufficient coverage of important business functions. Therefore, after application upgrades or function changes, all key business logics cannot be effectively verified, bringing potential risks to subsequent production operations.
[0003] In response to the above problems, no effective solution has been proposed yet. Summary of the Invention
[0004] Embodiments of the present application provide a method and apparatus for executing tasks, a storage medium, and an electronic device to at least solve the technical problem of low test coverage rate of services.
[0005] According to one aspect of the embodiments of the present application, a method for executing a task is provided, including: obtaining an initial use case set corresponding to a target application, where the initial use case set is used to test whether the target application allows processing of a target service; in a case where the initial use case set does not meet the use case condition, determining a sample use case set from a sample use case library according to the application characteristics of the target application, where the sample use case library includes use case sets corresponding to multiple business applications with different application characteristics, and the use case condition is used to determine whether the initial use case set allows covering the test scope of the target service; updating the initial use case set according to the sample use case set to obtain a target use case set, and using the target use case set to execute a test task corresponding to the target service.
[0006] According to another aspect of the embodiments of the present application, an apparatus for executing a task is further provided, including: an obtaining module, configured to obtain an initial use case set corresponding to a target application, where the initial use case set is used to test whether the target application can process a target service; an updating module, configured to, in a case where the initial use case set does not meet the use case condition, determine a sample use case set from a sample use case library according to the application characteristics of the target application, where the sample use case library includes use case sets corresponding to multiple business applications with different application characteristics, and the use case condition is used to determine whether the initial use case set allows covering the test scope of the target service; an execution module, configured to update the initial use case set according to the sample use case set to obtain a target use case set, and use the target use case set to execute a test task corresponding to the target service.
[0007] Optionally, the device is further configured to: when the initial use case set does not meet the use case condition, obtain an application list and application characteristics of the target application, where the application list includes a plurality of the service applications, and the plurality of service applications are respectively deployed in their corresponding service systems; determine a set of sample applications from the application list according to the application characteristics of the target application; determine a sample use case set from the sample use case library according to the set of sample applications, and update the initial use case set according to the sample use case set to obtain a target use case set, where the sample use case set is a use case set corresponding to the set of sample applications in the sample use case library.
[0008] Optionally, the device is configured to determine a set of sample applications from the application list according to the application characteristics of the target application in the following manner: determine the business domain to which the target application belongs according to the application characteristics of the target application; determine the service applications that are in the business domain and in different service systems in the application list as the set of sample applications.
[0009] Optionally, the device is further configured to: when the test scopes of the initial use case set and the sample use case set are the same, determine that the initial use case set meets the use case condition; when the test scopes of the initial use case set and the sample use case set are different, determine that the initial use case set does not meet the use case condition.
[0010] Optionally, the device is configured to determine that the initial use case set meets the use case condition in the following manner when the test scopes of the initial use case set and the sample use case set are the same: when the test scope of the initial use case set is greater than the test scope of the sample use case set, update the sample use case set with first test cases, and execute the test task with the initial use case set, where the first test cases represent test cases that belong to the initial use case set and do not belong to the sample use case set; when the test scope of the initial use case set is less than the test scope of the sample use case set, update the initial use case set with second test cases to obtain the target use case set, and execute the test task with the target use case set, where the second test cases represent test cases that belong to the sample use case set and do not belong to the initial use case set; when the test scope of the initial use case set is equal to the test scope of the sample use case set, execute the test task with the initial use case set.
[0011] Optionally, the device is used to obtain an initial use case set corresponding to the target application in the following manner: determine a group of services to be tested in the target application; obtain a target service to be tested whose operation frequency is greater than or equal to a preset frequency in the group of services to be tested; and determine the initial use case set based on the test cases corresponding to the target service to be tested.
[0012] According to another aspect of the embodiments of the present application, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute a method for executing the above-mentioned task at runtime.
[0013] According to another aspect of the embodiment of the present application, a computer program product or a computer program is provided, the computer program product or the computer program includes computer instructions, the computer instructions are stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device performs the execution method of the above task.
[0014] According to another aspect of the embodiments of the present application, there is also provided an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to execute the execution method of the above-mentioned task through the computer program.
[0015] In an embodiment of the present application, an initial use case set corresponding to a target application is obtained, wherein the initial use case set is used to test whether the target application is allowed to process a target business; when the initial use case set does not meet the use case condition, a sample use case set is determined from a sample use case library according to the application characteristics of the target application, wherein the sample use case library includes use case sets corresponding to multiple business applications with different application characteristics, and the use case condition is used to determine whether the initial use case set is allowed to cover the test scope of the target business; the initial use case set is updated according to the sample use case set to obtain a target use case set, and the target use case set is used to execute the test tasks corresponding to the target business, and the purpose of improving the business test coverage is achieved through refined management and dynamic adjustment of test cases, thereby achieving the technical effect of optimizing the functional regression test process and enhancing the test effectiveness, thereby solving the technical problem of low test coverage of the business, ensuring that after software upgrades or function changes, the business functions of each business subsystem can be fully verified, thereby improving the stability of the system and user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:
[0017] Figure 1 It is a schematic diagram of an application environment of an optional task execution method according to an embodiment of the present application;
[0018] Figure 2 It is a schematic flowchart of an optional task execution method according to an embodiment of the present application;
[0019] Figure 3 It is a schematic diagram of an optional task execution method according to an embodiment of the present application;
[0020] Figure 4 It is a schematic structural diagram of an optional task execution device according to an embodiment of the present application;
[0021] Figure 5 It is a schematic structural diagram of an optional task execution product according to an embodiment of the present application;
[0022] Figure 6 It is a schematic structural diagram of an optional electronic device according to an embodiment of the present application. Detailed implementation manners
[0023] In order to enable those skilled in the art to better understand the solutions of the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present application.
[0024] It should be noted that 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 do not necessarily need to describe a specific order or sequence. It should be understood that such data can be interchanged under appropriate circumstances so that the embodiments of the present application described herein can be implemented in an order different from those illustrated or described herein. In addition, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device comprising a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0025] The present application will be described below with reference to the embodiments:
[0026] According to one aspect of the embodiments of the present application, an execution method for a task is provided. Optionally, in this embodiment, the above-mentioned task execution method can be applied to, for example, Figure 1In the hardware environment composed of the server 101 and the terminal device 103 as shown. As Figure 1 shown, the server 101 is connected to the terminal device 103 through a network and can be used to provide services for the terminal device or the application installed on the terminal device. The application 107 can be a video application, an instant messaging application, a browser application, an educational application, a game application, etc. The database 105 can be set on the server or independently of the server to provide data storage services for the server 101. For example, a game data storage server. The above network can include, but is not limited to: a wired network, a wireless network. Among them, the wired network includes: a local area network, a metropolitan area network, and a wide area network. The wireless network includes: Bluetooth, WIFI, and other networks that implement wireless communication. The terminal device 103 can be a terminal configured with an application and can include, but is not limited to, at least one of the following: a mobile phone (such as an Android mobile phone, an iOS mobile phone, etc.), a laptop computer, a tablet computer, a handheld computer, a MID (Mobile Internet Devices, mobile Internet device), a PAD, a desktop computer, a smart TV, a smart voice interaction device, a smart home appliance, a vehicle-mounted terminal, an aircraft, a virtual reality (Virtual Reality, VR for short) terminal, an augmented reality (Augmented Reality, AR for short) terminal, a mixed reality (Mixed Reality, MR for short) terminal, and other computer devices. The above server can be a single server, a server cluster composed of multiple servers, or a cloud server.
[0027] Combined with Figure 1 shown, the execution method of the above task can be executed by an electronic device. The electronic device can be a terminal device or a server. The execution method of the above task can be implemented by the terminal device or the server respectively, or jointly implemented by the terminal device and the server.
[0028] The above is only an example, and this embodiment does not make specific limitations.
[0029] Optionally, as an alternative implementation, as Figure 2 shown, the execution method of the above task includes:
[0030] S202, obtain an initial use case set corresponding to the target application, where the initial use case set is used to test whether the target application allows processing the target service;
[0031] Optionally, in the embodiments of the present application, the above-mentioned initial use case set refers to a set of test cases designed to verify the ability of the target application to process specific business functions in the initial stage of software testing, including but not limited to types such as function verification, performance testing, and compatibility testing. These test cases are intended to cover the main business processes, operation scenarios, and boundary conditions of the target application to ensure the stability and correctness of the application in different usage scenarios.
[0032] It should be noted that the construction of the initial use case set is based on the preliminary understanding of the target application and the analysis of business requirements, and may vary according to the complexity of the application, the particularity of the business domain, or the refinement degree of requirements. The present application does not make any limitations in this regard.
[0033] Furthermore, considering the update and iteration of business functions or the changes in test requirements, the initial use case set is not fixed, but needs to be continuously optimized and supplemented in subsequent test practices to ensure its continuous compliance with the test requirements for the target business of the application, thereby effectively improving the test coverage rate and software quality.
[0034] S204, in the case where the initial use case set does not meet the use case conditions, determine a sample use case set from the sample use case library according to the application characteristics of the target application, where the sample use case library includes use case sets corresponding to multiple business applications with different application characteristics, and the use case conditions are used to determine whether the initial use case set allows covering the test scope of the target business;
[0035] Optionally, in the embodiments of the present application, the above-mentioned sample use case library refers to a pre-constructed resource library containing multiple test case sets designed for different application characteristics. These application characteristics cover the diversity of business functions, the complexity of operation processes, the particularity of data processing, etc., and the sample use case sets are designed according to these characteristics to supplement and enrich the initial use case set to ensure the comprehensive coverage of the test scope. It includes but is not limited to types such as function regression test cases, exception handling test cases, and performance stress test cases.
[0036] It should be noted that the construction of the sample use case library can be based on historical project experience, industry standard test cases, or test cases generated by automated tools. Its content is rich and targeted, and can effectively meet the test requirements of the target application in different business scenarios. The present application does not make any limitations in this regard. The sample use case library should be flexibly selected and customized according to the specific characteristics and business requirements of the target application to achieve the best test effect.
[0037] In addition, when setting the use case conditions, the characteristics of the target business and the test objectives should be fully considered, such as the function points to be verified, the expected test results, the integrity of the business process, etc., which are used as the basis for judging whether the initial use case set meets the test scope coverage standard. This condition can be quantitative, such as the percentage of test coverage to be achieved; it can also be qualitative, such as covering all business paths and exception situations.
[0038] S206. Update the initial use case set according to the sample use case set to obtain the target use case set, and use the target use case set to execute the test tasks corresponding to the target business.
[0039] Optionally, in the embodiments of the present application, the above-mentioned target use case set refers to a more comprehensive and targeted test case set formed by integrating the supplementary test cases in the sample use case set with the initial use case set. It includes, but is not limited to, function verification use cases, exception handling use cases, boundary condition test cases, and performance test cases, aiming to cover all key test points of the target business and ensure the stability and functionality of the software or system.
[0040] It should be noted that the formation of the target use case set can be achieved by screening, adjusting, and combining the sample use case set to adapt to the specific business scenarios and function requirements of the target application. The present application does not limit this.
[0041] Exemplarily, first lock the target application and collect a series of initial use case sets, which are used to verify the ability of the application to handle its expected business. When it is found that the initial use case set is not sufficient to cover all necessary test scopes, that is, it does not meet the preset use case conditions, the system will screen out the use case set with relevant application characteristics from the huge sample use case library according to the specific attributes of the target application. The sample use case library covers a wide range of application scenarios and business types, ensuring that the deficiencies of the initial use cases can be supplemented from multiple perspectives. Subsequently, through analyzing and integrating the sample use case set, the initial use cases are updated and extended as necessary to form a more comprehensive target use case set. Finally, this set is used to comprehensively test the target business to ensure that all key function points and business processes are fully verified, improving the integrity and effectiveness of the test.
[0042] In an exemplary embodiment, taking the scenario of an e-commerce system with multiple customer interaction functions as the target application as an example:
[0043] The initial use case set is mainly designed around basic functions such as product browsing, shopping cart management, and order submission. However, in in-depth testing, it is found that for special business scenarios such as promotion activity processing, inventory synchronization, and user evaluation feedback, the initial use cases do not fully cover.
[0044] At this time, the system will extract a set of use cases containing application features such as promotion management, inventory control, and user interaction from the sample use case library according to the characteristics of the e-commerce system. These sample use case sets are carefully designed based on the testing experience of previous similar e-commerce applications and can supplement the test points lacking in the initial use case set.
[0045] Through comparative analysis, the test cases that do not exist in the initial use case set are integrated into the initial use case set to form a target use case set, including but not limited to modifying test data, updating expected results, etc., to ensure that the newly added use cases match the environment and requirements of the target application.
[0046] Finally, the target use case set is used to comprehensively and deeply test the target services such as the promotion activity processing function, inventory management, and user evaluation feedback mechanism of the e-commerce system to ensure the stability and functional integrity of the system, and improve the user experience and business reliability.
[0047] Through the embodiments of the present application, an initial use case set corresponding to the target application is obtained, where the initial use case set is used to test whether the target application allows processing of the target service; in the case where the initial use case set does not meet the use case conditions, a set of sample use cases is determined from the sample use case library according to the application characteristics of the target application, where the sample use case library includes use case sets corresponding to multiple business applications with different application characteristics, and the use case conditions are used to determine whether the initial use case set allows covering the test scope of the target service; the initial use case set is updated according to the set of sample use cases to obtain a target use case set, and the target use case set is used to execute the test task corresponding to the target service. By means of refined management and dynamic adjustment of test cases, the purpose of improving the business test coverage rate is achieved, thereby realizing the technical effects of optimizing the functional regression test process and enhancing the test effectiveness, and further solving the technical problem of low business test coverage rate, ensuring that after software upgrade or function change, the business functions of each business subsystem can be comprehensively verified, and the stability of the system and the user experience are improved.
[0048] As an alternative solution, the above method further includes: in the case where the initial use case set does not meet the use case conditions, obtaining an application list and the application characteristics of the target application, where the application list includes multiple business applications, and the multiple business applications are respectively deployed in their corresponding business systems; determining a set of sample applications from the application list according to the application characteristics of the target application; determining a set of sample use cases from the sample use case library according to the set of sample applications, and updating the initial use case set according to the set of sample use cases to obtain a target use case set, where the set of sample use cases is the use case set corresponding to the set of sample applications in the sample use case library.
[0049] Optionally, in the embodiments of the present application, the above application list refers to a list containing multiple different business applications, which are deployed in their respective independent business systems and cover a wide range of business scenarios and functional requirements. The application characteristics of the target application refer to a set of information used to describe the characteristics of the target application in terms of functions, architecture, business processes, etc., including but not limited to business types, interaction methods, data processing requirements, etc. The sample applications refer to a set of business applications that are similar to the target application in certain application characteristics and can provide reference test cases. The sample use case set refers to the set of test cases in the sample use case library that corresponds to the determined sample applications and is used to test specific business scenarios and function points.
[0050] It should be noted that the construction of the application list can be sourced from the business system catalog within the enterprise, third-party application markets, or industry standard application classifications, and its content and structure should be adjusted according to the actual business environment and test requirements. The application characteristics of the target application should be detailed and accurate to quickly identify sample applications with similar characteristics. The selection and update process of the sample use case set can be automated or support manual review and modification to ensure the applicability and accuracy of the test cases, fully meet the test requirements of the target application, and improve the overall test efficiency and quality.
[0051] In an exemplary embodiment, taking the scenario of a fintech system involving multi-channel payment processing as the target application, the initial use case set can be designed around basic payment functions such as online payment and refund processing, but fails to fully consider special business scenarios such as cross-border payment and multi-currency support. After detecting this deficiency, the system determines a group of sample applications from the application list that include payment functions and particularly focus on cross-border payment and multi-currency support. Based on these sample applications, a sample use case set containing use cases such as cross-border payment testing and multi-currency transaction verification is selected from the sample use case library. These use cases are added to the initial use case set to update and expand its test scope, resulting in the target use case set. Using this set, the target business of the fintech system can be comprehensively and deeply tested to ensure the stability and functionality of the system in various payment scenarios.
[0052] Exemplarily, in the embodiments of the present application, the processing flow when the initial use case set does not meet the use case conditions is further refined.
[0053] Specifically, first, based on the unique application characteristics of the target application, a group of sample applications similar to or having common points with it are screened out from the above application list. This application list contains multiple business applications, each of which is deployed in a different business system and covers various business scenarios and functional requirements.
[0054] Next, according to this set of sample applications, the corresponding set of sample use cases is accurately selected from the sample use case library. The sample use case library is a repository that has accumulated a large number of test cases. The use case sets therein are designed for different business applications and can reflect the requirements of various business operations and functional tests. By corresponding with the sample applications, it can be ensured that the selected set of sample use cases closely fits the test requirements of the target application, especially those test points that are not fully covered in the initial set of use cases.
[0055] Finally, the initial set of use cases will be updated by integrating the test cases in the selected set of sample use cases to generate a more complete set of target use cases. This set can more comprehensively and accurately reflect the test scope of the target business, ensuring that all key functions and business processes can be effectively verified when performing the test tasks corresponding to the target business.
[0056] Through the embodiments of this application, even if the initial set of use cases is insufficient, it can be supplemented and optimized by introducing the set of sample use cases, ultimately achieving the purpose of improving the test quality and efficiency.
[0057] As an alternative solution, a set of sample applications is determined from the application list according to the application characteristics of the target application, including: determining the business domain to which the target application belongs according to the application characteristics of the target application; and determining the business applications in the business domain and in different business systems in the application list as the set of sample applications.
[0058] Optionally, in the embodiments of this application, the application characteristics of the above-mentioned target application refer to a set of characteristics describing the functions, architectures, business processes, etc. of the target application, including but not limited to business types, operation modes, data interaction methods, etc. The application list refers to a list containing multiple business applications, which are deployed in their respective independent business systems and cover different business domains and application scenarios. The business domain is a classification of the types of business processed by the application, such as payment processing, account management, risk management, etc.
[0059] It should be noted that the definitions and classifications of business systems are diverse. They can be divided according to the technical architecture or according to the business functions. This application does not make any limitations in this regard. The key is to ensure that the selected sample applications can provide test cases related to the target application. The business domain to which the target application belongs should be reasonably judged based on its application characteristics. At the same time, the selection of sample applications in the application list should also take into account the representativeness of different business systems to increase the diversity and comprehensiveness of test cases.
[0060] For example, when the initial use case set fails to fully cover the test requirements, we first determine the business domain to which the target application belongs based on its application characteristics, and then select business applications in the same business domain but deployed in different business systems from the application list as sample applications, so as to obtain test cases from more angles and enrich the target use case set.
[0061] In an exemplary embodiment, taking the application scenario of the bank head office and branch collaboration system as an example,
[0062] The target application is a newly developed loan approval system for the head office, and its application features include credit business processing, risk assessment, compliance inspection, etc. First, it was determined that this application belongs to the credit management business field, and then the credit business system, risk management system, compliance audit system, etc. deployed by each branch were selected from the application list as a group of sample applications.
[0063] Specifically, these sample applications are in different business systems (stored in different storage spaces), are all related to the credit management business field, and can provide a wealth of test cases covering various loan scenarios and risk management requirements. Therefore, based on these sample applications, corresponding test cases can be extracted from the sample use case library, the initial use case set of the target application can be updated, and a more comprehensive target use case set can be generated for performing functional regression testing of the loan approval system.
[0064] Through the embodiments of the present application, a sample application selection strategy based on business fields and application characteristics is adopted to achieve accurate supplementation and optimization of target application test cases, achieve the purpose of improving the coverage and quality of functional regression testing, and ensure the stability and reliability of loan approval business under the bank's head office and branch collaborative system.
[0065] As an optional scheme, the method also includes: when the test scopes of the initial use case set and the sample use case set are the same, determining that the initial use case set satisfies the use case condition; when the test scopes of the initial use case set and the sample use case set are different, determining that the initial use case set does not satisfy the use case condition.
[0066] Optionally, in the embodiment of the present application, the above test scope refers to the specific scope of business functions, operation processes, data processing, etc. that can be tested by the use case set, including but not limited to functional coverage, exception handling capabilities, performance indicators, etc. The use case condition is an evaluation standard for the completeness and effectiveness of the test scope, which is used to determine whether the use case set is suitable for performing a specific test task and covers all key test points.
[0067] It should be noted that the comparison of the test scope can be carried out in various ways, including but not limited to the comparison of the number of test cases, business coverage, exception handling capabilities, and the analysis of the overlap degree of function points between test case sets through intelligent algorithms. In addition, the setting of test case conditions can be based on specific business requirements, test objectives, and system characteristics, which are not limited in this application, aiming to ensure that test cases can accurately reflect the test requirements of the target business.
[0068] Exemplarily, when the test scopes of the initial test case set and the sample test case set are exactly the same, the system will automatically determine that the initial test case set meets the test case conditions and can be directly used for the test of the target business. On the contrary, if there are differences in their test scopes, that is, the sample test case set can provide additional test cases or cover test points missed by the initial test case set, the system will consider that the initial test case set does not meet the test case conditions and needs to be supplemented or adjusted to ensure the comprehensiveness and effectiveness of the test.
[0069] In an exemplary embodiment, taking the test scenario of a financial trading system as an example, the initial test case set focuses on the testing of core functions such as high-frequency trading, account management, and payment gateways. Through comparative analysis, the system finds a set of sample applications in the sample test case library, and its sample test case set contains additional test cases, such as cross-border transactions, fund settlement processes, and anti-fraud mechanisms. Since these cases are not covered in the initial test case set, the system determines that the initial test case set does not meet the test case conditions. Subsequently, the system integrates these cases in the sample test case set into the initial test case set to form a target test case set, ensuring that when the financial trading system conducts functional regression testing, it can comprehensively cover all key business scenarios and function points.
[0070] Through the embodiments of this application, by adopting the strategies of test scope comparison and test case condition evaluation, the automatic judgment of the effectiveness and integrity of the initial test case set is realized, achieving the purpose of optimizing the test process and ensuring the test quality, and providing a more efficient and accurate test solution for complex business scenarios such as financial trading systems.
[0071] As an alternative solution, when the test scopes of the initial use case set and the sample use case set are the same, determining that the initial use case set meets the use case conditions includes: when the test scope of the initial use case set is greater than that of the sample use case set, updating the sample use case set with the first test case and performing the test task with the initial use case set, where the first test case refers to a test case that belongs to the initial use case set but not to the sample use case set; when the test scope of the initial use case set is less than that of the sample use case set, updating the initial use case set with the second test case to obtain the target use case set and performing the test task with the target use case set, where the second test case refers to a test case that belongs to the sample use case set but not to the initial use case set; when the test scope of the initial use case set is equal to that of the sample use case set, performing the test task with the initial use case set.
[0072] Optionally, in the embodiments of the present application, the above-mentioned first test case refers to a specific test case that exists in the initial use case set but not in the sample use case set, and these use cases can supplement the test scope of the sample use case set. The second test case indicates that it exists in the sample use case set but not in the initial use case set and is used to expand the test coverage of the initial use case set. The use case condition refers to the evaluation criteria for the integrity and effectiveness of the use case set according to the test objectives and requirements, and is used to determine whether the use case set can meet the test requirements of a specific business scenario.
[0073] It should be noted that the comparison of the test scope and the evaluation of the use case conditions can be based on multiple dimensions, including but not limited to aspects such as function coverage, exception handling ability, and performance testing.
[0074] In addition, the determination of the first test case and the second test case involves cross-comparison, intelligent analysis, or manual judgment of use cases to identify the differences between use case sets, and the present application does not limit this.
[0075] Exemplarily, when the test scope of the initial use case set is greater than that of the sample use case set, the embodiments of the present application do not simply recognize the effectiveness of the initial use case set, but further use the first test case to enrich and optimize the sample use case set to ensure that it can cover a wider range of test scenarios, thereby enhancing the comprehensiveness and applicability of the sample use case set.
[0076] Conversely, when the test scope of the sample use case set is larger than that of the initial use case set, the system will update the initial use case set according to the second test cases to form a target use case set, ensuring that the initial use case set can completely cover all mandatory test function points. Only when the test scopes of the two are exactly the same, the initial use case set is directly used to execute the test task, avoiding unnecessary use case duplication and resource waste.
[0077] In an exemplary embodiment, taking the functional regression test of a bank credit system as an example, the initial use case set has covered functions such as loan application, approval process, and repayment processing, but does not include tests for special business scenarios such as overdue collection and credit assessment model update. By comparing with the sample use case set, the system identifies the second test cases in these special scenarios and integrates them into the initial use case set to form a target use case set, ensuring that the functional regression test of the credit system can comprehensively cover all business processes, including those details and abnormal situations overlooked in the initial stage, and improving the accuracy and reliability of the test.
[0078] Through the embodiments of the present application, by adopting the strategies of dynamic comparison of test scopes and intelligent update of use case sets, the technical effect of automatically optimizing the use case set according to business scenarios and test requirements is achieved, the purpose of improving test efficiency and ensuring the functional stability of software or systems is achieved, and a flexible and efficient test solution is provided for complex and changeable business environments.
[0079] As an optional solution, the obtaining of the initial use case set corresponding to the target application includes: determining a group of to-be-tested services in the target application; obtaining target to-be-tested services with an operation frequency greater than or equal to a preset frequency in the group of to-be-tested services; and determining the initial use case set based on the test cases corresponding to the target to-be-tested services.
[0080] Optionally, in the embodiments of the present application, the above-mentioned group of to-be-tested services refers to all business modules or business scenarios identified from the target application that need to be functionally tested, including but not limited to banking business functions such as account management, payment processing, and loan approval. The operation frequency represents the number of times a user or system executes a specific business operation within a certain time period, and the preset frequency is a predefined threshold used to screen out frequently used or highly critical business operations as the key focus objects for testing. The target to-be-tested services refer to the services with an operation frequency greater than or equal to the preset frequency, and these services need to be preferentially considered for formulating test cases due to their high usage frequency or business importance.
[0081] It should be noted that the statistics of operation frequencies and the setting of preset frequencies can be based on different business data and testing strategies, including analyzing historical user behaviors, business transaction volumes, system logs, etc., to determine which business operations have the greatest impact on system stability and user experience. This application does not limit this. Similarly, the determination of the target business to be tested can also be combined with expert evaluation, business rules, or intelligent algorithms to ensure that the selected test cases not only conform to the characteristics of high-frequency operations but also cover the critical paths and abnormal situations of the business.
[0082] Exemplarily, first, the system determines the list of businesses to be tested by analyzing the operation records of all businesses in the target application. Then, according to the preset operation frequency threshold, it filters out the target businesses to be tested whose operation frequencies are greater than or equal to the preset frequency. These businesses usually include key test points such as high-frequency transactions, important functions, and exception handling. Finally, the system integrates the test cases corresponding to the target businesses to be tested to form an initial test case set, ensuring that the test case set can comprehensively cover all test requirements of high-frequency operations.
[0083] In an exemplary embodiment, taking the business continuity test of a bank's head-office and branch collaborative system as an example, the system first identifies all businesses to be tested, such as online payment, account query, batch transfer, etc. Subsequently, based on the statistics of historical operation data, it determines that the preset frequency is business operations exceeding 5,000 times per day, thereby filtering out the target businesses to be tested, such as online payment and batch transfer. The system further extracts the test cases related to these target businesses to be tested from the test case library, including transaction verification, exception handling, performance testing, etc., to form an initial test case set for performing comprehensive functional regression testing to ensure the stability and reliability of the system in high-frequency operation scenarios.
[0084] Through the embodiments of this application, by adopting the business screening and test case integration method based on operation frequencies, accurate testing of high-frequency businesses in the target application is achieved, achieving the technical effect of improving testing efficiency and quality, and ensuring the stability and user experience of the head-office and branch collaborative system in key business operations.
[0085] In an exemplary embodiment, the execution method of the above tasks can be applied to the testing field of banking business systems. First, the following explanations are made for the professional terms appearing in the embodiments of this application:
[0086] Required test cases: Required test cases are the cases that need to be covered in the functional regression verification testing phase and should include important transactions and important batches. Important transactions should cover important business functions, main transaction channels, important transaction paths, and transactions that are likely to trigger production events.
[0087] Head-office and branch collaborative system: A system jointly developed by the head office and branches of a bank. The head office is responsible for developing the core functions, and the branches do front-end development and interface calls according to their respective situations.
[0088] Functional regression testing: It refers to retesting the mandatory test cases after modifying the old code to confirm that the modification has not introduced new errors or caused errors in other code.
[0089] First, different from the current mainstream functional regression testing method, that is, in the early stage, testers sort out the mandatory test cases according to the top 85% of high-frequency transactions in the system dimension. In the functional regression testing stage, all mandatory test cases of the system are tested in the physical subsystem dimension.
[0090] Based on this, considering that sorting out the mandatory test cases according to the top 85% of high-frequency transactions in the system dimension cannot accurately cover important business functions, and some important business functions cannot be accurately covered, resulting in insufficient testing and causing some production incidents, bringing losses to customers and the company.
[0091] Moreover, the mandatory test cases are sorted out by each branch independently. Once the enthusiasm of the staff is not high or they are not proficient in business, etc., it will lead to the quantity and quality of the mandatory test cases, and then some functions cannot be covered by the mandatory test cases, resulting in insufficient functional regression testing.
[0092] To overcome the above technical problems, the embodiment of the present application proposes an execution method for tasks. Figure 3 It is a schematic diagram of an optional execution method for tasks according to the embodiment of the present application. The overall process is as Figure 3 shown and mainly consists of the following contents:
[0093] S1. Form a mandatory test case asset library for each branch (the above sample use case library);
[0094] S2. Divide the business areas;
[0095] S3. Form important functions in the application dimension;
[0096] S4. Compare the missing important functions of each branch;
[0097] S5. Form a baseline of important functions for each branch and the corresponding mandatory test cases (the above sample use case set).
[0098] Exemplarily, forming a mandatory test case asset library for each branch includes:
[0099] Branch testers sort out the mandatory test cases according to the top 85% of high-frequency transactions in the system dimension. The case numbers and case names are filled in standardly, the case overviews are clearly described, the case steps are detailed and accurate, and the expected results are clear. Then, they submit the test cases to the asset library for in-library review. If the version verification test manager reviews and approves, the mandatory test cases are stored in the library; otherwise, they are returned.
[0100] Exemplarily, based on the physical subsystems to which the mandatory test cases belong, dividing the branch systems according to business areas and applications includes:
[0101] S2-1. Identify the business areas to which each branch physical subsystem belongs. Based on the name of each branch physical subsystem, the functions of the mandatory test cases, and the head office systems of the interfaces, confirm the business areas to which they belong, such as cash management, agency social security, agency finance, etc.
[0102] S2-2. Identify the applications involved within each branch physical subsystem. According to the functions of the mandatory test cases and the applications involved in the names of the mandatory test cases of the branch physical subsystems within the same business area, take the union of all applications to form the applications within the business area. For example, second-hand houses, commercial houses, etc. under the cash management area.
[0103] Exemplarily, the important functions formed in the application dimension include:
[0104] S3-1. Identify the important functions within the branch applications according to transaction frequency, etc. After distinguishing the branch physical subsystems according to business areas and applications, identify the important functions of each branch under different business areas and different applications.
[0105] S3-2. Form the important functions in the application dimension. After identifying the important functions of each branch under different business areas and different applications, merge the important functions of each branch under the same type of application, and delete the same important functions to form the important function baseline in the application dimension.
[0106] Exemplarily, the important functions missing from the applications within the business areas involved by each branch include:
[0107] S4-1. Compare the functions involved in the business areas and applications to which each branch physical subsystem belongs with the important function baseline in the application dimension. Based on the characteristic that the functions of the same application under the same business area of each branch are similar, compare the functions of the identified application of each branch with the formed important function baseline in the application dimension, find out the functions missing from the application of the branch, form the important functions missing in the application dimension of each branch, and then improve the mandatory test cases to increase the quality of the mandatory test cases.
[0108] S4-2. Handling of the important functions missing in the application dimension. Communicate with the branch testers whether the missing important function is involved in the application of the branch. For the branches that do not actually involve the missing function, store the original mandatory test cases in the database. For the branches missing this part of the important function, require them to add the mandatory test cases for the missing part of the function and store the updated mandatory test cases in the database.
[0109] Exemplarily, the baseline of the mandatory test cases for different business functions and different applications of the branches includes:
[0110] Based on the mandatory test cases updated by each branch, a baseline of mandatory test cases for different business functions and different applications of each branch is formed. For each physical subsystem put into production, the mandatory test cases are pushed to the test platform according to the applications involved, and functional regression testing of the mandatory test cases is carried out on the test platform.
[0111] Exemplarily, the baseline of mandatory test cases for different business functions and different applications can also be used as the basis for the review of mandatory test cases of branches in the later stage.
[0112] The baseline of mandatory test cases for different business functions and different applications is precipitated as an asset and used as the basis for the review of mandatory test cases of branches in the later stage. For the situation where there is no such business area or such application in this business area in the early stage, but the branch needs to add this application, a review of mandatory test cases is required. The functions and cases of the added application need to be compared with the mandatory test case assets formed in the early stage to check the online function situation and the corresponding mandatory test cases.
[0113] On the other hand, the branch can add a review of new applications or new functions added to applications. After comparing the review of adding new applications or new functions added to applications with the mandatory test cases of this existing application, for branches that cover all functions of this application, it is approved; for cases with missing functions, verify with the branch. If there is indeed no such function, it is approved. If there are missing functions, the branch needs to supplement the mandatory test cases. If the added function is not available in the original mandatory test case assets, update the mandatory test case assets as a new baseline.
[0114] It should be noted that one business area corresponds to one or more physical subsystems, and the branch system (the above-mentioned business system) can include multiple business areas.
[0115] Through the embodiments of the present application, the mandatory test cases of each branch are effectively sorted out for each application in each business area. The system characteristics of the overall branch system are that the head office opens the core transaction content, the branch makes interfaces, and the branch business has commonalities. According to this characteristic, the functions put into production of the systems launched by the branch can be compared according to the applications in the business area. By forming the function baselines of each application in each business area, the missing functions of each branch can be compared. The mandatory test cases in the functional regression stage are the basis for functional regression testing. Only when the cases are complete can the effectiveness of the functional regression testing be guaranteed.
[0116] By forming the functional baselines of each application in each business area and comparing them with the existing functions of each branch, it is used to find the missing functions of each branch. For branches with missing functions, mandatory test cases are added. This not only increases the number of mandatory test cases, but also supplements the missing functions, improves the mandatory test cases, and increases the quality of the mandatory test cases. By forming the functional baselines of each product in each business area, asset precipitation is formed, providing a basis for the later review of mandatory test cases of branches. By forming the functional baselines of each product in each business area and then comparing them with the existing functions of the branches, the missing functions of each branch are found. The branches add mandatory test cases and supplement them to the mandatory test case library, increasing the quality of the mandatory test case asset library. At the same time, the functional baselines are supplemented, showing a spiral upward trend. And in the case where this application function is not involved in the branch in the early stage, it can be compared with the mandatory test case baseline under this application to improve the relevant functions and provide a basis for the review of mandatory test cases.
[0117] It can be understood that in the specific implementation manners of the present application, data related to user information and the like is involved. When the above embodiments of the present application are applied to specific products or technologies, user permission or consent needs to be obtained, and the collection, use, and processing of relevant data need to comply with relevant laws, regulations, and standards of relevant countries and regions.
[0118] It should be noted that for the foregoing method embodiments, for the sake of simple description, they are all expressed as a series of action combinations. However, those skilled in the art should know that the present application is not limited by the described action sequence, because according to the present application, certain steps can be performed in other sequences or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily essential to the present application.
[0119] According to another aspect of the embodiments of the present application, there is also provided an execution device for implementing the task of the above-mentioned execution method of the task. As Figure 4 shown, the device includes:
[0120] An acquisition module 402, configured to acquire an initial use case set corresponding to a target application, where the above-mentioned initial use case set is used to test whether the above-mentioned target application can process a target service;
[0121] An update module 404, configured to determine a sample use case set from a sample use case library according to the application characteristics of the above-mentioned target application when the above-mentioned initial use case set does not meet the use case conditions, where the above-mentioned sample use case library includes use case sets corresponding to multiple business applications with different application characteristics, and the above-mentioned use case conditions are used to determine whether the above-mentioned initial use case set allows covering the test scope of the above-mentioned target service;
[0122] An execution module 406 is configured to update the above initial use case set according to the above sample use case set to obtain a target use case set, and execute a test task corresponding to the above target service using the above target use case set.
[0123] As an alternative solution, the above device is further configured to: when the above initial use case set does not meet the above use case conditions, obtain an application list and application characteristics of the above target application, where the above application list includes a plurality of the above service applications, and the plurality of the above service applications are respectively deployed in their corresponding service systems; determine a set of sample applications from the above application list according to the application characteristics of the above target application; determine a sample use case set from the above sample use case library according to the above set of sample applications, and update the above initial use case set according to the above sample use case set to obtain a target use case set, where the above sample use case set is a use case set corresponding to the above set of sample applications in the above sample use case library.
[0124] As an alternative solution, the above device is configured to determine a set of sample applications from the above application list in the following manner: determine the business domain to which the above target application belongs according to the application characteristics of the above target application; determine the above service applications that are in the above business domain and in different above service systems in the above application list as the above set of sample applications.
[0125] As an alternative solution, the above device is further configured to: when the test scopes of the above initial use case set and the above sample use case set are the same, determine that the above initial use case set meets the above use case conditions; when the test scopes of the above initial use case set and the above sample use case set are different, determine that the above initial use case set does not meet the above use case conditions.
[0126] As an optional scheme, the above-mentioned device is used to determine that the above-mentioned initial use case set satisfies the above-mentioned use case condition when the test ranges of the above-mentioned initial use case set and the above-mentioned sample use case set are the same in the following manner: when the test range of the above-mentioned initial use case set is larger than the test range of the above-mentioned sample use case set, use the first test case to update the above-mentioned sample use case set, and use the above-mentioned initial use case set to perform the above-mentioned test task, wherein the above-mentioned first test case represents the test case that belongs to the above-mentioned initial use case set and does not belong to the above-mentioned sample use case set; when the test range of the above-mentioned initial use case set is smaller than the test range of the above-mentioned sample use case set, use the second test case to update the above-mentioned initial use case set to obtain the above-mentioned target use case set, and use the above-mentioned target use case set to perform the above-mentioned test task, wherein the above-mentioned second test case represents the test case that belongs to the above-mentioned sample use case set and does not belong to the above-mentioned initial use case set; when the test range of the above-mentioned initial use case set is equal to the test range of the above-mentioned sample use case set, use the above-mentioned initial use case set to perform the above-mentioned test task.
[0127] As an optional solution, the above-mentioned device is used to obtain the initial use case set corresponding to the target application in the following manner: determine a group of services to be tested in the above-mentioned target application; obtain a target service to be tested whose operation frequency is greater than or equal to a preset frequency in the above-mentioned group of services to be tested; and determine the above-mentioned initial use case set based on the test cases corresponding to the above-mentioned target service to be tested.
[0128] In the embodiments of the present application, the term "module" or "unit" refers to a computer program or a part of a computer program with a predetermined function, and works together with other related parts to achieve a predetermined goal, and can be implemented in whole or in part by using software, hardware (such as processing circuits or memories) or a combination thereof. Similarly, a processor (or multiple processors or memories) can be used to implement one or more modules or units. In addition, each module or unit can be part of an overall module or unit that includes the function of the module or unit.
[0129] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.
[0130] According to one aspect of the present application, a computer program product is provided. The computer program product includes a computer program.
[0131] The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.
[0132] Figure 5 The structure block diagram of a computer system for implementing an electronic device according to an embodiment of the present application is schematically shown.
[0133] It should be noted that Figure 5 The computer system 500 of the illustrated electronic device is merely an example and should not impose any limitation on the functions and scope of use of the embodiments of the present application.
[0134] As Figure 5 shown, the computer system 500 includes a central processing unit 501 (CPU), which can perform various appropriate actions and processes according to the program stored in the read-only memory 502 (ROM) or the program loaded from the storage section 508 into the random access memory 503 (RAM). In the random access memory 503, various programs and data required for system operation are also stored. The central processing unit 501, the read-only memory 502, and the random access memory 503 are connected to each other via a bus 504. The input / output interface 505 (Input / Output interface, i.e., I / O interface) is also connected to the bus 504.
[0135] The following components are connected to the input / output interface 505: an input section 506 including a keyboard, a mouse, etc.; an output section 507 including, for example, a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker; a storage section 508 including a hard disk, etc.; and a communication section 509 including a network interface card such as a local area network card, a modem, etc. The communication section 509 performs communication processing via a network such as the Internet. A drive 510 is also connected to the input / output interface 505 as needed. A removable medium 511, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 510 as needed so that a computer program read from it can be installed into the storage section 508 as needed.
[0136] Specifically, according to the embodiments of the present application, the processes described in each method flowchart can be implemented as computer software programs. For example, the embodiments of the present application include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes program codes for performing the methods shown in the flowcharts. In such an embodiment, the computer program can be downloaded and installed from the network via the communication section 509, and / or installed from the removable medium 511. When the computer program is executed by the central processing unit 501, various functions defined in the system of the present application are executed.
[0137] In such an embodiment, the computer program can be downloaded and installed from a network through the communication section 509, and / or installed from the removable medium 511. When the computer program is executed by the central processing unit 501, various functions provided by the embodiments of the present application are executed.
[0138] According to another aspect of the embodiments of the present application, an electronic device for implementing the execution method of the above tasks is further provided. The electronic device may be Figure 1 the terminal device or server shown. This embodiment takes the electronic device as the terminal device as an example for illustration. As Figure 6 shown, the electronic device includes a memory 602 and a processor 604. A computer program is stored in the memory 602, and the processor 604 is configured to execute the steps in any of the above method embodiments through the computer program.
[0139] Optionally, in this embodiment, the above electronic device may be at least one of multiple network devices in a computer network.
[0140] Optionally, in this embodiment, the above processor may be configured to execute the methods in the embodiments of the present application through a computer program.
[0141] Optionally, those of ordinary skill in the art can understand that Figure 6 the structure shown is only schematic, Figure 6 and it does not limit the structure of the above electronic device. For example, the electronic device may further include more or fewer components (such as a network interface, etc.) than those shown in Figure 6 , or have a different configuration from that shown in Figure 6 .
[0142] Among them, the memory 602 can be used to store software programs and modules, such as program instructions / modules corresponding to the execution method and device of the tasks in the embodiments of the present application. The processor 604 executes various functional applications and data processing by running the software programs and modules stored in the memory 602, that is, implements the above execution method of the tasks. The memory 602 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memories, or other non-volatile solid-state memories. In some instances, the memory 602 may further include a memory remotely set relative to the processor 604, and these remote memories can be connected to the terminal through a network. Examples of the above network include but are not limited to the Internet, enterprise intranet, local area network, mobile communication network, and their combinations. Among them, the memory 602 can specifically but not limitedly be used to store information such as a target use case set, a sample use case set, and an initial use case set. As an example, as Figure 6As shown, the above-mentioned memory 602 may but is not limited to include the acquisition module 402, the update module 404, and the execution module 406 in the execution device of the above-mentioned task. In addition, it may also include but is not limited to other module units in the execution device of the above-mentioned task, which will not be elaborated in this example.
[0143] Optionally, the above-mentioned transmission device 606 is used to receive or send data via a network. Specific examples of the above-mentioned network may include a wired network and a wireless network. In one example, the transmission device 606 includes a network adapter (Network Interface Controller, NIC), which can be connected to other network devices and routers through a network cable, so as to communicate with the Internet or a local area network. In one example, the transmission device 606 is a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.
[0144] In addition, the above-mentioned electronic device further includes: a display 608, which is used to display the execution process of the above-mentioned test task; and a connection bus 610, which is used to connect each module component in the above-mentioned electronic device.
[0145] In other embodiments, the above-mentioned terminal device or server may be a node in a distributed system. Among them, the distributed system may be a blockchain system, and the blockchain system may be a distributed system formed by connecting the multiple nodes through network communication. Among them, the nodes can form a peer-to-peer network, and any form of computing device, such as an electronic device such as a server or a terminal, can become a node in the blockchain system by joining the peer-to-peer network.
[0146] According to one aspect of the present application, a computer-readable storage medium is provided. The processor of the electronic device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the electronic device executes the task execution methods provided in various optional implementation manners of the execution aspect of the above-mentioned task.
[0147] Optionally, in this embodiment, the above-mentioned computer-readable storage medium may be set to store the methods for executing the embodiments of the present application.
[0148] Optionally, in this embodiment, those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above-mentioned embodiments can be completed by a program instructing the relevant hardware of the terminal device. The program can be stored in a computer-readable storage medium, and the storage medium may include: a flash drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disc, etc.
[0149] The serial numbers of the embodiments of the present application above are only for description and do not represent the superiority or inferiority of the embodiments.
[0150] If the integrated units in the above embodiments are implemented in the form of software function units and sold or used as independent products, they can be stored in the above computer-readable storage media. Based on such an understanding, the technical solution of the present application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing one or more electronic devices to execute all or part of the steps of the methods described in the various embodiments of the present application.
[0151] In the above embodiments of the present application, the descriptions of the various embodiments have their own emphases. For the parts not detailed in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0152] In the several embodiments provided by the present application, it should be understood that the disclosed application program can be implemented in other ways. Among them, the device embodiments described above are only illustrative. For example, the division of the units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed couplings or direct couplings or communication connections to each other can be through some interfaces. The indirect couplings or communication connections of the units or modules can be in an electrical or other form.
[0153] The units described as separate components may or may not be physically separated. The components displayed as units may or may not be physical units, that is, they can be located in one place or distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0154] In addition, the functional units in the various embodiments of the present application can be integrated in a processing unit, or each unit can exist physically alone, or two or more units can be integrated in one unit. The above integrated units can be implemented in the form of hardware or in the form of software function units.
[0155] The above is only the preferred embodiment of the present application. It should be noted that for those of ordinary skill in the art, without departing from the principle of the present application, several improvements and refinements can be made, and these improvements and refinements should also be regarded as the protection scope of the present application.
Claims
1. A method for executing a task, characterized in that: include: Acquire an initial use case set corresponding to the target application, wherein the initial use case set is used to test whether the target application is allowed to process the target business; In the case that the initial use case set does not meet the use case condition, a sample use case set is determined from a sample use case library according to the application characteristics of the target application, wherein the sample use case library includes use case sets corresponding to a plurality of business applications with different application characteristics, and the use case condition is used to determine whether the initial use case set is allowed to cover the test scope of the target business; The initial use case set is updated according to the sample use case set to obtain a target use case set, and the target use case set is used to execute the test task corresponding to the target business.
2. The method according to claim 1, characterized in that The method further comprises: In the case that the initial use case set does not satisfy the use case condition, obtaining an application list and application characteristics of the target application, wherein the application list includes a plurality of the business applications, and the plurality of the business applications are respectively deployed in their corresponding business systems; Determining a group of sample applications from the application list according to application characteristics of the target application; A sample use case set is determined from the sample use case library according to the group of sample applications, and the initial use case set is updated according to the sample use case set to obtain a target use case set, wherein the sample use case set is a use case set corresponding to the group of sample applications in the sample use case library.
3. The method according to claim 2, characterized in that A group of sample applications is determined from the application list according to the application characteristics of the target application, including: Determining the business field to which the target application belongs according to the application characteristics of the target application; The business applications in the application list that are in the business domain and in different business systems are determined as the group of sample applications.
4. The method according to claim 1, characterized in that: The method further comprises: When the test scopes of the initial use case set and the sample use case set are the same, determining that the initial use case set meets the use case condition; When the test scopes of the initial use case set and the sample use case set are different, it is determined that the initial use case set does not satisfy the use case condition.
5. The method according to claim 4, characterized in that When the test scopes of the initial use case set and the sample use case set are the same, determining that the initial use case set meets the use case condition includes: In the case where the test scope of the initial use case set is larger than the test scope of the sample use case set, using a first test case to update the sample use case set, and using the initial use case set to perform the test task, wherein the first test case represents a test case that belongs to the initial use case set and does not belong to the sample use case set; In the case where the test scope of the initial use case set is smaller than the test scope of the sample use case set, the initial use case set is updated using a second test case to obtain the target use case set, and the test task is performed using the target use case set, wherein the second test case represents a test case that belongs to the sample use case set and does not belong to the initial use case set; When the test scope of the initial use case set is equal to the test scope of the sample use case set, the test task is executed using the initial use case set.
6. The method according to claim 1, characterized in that The obtaining of the initial use case set corresponding to the target application includes: Determining a group of services to be tested in the target application; Acquire a target service to be tested whose operation frequency is greater than or equal to a preset frequency from the group of services to be tested; The initial test case set is determined based on the test cases corresponding to the target business to be tested.
7. A task execution device, characterized in that: include: An acquisition module, used to acquire an initial use case set corresponding to a target application, wherein the initial use case set is used to test whether the target application can process a target business; An updating module, configured to determine a sample use case set from a sample use case library according to application characteristics of the target application when the initial use case set does not meet the use case condition, wherein the sample use case library includes use case sets corresponding to a plurality of business applications having different application characteristics, and the use case condition is used to determine whether the initial use case set is allowed to cover the test scope of the target business; The execution module is used to update the initial use case set according to the sample use case set to obtain a target use case set, and use the target use case set to execute the test task corresponding to the target business.
8. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored computer program, wherein the computer program can be executed by an electronic device to perform the method described in any one of claims 1 to 6.
9. 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 described in any one of claims 1 to 6 are implemented.
10. An electronic device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and the processor is configured to execute the method according to any one of claims 1 to 6 through the computer program.