Test management method and device based on operating environment-case, equipment and medium
By independently correlating the cases to be tested in multiple operating environments, the problem of difficulty in configuring and testing multiple software/application cases in the prior art is solved, and a more efficient and transparent testing process is achieved, improving the flexibility and accuracy of testing.
Patent Information
- Application Number
- CN202510329493.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-19
- Publication Date
- 2025-07-22
AI Technical Summary
The prior art is difficult to efficiently configure and test cases to be tested on multiple software/applications simultaneously, which affects the efficiency of automated testing.
By generating multiple run environments and independently associated each case to test into these environments, dynamically adjusting to adapt to the characteristics of different environments, output test status and pass rate.
It improves the flexibility and adaptability of testing, ensures the application and effectiveness of the cases to be tested in different operating environments, enhances the transparency and accuracy of the testing process, helps to promptly discover problems and improve product quality.
Smart Images

Figure CN120353720A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field of automated testing, and particularly to a test management method, apparatus, device, and medium based on a running environment - case. Background Art
[0002] In the field of information technology (IT) industry, before a software / application is officially released and put into market operation, operators will test it to ensure that all its functions can run properly as much as possible. Moreover, for general operators, it is quite common to have 4 - 5 test environments during the testing of software / applications to handle different testing stages and scenarios. Based on this, how to improve the testing efficiency of software / applications (especially more than one software / application to be tested) and provide corresponding solutions based on the test results are problems that need to be solved urgently by those skilled in the art.
[0003] Chinese Patent Application CN101135989A discloses an automated testing method and apparatus for a Web application system. This method needs to use a dedicated browser window for functional testing and cannot configure / test more than one test case to be tested simultaneously, which affects the overall efficiency of automated testing.
[0004] Chinese Patent Application CN104834595A discloses a visual automated testing method and system. This method requires establishing a graphical test interface to test the corresponding background test cases, and there is also a problem that multiple test cases cannot be configured / tested simultaneously. Summary of the Invention
[0005] Based on this, it is necessary to provide a test management method, apparatus, device, and medium based on a running environment - case for at least one of the above technical problems.
[0006] In a first aspect, the present application provides a test management method based on a running environment - case, which includes the following steps:
[0007] Generate a first quantity of running environments according to the user's configuration operation;
[0008] Obtain a second quantity of test cases to be tested input by the user;
[0009] Associate each test case to be tested with at least one running environment independently of each other, where, for each test case to be tested relative to each other, the combination of the running environments to which it is associated is the same or different;
[0010] Invoke each test case to be tested into each of at least one associated runtime environment and run it; and
[0011] Output the test status and / or pass rate of each test case to be tested in each of at least one associated runtime environment.
[0012] In one embodiment, the runtime environment includes a test environment, a pre-release environment, a gray test environment, and a production environment.
[0013] In another embodiment, the test status includes a completed status, an in-progress status, and an untested status.
[0014] In yet another embodiment, the in-progress status further includes a partially passed sub-status, a partially failed sub-status, a suspended sub-status, and a to-be-tested sub-status.
[0015] In yet another embodiment, each of the partially passed sub-status, the partially failed sub-status, the suspended sub-status, and the to-be-tested sub-status represents the test progress of each test case to be tested in each of at least one associated runtime environment in the form of a percentage.
[0016] In yet another embodiment, each test case to be tested is further associated with a privileged user, such that the steps of associating each test case to be tested, independently of each other, to at least one runtime environment, and the steps of invoking each test case to be tested into each of at least one associated runtime environment and running it can only be operated by the privileged user.
[0017] In a second aspect, the present application provides a test management apparatus based on a runtime environment - case, which includes:
[0018] A runtime environment module configured to provide a first number of runtime environments;
[0019] A case module configured to provide a second number of test cases to be tested;
[0020] An association module configured to associate each test case to be tested, independently of each other, to at least one runtime environment, wherein, for each test case relative to each other, the combination of the associated runtime environments is the same or different;
[0021] A running module configured to invoke each test case to be tested into each of at least one associated runtime environment and run it; and
[0022] An output module configured to output the test status and / or pass rate of each test case to be tested in each of at least one associated runtime environment.
[0023] In one embodiment, the association module is in an active state only when the case module is configured with at least one case to be tested.
[0024] In a third aspect, the present application provides a computer device, including a memory that stores computer-readable instructions; at least one processor; and the at least one processor is configured to, when executing the computer-readable instructions, implement at least one step of the test management method based on the running environment - case as described in the first aspect of the present application.
[0025] In a fourth aspect, the present application provides a non-volatile computer-readable storage medium that stores computer-readable instructions, and the computer-readable instructions are executed by at least one processor and are configured to implement at least one step of the test management method based on the running environment - case as described in the first aspect of the present application.
[0026] The test management method based on the running environment - case of the present application allows the cases to be tested to be dynamically associated with different running environments, so that the cases to be tested can be adapted and adjusted according to the characteristics of the running environment. Among them, such a dynamic association mechanism improves the flexibility and adaptability of testing, and ensures the applicability and effectiveness of the cases to be tested in different running environments. The test management device based on the running environment - case of the present application can record the status of each case to be tested and even its executor, enhancing the transparency of the test process, enabling each step of the test activity to be traced and audited, helping to discover and solve problems in a timely manner, and improving the accuracy and reliability of testing. Further, the test management and device based on the running environment - case of the present application can also count the execution results of the cases to be tested in each environment, providing data support for monitoring and controlling the verification results of each environment, enabling managers to make more accurate decisions based on quantitative data, effectively controlling the software / application release risk, and improving the overall quality of the product. Description of the Drawings
[0027] To more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the following drawings are only some embodiments of the present application. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings.
[0028] Figure 1 Shows a flowchart of the test management method based on the running environment - case according to an embodiment of the present application.
[0029] Figure 2 Shows a schematic diagram of the test management device based on the running environment - case according to another embodiment of the present application.
[0030] Figure 3 The internal structure diagram of a computer device according to another embodiment of the present application is shown. Detailed implementation manners
[0031] To make the objectives, technical solutions, and advantages of the present application clearer, 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. Apparently, the described embodiments are only a part rather than all of the embodiments of the present application. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in the present application without creative efforts shall fall within the protection scope of the present application.
[0032] In the description of the present application, it should be understood that the terms "first" and "second" are only used for descriptive purposes and cannot be construed as indicating or implying relative importance or implicitly specifying the quantity of the indicated technical features. Thus, features defined with "first" and "second" may explicitly or implicitly include one or more of such features. In the description of the present application, unless otherwise stated, the meaning of "a plurality of" is two or more.
[0033] In the description of the present application, it should be noted that unless otherwise clearly defined and limited, the terms "installed", "connected", and "coupled" should be understood in a broad sense. For example, it may be a fixed connection, a detachable connection, or an integral connection; it may be a mechanical connection or an electrical connection; it may be directly connected or indirectly connected through an intermediate medium, and it may be the internal communication of two components. For those of ordinary skill in the art, the specific meanings of the above terms in the present application can be understood according to specific circumstances.
[0034] In a first aspect, as Figure 1 shown, the present application provides a test management method based on a running environment - case. This method can be executed by a computer device of a software / application release agency. The computer device may be, for example, a server, a personal computer, a tablet computer, a portable intelligent terminal, and so on. The method includes:
[0035] S1. Generate a first quantity of running environments according to the configuration operations of a user.
[0036] In daily test work, some defects of a software / application may not be discovered due to problems such as operation and maintenance configuration problems, running environment differences, missed test problems, and insufficient evaluation of the modification scope, resulting in frequent post - release errors and the need for rollback of the software / application. Therefore, it is very necessary to test the software / application to be released in different running environments.
[0037] Generally, the operator is equipped with 4 - 5 operating environments to cope with different test stages and scenarios. In this embodiment, 4 operating environments are equipped, namely the test environment, the pre - release environment, the gray - scale test environment, and the production environment, where:
[0038] - Test environment: It is used for testing software / applications during the test stage. However, in this environment, the software / application does not have to be jointly debugged with the external, that is, the test environment is the first step of testing;
[0039] - Pre - release environment: The image that has been tested in the test environment is placed in the pre - release environment for joint debugging with the external;
[0040] - Gray - scale test environment: To a certain extent, it is equivalent to the production environment, and what it affects is also the production environment. Its scope is wider and more real than the test environment. In fact, it is a small - scale production environment;
[0041] - Production environment: That is, the online environment, the environment where users use (the software / application),
[0042] which needs to be maintained by specific personnel, and ordinary people do not have the permission to modify.
[0043] Furthermore, in other embodiments, the operator can also be equipped with other operating environments, including the functional test environment and the automated test environment, where:
[0044] - Functional test environment: It is mainly used for verifying new functional versions;
[0045] - Automated test environment: It is mainly an environment built for the automated testing of the stable version of (the software / application).
[0046] S2. Obtain the second quantity of test cases input by the user.
[0047] This method supports the user to easily add test cases, including but not limited to software / applications to be tested. In the case where no test cases are added, the association operation between the operating environment and the cases is unavailable. When the user adds test cases to the computer device (such as a personal computer, etc.) running this method, all the added test cases can be displayed in the case list. Even more, with the help of this case list, the user can add and batch - operate on test cases.
[0048] S3. Independently associate each test case with at least one operating environment relative to each other.
[0049] When the user has added / configured a first quantity of running environments and a second quantity of test cases to be tested, the association operation between the running environments and the cases can be performed. For example, in this case list, the user can either individually associate a certain test case to the running environment it must go through, or batch-operate on all or some of the test cases to be tested and associate them to the running environments they respectively need to go through. Even vice versa, the user can also individually or batch-operate on a certain / some / all of the test cases to be tested to decouple them from their respective associated running environments.
[0050] It should be noted that for each test case to be tested relative to each other, the combinations of the running environments they are associated with are the same or different. For example, the first test case to be tested can be associated with the test environment, the pre-release environment, and the gray-scale test environment; the second test case to be tested can also be associated with the test environment, the pre-release environment, and the gray-scale test environment; the third test case to be tested can be associated with the test environment, the gray-scale test environment, and the production environment; the fourth test case to be tested can be associated with all 4 running environments, namely the test environment, the pre-release environment, the gray-scale test environment, and the production environment. Therefore, the combinations of the running environments associated with each test case to be tested can be matched by the user as needed.
[0051] Furthermore, each test case to be tested is further associated with authorized users, such that the step of associating each test case to be tested to at least one running environment independently of each other, i.e., step S3, and the step of invoking each test case to be tested into each of the at least one running environment it is associated with and running it, i.e., step S4, can only be operated by authorized users, which will be further described below. Even more, users without permission cannot change the associated authorized users of the test case to be tested or the corresponding status of the test case. On the other hand, the operation of adding or removing test cases to be tested from the computer device running this method can also only be performed by authorized users.
[0052] S4. Invoke each test case to be tested into each of the at least one running environment it is associated with and run it.
[0053] After the authorized user associates each test case to be tested to at least one running environment, the authorized user can then, as needed, invoke the second quantity of test cases to be tested into the combination of the associated running environments for subsequent testing. For example, the authorized user can select a certain test case to be tested in the case list and view the combination of the associated running environments. On this basis, the authorized user can continue to operate on the entry of this test case to be tested, such as clicking, to invoke this test case to be tested into the corresponding running environment for testing.
[0054] S5. Output the test status and / or pass rate of each test case to be tested in each of at least one associated running environment.
[0055] When a test case to be tested is running / being tested in a corresponding running environment, it can be imagined that each test case to be tested will not be tested instantaneously but will take a rather long period of time. Further, considering the performance of the computer device running this method, it may be impractical for it to run / test multiple test cases simultaneously. Therefore, it is acceptable for an authorized user to edit the test order of all test cases to be tested and run / test the test cases one by one in this order.
[0056] Since each test case to be tested is called into the running environment one by one and in sequence for testing, as the name implies, the states of each test case to be tested are different from each other. The test status of each test case to be tested may include a completed state, a state in progress, and an untested state. Further, the state in progress further includes a partially passed sub-state, a partially failed sub-state, a suspended sub-state, and a to-be-tested sub-state. Among them, each of the partially passed sub-state, the partially failed sub-state, the suspended sub-state, and the to-be-tested sub-state represents the test progress of each test case to be tested in each of at least one associated running environment in the form of a percentage. For example, for a certain test case to be tested, its partially passed sub-state reaches 8%, its partially failed sub-state reaches 17%, its suspended sub-state reaches 8%, and its to-be-tested sub-state reaches 67%. Thus, the authorized user can clearly understand the test progress of the current test case to be tested. Even more, based on this, the authorized user can further design a bug-finding program for the test method and use the percentage values of each of the partially passed sub-state, the partially failed sub-state, the suspended sub-state, and the to-be-tested sub-state to locate the bugs in the current test case to be tested.
[0057] In a second aspect, the present application provides a test management device based on a running environment - case, as Figure 2 shown, which includes a running environment module 10, a case module 20, an association module 30, a running module 40, and an output module 50, where:
[0058] The running environment module 10 is configured to provide a first number of running environments;
[0059] The case module 20 is configured to provide a second number of test cases to be tested;
[0060] The association module 30 is configured to independently associate each test case to be tested with at least one running environment relative to each other, where, relative to each other, the combinations of the running environments associated with each test case to be tested are the same or different;
[0061] A running module 40, configured to call each test case to be tested into each of at least one associated running environment and run it; and
[0062] An output module 50, configured to output the test status and / or pass rate of each test case to be tested in each of at least one associated running environment.
[0063] Furthermore, the association module 30 is in an active state only when the case module 20 is configured with at least one test case to be tested. In other words, in the case where no test case to be tested is added, the association operation between the running environment and the case in the association module 30 is in an unavailable state.
[0064] In a third aspect, as Figure 3 shown, the present application provides a computer device, which includes a memory, a processor, and computer-readable instructions stored on the memory and executable on the processor. When the processor executes the computer-readable instructions, at least one step of the test management method based on the running environment - case provided in any embodiment of the first aspect of the present application is implemented.
[0065] In an embodiment, the computer device may be a server. The computer device includes a processor, a memory, a network interface, and a database connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and computer-readable instructions. The internal memory provides an environment for the operation of the operating system and computer-readable instructions in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer-readable instructions are executed by the processor, a method for generating an electronic fence for an area of interest is implemented.
[0066] In a fourth aspect, the present application provides a computer-readable storage medium, on which computer-readable instructions are stored. When the computer-readable instructions are executed by a processor, at least one step of the test management method based on the running environment - case provided in any embodiment of the first aspect of the present application is implemented.
[0067] Those of ordinary skill in the art can understand that all or part of the processes of implementing the methods in the above embodiments can be completed by instructing relevant hardware through computer-readable instructions. The above computer-readable instructions can be stored in a non-volatile computer-readable storage medium. When the computer-readable instructions are executed, they can include the processes of the embodiments of the above methods. Among them, any reference to a memory, storage, database, or other medium used in the various embodiments provided in the present application can include non-volatile and / or volatile memories. Non-volatile memories can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memories can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), Rambus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and Rambus dynamic RAM (RDRAM), etc.
[0068] The technical features of the above embodiments can be combined arbitrarily. For the sake of brevity of description, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, it should be considered as the scope recorded in this specification.
[0069] The above embodiments only represent several implementation manners of the present application. Their descriptions are relatively specific and detailed, but they should not be construed as limiting the scope of the invention patent. It should be noted that for those of ordinary skill in the art, without departing from the concept of the present application, several modifications and improvements can still be made, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the appended claims.
[0070] It should be understood that the above drawings and the specific embodiments described are only exemplary embodiments of the present application, rather than an exhaustive list of possible embodiments of the present application. Those skilled in the art can make various modifications to the above specific embodiments within the protection scope of the present application without departing from the gist of the present application.
Claims
1. A test management method based on a running environment - case, characterized in that Comprising the following steps: Generate a first quantity of operating environments according to the configuration operations of the user; Obtain a second quantity of test cases to be tested input by the user; Associate each of the test cases to be tested, independently of each other, to at least one of the operating environments, wherein, for each of the test cases to be tested relative to each other, the combination of the operating environments to which it is associated is the same or different; Invoke each of the test cases to be tested into each of the at least one operating environment to which it is associated and run; and Output the test status and / or pass rate of each of the test cases to be tested in each of the at least one operating environment to which it is associated.
2. The test management method according to claim 1, characterized in that, The operating environment includes a test environment, a pre-release environment, a gray-scale test environment, and a production environment.
3. The test management method according to claim 1, wherein The test status includes a completed status, an in-progress status, and a not-tested status.
4. The test management method according to claim 3, characterized in that The in-progress status further includes a partially-passed sub-status, a partially-failed sub-status, a suspended sub-status, and a to-be-tested sub-status.
5. The test management method according to claim 4, wherein, Each of the partially-passed sub-status, the partially-failed sub-status, the suspended sub-status, and the to-be-tested sub-status represents the test progress of each of the test cases to be tested in each of the at least one operating environment to which it is associated in the form of a percentage.
6. The test management method according to claim 1, characterized in that Each of the test cases to be tested is further associated with a privileged user, such that the steps of associating each of the test cases to be tested, independently of each other, to at least one of the operating environments, and the step of invoking each of the test cases to be tested into each of the at least one operating environment to which it is associated and running can only be operated by the privileged user.
7. A test management device based on a running environment - case, characterized in that, Comprising: An operating environment module configured to provide a first quantity of operating environments; A case module configured to provide a second quantity of test cases to be tested; An association module configured to associate each of the test cases to be tested, independently of each other, to at least one of the operating environments, wherein, for each of the test cases to be tested relative to each other, the combination of the operating environments to which it is associated is the same or different; An operation module configured to invoke each of the test cases to be tested into each of the at least one operating environment to which it is associated and run; and An output module configured to output the test status and / or pass rate of each of the test cases to be tested in each of the at least one operating environment to which it is associated.
8. The test management device according to claim 7, wherein, The association module is in an active state only when the case module is configured with at least one of the test cases to be tested.
9. A computer device, characterized in that, Comprising: A memory that stores computer-readable instructions; At least one processor; The at least one processor is configured to, when executing the computer-readable instructions, implement at least one step of the test management method based on operating environment - case as described in any one of claims 1 - 6.
10. A non-volatile computer-readable storage medium stores computer-readable instructions, characterized in that, The computer-readable instructions are executed by at least one processor and are configured to implement at least one step of the test management method based on operating environment - case as described in any one of claims 1 - 6.
Citation Information
Patent Citations
Automatization test method and device for Web applied system
CN101135989A
Visual automatic test method and system
CN104834595A