Scripting methods, apparatus, computer equipment and storage media

By adjusting the total number of days and daily execution duration of automated test scripts, and generating and updating script orchestration plans, the problem of low resource utilization caused by traditional manual allocation is solved, achieving more reasonable resource allocation and higher utilization.

CN116185866BActive Publication Date: 2026-05-26INDUSTRIAL AND COMMERCIAL BANK OF CHINA
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
INDUSTRIAL AND COMMERCIAL BANK OF CHINA
Filing Date
2023-03-06
Publication Date
2026-05-26

Smart Images

  • Figure CN116185866B_ABST
    Figure CN116185866B_ABST
Patent Text Reader

Abstract

This application relates to a script orchestration method, apparatus, computer device, storage medium, and computer program product, belonging to the field of artificial intelligence technology. The method includes: acquiring a script execution plan for a test task and preset adjustment information for the script execution plan; when the planned total execution time corresponding to the script execution plan is not equal to the actual total execution time, adjusting the total number of execution days and / or daily execution time of the script execution plan according to the preset adjustment information to obtain a script orchestration plan; the actual total execution time is the sum of the actual execution times of each script in the full set of scripts in the script execution plan; iteratively executing all scripts according to the script orchestration plan to obtain the average execution time of each script in the full set of scripts; updating the script orchestration plan according to the average execution time of each script to obtain an updated script orchestration plan. Using this method can improve the utilization rate of automated testing resources.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of artificial intelligence technology, and in particular to a scripting method, apparatus, computer equipment, storage medium, and computer program product. Background Technology

[0002] With the development of computer software technology, the number of scripts in automated testing projects is constantly increasing. Given limited testing resources, in order to cope with scenarios such as regression testing and version iteration testing where all scripts are executed in batches on a regular basis, it is necessary to rationally allocate the execution order of the scripts.

[0003] Traditional techniques primarily rely on manually allocating the execution order of scripts periodically. However, this allocation method results in significant variations in the execution time of each automated test job, leading to low utilization of automated testing resources. Summary of the Invention

[0004] Therefore, it is necessary to provide a script orchestration method, apparatus, computer equipment, computer-readable storage medium, and computer program product that can improve the utilization rate of automated testing resources to address the aforementioned technical problems.

[0005] Firstly, this application provides a script orchestration method. The method includes:

[0006] Obtain the script execution plan for the test task and preset adjustment information for the script execution plan;

[0007] If the total execution time of the script execution plan is not equal to the actual total execution time, the total number of execution days and / or the daily execution time of the script execution plan are adjusted according to the preset adjustment information to obtain the script orchestration plan; the actual total execution time is the sum of the actual execution times of each script in the full set of scripts in the script execution plan;

[0008] According to the script orchestration plan, the full script is executed iteratively to obtain the average execution time of each script in the full script;

[0009] The script orchestration plan is updated based on the average execution time of each script to obtain the updated script orchestration plan.

[0010] In one embodiment, adjusting the total number of execution days and / or daily execution duration of the script execution plan according to the preset adjustment information to obtain the script orchestration plan includes:

[0011] If the preset adjustment information prioritizes adjusting the daily execution duration, an array of corresponding numbers is created based on the total number of execution days, and each script is sorted in descending order based on its actual execution duration.

[0012] The sorted scripts are sequentially placed into the array with the smallest current cumulative execution time in the created array to obtain the script list to be executed each day within the total number of execution days, which serves as the script orchestration plan; the difference between the total execution time of the script list executed each day and the updated daily execution time meets a preset range, and the updated daily execution time is determined based on the total number of execution days of the script execution plan and the actual total execution time.

[0013] In one embodiment, adjusting the total number of execution days and / or daily execution duration of the script execution plan according to the preset adjustment information to obtain the script orchestration plan includes:

[0014] If the preset adjustment information prioritizes adjusting the total number of execution days, the total number of execution days of the script execution plan is updated based on the daily execution duration of the script execution plan and the actual total execution duration.

[0015] Create an array of corresponding numbers based on the updated total execution days, and sort the scripts in descending order based on the actual execution time of each script;

[0016] The sorted scripts are sequentially placed into the array with the smallest current cumulative execution time in the created array to obtain the daily script list to be executed within the updated total number of execution days, which serves as the script orchestration plan; the total execution time of the daily script list is less than or equal to the daily execution time.

[0017] In one embodiment, updating the total number of execution days of the script execution plan based on the daily execution duration of the script execution plan and the actual total execution duration includes:

[0018] Based on the total planned execution time, the actual total execution time, and the daily execution time, update information for the total number of execution days of the script execution plan is determined; the update information is used to indicate the number of days added or subtracted from the total execution days.

[0019] The total number of execution days is updated based on the updated information to obtain the updated total number of execution days.

[0020] In one embodiment, the step of iteratively executing the entire script according to the script orchestration plan to obtain the average execution time of each script in the entire script includes:

[0021] According to the script orchestration plan, the full script is executed iteratively, and the execution time of each script in the full script is recorded until the total number of executions of the full script is the same as the preset number.

[0022] The average execution time of each script in the full script is determined based on the execution time of each script in the full script.

[0023] In one embodiment, updating the script orchestration plan based on the average execution time of each script to obtain an updated script orchestration plan includes:

[0024] If the total execution time of the script execution plan is not equal to the actual total execution time, the total number of execution days and / or the daily execution time of the script execution plan shall be adjusted again according to the preset adjustment information and the average execution time of each script.

[0025] The updated script orchestration plan is obtained based on the adjustment results of the script execution plan.

[0026] In one embodiment, the method further includes:

[0027] If an execution error occurs during the execution of the full script, an error data alarm message is generated based on the duration of the abnormal execution.

[0028] Based on the abnormal data alarm information, the abnormal execution time of the script is excluded using a preset abnormal data processing method.

[0029] Secondly, this application also provides a script orchestration apparatus. The apparatus includes:

[0030] The information acquisition module is used to acquire the script execution plan of the test task and preset adjustment information for the script execution plan;

[0031] The script orchestration module is used to adjust the total number of execution days and / or daily execution time of the script execution plan according to the preset adjustment information when the total planned execution time corresponding to the script execution plan is not equal to the actual total execution time, so as to obtain the script orchestration plan; the actual total execution time is the sum of the actual execution times of each script in the full set of scripts in the script execution plan;

[0032] The script execution module is used to iteratively execute the full script according to the script orchestration plan to obtain the average execution time of each script in the full script;

[0033] The orchestration update module is used to update the script orchestration plan based on the average execution time of each script, so as to obtain the updated script orchestration plan.

[0034] Thirdly, this application also provides a computer device. The computer device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to perform the following steps:

[0035] Obtain the script execution plan for the test task and preset adjustment information for the script execution plan;

[0036] If the total execution time of the script execution plan is not equal to the actual total execution time, the total number of execution days and / or the daily execution time of the script execution plan are adjusted according to the preset adjustment information to obtain the script orchestration plan; the actual total execution time is the sum of the actual execution times of each script in the full set of scripts in the script execution plan;

[0037] According to the script orchestration plan, the full script is executed iteratively to obtain the average execution time of each script in the full script;

[0038] The script orchestration plan is updated based on the average execution time of each script to obtain the updated script orchestration plan.

[0039] Fourthly, this application also provides a computer-readable storage medium. The computer-readable storage medium stores a computer program thereon, which, when executed by a processor, performs the following steps:

[0040] Obtain the script execution plan for the test task and preset adjustment information for the script execution plan;

[0041] If the total execution time of the script execution plan is not equal to the actual total execution time, the total number of execution days and / or the daily execution time of the script execution plan are adjusted according to the preset adjustment information to obtain the script orchestration plan; the actual total execution time is the sum of the actual execution times of each script in the full set of scripts in the script execution plan;

[0042] According to the script orchestration plan, the full script is executed iteratively to obtain the average execution time of each script in the full script;

[0043] The script orchestration plan is updated based on the average execution time of each script to obtain the updated script orchestration plan.

[0044] Fifthly, this application also provides a computer program product. The computer program product includes a computer program that, when executed by a processor, performs the following steps:

[0045] Obtain the script execution plan for the test task and preset adjustment information for the script execution plan;

[0046] If the total execution time of the script execution plan is not equal to the actual total execution time, the total number of execution days and / or the daily execution time of the script execution plan are adjusted according to the preset adjustment information to obtain the script orchestration plan; the actual total execution time is the sum of the actual execution times of each script in the full set of scripts in the script execution plan;

[0047] According to the script orchestration plan, the full script is executed iteratively to obtain the average execution time of each script in the full script;

[0048] The script orchestration plan is updated based on the average execution time of each script to obtain the updated script orchestration plan.

[0049] The aforementioned script orchestration method, apparatus, computer equipment, storage medium, and computer program product acquire the script execution plan for the test task and preset adjustment information for the script execution plan; when the planned total execution time corresponding to the script execution plan is not equal to the actual total execution time, the total number of execution days and / or daily execution time of the script execution plan are adjusted according to the preset adjustment information to obtain the script orchestration plan; then, according to the script orchestration plan, all scripts are iteratively executed to obtain the average execution time of each script in the full set of scripts; finally, the script orchestration plan is updated according to the average execution time of each script to obtain the updated script orchestration plan. This approach involves first obtaining the script execution plan for the test task and preset adjustment information for that plan. This allows for flexible adjustments to the script execution plan based on the preset information. If the planned total execution time differs from the actual total execution time, the total number of execution days and / or daily execution time are adjusted according to the preset information to obtain a script orchestration plan. This effectively transforms the initial script execution plan into a more realistic orchestration plan, improving the rationality of automated test resource allocation. Finally, based on the script orchestration plan, all scripts are iteratively executed to obtain the average execution time of each script in the full dataset. The execution time is considered because analyzing the average execution time makes the script orchestration analysis more accurate. Finally, the script orchestration plan is updated based on the average execution time of each script, resulting in an updated script orchestration plan. In other words, an automated test script orchestration method based on artificial intelligence technology is used to generate the script orchestration plan. By balancing the resource usage of each automated test job as much as possible while meeting the daily execution time range, the rationality of automated test resource allocation is improved. Moreover, the entire process does not require manual intervention, thus avoiding the deviation caused by subjective human factors and improving the utilization rate of automated test resources. Attached Figure Description

[0050] Figure 1 This is a flowchart illustrating a script orchestration method in one embodiment;

[0051] Figure 2 This is a flowchart illustrating the steps involved in creating a script orchestration plan in one embodiment;

[0052] Figure 3 This is a flowchart illustrating the script orchestration method in another embodiment;

[0053] Figure 4 This is a flowchart illustrating the script orchestration method in yet another embodiment;

[0054] Figure 5 This is a structural block diagram of a script orchestration device in one embodiment;

[0055] Figure 6 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation

[0056] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0057] In one embodiment, such as Figure 1 As shown, a script orchestration method is provided. This embodiment illustrates the application of this method to a terminal. It is understood that this method can also be applied to a server, and to a system including both a terminal and a server, and is implemented through interaction between the terminal and the server. The terminal can be, but is not limited to, various personal computers, laptops, smartphones, tablets, etc.; the server can be a standalone server or a server cluster composed of multiple servers. In this embodiment, the method includes the following steps:

[0058] Step S101: Obtain the script execution plan for the test task and the preset adjustment information for the script execution plan.

[0059] Among them, test tasks refer to automated test tasks, such as script-based regression testing and version iteration testing.

[0060] The script execution plan refers to the script execution plan information that the user pre-defines before the script is executed; for example, the automated test script is fully executed once every 6 days, with a daily execution time of 60 minutes, and a total planned execution time of 360 minutes.

[0061] Among them, the preset adjustment information refers to the user's pre-defined automatic adjustment preferences for the script execution plan when the actual arrangement does not conform to the plan, such as prioritizing the adjustment of the total number of execution days or prioritizing the adjustment of the daily execution duration.

[0062] Specifically, the terminal receives a script orchestration request for an automated testing task, and based on the script orchestration request, obtains the user-defined script execution plan and the preset adjustment information corresponding to the script execution plan.

[0063] For example, suppose a user pre-defined script execution plan is: execute the automated test script once every 6 days, with a daily execution time of 60 minutes, for a total planned execution time of 360 minutes; the pre-defined adjustment information corresponding to this script execution plan is: if the planned total execution time is not equal to the actual total execution time, the total number of execution days will be adjusted first.

[0064] Furthermore, after obtaining the script execution plan for the test task and the preset adjustment information for the script execution plan, the terminal will also execute all scripts according to the preset orchestration plan, record the start timestamp before each script is executed, and record the end timestamp after each script is executed; based on the start timestamp and end timestamp, the script execution duration of each script is obtained, which is used as the actual execution duration of each script in the full set of scripts.

[0065] Step S102: If the total execution time of the script execution plan is not equal to the actual total execution time, adjust the total number of execution days and / or the daily execution time of the script execution plan according to the preset adjustment information to obtain the script orchestration plan; the actual total execution time is the sum of the actual execution times of each script in the full script in the script execution plan.

[0066] The actual total execution time refers to the sum of the actual execution times of each script in the full script execution plan.

[0067] The script orchestration plan refers to the orchestration plan for a script obtained through script orchestration analysis and adjustment based on the script execution plan and preset adjustment information.

[0068] Specifically, the terminal obtains the total planned execution time and the actual total execution time corresponding to the script execution plan, determines whether the total planned execution time and the actual total execution time are equal, and if the total planned execution time and the actual total execution time are not equal, adjusts the total number of execution days and / or the daily execution time of the script execution plan according to the preset adjustment information, and obtains the list of scripts to be executed each day within the total number of execution days, that is, the script orchestration plan.

[0069] For example, consider a scenario where the planned total execution time exceeds the actual total execution time, and the user prioritizes adjusting the total execution days. Assume the user's pre-defined script execution plan is: execute the automated test script once every 6 days, with a daily execution time of 60 minutes, for a planned total execution time of 360 minutes. However, the actual total execution time for one full run of the automated test script is 300 minutes. After processing by the script orchestration and analysis module, the generated execution plan will be: execute the automated test script once every 5 days, with a daily execution time of 60 minutes.

[0070] Step S103: According to the script orchestration plan, iteratively execute all scripts to obtain the average execution time of each script in the full script.

[0071] In this context, iteration refers to the activity of repeating a feedback process, usually with the aim of approximating a desired goal or result. Each repetition of the process is called an "iteration," and the result of each iteration serves as the initial value for the next iteration.

[0072] Specifically, the terminal iteratively executes all scripts according to the script orchestration plan, while recording the execution time of each script in the full script. This process is repeated until the total number of executions of the full script reaches the preset number. Based on the execution time of each script in the full script, the average execution time of each script in the full script is calculated.

[0073] Step S104: Update the script orchestration plan based on the average execution time of each script to obtain the updated script orchestration plan.

[0074] The updated script orchestration plan refers to a more reasonable script orchestration plan derived after multiple iterations.

[0075] Specifically, the terminal re-analyzes the scripts using each module based on the average execution time of each script to obtain a more reasonable script orchestration plan, which serves as the updated script orchestration plan. For example, the terminal uses preset adjustment information and the average execution time of each script to adjust the total number of execution days and / or the daily execution time of the script orchestration plan, resulting in an adjusted script orchestration plan, which serves as the updated script orchestration plan.

[0076] In the above script orchestration method, the script execution plan of the test task and the preset adjustment information for the script execution plan are obtained. When the total execution time of the script execution plan is not equal to the actual total execution time, the total number of execution days and / or the daily execution time of the script execution plan are adjusted according to the preset adjustment information to obtain the script orchestration plan. Then, according to the script orchestration plan, all scripts are executed iteratively to obtain the average execution time of each script in the full set of scripts. Finally, the script orchestration plan is updated according to the average execution time of each script to obtain the updated script orchestration plan. This approach involves first obtaining the script execution plan for the test task and preset adjustment information for that plan. This allows for flexible adjustments to the script execution plan based on the preset information and user preferences. If the planned total execution time differs from the actual total execution time, the total number of execution days and / or daily execution time are adjusted according to the preset information to obtain a script orchestration plan. This effectively transforms the initial script execution plan into a more realistic orchestration plan, improving the rationality of automated test resource allocation. Then, based on the script orchestration plan, all scripts are iteratively executed to obtain the results for each script within the full set. The average execution time of each script is used for analysis, as this makes the script orchestration analysis more accurate. Finally, the script orchestration plan is updated based on the average execution time of each script, resulting in an updated script orchestration plan. In other words, an automated test script orchestration method based on artificial intelligence technology is used to generate the script orchestration plan. By balancing the resource usage of each automated test job as much as possible while meeting the daily execution time range, the rationality of automated test resource allocation is improved. Moreover, the entire process does not require manual intervention, thus avoiding the deviation caused by subjective human factors and improving the utilization rate of automated test resources.

[0077] In one embodiment, step S102 above, adjusting the total number of execution days and / or daily execution duration of the script execution plan according to preset adjustment information to obtain a script orchestration plan, specifically includes the following: when the preset adjustment information prioritizes adjusting the daily execution duration, creating an array corresponding to the total number of execution days, and sorting each script in descending order according to the actual execution duration of each script; placing the sorted scripts sequentially into the array with the smallest current cumulative total execution duration in the created array to obtain a list of scripts to be executed each day within the total number of execution days, which serves as the script orchestration plan; the difference between the total execution duration of the daily script list and the updated daily execution duration satisfies a preset range, and the updated daily execution duration is determined based on the total number of execution days of the script execution plan and the actual total execution duration.

[0078] An array is a linear data structure that uses a contiguous block of memory to store a group of data of the same type.

[0079] Descending sort refers to sorting from largest to smallest.

[0080] The preset range refers to a pre-defined time range, such as the difference between the total execution time of the script list to be executed each day and the updated daily execution time. The time range to be met is between 0 and 10 minutes.

[0081] Specifically, the terminal identifies the obtained script execution plan and preset adjustment information to obtain the total number of execution days of the script execution plan, and the preset adjustment information prioritizes adjusting the daily execution duration; it creates an array corresponding to the total number of execution days, and sorts each script in descending order according to the actual execution duration of each script; it iterates through the sorted scripts and puts the sorted scripts into the array with the smallest current cumulative execution duration in the created array, to obtain a list of scripts to be executed each day within the total number of execution days, which serves as the script orchestration plan.

[0082] For example, suppose a user's pre-defined script execution plan is: execute the automated test script once every 6 days, with a daily execution time of 60 minutes, for a total planned execution time of 360 minutes. However, the actual total execution time of the automated test script once is 300 minutes. The terminal identifies the obtained script execution plan and preset adjustment information, determining that the total execution days of the script execution plan are 6 days, and adjusts the daily execution time from 60 minutes to 50 minutes. Six arrays are created based on the total execution days, and each script is sorted in descending order based on its actual execution time. A greedy algorithm is used to iterate through the sorted scripts and place them sequentially into the array with the smallest current cumulative execution time. If the execution time is the same, the array with the earlier sequence number takes priority. This yields the list of scripts to be executed each day for the 6 days of execution, i.e., the script orchestration plan.

[0083] To further illustrate, suppose there are 9 scripts: A1 (0.5 minutes), A2 (0.8 minutes), A3 (1.2 minutes), A4 (1.5 minutes), A5 (2 minutes), A6 (2.4 minutes), A7 (2.8 minutes), A8 (3 minutes), and A9 (3.2 minutes). Sort them in descending order based on their actual execution time: A9, A8, A7, A6, A5, A4, A3, A2, A1. If the user specifies a total execution period of 3 days, then 3 arrays are created. Using a greedy algorithm, the sorted scripts are traversed, and the script path is placed into the array with the smallest current cumulative execution time (if the current cumulative execution time is the same, the array with the earlier sequence number takes priority). The result is:

[0084]

[0085] In this embodiment, by prioritizing the increase or decrease of the daily execution duration while keeping the total number of execution days unchanged, a list of scripts to be executed daily within the total number of execution days is created as a script orchestration plan, thereby effectively obtaining the target script orchestration plan in this embodiment.

[0086] In one embodiment, such as Figure 2 As shown, in step S102 above, the total number of execution days and / or daily execution duration of the script execution plan are adjusted according to preset adjustment information to obtain the script orchestration plan, which specifically includes the following steps:

[0087] Step S201: If the preset adjustment information is to prioritize adjusting the total number of execution days, update the total number of execution days of the script execution plan based on the daily execution duration of the script execution plan and the actual total execution duration.

[0088] Step S202: Create an array of corresponding numbers based on the updated total execution days, and sort the scripts in descending order based on the actual execution time of each script.

[0089] Step S203: Place the sorted scripts into the array with the smallest current cumulative execution time in the created array to obtain the daily script list to be executed within the updated total execution days, which serves as the script orchestration plan; the total execution time of the daily script list is less than or equal to the daily execution time.

[0090] The updated total execution days refer to the new total execution days obtained by adding or subtracting from the original total execution days.

[0091] Specifically, the terminal identifies the obtained script execution plan and preset adjustment information to obtain the total number of execution days of the script execution plan, and the preset adjustment information prioritizes adjusting the total number of execution days; based on the daily execution duration of the script execution plan and the actual total execution duration, the total number of execution days of the script execution plan is updated; an array corresponding to the updated total number of execution days is created, and each script is sorted in descending order based on its actual execution duration; the sorted scripts are traversed, and the sorted scripts are sequentially placed into the array with the smallest current cumulative total execution duration in the created array, to obtain the list of scripts to be executed each day within the updated total number of execution days, which serves as the script orchestration plan.

[0092] For example, suppose a user's pre-defined script execution plan is: execute the automated test script once every 6 days, with a daily execution time of 60 minutes, for a planned total execution time of 360 minutes. However, the actual total execution time for the automated test script once is 300 minutes. The terminal identifies the obtained script execution plan and preset adjustment information, determining that the daily execution time is 60 minutes, and adjusts the total execution days from 6 days to 5 days. Five arrays are created based on the updated total execution days, and each script is sorted in descending order according to its actual execution time. A greedy algorithm is used to iterate through the sorted scripts and place them sequentially into the array with the smallest current cumulative execution time. If the execution time is the same, the array with the earlier sequence number takes priority, thus obtaining the list of scripts to be executed each day within the 5-day execution period, i.e., the script orchestration plan.

[0093] In this embodiment, by prioritizing the increase or decrease of the total execution days, an updated list of scripts to be executed daily within the total execution days is created as a script orchestration plan, thereby effectively obtaining the target script orchestration plan in this embodiment.

[0094] In one embodiment, step S201 above, updating the total number of execution days of the script execution plan based on the daily execution duration of the script execution plan and the actual total execution duration, specifically includes the following: determining the update information of the total number of execution days of the script execution plan based on the planned total execution duration, the actual total execution duration, and the daily execution duration; the update information is used to indicate the number of days added or subtracted from the total number of execution days; updating the total number of execution days based on the update information to obtain the updated total number of execution days.

[0095] The update information refers to information used to indicate the number of days added or subtracted from the total number of execution days.

[0096] Specifically, the terminal inputs the planned total execution time, the actual total execution time, and the daily execution time into a pre-built numerical calculation model to obtain the numerical calculation results; based on the numerical calculation results, it determines the update information of the total number of execution days of the script execution plan; and updates the total number of execution days according to the update information to obtain the updated total number of execution days.

[0097] For example, suppose the user pre-defined script execution plan is: to execute the automated test script once every 6 days, with a daily execution time of 60 minutes, and a planned total execution time of 360 minutes. However, the actual total execution time of executing the automated test script once is 300 minutes. After calculation, the numerical result is -1, that is, the updated information of the total execution days is -1. Based on the updated information, the total execution days are updated to 5 days.

[0098] In this embodiment, the total number of execution days of the script execution plan is accurately calculated using three data indicators: total planned execution time, total actual execution time, and daily execution time; thus, the updated total number of execution days is effectively obtained.

[0099] In one embodiment, step S103 above, which iteratively executes all scripts according to the script orchestration plan to obtain the average execution time of each script in the full script, specifically includes the following: according to the script orchestration plan, iteratively executes all scripts and records the execution time of each script in the full script until the total number of executions of the full script is the same as the preset number; and determines the average execution time of each script in the full script based on the execution time of each script in the full script.

[0100] The preset number of times refers to the target number of times the full script is executed, which is set in advance.

[0101] Specifically, the terminal obtains the preset number of times to execute the full script. After completing the initial script orchestration analysis, it iteratively executes the full script according to the script orchestration plan, while recording the execution duration of each script in the full script until the total number of executions of the full script is the same as the preset number. Based on the execution duration of each script in the full script, the average execution duration of each script in the full script is calculated.

[0102] In this embodiment, the full script is executed in multiple rounds of iteration, and the execution time of each script in the full script is recorded. Based on the recorded valid information, the average execution time of each script in the full script is accurately calculated.

[0103] In one embodiment, in step S104 above, the script orchestration plan is updated based on the average execution time of each script to obtain an updated script orchestration plan. Specifically, this includes the following: if the total planned execution time corresponding to the script execution plan is not equal to the actual total execution time, the total number of execution days and / or the daily execution time of the script execution plan are adjusted again based on preset adjustment information and the average execution time of each script; and the updated script orchestration plan is obtained based on the adjustment results of the script execution plan.

[0104] The script execution plan adjustment result refers to the result obtained after making more accurate adjustments based on preset adjustment information and the average execution time of each script.

[0105] Specifically, the terminal obtains the planned total execution time and the actual total execution time corresponding to the script execution plan, determines whether the planned total execution time and the actual total execution time are equal, and if they are not equal, adjusts the total number of execution days and / or the daily execution time of the script execution plan again according to the preset adjustment information and the average execution time of each script; based on the adjustment result of the script execution plan, obtains the list of scripts to be executed each day within the new total number of execution days, that is, obtains the updated script orchestration plan.

[0106] For example, an automated testing project plans to execute the automated test scripts once every 6 days, with 60 minutes of execution per day, for a total planned execution time of 360 minutes. If the actual total execution time is longer than the planned total execution time, and the user chooses to prioritize adjusting the total number of execution days, assuming the actual total execution time of the automated testing project is 420 minutes, then after processing by the script orchestration and analysis module, the generated execution plan will be to execute the automated test scripts once every 7 days, with 60 minutes of execution per day.

[0107] To illustrate further, an automated testing project is planned to execute the automated test scripts once every 6 days, with each day lasting 60 minutes, for a total planned execution time of 360 minutes. If the actual total execution time is less than the planned total execution time, and the user chooses to prioritize adjusting the daily execution time, assuming the actual total execution time of the automated testing project is 300 minutes, then after processing by the script orchestration and analysis module, the generated execution plan will be to execute the automated test scripts once every 6 days, with each day lasting 50 minutes.

[0108] In this embodiment, when the total planned execution time corresponding to the script execution plan is not equal to the actual total execution time, the total number of execution days and / or daily execution time of the script execution plan are adjusted again according to the preset adjustment information and the average execution time of each script, so as to effectively obtain the updated script orchestration plan based on the adjustment result of the script execution plan.

[0109] In one embodiment, the script orchestration method further includes the following: during the execution of the full script, if a script execution exception occurs, generating an exception data alarm message based on the exception execution duration of the script; and using a preset exception data processing method to exclude the exception execution duration of the script based on the exception data alarm message.

[0110] Among them, abnormal script execution refers to situations where the script execution time is too short or too long.

[0111] The preset abnormal data handling methods typically include two types: manual exclusion by the user and automatic exclusion by the system.

[0112] Specifically, during the execution of the full script, if the terminal identifies a script execution exception, it obtains the exception execution duration corresponding to the exception and generates an exception data alarm based on the exception execution duration. Then, based on the exception data alarm, it uses a preset exception data processing method to exclude the exception execution duration of the script.

[0113] For example, during the execution of a full script, if the terminal detects that the script execution time is too long, it obtains the abnormal execution time corresponding to the script execution exception and generates an exception data alarm information based on the abnormal execution time of the script; then, based on the abnormal data alarm information, the system automatically excludes the abnormal execution time of the script.

[0114] In this embodiment, by generating abnormal data alarm information when a script execution exception occurs, and using a preset abnormal data processing method to exclude the abnormal execution time of the abnormal script, the impact of abnormal execution time on script orchestration and analysis is reduced.

[0115] In one embodiment, such as Figure 3 As shown, another script orchestration method is provided, which includes the following steps:

[0116] Step S301: Obtain the script execution plan for the test task and the preset adjustment information for the script execution plan.

[0117] Step S302: If the preset adjustment information is to prioritize adjusting the daily execution duration, create an array of corresponding numbers based on the total number of execution days, and sort each script in descending order based on the actual execution duration of each script.

[0118] Step S303: The sorted scripts are sequentially placed into the array with the smallest current cumulative total execution time in the created array to obtain the script list to be executed each day within the total number of execution days, which serves as the script orchestration plan; the difference between the total execution time of the script list executed each day and the updated daily execution time meets the preset range, and the updated daily execution time is determined based on the total number of execution days of the script execution plan and the actual total execution time.

[0119] Step S304: If the preset adjustment information is to prioritize adjusting the total number of execution days, determine the update information of the total number of execution days of the script execution plan based on the planned total execution time, the actual total execution time, and the daily execution time; the update information is used to indicate the number of days added or subtracted based on the total number of execution days.

[0120] Step S305: Update the total execution days according to the update information to obtain the updated total execution days; create an array with the corresponding number of execution days according to the updated total execution days, and sort the scripts in descending order according to the actual execution time of each script.

[0121] Step S306: Place the sorted scripts into the array with the smallest current cumulative execution time in the created array to obtain the daily script list to be executed within the updated total execution days, which serves as the script orchestration plan; the total execution time of the daily script list is less than or equal to the daily execution time.

[0122] Step S307: According to the script orchestration plan, iteratively execute all scripts and record the execution time of each script in the full script until the total number of executions of the full script is the same as the preset number; determine the average execution time of each script in the full script based on the execution time of each script in the full script.

[0123] Step S308: If the total planned execution time corresponding to the script execution plan is not equal to the actual total execution time, adjust the total number of execution days and / or daily execution time of the script execution plan again according to the preset adjustment information and the average execution time of each script; and obtain the updated script orchestration plan based on the adjustment results of the script execution plan.

[0124] Step S309: If a script execution exception occurs during the execution of the full script, generate an exception data alarm message based on the exception execution duration of the script; based on the exception data alarm message, use a preset exception data processing method to exclude the exception execution duration of the script.

[0125] In the above script orchestration method, the script execution plan for the test task and the preset adjustment information for the script execution plan are first obtained. This facilitates subsequent adjustments to the script execution plan based on the preset adjustment information and the user's adjustment preferences. When the preset adjustment information prioritizes adjusting the daily execution duration, an array corresponding to the total number of execution days is created. Each script is then sorted in descending order based on its actual execution duration. The sorted scripts are then sequentially placed into the array with the smallest current cumulative total execution duration, resulting in a list of scripts to be executed each day within the total number of execution days, which serves as the script orchestration plan. By prioritizing increasing or decreasing the daily execution duration while keeping the total number of execution days constant, a list of scripts to be executed daily within the total number of execution days is created, thereby effectively obtaining the target script orchestration plan in this embodiment. With the preset adjustment information prioritizing the adjustment of the total execution days, the update information of the total execution days of the script execution plan is determined based on the planned total execution time, the actual total execution time, and the daily execution time. The total execution days are then updated according to the updated information to obtain the updated total execution days. An array corresponding to the updated total execution days is created, and the scripts are sorted in descending order according to the actual execution time of each script. The sorted scripts are then placed sequentially into the array with the smallest current cumulative total execution time, resulting in a list of scripts to be executed each day within the updated total execution days, which serves as the script orchestration plan. By creating a list of scripts to be executed daily within the updated total execution days with the priority of increasing or decreasing the total execution days, the target script orchestration plan in this embodiment is effectively obtained. According to the script orchestration plan, all scripts are executed iteratively, and the execution duration of each script in the full script is recorded until the total number of executions of the full script is the same as the preset number. Based on the execution duration of each script in the full script, the average execution duration of each script in the full script is determined. Through multiple rounds of iterative execution of the full script, while recording the execution duration of each script in the full script, the average execution duration of each script in the full script is accurately calculated based on the recorded valid information. If the planned total execution duration corresponding to the script execution plan is not equal to the actual total execution duration, the total number of execution days and / or the daily execution duration of the script execution plan are adjusted again based on the preset adjustment information and the average execution duration of each script. Thus, based on the adjustment results of the script execution plan, an updated script orchestration plan is effectively obtained. During the execution of the full script, if a script execution abnormality occurs, abnormal data alarm information is generated based on the abnormal execution duration of the script. Based on the abnormal data alarm information, the abnormal execution duration of the script is excluded using a preset abnormal data processing method, thereby reducing the impact of abnormal execution duration on script orchestration analysis.This involves using an automated test script orchestration method based on artificial intelligence technology to generate script orchestration plans. By balancing the resource usage of each automated test job as much as possible while meeting the daily execution time range, the rationality of automated test resource allocation is improved. Moreover, the entire process does not require manual intervention, thereby avoiding deviations caused by subjective human factors and improving the utilization rate of automated test resources.

[0126] To more clearly illustrate the script orchestration method provided in the embodiments of this application, the following describes the script orchestration method in detail with a specific embodiment. In one embodiment, as follows... Figure 4 As shown, this application also provides another script orchestration method, which specifically includes the following steps:

[0127] Step 1: Obtain the user-defined script execution plan, as well as the automatic adjustment preference when the actual orchestration does not conform to the plan.

[0128] Step 2: Perform the first full script execution using the default orchestration plan, and record the resource usage of each script through the resource monitoring module.

[0129] Step 3: Calculate the total resource usage based on the resource usage records of each script, and perform script orchestration analysis.

[0130] Step 4: Determine whether the user-defined script execution plan is met.

[0131] Step 5: If the script orchestration analysis results do not meet the script execution plan, adjust the script execution plan according to the automatic adjustment preference.

[0132] Step 6: Complete the orchestration and obtain the script orchestration plan.

[0133] Step 7: Iteratively execute the entire script using the generated script orchestration plan, and after multiple iterations, obtain a more reasonable script orchestration plan.

[0134] In the above script orchestration method, the user-defined script execution plan and the automatic adjustment preference when the actual orchestration does not conform to the plan are first obtained, facilitating subsequent flexible adjustment of the script execution plan based on the user's adjustment preference. An initial full script execution is performed using the default orchestration plan, and the resource usage of each script is recorded through the resource monitoring module, thereby accurately obtaining the execution time of each script. Based on the resource usage records of each script, the total resource usage is calculated, providing data for subsequent script orchestration analysis. It is then determined whether the user-defined script execution plan is met. If the script orchestration analysis results show that the script execution plan is not met, the script execution plan is adjusted according to the automatic adjustment preference, completing the orchestration and obtaining the script orchestration plan, thus effectively implementing the initial script execution plan. Adjusting the script orchestration plan to better suit the actual situation helps improve the rationality of automated testing resource allocation. Finally, based on the generated script orchestration plan, all scripts are executed iteratively to obtain the average execution time of each script. The script orchestration plan is then updated based on the average execution time of each script to obtain a more reasonable script orchestration plan. In other words, using an automated testing script orchestration method based on artificial intelligence technology to generate the script orchestration plan improves the rationality of automated testing resource allocation by balancing the resource usage of each automated testing job as much as possible while meeting the daily execution time range. Moreover, the entire process does not require manual intervention, thus avoiding deviations caused by subjective human factors and improving the utilization rate of automated testing resources.

[0135] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0136] Based on the same inventive concept, this application also provides a script orchestration apparatus for implementing the script orchestration method described above. The solution provided by this apparatus is similar to the implementation scheme described in the above method; therefore, the specific limitations in one or more script orchestration apparatus embodiments provided below can be found in the limitations of the script orchestration method described above, and will not be repeated here.

[0137] In one embodiment, such as Figure 5As shown, a script orchestration device is provided, including: an information acquisition module 501, a script orchestration module 502, a script execution module 503, and an orchestration update module 504, wherein:

[0138] The information acquisition module 501 is used to acquire the script execution plan of the test task and the preset adjustment information for the script execution plan.

[0139] The script orchestration module 502 is used to adjust the total number of execution days and / or daily execution time of the script execution plan according to preset adjustment information when the total execution time of the script execution plan is not equal to the actual total execution time, so as to obtain the script orchestration plan; the actual total execution time is the sum of the actual execution time of each script in the full script in the script execution plan.

[0140] The script execution module 503 is used to iteratively execute all scripts according to the script orchestration plan to obtain the average execution time of each script in the full script.

[0141] The orchestration update module 504 is used to update the script orchestration plan based on the average execution time of each script, so as to obtain the updated script orchestration plan.

[0142] In one embodiment, the script orchestration module 502 is further configured to, under the preset adjustment information of prioritizing the adjustment of daily execution time, create an array corresponding to the total number of execution days, and sort each script in descending order according to the actual execution time of each script; place the sorted scripts into the array with the smallest current cumulative total execution time in the created array, to obtain a list of scripts to be executed each day within the total number of execution days, as the script orchestration plan; the difference between the total execution time of the script list executed each day and the updated daily execution time meets a preset range, and the updated daily execution time is determined based on the total number of execution days of the script execution plan and the actual total execution time.

[0143] In one embodiment, the script orchestration module 502 is further configured to: update the total execution days of the script execution plan based on the daily execution duration of the script execution plan and the actual total execution duration, provided that the preset adjustment information prioritizes adjusting the total execution days; create an array of corresponding numbers based on the updated total execution days, and sort the scripts in descending order based on the actual execution duration of each script; place the sorted scripts sequentially into the array with the smallest current cumulative total execution duration in the created array, thereby obtaining a list of scripts to be executed each day within the updated total execution days, which serves as the script orchestration plan; the total execution duration of the script list executed each day is less than or equal to the daily execution duration.

[0144] In one embodiment, the script orchestration module 502 is further configured to determine update information of the total number of execution days of the script execution plan based on the planned total execution time, the actual total execution time, and the daily execution time; the update information is used to indicate the number of days added or subtracted based on the total number of execution days; and the total number of execution days is updated based on the update information to obtain the updated total number of execution days.

[0145] In one embodiment, the script execution module 503 is further configured to iteratively execute the entire script according to the script orchestration plan, and record the execution duration of each script in the entire script until the total number of executions of the entire script is the same as the preset number; and determine the average execution duration of each script in the entire script based on the execution duration of each script in the entire script.

[0146] In one embodiment, the orchestration update module 504 is further configured to, when the total planned execution time corresponding to the script execution plan is not equal to the actual total execution time, adjust the total number of execution days and / or the daily execution time of the script execution plan again according to preset adjustment information and the average execution time of each script; and obtain the updated script orchestration plan based on the adjustment result of the script execution plan.

[0147] In one embodiment, the script orchestration device further includes an exception handling module, which is used to generate exception data alarm information based on the exception execution duration of the script when an exception occurs during the execution of the full script; and to exclude the exception execution duration of the script using a preset exception data processing method based on the exception data alarm information.

[0148] Each module in the aforementioned script orchestration device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device, or stored in the memory of a computer device as software, so that the processor can call and execute the operations corresponding to each module.

[0149] In one embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 6As shown, the computer device includes a processor, memory, input / output interfaces, a communication interface, a display unit, and an input device. The processor, memory, and input / output interfaces are connected via a system bus, and the communication interface, display unit, and input device are also connected to the system bus via the input / output interfaces. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The input / output interfaces are used for exchanging information between the processor and external devices. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, mobile cellular networks, NFC (Near Field Communication), or other technologies. When the computer program is executed by the processor, it implements a scripting method. The display unit is used to form a visually visible image and can be a display screen, a projection device, or a virtual reality imaging device. The display screen can be an LCD screen or an e-ink screen. The input device of the computer device can be a touch layer covering the display screen, or buttons, trackballs, or touchpads set on the casing of the computer device, or external keyboards, touchpads, or mice, etc.

[0150] Those skilled in the art will understand that Figure 6 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0151] In one embodiment, a computer device is provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to perform the following steps:

[0152] Obtain the script execution plan for the test task and preset adjustment information for the script execution plan;

[0153] If the total execution time of the script execution plan is not equal to the actual total execution time, the total number of execution days and / or the daily execution time of the script execution plan are adjusted according to the preset adjustment information to obtain the script orchestration plan; the actual total execution time is the sum of the actual execution times of each script in the full set of scripts in the script execution plan;

[0154] According to the script orchestration plan, the full script is executed iteratively to obtain the average execution time of each script in the full script;

[0155] The script orchestration plan is updated based on the average execution time of each script to obtain the updated script orchestration plan.

[0156] In one embodiment, when the processor executes the computer program, it further performs the following steps: If the preset adjustment information prioritizes adjusting the daily execution duration, an array corresponding to the total number of execution days is created, and each script is sorted in descending order based on its actual execution duration; the sorted scripts are then sequentially placed into the array with the smallest current cumulative total execution duration, resulting in a list of scripts to be executed each day within the total number of execution days, which serves as the script orchestration plan; the difference between the total execution duration of the daily script list and the updated daily execution duration satisfies a preset range, and the updated daily execution duration is determined based on the total number of execution days of the script execution plan and the actual total execution duration.

[0157] In one embodiment, when the processor executes the computer program, it further performs the following steps: If the preset adjustment information prioritizes adjusting the total number of execution days, update the total number of execution days of the script execution plan based on the daily execution duration of the script execution plan and the actual total execution duration; create an array corresponding to the updated total number of execution days, and sort the scripts in descending order based on the actual execution duration of each script; place the sorted scripts sequentially into the array with the smallest current cumulative total execution duration in the created array, obtaining a list of scripts to be executed each day within the updated total number of execution days, which serves as the script orchestration plan; the total execution duration of the script list executed each day is less than or equal to the daily execution duration.

[0158] In one embodiment, when the processor executes the computer program, it further performs the following steps: determining update information for the total number of execution days of the script execution plan based on the planned total execution time, the actual total execution time, and the daily execution time; the update information is used to indicate the number of days added or subtracted from the total number of execution days; and updating the total number of execution days based on the update information to obtain the updated total number of execution days.

[0159] In one embodiment, when the processor executes the computer program, it further performs the following steps: according to the script orchestration plan, iteratively executes the entire script and records the execution time of each script in the entire script until the total number of executions of the entire script is the same as the preset number; and determines the average execution time of each script in the entire script based on the execution time of each script in the entire script.

[0160] In one embodiment, when the processor executes the computer program, it further performs the following steps: if the total planned execution time corresponding to the script execution plan is not equal to the actual total execution time, adjust the total number of execution days and / or the daily execution time of the script execution plan again according to the preset adjustment information and the average execution time of each script; and obtain the updated script orchestration plan based on the adjustment result of the script execution plan.

[0161] In one embodiment, when the processor executes the computer program, it further performs the following steps: if a script execution exception occurs during the execution of the full script, an exception data alarm message is generated based on the exception execution duration of the script; based on the exception data alarm message, a preset exception data processing method is used to exclude the exception execution duration of the script.

[0162] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon that, when executed by a processor, implements the steps in the above method embodiments.

[0163] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in the above method embodiments.

[0164] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of the relevant data shall comply with the relevant laws, regulations and standards of the relevant countries and regions.

[0165] 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 instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, etc., and are not limited to these.

[0166] 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.

[0167] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. 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 application should be determined by the appended claims.

Claims

1. A script arrangement method, characterized in that, The method includes: Obtain the script execution plan for the test task and preset adjustment information for the script execution plan; If the total execution time of the script execution plan is not equal to the actual total execution time, the total number of execution days and / or the daily execution time of the script execution plan are adjusted according to the preset adjustment information to obtain the script orchestration plan; the actual total execution time is the sum of the actual execution times of each script in the full set of scripts in the script execution plan; According to the script orchestration plan, the full script is executed iteratively to obtain the average execution time of each script in the full script; The script orchestration plan is updated based on the average execution time of each script to obtain the updated script orchestration plan. The step of updating the script orchestration plan based on the average execution time of each script to obtain the updated script orchestration plan includes: If the total execution time of the script execution plan is not equal to the actual total execution time, the total number of execution days and / or the daily execution time of the script execution plan shall be adjusted again according to the preset adjustment information and the average execution time of each script. The updated script orchestration plan is obtained based on the adjustment results of the script execution plan.

2. The method according to claim 1, characterized in that, The step of adjusting the total number of execution days and / or daily execution duration of the script execution plan according to the preset adjustment information to obtain the script orchestration plan includes: If the preset adjustment information prioritizes adjusting the daily execution duration, an array of corresponding numbers is created based on the total number of execution days, and each script is sorted in descending order based on its actual execution duration. The sorted scripts are sequentially placed into the array with the smallest current cumulative execution time in the created array to obtain the script list to be executed each day within the total number of execution days, which serves as the script orchestration plan; the difference between the total execution time of the script list executed each day and the updated daily execution time meets a preset range, and the updated daily execution time is determined based on the total number of execution days of the script execution plan and the actual total execution time.

3. The method according to claim 1, characterized in that, The step of adjusting the total number of execution days and / or daily execution duration of the script execution plan according to the preset adjustment information to obtain the script orchestration plan includes: If the preset adjustment information prioritizes adjusting the total number of execution days, the total number of execution days of the script execution plan is updated based on the daily execution duration of the script execution plan and the actual total execution duration. Create an array of corresponding numbers based on the updated total execution days, and sort the scripts in descending order based on the actual execution time of each script; The sorted scripts are sequentially placed into the array with the smallest current cumulative execution time in the created array to obtain the daily script list to be executed within the updated total number of execution days, which serves as the script orchestration plan; the total execution time of the daily script list is less than or equal to the daily execution time.

4. The method according to claim 3, characterized in that, The step of updating the total number of execution days of the script execution plan based on the daily execution duration of the script execution plan and the actual total execution duration includes: Based on the total planned execution time, the actual total execution time, and the daily execution time, update information for the total number of execution days of the script execution plan is determined; the update information is used to indicate the number of days added or subtracted from the total execution days. The total number of execution days is updated based on the updated information to obtain the updated total number of execution days.

5. The method according to claim 1, characterized in that, The step of iteratively executing the full scripts according to the script orchestration plan to obtain the average execution time of each script in the full scripts includes: According to the script orchestration plan, the full script is executed iteratively, and the execution time of each script in the full script is recorded until the total number of executions of the full script is the same as the preset number. The average execution time of each script in the full script is determined based on the execution time of each script in the full script.

6. The method according to claim 1, characterized in that, The method further includes: If an execution error occurs during the execution of the full script, an error data alarm message is generated based on the duration of the abnormal execution. Based on the abnormal data alarm information, the abnormal execution time of the script is excluded using a preset abnormal data processing method.

7. A script arrangement device, characterized in that, The device includes: The information acquisition module is used to acquire the script execution plan of the test task and preset adjustment information for the script execution plan; The script orchestration module is used to adjust the total number of execution days and / or daily execution time of the script execution plan according to the preset adjustment information when the total planned execution time corresponding to the script execution plan is not equal to the actual total execution time, so as to obtain the script orchestration plan; the actual total execution time is the sum of the actual execution times of each script in the full set of scripts in the script execution plan; The script execution module is used to iteratively execute the full script according to the script orchestration plan to obtain the average execution time of each script in the full script; The orchestration update module is used to update the script orchestration plan based on the average execution time of each script, so as to obtain the updated script orchestration plan. The orchestration update module is specifically used to adjust the total number of execution days and / or daily execution time of the script execution plan again, based on the preset adjustment information and the average execution time of each script, when the total planned execution time corresponding to the script execution plan is not equal to the actual total execution time. The updated script orchestration plan is obtained based on the adjustment results of the script execution plan.

8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.

10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.