Server automatic test method and device, electronic equipment and nonvolatile storage medium

Through the combination of the test model generator and the test management platform, automatic server testing without manual participation is realized, which solves the problems of low testing efficiency and insufficient accuracy in the existing technology, and significantly improves the efficiency and accuracy of server testing.

CN118820107APending Publication Date: 2024-10-22INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202411029217.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-30
Publication Date
2024-10-22

AI Technical Summary

Technical Problem

Existing server testing methods rely on a large amount of manual participation, resulting in low testing efficiency and insufficient accuracy, and cannot effectively guarantee server performance.

Method used

Use the test model generator to intelligently scan the server test plan, extract the original data as test model data, automatically generate test case data combined with the server test management platform, automatically start the test prototype for testing, completely replace manual participation, and adjust the test model generator parameters to improve Test case accuracy.

Benefits of technology

It greatly reduces labor costs, improves server testing efficiency and accuracy, reduces the probability of manual errors, and improves the reliability and efficiency of test results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118820107A_ABST
    Figure CN118820107A_ABST
Patent Text Reader

Abstract

The invention discloses an automatic server testing method and device, electronic equipment and a nonvolatile storage medium, and is applied to the technical field of testing. The method comprises the steps that a test model generator which automatically scans data according to a server test scheme to generate server test model data and correspondingly adjusts parameters according to received test data in the execution process of a server test task is constructed in advance; calling a test model generator to automatically scan the server test scheme to generate server test model data; calling the test management platform to generate a server test task packet according to the server test model data and the server configuration parameters, and automatically starting a server test prototype for testing; and inputting test data generated in the process of executing the server test task by the server test prototype into the test model generator. According to the invention, the problem that manual participation in a large amount of work is still needed in automatic testing in related technologies can be solved, and the testing efficiency and the testing accuracy of the server can be effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of testing technology, and in particular to a server automatic testing method, device, electronic equipment and non-volatile storage medium. Background Art

[0002] With the rapid development of data centers and cloud computing, users have higher and higher requirements for server stability and reliability. Servers need to be tested during the demand analysis stage, R&D stage, before shipment, and after going online. It can be seen that server testing efficiency and testing progress will affect server performance.

[0003] The server testing process of related technologies, even for automatic testing, requires a lot of human participation. For example, the training sample data required for deep learning training models requires at least manual labeling, and automated testing that relies on scripts requires manual parameter transmission. This leads to the fact that the practicality and accuracy of the server test cases cannot be guaranteed, and thus the server performance cannot be ensured.

[0004] In view of this, improving the efficiency and accuracy of server testing is a technical problem that technical personnel in this field need to solve.

[0005] It should be noted that the information disclosed in the above background technology section is only used to enhance the understanding of the background of the present application, and therefore may include information that does not constitute the prior art known to ordinary technicians in the field. Summary of the invention

[0006] The present invention provides a server automatic testing method, device, electronic equipment and non-volatile storage medium, which effectively improve the efficiency and accuracy of server testing.

[0007] In order to solve the above technical problems, the present invention provides the following technical solutions:

[0008] One aspect of the present invention provides a server automatic testing method, comprising:

[0009] Pre-build a test model generator that automatically scans data to generate server test model data according to the server test plan, and adjusts parameters accordingly according to the received test data during the execution of the server test task;

[0010] In the process of executing the server test task on the server test prototype, a target server test plan corresponding to the current test requirement is obtained, the test model generator is called to automatically scan the target server test plan, and server test model data that meets the current test requirement is generated;

[0011] Calling the test management platform, generating a current server test task package according to the server test model data and server configuration parameters, and automatically starting the server test prototype for testing;

[0012] The test data generated during the execution of the server test task by the server test prototype is input into the test model generator.

[0013] In a first exemplary implementation, the calling of the test management platform to generate a current server test task package according to the server test model data and the server configuration parameters includes:

[0014] Calling the test management platform to generate server test case model data that meets the preset storage and representation format according to the server test model data, and automatically generating executable server test cases according to the server test case model data;

[0015] Based on each executable server test case and server configuration parameters, a server test task package is generated by packaging in a manner that contains multiple test cases with the same configuration.

[0016] In a second exemplary implementation, before executing the server test task on the server test prototype, the process further includes:

[0017] Pre-built model pool;

[0018] The server test model data is stored in the model pool, so that the test management platform directly reads the server test model data from the model pool.

[0019] In a third exemplary implementation, the test data generated during the execution of the server test task by the server test prototype is input into the test model generator, including:

[0020] Obtaining the operation log and test execution results generated during the execution of the server test task by the server test prototype;

[0021] The operation log and test execution results that conform to the target data format and have correct data content are sent to the test model generator.

[0022] In a fourth exemplary embodiment, the construction process of the test model generator includes:

[0023] Call the server test rule formula to build a test model generator; the server test rule formula is:

[0024] ;

[0025] Wherein, Y represents the server test model data output by the test model generator, A[] represents the test scheme automatic scanning data set, Indicates the nth test scenario automatic scan data in the test scenario automatic scan data set. It represents the frequency of occurrence of the set of data automatically scanned by the test plan, B[] represents the first type of data set in the running log data, represents the mth running log data in B[], represents the frequency of B[], P[] represents the second type of data set in the running log data, represents the qth running log data in P[], and L represents the deviation rate of the server test model data;

[0026] Among them, the first category of data is the test module, test configuration, and test strategy data in the log data generated during the execution of the server test case, and the second category of data is the test execution results, program defects, and test case execution efficiency in the log data generated during the execution of the server test case.

[0027] In a fifth exemplary implementation, adjusting parameters accordingly according to received test data during execution of the server test task includes:

[0028] According to the test modules, test configurations, test strategy data, test execution results, program defects, and test case execution efficiency generated during the execution of the current test task, the deviation rate of the server test model data of the server test rule relationship is adjusted.

[0029] In a sixth exemplary implementation, the construction process of the test model generator includes:

[0030] Build a test model generator including input layer, data scanning layer, data processing layer and data output layer;

[0031] Wherein, the data input layer is used to receive the historical test data generated by the server during the execution of the historical test task;

[0032] The data scanning layer is used to actively obtain the server test plan historical data, obtain the historical test plan scanning data by scanning the server test plan historical data, and send the historical test plan scanning data to the data processing layer; the historical test plan scanning data includes historical test module data, historical test configuration data and historical test strategy data;

[0033] The data processing layer is used to determine the predicted test module model, test configuration model, and test strategy model according to the historical test scheme scanning data and its occurrence frequency, the test module operation data, test configuration operation data, and test strategy operation data in the historical test data and their occurrence frequency, the test execution results, program defects, and test case execution efficiency in the historical test data, and the deviation rate of the server test model data; wherein the deviation rate of the server test model data is adjusted according to the historical test data;

[0034] The data output layer is used to output the test module model, the test configuration model and the test strategy model as predicted server test model data.

[0035] Another aspect of the present invention provides a server automatic testing device, comprising:

[0036] A test model generator pre-construction module is used to pre-construct a test model generator that automatically scans data according to a server test plan to generate server test model data, and adjusts parameters accordingly according to the received test data during the execution of the server test task;

[0037] A test model data generation module is used to obtain a target server test plan corresponding to a current test requirement during the execution of a server test task on a server test prototype, call the test model generator to automatically scan the target server test plan, and generate server test model data that meets the current test requirement;

[0038] The test module is used to call the test management platform, generate the current server test task package according to the server test model data and server configuration parameters, and automatically start the server test prototype for testing;

[0039] The parameter updating module is used to input the test data generated during the execution of the server test task by the server test prototype into the test model generator.

[0040] The present invention also provides an electronic device, comprising a processor, wherein the processor is used to implement the steps of the server automatic testing method as described in any of the preceding items when executing a computer program stored in a memory.

[0041] Finally, the present invention also provides a non-volatile storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the server automatic testing method as described in any of the preceding items are implemented.

[0042] The advantage of the technical solution provided by the present invention is that the test model generator is used to intelligently scan the server test plan, and the original data is extracted as test model data, without the need to manually input data and process the sample data; with the help of the server test management platform, according to the test model data combined with the server configuration parameters, the use case data related to the server test is automatically generated, and the server test prototype is automatically started to perform server testing. The entire process completely replaces manual labor, effectively reduces labor costs, greatly reduces server testing costs, improves server testing efficiency, and can also reduce the probability of errors caused by manual labor, which is conducive to improving the accuracy of server testing. Furthermore, by adjusting the parameters of the test model generator through the test data generated by the test process, the accuracy of the test case can be further improved, and the fit between the server test prototype model data and the server test case can be improved, thereby improving the accuracy of the server test.

[0043] In addition, the present invention also provides a corresponding implementation device, electronic device and non-volatile storage medium for the server automatic testing method, which further makes the method more practical, and the device, electronic device and non-volatile storage medium have corresponding advantages.

[0044] The technical features mentioned above, the technical features to be mentioned below, and the technical features shown separately in the drawings can be arbitrarily combined with each other, as long as the combined technical features are not contradictory. All feasible feature combinations are technical contents clearly recorded in this article. Any of the multiple sub-features contained in the same sentence can be applied independently, and does not have to be applied together with other sub-features. It should be understood that the above general description and the detailed description below are only exemplary and cannot limit the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] In order to more clearly illustrate the technical solutions of the present invention or related technologies, the following briefly introduces the drawings required for use in the embodiments or related technical descriptions. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0046] Figure 1 A schematic diagram of a flow chart of a server automatic testing method provided by the present invention;

[0047] Figure 2 A schematic diagram of a data processing flow of a test management platform provided by the present invention in an exemplary application scenario;

[0048] Figure 3 A flow chart of another server automatic testing method provided by the present invention;

[0049] Figure 4 A schematic diagram of a framework of a model pool provided by the present invention in an exemplary application scenario;

[0050] Figure 5 A schematic diagram of a framework of a test model generator provided by the present invention in an exemplary application scenario;

[0051] Figure 6 A structural diagram of a specific implementation of the server automatic testing device provided by the present invention;

[0052] Figure 7 A structural diagram of a specific implementation of the electronic device provided by the present invention. DETAILED DESCRIPTION

[0053] In order to enable those skilled in the art to better understand the technical solution of the present invention, the present invention is further described in detail below in conjunction with the accompanying drawings and specific embodiments. Among them, the terms "first", "second", "third", "fourth", etc. in the specification and the above-mentioned drawings are used to distinguish different objects, rather than to describe a specific order. In addition, the terms "including" and "having" and any variations of the two are intended to cover non-exclusive inclusions. The term "exemplary" means "used as an example, embodiment or illustrative". Any embodiment described here as "exemplary" is not necessarily interpreted as being superior or better than other embodiments.

[0054] When testing a server, the traditional method is to use test engineers to manually analyze the previous test plan to form a test sample model and a strategy model, and then combine their own experience analysis to form a test case sample, and then create relevant test cases based on the test case sample, and the test engineer will start the test case to test the server. Because the traditional method is highly dependent on manual labor, it cannot release manpower, and it also requires manual labor to have server testing business knowledge and the ability to work on the overall server testing, the labor cost investment is large and the efficiency is low.

[0055] In order to solve the drawbacks of traditional testing methods, related technologies use automated methods to implement server testing. For example, a related technology uses XML (eXtensible Markup Language) file element scanning lines to form basic data, and then combines test templates to generate related equipment test cases, and automatically generates test cases for customized computer chain systems. A related technology generates a syntax template based on database test standards, and then combines instance data to form parameter definition data and basic information of the database to be tested to generate database standard test cases. A related technology automatically generates test cases based on crawlers, and generates test cases for code interfaces based on various existing parameters combined with existing case templates. A related technology inputs pre-processed test case samples into a test strategy feature pre-training model to extract test strategy features and then generate test cases. However, these related technologies generate related test cases at one time based on various manually transmitted parameters or fixed test case templates formed by a small amount of data. The accuracy of the automatically generated test cases cannot be guaranteed, which will affect the accuracy of server testing. In addition, training and generating test cases based on preprocessed test case samples requires reliance on manual labeling, which cannot achieve timely and accurate optimization, and cannot guarantee the practicality and accuracy of the test cases, nor the timeliness, efficiency, and accuracy of server testing.

[0056] In view of this, the present invention uses a test model generator to intelligently scan the server test plan, extracts the original data as test model data, and does not need to manually input data and process sample data; with the help of the server test management platform, according to the test model data combined with the server configuration parameters, automatically generates use case data related to the server test, and automatically starts the server test prototype to perform server testing, thereby realizing a fully automated server testing method that requires almost no human participation, and can effectively improve the efficiency and test accuracy of server testing. After introducing the technical scheme of the present invention, various non-limiting embodiments of the present invention are described in detail below. In order to better illustrate the present invention, numerous specific details are given in the specific embodiments below. Those skilled in the art should understand that the present invention can also be implemented without these specific details. In other examples, methods, means, components and circuits well known to technicians in the relevant field are not described in detail in order to highlight the main purpose of the present invention.

[0057] First see Figure 1 , Figure 1 A flow chart of a server automatic testing method provided in this embodiment, this embodiment may include the following contents:

[0058] S101: pre-build a test model generator that automatically scans data according to a server test plan to generate server test model data, and adjusts parameters accordingly according to received test data during the execution of the server test task.

[0059] In the present invention, the test model generator is used to generate server test model data, including but not limited to test module model, test configuration model and test strategy model. Wherein, the test module model (i.e. Test ModuleModel) decomposes the test object into multiple modules, and each module can be tested independently, thereby improving the manageability and reusability of the test and reducing the complexity of the test. The test configuration model (i.e. Test Configuration Model) refers to the configuration management of the test environment and test data during the test process to ensure that the test can be carried out under different environments and conditions, while ensuring the consistency and repeatability of the test results. The test configuration model includes but is not limited to hardware configuration, software configuration, network configuration, and data configuration. Through reasonable configuration, different test scenarios can be simulated to improve the coverage and effectiveness of the test. The test strategy model (i.e. Test Strategy Model) refers to the test plan and method determined according to the test target and test resources during the test process. Through reasonable test strategy, test resources can be effectively utilized to improve the efficiency and effect of the test. The test strategy model includes but is not limited to test type, test method, and test tool. Among them, test types include unit testing, integration testing, system testing, acceptance testing; test methods include black box testing, white box testing, gray box testing; test tools include automation testing tools, performance testing tools, and security testing tools.

[0060] In the present invention, the test model generator of the present invention has the function of automatically acquiring data and scanning the acquired data. During the model building process, historical server test plans can be automatically acquired and scanned. During the actual application process, the server test plan corresponding to the current test requirements can be automatically acquired and scanned. Since the test model generator can automatically identify the required data and scan the required data, there is no need for manual analysis and manual abstraction of the original model data, thereby reducing the problem of human intervention in the server model test data generation process, ensuring the timeliness, efficiency and accuracy of the server test, and improving the efficiency of the overall server testing work. In addition, the model parameters of the test model generator of the present invention are not fixed during the server test process, that is, the server model test data generated during the server test process will be flexibly adjusted according to the actual test situation. In other words, the test model generator of the present invention also has an optimization mechanism. On the basis of the existing historical data, it will also continuously learn according to the test data generated during the current test process, and continuously optimize, adjust, and improve the test model generator. The subsequent server model test data is generated by scanning and comparing the massive operation logs and test results generated by the server test case, and then intelligently analyzing, summarizing, and summarizing to improve the fit between the server model test data and the server test case. In addition, in the process of the test model generator automatically generating server model test data, it is not easily affected by inattention, misjudgment, logical reasoning errors or other human factors, which reduces the possibility of errors and improves the accuracy of generating server model test data.

[0061] S102: During the execution of the server test task on the server test prototype, a target server test plan corresponding to the current test requirement is obtained, a test model generator is called to automatically scan the target server test plan, and server test model data that meets the current test requirement is generated.

[0062] In this step, the server test prototype is a device built by the server solution test engineer for the current test requirements, which is used to test the server performance, stability, compatibility and other aspects, in order to ensure that the server can meet the expected performance and reliability standards in actual deployment and use. It can be an actual physical server or a virtual server. S101-S104 of the present invention is a cyclic process in the entire server test task execution process. The target server test solution is a server test solution written by the server solution test engineer for the current test requirements. The target server test solution can be fixed or adjusted in real time during the entire test process. Whenever the target server test solution changes, it will re-scan and generate the data corresponding to the target server test solution. Since the parameters of the test model generator will be updated and adjusted during the test process, accordingly, regardless of whether the target server test solution is adjusted, the generated server test model data will also be adjusted accordingly. In this way, there is no need to wait until the server test cases are all executed. For the massive log data, test results and other data generated by the server test cases, the test solution is optimized and adjusted after analysis, induction and summary, such as the parameter indicators that affect the server test work such as server performance coefficient, components, test range, test laps, and test duration. During the process of executing the server test task on the server test prototype, it can be determined whether the server test model data related to the test prototype exists. If not, the test model generator is automatically called to generate the server test model data of the server test prototype.

[0063] In this step, the server test model data may include a test module model, a test configuration model, and a test strategy model. Among them, the test module model decomposes the server into a hardware module, a software module, a service module, a network module, a monitoring and logging module, a backup and recovery module, and a compatibility and migration module, and designs independent test cases for each module. The hardware module may include, for example, a central processing unit, a memory, a storage device, and a network interface. The software module may include, for example, an operating system, a database, a middleware, and an application. The service module may include, for example, a Web service, a mail service, and a file service. The network module may include, for example, a network connection, a load balancing, and a network security. The monitoring and logging module may include, for example, a monitoring system and a logging system. The backup and recovery module may include, for example, data backup and system recovery. The compatibility and migration module may include, for example, hardware compatibility and software migration. The test configuration model configures different hardware resources for each hardware module included in the above test module model, such as different CPU configurations, memory configurations, and storage device configurations; configures different operating systems and database versions for the software modules included in the above test module model, such as the configuration of the operating system, database, and middleware; configures different network environments and load conditions for service modules, such as network connections, load balancing, and network security configurations, such as the management of test data generation, import, and cleanup, such as the construction and management of test environments such as test servers and test networks. The test strategy model includes a detailed test plan, such as test types, test methods, and test tools, as well as test priorities, such as testing key functions first, and managing test resources to ensure that the test proceeds as planned.

[0064] S103: calling the test management platform, generating the current server test task package according to the server test model data and the server configuration parameters, and automatically starting the server test prototype for testing.

[0065] Among them, the test management platform intelligently analyzes and combines to generate server test tasks, which is a tool or system for managing and executing server tests, and has functions including but not limited to the following: Test plan management: allows users to create, edit and maintain test plans, including test objectives, test cases, test cycles, etc. Test case management: provides test case creation, editing, execution and tracking functions. Test cases may include test steps, expected results and actual results. Automated testing: supports the writing and execution of automated test scripts to improve test efficiency and accuracy. Test result management: automatically records test results, including success, failure and errors, etc., and provides detailed test reports. Defect management: integrates defect tracking system to allow users to report, track and manage defects. Environment management: manages the test environment, including server configuration, network settings, etc. Integration and scalability: supports integration with other tools and systems, such as continuous integration / continuous deployment tools, project management tools, etc. Those skilled in the art can choose any existing test management platform according to actual needs, such as the open source TestLink (name of the test management platform), or build a server test management platform by themselves according to test requirements and actual application scenarios, which does not affect the implementation of the present invention. Server configuration parameters include but are not limited to the hardware configuration parameters, software configuration parameters, and test environment parameters of the server to be tested. Hardware configuration parameters include relevant performance data information of the central processing unit, memory configuration information, and relevant performance data of the hard disk and network interface. Software configuration parameters include performance parameters of the operating system and database. Test environment parameters include network environment parameters and storage environment parameters.

[0066] In this embodiment, the test management platform reads the server test model data, performs intelligent aggregation, analysis, and combination, and then combines the server configuration parameters to automatically generate use case data related to the server test, that is, the test task package, and then automatically calls and starts the server test prototype, and enters the server test execution phase according to the test task package. The entire process completely replaces manual work.

[0067] S104: Input the test data generated during the execution of the server test task by the server test prototype into the test model generator.

[0068] In this step, when the server test prototype performs a server test task, the test data input frequency can be pre-configured. For example, after completing the test for a test model of the test module model, the generated test data can be input into the test model generator. It can also be determined according to the number of test cases executed. For example, after completing n test cases, the generated test data is input into the test model generator. The test data includes various data generated by the server test prototype during the execution of the server test task, including but not limited to test result data and operation log data. Furthermore, after the test case is completed, the data results, logs and other data can be persisted and saved to disk or cache for subsequent traceability.

[0069] In the technical solution provided in this embodiment, the test model generator intelligently scans the server test solution and extracts the original data as the test model data, without the need to manually input data and process the sample data; with the help of the server test management platform, the use case data related to the server test is automatically generated according to the test model data combined with the server configuration parameters, and the server test prototype is automatically started to perform the server test. The whole process completely replaces manual work, effectively reduces labor costs, greatly reduces server testing costs, improves server testing efficiency, and can also reduce the probability of errors caused by manual work, which is conducive to improving the accuracy of server testing. Further, by adjusting the parameters of the test model generator through the test data generated by the test process, the accuracy of the test case can be further improved, and the fit between the server test prototype model data and the server test case can be improved, thereby improving the accuracy of the server test. Further, this fully automatic server test without manual intervention can realize intelligent control of the time occupied by each node in the entire process of server testing, which is conducive to improving the utilization rate of time. By analyzing the test data in real time and adjusting the server testing strategy in a timely and accurate manner, we can ensure that the server test cases are carried out efficiently, accurately, continuously and uninterruptedly, further improving the overall work efficiency of server testing. It is also beneficial to reduce the difficulty of server testing work and simplify the daily work of server testers.

[0070] It should be noted that there is no strict order of execution between the steps in the present invention. As long as they comply with the logical order, these steps can be executed simultaneously or in a certain preset order. Figure 1 This is just a schematic and does not mean that this is the only execution order.

[0071] In the above embodiment, there is no limitation on how to execute step S103. In this embodiment, an exemplary method for generating a server test task package is provided, which may include the following contents:

[0072] Call the test management platform to generate server test case model data that meets the preset storage and representation format based on the server test model data, and automatically generate executable server test cases based on the server test case model data; based on each executable server test case and server configuration parameters, package and generate a server test task package in a way that contains multiple test cases with the same configuration.

[0073] like Figure 2 As shown, the test management platform uses the test case management function to intelligently aggregate, analyze, and combine the server test model data to generate server test case model data. According to the actual test environment, the server test case model data is represented in the corresponding storage and representation format. For example, the server test case model data can be server test case model JSON data, that is, the preset storage and representation format is JSON (format name). Based on the test case model JSON data, the test case management function is used to automatically generate executable server test cases, and package them into test task packages containing multiple test cases under the same configuration, and the automated testing function is used to automatically call and start the server test prototype to enter the server test execution phase.

[0074] As can be seen from the above, this embodiment uses the test task package to perform comprehensive and systematic testing on multiple test cases under the same configuration, so as to discover and solve problems in a timely manner and improve the quality and reliability of server testing.

[0075] Based on the above embodiments, the present invention can also pre-construct a model pool, such as Figure 3 As shown, if the server test model data does not exist, the test model generator is called to generate the corresponding server test model data, and the generated server test model data is stored in the model pool, such as Figure 4 As shown, the model pool may include a test module model, a test configuration model, and a test strategy model. Furthermore, during the server testing process, the model pool may also store a set of predefined test configurations or test environments to simulate different operating conditions and load conditions, and quickly switch to different test environments according to different test requirements. The model pool can be continuously expanded and updated with new test requirements to ensure the consistency and comparability of test results in different test environments. Accordingly, the test management platform directly reads the server test model data from the model pool, and generates the server test case model JSON data after intelligent aggregation, analysis, and combination based on the model data in the model pool.

[0076] From the above, it can be seen that this embodiment uses a model pool to store server test model data. By reasonably managing and using the model pool, the efficiency and quality of the testing and development process can be significantly improved, and it is also beneficial to ensure the consistency and comparability of test results in different testing environments.

[0077] The above embodiment does not impose any limitation on the data input to the test model generator. Based on this, in order to improve the performance of the test model generator, this embodiment processes the test data before inputting it into the test model, which may include the following contents:

[0078] Obtain the operation log and test execution results generated by the server test prototype during the execution of the server test task; send the operation log and test execution results that conform to the target data format and have correct data content to the test model generator.

[0079] In this embodiment, the operation log includes but is not limited to the test module, test configuration, test strategy data, BUG (defect), and test case execution efficiency in the log data generated during the execution of the server test case. In order to facilitate the processing of the test model generator and to improve the performance of the test model generator, this embodiment performs data preprocessing operations on the acquired operation log and test execution results, such as interpolation and normalization processing to standardize the format of the input data, and it is also necessary to judge whether the operation log and test execution results are accurate data, that is, only the correct content is input.

[0080] From the above, it can be seen that this embodiment can improve the model performance of the test model generator, improve the function of the test model generator, and enhance the fit between the model and the server test case by screening and analyzing the input data and inputting it into the test model generator.

[0081] The above embodiment does not limit how to construct the test model generator. Based on the above embodiment, the present invention also provides an exemplary construction method of the test model generator, which may include the following contents:

[0082] The test model generator includes an input layer, a data scanning layer, a data processing layer and a data output layer; wherein the data input layer is used to receive historical test data generated by the server during the execution of historical test tasks; the data scanning layer is used to actively obtain the historical data of the server test plan, obtain the historical test plan scanning data by scanning the historical data of the server test plan, and send the historical test plan scanning data to the data processing layer; the historical test plan scanning data includes historical test module data, historical test configuration data and historical test strategy data; the data processing layer is used to determine the predicted test module model, test configuration model and test strategy model according to the historical test plan scanning data and its occurrence frequency, the test module running data, test configuration running data, test strategy running data and its occurrence frequency in the historical test data, the test execution results, program defects, test case execution efficiency in the historical test data, and the deviation rate of the server test model data; wherein the deviation rate of the server test model data is adjusted according to the historical test data; the data output layer is used to output the test module model, test configuration model and test strategy model as the predicted server test model data.

[0083] In this step, the input layer, data scanning layer, data processing layer and data output layer of the test model generator are used to describe the data processing process in the construction process. When it is in the actual server testing process, the data input layer is used to receive the test data sent in step S104, the data scanning layer is used to obtain the target server test plan, and the data processing layer generates server test model data based on the scan data of the target server test plan before starting to execute the test task, such as Figure 5 As shown, after a portion of the test cases are executed, server test model data is jointly generated based on the test data and the scan data of the target server test plan. For example, according to the test modules, test configurations, test strategy data, test execution results, program defects, and test case execution efficiency generated during the execution of the current test task, the deviation rate of the server test model data of the server test rule relationship is adjusted, and the server test model data is generated using the adjusted test model generator.

[0084] As an efficient model building process, the server test rule algorithm can be stored locally in advance. The server test rule algorithm can be expressed by a server test rule relational expression. By directly calling the server test rule relational expression, a test model generator is constructed. The server test rule relational expression can be expressed as:

[0085] ;

[0086] Wherein, Y represents the server test model data output by the test model generator, A[] represents the test scheme automatic scanning data set, Indicates the nth test scenario automatic scan data in the test scenario automatic scan data set. It represents the frequency of occurrence of the set of data automatically scanned by the test plan, B[] represents the first type of data set in the running log data, represents the mth running log data in B[], represents the frequency of B[], P[] represents the second type of data set in the running log data, represents the qth running log data in P[], and L represents the deviation rate of the server test model data; among them, the first type of data is the test module, test configuration, and test strategy data in the log data generated during the execution of the server test case, and the second type of data is the test execution results, program defects, and test case execution efficiency in the log data generated during the execution of the server test case.

[0087] Based on this, when the test model generator is called, it intelligently obtains test modules, test configurations, test strategies and other data according to the server test rule algorithm, generates server test model data, and adjusts the data model deviation rate in the server test rule algorithm to improve the test model generator. The logs and other data generated during the test execution are analyzed and provided to the test model generator, and the server test rule relationship in the test model generator is adjusted.

[0088] From the above, it can be seen that the test model generator of this embodiment can automatically obtain the server test plan and extract the server test plan as server test model data. During the testing process, the massive operation logs and test results generated by the server test can also be intelligently scanned, compared, intelligently analyzed, summarized, and summarized to generate server test model data, effectively improving the fit between the server test prototype model data and the server test case, improving the bug discovery rate and accuracy rate of server testing work, and helping to improve the overall pass rate of server testing.

[0089] Based on the above embodiments, in order to further improve the performance of the test model generator and ensure the accuracy and reliability of the data model generated by the test model generator, the present invention further provides the following embodiments, which may include the following contents:

[0090] First, whether in the model building process or in the actual application process, the input data of the test model generator needs to be cleaned and preprocessed to improve the quality of the input data. Among them, data cleaning includes removing erroneous, duplicated and irrelevant data to ensure the accuracy and completeness of the input data. Data preprocessing includes data conversion and normalization to improve the generalization ability of the test model generator. Secondly, the test model generator may also include feature selection and feature conversion functions. After receiving the data, it can use the automatic feature selection function to select the most useful features for prediction. Then the selected features are standardized, normalized or encoded to improve the performance of the model. Further, in order to ensure the performance of the test model generator, multiple server test rule algorithms can be pre-selected and configured, and the same test data set and verification set can be used to compare and evaluate each server test rule algorithm, such as accuracy, recall rate, F1 score, etc., and in the model training process, automated parameter tuning tools, such as grid search or random search, can be used to find the optimal model parameters. Furthermore, the importance of features can be analyzed to understand which features have the greatest impact on the prediction results of the test model generator, increase the interpretability of the test model generator, and use visualization tools to display the decision-making process and results of the test model generator.

[0091] It can be seen from the above that the present invention ensures that the performance of the test model generator in actual applications meets expectations by improving the accuracy and reliability of the server test data model generated by the test model generator.

[0092] The present invention also provides a corresponding device for the server automatic testing method, which further makes the method more practical. Among them, the device can be described from the perspective of functional modules and hardware. The server automatic testing device provided by the present invention is introduced below. The device is used to implement the server automatic testing method provided by the present invention. In this embodiment, the server automatic testing device may include or be divided into one or more program modules, and the one or more program modules are stored in a storage medium and executed by one or more processors to complete the server automatic testing method disclosed in Example 1. The program module referred to in this embodiment refers to a series of computer program instruction segments that can complete specific functions, which is more suitable for describing the execution process of the server automatic testing device in the storage medium than the program itself. The following description will specifically introduce the functions of each program module of this embodiment. The server automatic testing device described below and the server automatic testing method described above can be referenced to each other.

[0093] From the perspective of functional modules, see Figure 6 , Figure 6 The structure diagram of the server automatic testing device provided in this embodiment under a specific implementation mode may include:

[0094] A test model generator pre-construction module 601 is used to pre-construct a test model generator that automatically scans data according to a server test plan to generate server test model data, and adjusts parameters accordingly according to the received test data during the execution of the server test task;

[0095] The test model data generation module 602 is used to obtain the target server test plan corresponding to the current test requirement during the execution of the server test task on the server test prototype, call the test model generator to automatically scan the target server test plan, and generate server test model data that meets the current test requirement;

[0096] The test module 603 is used to call the test management platform, generate the current server test task package according to the server test model data and the server configuration parameters, and automatically start the server test prototype for testing;

[0097] The parameter updating module 604 is used to input the test data generated during the execution of the server test task by the server test prototype into the test model generator.

[0098] Exemplarily, in some implementations of this embodiment, the test module 603 may also be used to:

[0099] Calling the test management platform to generate server test case model data that meets the preset storage and representation format according to the server test model data, and automatically generating executable server test cases according to the server test case model data;

[0100] Based on each executable server test case and server configuration parameters, a server test task package is generated by packaging in a manner that contains multiple test cases with the same configuration.

[0101] Exemplarily, in some other implementations of this embodiment, the above-mentioned device may also include a model pool construction module for pre-building a model pool; storing the server test model data in the model pool so that the test management platform can directly read the server test model data from the model pool.

[0102] Exemplarily, in some other implementations of this embodiment, the parameter updating module 604 may also be used to:

[0103] Obtain the operation log and test execution results generated by the server test prototype during the execution of the server test task;

[0104] The operation logs and test execution results that conform to the target data format and have correct data content are sent to the test model generator.

[0105] Exemplarily, in some other implementations of this embodiment, the test model generator pre-construction module 601 may also be used to:

[0106] Call the server test rule formula to build a test model generator; the server test rule formula is:

[0107] ;

[0108] Wherein, Y represents the server test model data output by the test model generator, A[] represents the test scheme automatic scanning data set, Indicates the nth test scenario automatic scan data in the test scenario automatic scan data set. It represents the frequency of occurrence of the set of data automatically scanned by the test plan, B[] represents the first type of data set in the running log data, represents the mth running log data in B[], represents the frequency of B[], P[] represents the second type of data set in the running log data, represents the qth running log data in P[], and L represents the deviation rate of the server test model data;

[0109] Among them, the first type of data is the test module, test configuration, and test strategy data in the log data generated during the execution of server test cases, and the second type of data is the test execution results, program defects, and test case execution efficiency in the log data generated during the execution of server test cases.

[0110] As an exemplary implementation of the above embodiment, the above test model generator pre-construction module 601 can also be used for:

[0111] According to the test modules, test configurations, test strategy data, test execution results, program defects, and test case execution efficiency generated during the execution of the current test task, the deviation rate of the server test model data of the server test rule relationship is adjusted.

[0112] Exemplarily, in some other implementations of this embodiment, the test model generator pre-construction module 601 may also be used to:

[0113] Build a test model generator including input layer, data scanning layer, data processing layer and data output layer;

[0114] The data input layer is used to receive the historical test data generated by the server during the execution of the historical test tasks;

[0115] The data scanning layer is used to actively obtain the historical data of the server test plan, obtain the historical test plan scanning data by scanning the historical data of the server test plan, and send the historical test plan scanning data to the data processing layer; the historical test plan scanning data includes historical test module data, historical test configuration data and historical test strategy data;

[0116] The data processing layer is used to determine the predicted test module model, test configuration model, and test strategy model based on the historical test plan scanning data and its occurrence frequency, the test module operation data, test configuration operation data, and test strategy operation data in the historical test data and their occurrence frequency, the test execution results, program defects, and test case execution efficiency in the historical test data, and the deviation rate of the server test model data; wherein the deviation rate of the server test model data is adjusted according to the historical test data;

[0117] The data output layer is used to output the test module model, the test configuration model and the test strategy model as the predicted server test model data.

[0118] The functions of the functional modules of the server automatic testing device of this embodiment can be specifically implemented according to the method in the above method embodiment. The specific implementation process can refer to the relevant description of the above method embodiment, which will not be repeated here.

[0119] It can be seen from the above that this embodiment can solve the problem in the related art that automatic testing still requires a lot of manual participation, and can effectively improve the testing efficiency and testing accuracy of the server.

[0120] The server automatic testing device mentioned above is described from the perspective of functional modules. Furthermore, the present invention also provides an electronic device, which is described from the perspective of hardware. Figure 7 The following is a schematic diagram of the structure of an electronic device provided by an embodiment of the present invention in one implementation manner. Figure 7 As shown, the electronic device includes a memory 70 for storing a computer program; and a processor 71 for implementing the steps of the server automatic testing method mentioned in any of the above embodiments when executing the computer program.

[0121] Among them, the processor 71 may include one or more processing cores, such as a 4-core processor, an 8-core processor, and the processor 71 may also be a controller, a microcontroller, a microprocessor or other data processing chip. The processor 71 may be implemented in at least one hardware form of DSP (Digital Signal Processing), FPGA (Field-Programmable Gate Array), and PLA (Programmable Logic Array). The processor 71 may also include a main processor and a coprocessor. The main processor is a processor for processing data in the awake state, also known as a CPU (Central Processing Unit); the coprocessor is a low-power processor for processing data in the standby state. In some embodiments, the processor 71 may be integrated with a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content to be displayed on the display screen. In some embodiments, the processor 71 may also include an AI (Artificial Intelligence) processor, which is used to process computing operations related to machine learning.

[0122] The memory 70 may include one or more computer non-volatile storage media, which may be non-transitory. The memory 70 may also include high-speed random access memory and non-volatile memory, such as one or more disk storage devices and flash memory storage devices. In some embodiments, the memory 70 may be an internal storage unit of an electronic device, such as a hard disk of a server. In other embodiments, the memory 70 may also be an external storage device of an electronic device, such as a plug-in hard disk equipped on a server, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), etc. Further, the memory 70 may also include both an internal storage unit of an electronic device and an external storage device. The memory 70 may not only be used to store application software and various types of data installed in the electronic device, such as: the code of the program in the process of executing the server automatic test method, but also be used to temporarily store data that has been output or is to be output. In this embodiment, the memory 70 is at least used to store the following computer program 701, wherein, after the computer program is loaded and executed by the processor 71, the relevant steps of the server automatic test method disclosed in any of the aforementioned embodiments can be implemented. In addition, the resources stored in the memory 70 may also include an operating system 702 and data 703, and the storage method may be temporary storage or permanent storage. The operating system 702 may include Windows, Unix, Linux, etc. The data 703 may include but is not limited to data corresponding to the server automatic test results.

[0123] In some embodiments, the electronic device may further include a display screen 72, an input / output interface 73, a communication interface 74 or a network interface, a power supply 75 and a communication bus 76. Among them, the display screen 72 and the input / output interface 73, such as a keyboard, belong to the user interface, and exemplary user interfaces may also include standard wired interfaces, wireless interfaces, and the like. Optionally, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, and an OLED (Organic Light-Emitting Diode) touch device, and the like. The display may also be appropriately referred to as a display screen or a display unit, which is used to display information processed in the electronic device and to display a visual user interface. The communication interface 74 may exemplarily include a wired interface and / or a wireless interface, such as a WI-FI interface, a Bluetooth interface, and the like, which are generally used to establish a communication connection between the electronic device and other electronic devices. The communication bus 76 may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus, and the like. The bus may be divided into an address bus, a data bus, a control bus, and the like. For ease of representation, Figure 7 Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.

[0124] Those skilled in the art will understand that Figure 7 The structure shown in the figure does not constitute a limitation on the electronic device, and may include more or fewer components than shown in the figure, for example, it may also include a sensor 77 to implement various functions.

[0125] The functions of the functional modules of the electronic device of this embodiment can be specifically implemented according to the method in the above method embodiment. The specific implementation process can refer to the relevant description of the above method embodiment, which will not be repeated here.

[0126] It can be seen from the above that this embodiment can solve the problem in the related art that automatic testing still requires a lot of manual participation, and can effectively improve the testing efficiency and testing accuracy of the server.

[0127] It is understandable that if the server automatic test method in the above embodiment is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a non-volatile storage medium. Based on such an understanding, the technical solution of the present invention is essentially or the part that contributes to the relevant technology or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium to execute all or part of the steps of the methods of each embodiment of the present invention. The aforementioned storage medium includes but is not limited to: U disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), electrically erasable programmable ROM, register, hard disk, multimedia card, card-type memory (such as SD or DX memory, etc.), magnetic memory, removable disk, CD-ROM, magnetic disk or optical disk, etc. Various media that can store program codes. Based on this, the present invention also provides a non-volatile storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the server automatic test method recorded in any of the above embodiments are performed.

[0128] It is understandable that if the server automatic testing method in the above embodiment is implemented in the form of a software functional unit and sold or used as an independent product, the computer software product does not need to be stored in a physical storage medium. For example, it can be directly transmitted to a computer or other device with information processing capabilities through a wired network or a wireless network to perform all or part of the steps of the methods of each embodiment of the present invention. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the relevant technology or all or part of the technical solution can be embodied in the form of a software product. Based on this, the present invention also provides a computer program product, which stores a computer program. When the computer program is executed by a processor, it performs the steps of the server automatic testing method described in any of the above embodiments.

[0129] In this specification, each embodiment is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the embodiments can be referred to each other. For the hardware disclosed in the embodiments, including devices, electronic devices, and non-volatile storage media, since they correspond to the methods disclosed in the embodiments, the description is relatively simple, and the relevant parts can be referred to the method part description.

[0130] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.

[0131] The above is a detailed introduction to a server automatic testing method, device, electronic device and non-volatile storage medium provided by the present invention. Specific examples are used herein to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. It should be pointed out that based on the embodiments of the present invention, for ordinary technicians in this technical field, all other embodiments obtained without creative work are within the scope of protection of the present invention. Without departing from the principles of the present invention, the present invention can also be improved and modified in a number of ways, and these improvements and modifications also fall within the scope of protection of the present invention.

Claims

1. A server automatic testing method, characterized in that: include: Pre-build a test model generator that automatically scans data to generate server test model data according to the server test plan, and adjusts parameters accordingly according to the received test data during the execution of the server test task; In the process of executing the server test task on the server test prototype, a target server test plan corresponding to the current test requirement is obtained, the test model generator is called to automatically scan the target server test plan, and server test model data that meets the current test requirement is generated; Calling the test management platform, generating a current server test task package according to the server test model data and server configuration parameters, and automatically starting the server test prototype for testing; The test data generated during the execution of the server test task by the server test prototype is input into the test model generator.

2. The server automatic testing method according to claim 1, characterized in that: The calling test management platform generates a current server test task package according to the server test model data and server configuration parameters, including: Calling the test management platform to generate server test case model data that meets the preset storage and representation format according to the server test model data, and automatically generating executable server test cases according to the server test case model data; Based on each executable server test case and server configuration parameters, a server test task package is generated by packaging in a manner that contains multiple test cases with the same configuration.

3. The server automatic testing method according to claim 1, characterized in that: Before the server test task is executed on the server test prototype, the process further includes: Pre-built model pool; The server test model data is stored in the model pool, so that the test management platform directly reads the server test model data from the model pool.

4. The server automatic testing method according to claim 1, characterized in that: Inputting the test data generated during the execution of the server test task by the server test prototype into the test model generator includes: Obtaining the operation log and test execution results generated during the execution of the server test task by the server test prototype; The operation log and test execution results that conform to the target data format and have correct data content are sent to the test model generator.

5. The server automatic testing method according to claim 1, characterized in that: The construction process of the test model generator includes: Call the server test rule formula to build a test model generator; the server test rule formula is: ; Wherein, Y represents the server test model data output by the test model generator, A[] represents the test scheme automatic scanning data set, Indicates the nth test scenario automatic scan data in the test scenario automatic scan data set. It represents the frequency of occurrence of the set of data automatically scanned by the test plan, B[] represents the first type of data set in the running log data, represents the mth running log data in B[], represents the frequency of B[], P[] represents the second type of data set in the running log data, represents the qth running log data in P[], and L represents the deviation rate of the server test model data; Among them, the first category of data is the test module, test configuration, and test strategy data in the log data generated during the execution of the server test case, and the second category of data is the test execution results, program defects, and test case execution efficiency in the log data generated during the execution of the server test case.

6. The server automatic testing method according to claim 5, characterized in that: The adjusting parameters according to the received test data during the execution of the server test task includes: According to the test modules, test configurations, test strategy data, test execution results, program defects, and test case execution efficiency generated during the execution of the current test task, the deviation rate of the server test model data of the server test rule relationship is adjusted.

7. The server automatic testing method according to any one of claims 1 to 6, characterized in that: The construction process of the test model generator includes: Build a test model generator including input layer, data scanning layer, data processing layer and data output layer; Wherein, the data input layer is used to receive the historical test data generated by the server during the execution of the historical test task; The data scanning layer is used to actively obtain the server test plan historical data, obtain the historical test plan scanning data by scanning the server test plan historical data, and send the historical test plan scanning data to the data processing layer; the historical test plan scanning data includes historical test module data, historical test configuration data and historical test strategy data; The data processing layer is used to determine the predicted test module model, test configuration model, and test strategy model according to the historical test scheme scanning data and its occurrence frequency, the test module operation data, test configuration operation data, and test strategy operation data in the historical test data and their occurrence frequency, the test execution results, program defects, and test case execution efficiency in the historical test data, and the deviation rate of the server test model data; wherein the deviation rate of the server test model data is adjusted according to the historical test data; The data output layer is used to output the test module model, the test configuration model and the test strategy model as predicted server test model data.

8. A server automatic testing device, characterized in that: include: A test model generator pre-construction module is used to pre-construct a test model generator that automatically scans data according to a server test plan to generate server test model data, and adjusts parameters accordingly according to the received test data during the execution of the server test task; A test model data generation module is used to obtain a target server test plan corresponding to a current test requirement during the execution of a server test task on a server test prototype, call the test model generator to automatically scan the target server test plan, and generate server test model data that meets the current test requirement; The test module is used to call the test management platform, generate the current server test task package according to the server test model data and server configuration parameters, and automatically start the server test prototype for testing; The parameter updating module is used to input the test data generated during the execution of the server test task by the server test prototype into the test model generator.

9. An electronic device, characterized in that: The method comprises a processor and a memory, wherein the processor is used to implement the steps of the server automatic testing method according to any one of claims 1 to 7 when executing the computer program stored in the memory.

10. A non-volatile storage medium, characterized in that: The non-volatile storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the server automatic testing method according to any one of claims 1 to 7 are implemented.

Citation Information

Cited By

  • Simulation test system and simulation test tool for universal printer

    CN119354576A

  • Microcomputer system performance test and evaluation method, device, equipment and medium

    CN119576673A