A log automatic detection method, device, equipment and medium
Patent Information
- Application Number
- CN202310313820.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-28
- Publication Date
- 2026-09-08
- Estimated Expiration
- 2043-03-28
AI Technical Summary
[0004]所以,现在的测试日志审查方式比较耗时,效率极低,同时测试日志审查工作的质量无法保证;以及测试日志检测工作局限于测试工程师的经验、水平及责任心;同时现在的测试日志审查方式缺乏对其他类似项目或产品的已知测试需求问题点的排查,以及测试发现问题点后处理存在滞后性,对于引发此操作的测试步骤需要重新排查,增加了工作量,缺乏时效性
[0060]本申请实施例提供的技术方案是基于已知测试缺陷或问题点的日志自动审查方法,通过构建、分析以往类似产品的测试问题点库,构建已知缺陷在测试日志中对应的标识;测试日志排查采用自动化的手段,在排查原有测试日志的同时,对目标产品测试需求已知问题点的日志标识一起排查,提升了测试日志排查的质量及效率。
Smart Images

Figure CN116340042B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of testing technology, and in particular to an automatic log detection method, apparatus, device, and medium. Background Technology
[0002] Currently, to ensure system stability and robustness, the testing process, in principle, requires reviewing the test logs for all test steps to check for errors. Existing technology involves test engineers exporting and reviewing the test logs after executing a test project for a period of time. This is not only labor-intensive but also tedious; furthermore, because it is done manually, it is limited by the testing skills and experience of a single test engineer.
[0003] Currently, all product test log checks are done manually. After completing a day's or a phase of testing, testers export the test logs and check them manually. Because the test log data is quite large, they use mouse shortcuts to directly search for error characters.
[0004] Therefore, the current test log review method is time-consuming and inefficient, and the quality of the test log review work cannot be guaranteed. Furthermore, the test log inspection work is limited by the experience, skill level, and sense of responsibility of the test engineers. At the same time, the current test log review method lacks the investigation of known test requirement issues in other similar projects or products, and the handling of issues discovered during testing is delayed. The test steps that triggered this operation need to be re-examined, which increases the workload and lacks timeliness. Summary of the Invention
[0005] To overcome the aforementioned technical deficiencies, the purpose of this application is to provide an automatic log detection method, apparatus, device, and medium. The method includes: creating a correspondence table between test requirements of similar products and known test problem log identifiers for those similar product test requirements; obtaining test requirements for a target product; confirming the known test problem log identifiers corresponding to the target product test requirements based on the correspondence table; adding the known test problem log identifiers to the target product test requirements; and detecting the target product test logs containing the added known test problem log identifiers according to detection rules. This application checks both existing test logs and the known problem log identifiers for the target product test requirements, improving the quality and efficiency of test log checking.
[0006] The specific technical solutions provided in this application are as follows:
[0007] Firstly, an automatic log detection method is provided, the method comprising:
[0008] Create a table mapping test requirements for similar products to known test issue log identifiers for similar products;
[0009] Obtain the testing requirements for the target product;
[0010] Based on the correspondence table between the test requirements of similar products and the known test problem log identifiers of the test requirements of similar products, the known test problem log identifiers corresponding to the test requirements of the target product are confirmed.
[0011] Add the known test problem log identifiers corresponding to the target product test requirements to the target product test log list;
[0012] The target product test logs, marked with known test problem logs indicating the target product test requirements, are tested according to the testing rules.
[0013] Furthermore, the mapping table between the test requirements for creating similar products and the known test issue log identifiers for the test requirements of similar products includes:
[0014] Create a baseline library of test requirements for similar products;
[0015] Create a table mapping the test requirements of similar products to the known test issues of similar product test requirements.
[0016] Furthermore, before creating the correspondence table between the test requirements of similar products and the known test problem points of the test requirements of similar products, the following steps are included:
[0017] The test issues of similar products were identified, and a database of known test issues corresponding to the test requirements of similar products was created.
[0018] Furthermore, the creation of the correspondence table between the test requirements of similar products and the known test problem points of the test requirements of similar products includes:
[0019] Based on the baseline library of test requirements for similar products and the database of known problem points corresponding to the test requirements of similar products, create a table showing the correspondence between the test requirements of similar products and the known test problem points of the test requirements of similar products.
[0020] Furthermore, the creation of the correspondence table between the test requirements of similar products and the known test problem points of the test requirements of similar products also includes:
[0021] When the known test problem occurs in several test requirements of similar products, the known test problem is added to the list of similar product test requirements involving the problem.
[0022] Furthermore, after creating the correspondence table between the test requirements of similar products and the known test problem points of the test requirements of similar products, the method further includes:
[0023] Confirm the log identifiers in the log identifier library corresponding to the known test issues for the similar product test requirements.
[0024] Create a table mapping test requirements for similar products to known test issue log identifiers for similar product test requirements.
[0025] Further, after detecting the target product test logs with known test problem log identifiers added according to the detection rules, the process includes:
[0026] When test problems or error logs are detected, the system will issue an alarm and locate the cause of the test problem in the target product.
[0027] Secondly, an automatic log detection device is provided, the device comprising:
[0028] Create a module to create a mapping table between test requirements of similar products and known test issue log identifiers of test requirements of similar products;
[0029] The acquisition module is used to acquire the testing requirements of the target product.
[0030] The confirmation module is used to confirm the known test problem log identifiers corresponding to the test requirements of the target product based on the correspondence table between the test requirements of similar products and the known test problem log identifiers of the test requirements of similar products.
[0031] The processing module is used to add the known test problem log identifiers corresponding to the target product test requirements to the target product test log list;
[0032] The detection module is used to detect the target product test logs that include known test problem log identifiers for the target product test requirements, according to the detection rules.
[0033] Thirdly, a computer device is provided, the device comprising:
[0034] A memory, a processor, and a computer program stored on the memory, wherein the processor executes the computer program to implement the steps of the automatic log detection method as described in any of the first aspects.
[0035] Fourthly, a computer storage medium is provided, the medium comprising:
[0036] It stores a computer program that, when executed by the memory, implements the steps of the automatic log detection method described in any of the first aspects.
[0037] Compared with existing technologies, the automatic log detection method provided in this application is applied to products. The method includes: creating a correspondence table between test requirements of similar products and known test problem log identifiers for similar product test requirements; obtaining test requirements for a target product; confirming the known test problem log identifiers corresponding to the target product test requirements based on the correspondence table; adding the known test problem log identifiers corresponding to the target product test requirements to the target product test log list; and detecting the target product test logs with the added known test problem log identifiers according to detection rules. This application is an automatic log review method based on known test defects or problems. By constructing and analyzing a database of test problem points from similar products, it constructs identifiers corresponding to known defects in test logs. The test log review uses automated methods, reviewing existing test logs while simultaneously reviewing the log identifiers of known problem points for the target product test requirements, thus improving the quality and efficiency of test log review.
[0038] The technical solution provided in this application can solve the problems that test log review is time-consuming and inefficient, and that the quality of test log review is greatly affected by the level of test engineers. At the same time, this application introduces the correspondence analysis between known defects and log identifiers for previous similar product testing requirements, and takes the key log identifier fields of known defects as the review target, thus enriching the test log review methods.
[0039] The technical solution provided in this application addresses the problem of low timeliness in test log detection and analysis. Furthermore, this application provides real-time detection of test logs and sets up an alarm mechanism when problems are detected in the logs.
[0040] The technical solution provided in this application constructs a correspondence between test requirements, known defects, and log flags for similar products, enabling the transfer of known defect flags between product project test logs. It also adds known defect log flags for similar product test requirements to the test log review list, thus enriching the test log detection methods. Attached Figure Description
[0041] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0042] Figure 1 This is a first flowchart of the automatic log detection method provided in Embodiment 1 of this application;
[0043] Figure 2 This is a second flowchart of the automatic log detection method provided in Embodiment 2 of this application;
[0044] Figure 3 This is a flowchart illustrating the automatic log detection method provided in Embodiment 2 of this application.
[0045] Figure 4 This is a structural diagram of the automatic log detection device provided in Embodiment 3 of this application;
[0046] Figure 5 This is an exemplary system provided for Embodiment 5 of this application, which can be used to implement the various embodiments described in this application. Detailed Implementation
[0047] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0048] It should be noted that, unless the context explicitly requires it, the words "comprising," "including," and similar terms in the entire specification and claims should be interpreted as including rather than exclusive or exhaustive; that is, meaning "including but not limited to."
[0049] Furthermore, in the description of this application, unless otherwise stated, "a plurality of" means two or more.
[0050] Example 1
[0051] This application provides an automatic log detection method, such as... Figure 1 As shown, the method includes:
[0052] Create a table mapping test requirements for similar products to known test issue log identifiers for similar products;
[0053] Obtain the testing requirements for the target product;
[0054] Based on the correspondence table between the test requirements of similar products and the known test problem log identifiers of the test requirements of similar products, the known test problem log identifiers corresponding to the test requirements of the target product are confirmed.
[0055] Add the known test problem log identifiers corresponding to the target product test requirements to the target product test log list;
[0056] The target product test logs, marked with known test problem logs indicating the target product test requirements, are tested according to the testing rules.
[0057] Specifically, this application proposes an automatic detection method for test logs based on known problem points in similar product testing requirements. By constructing and analyzing a database of test problem points from similar products in the past, the method constructs the corresponding identifiers of known defects in the test logs. The test log screening adopts automated means. While screening the test logs of the target product for errors or logs at the above-level, the method also screens the log identifiers of known problem points in the test requirements of the target product, thereby improving the quality and efficiency of test log screening.
[0058] Here, the target product can be a product modified from the similar product, such as modifying a component material or a component structure of the similar product, but the overall main components are the same as the similar product; that is, the similar product is a product with a different model than the target product, but the main components are the same, and the secondary components are different in material or structure.
[0059] The beneficial effects of the technical solutions provided in this application are:
[0060] The technical solution provided in this application is an automatic log review method based on known test defects or problem points. By constructing and analyzing a test problem point library of similar products in the past, the method constructs the corresponding identifiers of known defects in the test logs. The test log review adopts automated means, and while reviewing the original test logs, it also reviews the log identifiers of known problem points of the target product test requirements, thereby improving the quality and efficiency of test log review.
[0061] The technical solution provided in this application can solve the problems that test log review is time-consuming and inefficient, and that the quality of test log review is greatly affected by the level of test engineers. At the same time, this application introduces the correspondence analysis between known defects and log identifiers for previous similar product testing requirements, and takes the key log identifier fields of known defects as the review target, thus enriching the test log review methods.
[0062] Example 2
[0063] This application provides an automatic log detection method, such as... Figure 2 As shown, the method includes:
[0064] Step S01: Create a table that maps test requirements for similar products to known test issue log identifiers for test requirements of similar products.
[0065] Step S01 also includes:
[0066] Step S011: Create a baseline library of test requirements for similar products.
[0067] Understandably, when building a table mapping test requirements for similar products to known test issue log identifiers for similar products, it is necessary to first build a baseline library of test requirements for similar products corresponding to the product in question. The naming principle for test requirements is as follows: R_module_name_requirement_number, such as R_login_001. The naming of requirements follows the principle of uniqueness.
[0068] The requirement baseline is defined by drawing a "line" for all fixed requirements, indicating that these requirements have been determined. Adding new requirements or modifying existing requirements must be done through the requirement change process. The requirement baseline is usually incorporated into configuration management in the form of a document.
[0069] Step S012: Organize the test issues of similar products and create a database of known test issues corresponding to the test requirements of similar products.
[0070] Specifically, we will sort out the known defects or issues corresponding to the testing requirements of similar products in the past and create a database of known testing issues corresponding to the testing requirements of similar products.
[0071] Step S013: Create a table showing the correspondence between the test requirements of the similar products and the known test problem points of the test requirements of the similar products.
[0072] Specifically, a correspondence table is constructed between the test requirements of similar products and the known test issues of the test requirements of similar products (the correspondence is 1:n). The known test issues of the test requirements of similar products are named as follows: B_R_Module Name_Requirement Number_Defect Number. For example: B_R_login_001_001.
[0073] Step S013 also includes:
[0074] Step S0131: Create a correspondence table between the test requirements of similar products and the known test problem points of similar products, based on the baseline library of test requirements for similar products and the database of known problem points corresponding to the test requirements of similar products.
[0075] Step S0132: When the known test problem occurs in several test requirements of similar products, the known test problem is added to the list of similar product test requirements involving the problem.
[0076] Specifically, when a known defect or known problem involves multiple test requirements, the known defect or known problem is added to the list of test requirements for similar products that involve the problem.
[0077] Step S014: Confirm the log identifiers in the log identifier library corresponding to the known test problem points of the similar product test requirements.
[0078] Create a table mapping test requirements for similar products to known test issue log identifiers for similar product test requirements.
[0079] Specifically, analyze the manifestation or identification of known test issues in the test log for similar product testing requirements, and define them as Marks. The naming principle is as follows: M_B_R_module_name_requirement_number_defect_mark_number. For example, M_B_R_login_001_001_001.
[0080] Step S02: Obtain the testing requirements for the target product.
[0081] Specifically, at the beginning of a product project, the product manager pulls the corresponding test requirements for the target product from the target product test requirement baseline library.
[0082] Step S03: Based on the correspondence table between the test requirements of similar products and the known test problem log identifiers of the test requirements of similar products, confirm the known test problem log identifiers corresponding to the test requirements of the target product.
[0083] Specifically, the test engineer needs to retrieve the Mark corresponding to the known test problem log identifier of the target product test requirement from the correspondence table between the test requirements of similar products and the known test problem log identifiers of the test requirements of similar products.
[0084] Step S04: Add the known test problem log identifiers corresponding to the target product test requirements to the target product test log list.
[0085] Specifically, the system automatically adds the known test problem log identifiers (mark) corresponding to the existing test requirements of the target product to the target product test log list. While checking whether the original test logs contain errors or logs at the higher levels, the system also checks the log identifiers of the known problem points of the target product test requirements.
[0086] Step S05: Detect the target product test logs that include the known test problem log identifiers for the target product test requirements according to the detection rules.
[0087] Specifically, once the testing begins, the system performs real-time testing on the target product test logs, which include known test problem logs indicating the target product's test requirements, according to the testing rules.
[0088] Step S06: When a test problem or error log occurs, the system will issue an alarm and locate the cause of the test problem of the target product.
[0089] Specifically, when a corresponding test defect marker is detected, the system promptly displays a dialog box and an alert, facilitating the real-time discovery and root cause identification of the test defect bug in the target product. This automates test log detection and enables the "transfer" of known defects corresponding to similar product testing requirements between different product test projects, improving the scientific rigor and efficiency of test log detection.
[0090] like Figure 3 The diagram shows the specific flowchart of the automatic log detection in this application. The technical solution of this application creates a correspondence table between test requirements of similar products and known test problem log identifiers of similar product test requirements; obtains the test requirements of the target product; confirms the known test problem log identifiers corresponding to the test requirements of the target product according to the correspondence table between the test requirements of similar products and known test problem log identifiers of similar product test requirements; adds the known test problem log identifiers corresponding to the test requirements of the target product to the test log list of the target product; and detects the target product test logs with the added known test problem log identifiers of the test requirements of the target product according to the detection rules.
[0091] It is understandable that this application constructs a test requirement baseline library and a known defect library, and associates the two to achieve the transfer of test requirements corresponding to known defects between different product projects; by analyzing the key characters or identifiers of known defects in the test logs, the purpose of identifying known defects in test requirements is achieved, and the log identifiers of known defects are added to the original test log list, and the test logs are automatically detected in real time, and an alarm is issued in real time when a problem is detected.
[0092] The automatic log detection method provided in this application embodiment can be improved and optimized in several ways without departing from the technical solution of this application, and these improvements and optimizations should also be considered within the protection scope of this application.
[0093] The beneficial effects of the technical solutions provided in this application are:
[0094] The technical solution provided in this application addresses the problem of low timeliness in test log detection and analysis. Furthermore, this application provides real-time detection of test logs and sets up an alarm mechanism when problems are detected in the logs.
[0095] The technical solution provided in this application constructs a correspondence between test requirements, known defects, and log flags for similar products, enabling the transfer of known defect flags between product project test logs. It also adds known defect log flags for similar product test requirements to the test log review list, thus enriching the test log detection methods.
[0096] Example 3
[0097] This application provides an automatic log detection device, such as... Figure 4 As shown, the device includes a creation module, an acquisition module, a confirmation module, a processing module, a detection module, and an alert module.
[0098] In this embodiment, a creation module is used to create a correspondence table between test requirements of similar products and known test problem log identifiers of test requirements of similar products;
[0099] The acquisition module is used to acquire the testing requirements of the target product.
[0100] The confirmation module is used to confirm the known test problem log identifiers corresponding to the test requirements of the target product based on the correspondence table between the test requirements of similar products and the known test problem log identifiers of the test requirements of similar products.
[0101] The processing module is used to add the known test problem log identifiers corresponding to the target product test requirements to the target product test log list;
[0102] The detection module is used to detect the target product test logs that include known test problem log identifiers for the target product test requirements, according to the detection rules.
[0103] Furthermore, a module is created to create a baseline library of test requirements for similar products;
[0104] Create a table mapping the test requirements of similar products to the known test issues of similar product test requirements.
[0105] Furthermore, the creation module is also used to sort out the test issues of similar products and create a database of known test issues corresponding to the test requirements of similar products.
[0106] Furthermore, a module is created to create a correspondence table between the test requirements of the similar products and the known test problem points of the test requirements of the similar products, based on the baseline library of test requirements for the similar products and the database of known problem points corresponding to the test requirements of the similar products.
[0107] Furthermore, the creation module is also used to add the known test problem point to the list of similar product test requirements involving the problem point when the known test problem point occurs in several test requirements of similar products.
[0108] Furthermore, the creation module is also used to confirm the log identifiers in the log identifier library corresponding to the known test problem points of the similar product test requirements.
[0109] Create a table mapping test requirements for similar products to known test issue log identifiers for similar product test requirements.
[0110] Furthermore, the alert module is used to issue an alarm when a test problem or error log occurs, and to locate the cause of the test problem of the target product.
[0111] The beneficial effects of the technical solutions provided in this application are:
[0112] The technical solution provided in this application can solve the problems that test log review is time-consuming and inefficient, and that the quality of test log review is greatly affected by the level of test engineers. At the same time, this application introduces the correspondence analysis between known defects and log identifiers for previous similar product testing requirements, and takes the key log identifier fields of known defects as the review target, thus enriching the test log review methods.
[0113] The technical solution provided in this application addresses the problem of low timeliness in test log detection and analysis. Furthermore, this application provides real-time detection of test logs and sets up an alarm mechanism when problems are detected in the logs.
[0114] Example 4
[0115] This application provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it can perform the following method for automatic log detection:
[0116] Create a table mapping test requirements for similar products to known test issue log identifiers for similar products;
[0117] Obtain the testing requirements for the target product;
[0118] Based on the correspondence table between the test requirements of similar products and the known test problem log identifiers of the test requirements of similar products, the known test problem log identifiers corresponding to the test requirements of the target product are confirmed.
[0119] Add the known test problem log identifiers corresponding to the target product test requirements to the target product test log list;
[0120] The target product test logs, marked with known test problem logs indicating the target product test requirements, are tested according to the testing rules.
[0121] The beneficial effects of the technical solutions provided in this application are:
[0122] The technical solution provided in this application addresses the problem of low timeliness in test log detection and analysis. Furthermore, this application provides real-time detection of test logs and sets up an alarm mechanism when problems are detected in the logs.
[0123] The technical solution provided in this application constructs a correspondence between test requirements, known defects, and log flags for similar products, enabling the transfer of known defect flags between product project test logs. It also adds known defect log flags for similar product test requirements to the test log review list, thus enriching the test log detection methods.
[0124] Example 5
[0125] This application provides a computer storage medium, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, it performs the following steps:
[0126] Create a table mapping test requirements for similar products to known test issue log identifiers for similar products;
[0127] Obtain the testing requirements for the target product;
[0128] Based on the correspondence table between the test requirements of similar products and the known test problem log identifiers of the test requirements of similar products, the known test problem log identifiers corresponding to the test requirements of the target product are confirmed.
[0129] Add the known test problem log identifiers corresponding to the target product test requirements to the target product test log list;
[0130] The target product test logs, marked with known test problem logs indicating the target product test requirements, are tested according to the testing rules.
[0131] Furthermore, the mapping table between the test requirements for creating similar products and the known test issue log identifiers for the test requirements of similar products includes:
[0132] Create a baseline library of test requirements for similar products;
[0133] Create a table mapping the test requirements of similar products to the known test issues of similar product test requirements.
[0134] Furthermore, before creating the correspondence table between the test requirements of similar products and the known test problem points of the test requirements of similar products, the following steps are included:
[0135] The test issues of similar products were identified, and a database of known test issues corresponding to the test requirements of similar products was created.
[0136] Furthermore, the creation of the correspondence table between the test requirements of similar products and the known test problem points of the test requirements of similar products includes:
[0137] Based on the baseline library of test requirements for similar products and the database of known problem points corresponding to the test requirements of similar products, create a table showing the correspondence between the test requirements of similar products and the known test problem points of the test requirements of similar products.
[0138] Furthermore, the creation of the correspondence table between the test requirements of similar products and the known test problem points of the test requirements of similar products also includes:
[0139] When the known test problem occurs in several test requirements of similar products, the known test problem is added to the list of similar product test requirements involving the problem.
[0140] Furthermore, after creating the correspondence table between the test requirements of similar products and the known test problem points of the test requirements of similar products, the method further includes:
[0141] Confirm the log identifiers in the log identifier library corresponding to the known test issues for the similar product test requirements.
[0142] Create a table mapping test requirements for similar products to known test issue log identifiers for similar product test requirements.
[0143] Further, after detecting the target product test logs with known test problem log identifiers added according to the detection rules, the process includes:
[0144] When test problems or error logs are detected, the system will issue an alarm and locate the cause of the test problem in the target product.
[0145] This application is based on an automated log review method for known test defects or issues. By constructing and analyzing a database of test issues from similar products in the past, it constructs the corresponding identifiers for known defects in the test logs. The test log review adopts automated methods, reviewing the log identifiers of known issues for the target product's test requirements while reviewing the original test logs, thereby improving the quality and efficiency of test log review.
[0146] Figure 5 This is an exemplary system provided as Embodiment 5 of the present application, which can be used to implement the various embodiments described in this application;
[0147] like Figure 5 As shown, in some embodiments, the system can function as any of the aforementioned devices for automatic log detection in each of the various embodiments. In some embodiments, the system may include one or more computer-readable media (e.g., system memory or NVM / storage device) having a result, and one or more processors (e.g., one or more processors) coupled to the one or more computer-readable media and configured to execute the result to implement the module thereby performing the actions described in this application.
[0148] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program using related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0149] The technical features of the above embodiments can be combined in any way. For the sake of brevity, 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, they should be considered to be within the scope of this specification.
[0150] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the invention patent. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this patent application should be determined by the appended claims.
Claims
1. An automatic log detection method, characterized in that, The method includes: Create a table mapping test requirements for similar products to known test issue log identifiers for similar products; Obtain the testing requirements for the target product; Based on the correspondence table between the test requirements of similar products and the known test problem log identifiers of the test requirements of similar products, the known test problem log identifiers corresponding to the test requirements of the target product are confirmed. Add the known test problem log identifiers corresponding to the target product test requirements to the target product test log list; The target product test logs, marked with known test problem points and added to the target product test requirements, are tested according to the testing rules. Before creating the mapping table between the test requirements of similar products and the known test problem points of the test requirements of similar products, the following steps are included: The test issues of similar products were identified, and a database of known test issues corresponding to the test requirements of similar products was created. The mapping table between the test requirements for creating similar products and the known test issue log identifiers for the test requirements of similar products includes: Create a baseline library of test requirements for similar products; Create a table mapping the test requirements of similar products to the known test issues of similar product test requirements; The table mapping the test requirements for similar products to known test issues in the test requirements of similar products includes: Based on the baseline library of test requirements for similar products and the database of known problem points corresponding to the test requirements of similar products, create a table showing the correspondence between the test requirements of similar products and the known test problem points of the test requirements of similar products. When the known test problem occurs in several test requirements of similar products, the known test problem is added to the list of test requirements of similar products involving the problem. The method further includes: constructing a test requirement baseline library and a known defect library, and associating the two to realize the transfer of test requirements corresponding to known defects between different product projects; analyzing the key characters or identifiers of known defects in the test logs, and adding the log identifiers of known defects to the test log list, automatically detecting test logs in real time, and issuing alarms in real time when problems are detected.
2. The automatic log detection method according to claim 1, characterized in that, After creating the correspondence table between the test requirements of similar products and the known test problem points of the test requirements of similar products, the method further includes: Confirm the log identifiers in the log identifier library corresponding to the known test issues for the similar product test requirements. Create a table mapping test requirements for similar products to known test issue log identifiers for similar product test requirements.
3. The automatic log detection method according to claim 1, characterized in that, After performing the detection on the target product test logs marked with known test problem logs according to the detection rules, the process includes: When test problems or error logs are detected, the system will issue an alarm and locate the cause of the test problem for the target product.
4. An automatic log detection device for implementing the method as described in claim 1, characterized in that, The device includes: Create a module to create a mapping table between test requirements of similar products and known test issue log identifiers of test requirements of similar products; The acquisition module is used to acquire the testing requirements of the target product. The confirmation module is used to confirm the known test problem log identifiers corresponding to the test requirements of the target product based on the correspondence table between the test requirements of similar products and the known test problem log identifiers of the test requirements of similar products. The processing module is used to add the known test problem log identifiers corresponding to the target product test requirements to the target product test log list; The detection module is used to detect the target product test logs that include known test problem log identifiers for the target product test requirements, according to the detection rules.
5. A computer device, comprising a memory, a processor, and a computer program stored in the memory, characterized in that, The processor executes the computer program to implement the steps of the automatic log detection method as described in any one of claims 1 to 3.
6. A computer storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the memory, it implements the steps of the automatic log detection method as described in any one of claims 1 to 3.
Citation Information
Patent Citations
Log analysis method and device and computer readable storage medium
CN109828920A
Analysis method and device for automated test log file
CN110968518A