CN115794654A - Test case distribution processing method, system, equipment and storage medium - Google Patents

Test case distribution processing method, system, equipment and storage medium Download PDF

Info

Publication number
CN115794654A
CN115794654A CN202211652334.8A CN202211652334A CN115794654A CN 115794654 A CN115794654 A CN 115794654A CN 202211652334 A CN202211652334 A CN 202211652334A CN 115794654 A CN115794654 A CN 115794654A
Authority
CN
China
Prior art keywords
case
test case
list
redis database
data
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202211652334.8A
Other languages
Chinese (zh)
Inventor
黄韶军
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ping An Bank Co Ltd
Original Assignee
Ping An Bank Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ping An Bank Co Ltd filed Critical Ping An Bank Co Ltd
Priority to CN202211652334.8A priority Critical patent/CN115794654A/en
Publication of CN115794654A publication Critical patent/CN115794654A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

When an idle process exists in an execution machine, an lua language script is actively called to obtain an executed case, the lua language script accesses a redis database in a single thread mode, a corresponding list object list is determined from the redis database according to the type of the case which can be executed by the execution machine, and therefore automatic test case data which enter the list object list firstly are returned to the execution machine, and the execution machine executes a test. The case data is stored in the redis database, the situation data is prevented from being acquired by a plurality of execution machines in a message queue mode, the execution machines actively acquire simple profit, the passive waiting relation between case distribution and the execution machines is decoupled, the resources of the execution machines are effectively utilized, and the technical problem that if a case is directly placed in an MQ message queue, different execution machines can possibly acquire the same case information, so that the same case can be executed for a plurality of times is solved.

Description

Test case distribution processing method, system, equipment and storage medium
Technical Field
The present application relates to the field of automated testing technologies, and in particular, to a method, a system, a device, and a storage medium for distributing and processing test cases.
Background
In the process of distributing the automatic test cases to the execution machines, the traditional case distribution is to pack a plurality of cases into a case set and then distribute the case set to one execution machine to execute each case in sequence for testing.
However, since the number of cases included in the case set is too large, it is easy to cause resource exhaustion of the execution machine or there is a case where one execution machine is queued for a large number of cases, and other execution machines not distributed to the case set are in an idle state.
In the conventional queue scheme, a message queue MQ is mostly adopted, and if a case is directly put into the MQ message queue, different execution machines may acquire the same case information, so that the technical problem that the same case can be executed for multiple times is caused.
Disclosure of Invention
The application provides a method, a system, equipment and a storage medium for distributing and processing test cases, which solve the technical problem that if the cases are directly put into an MQ message queue, different execution machines may acquire the same case information, so that the same case can be executed for multiple times.
In view of this, a first aspect of the present application provides a test case distribution processing method, where the method includes:
s1, when an idle thread exists in an execution machine, the execution machine sends a case distribution request to a lua language script, wherein the case distribution request carries a case type;
s2, the lua language script single thread accesses a redis database, a list object list corresponding to the case type is determined, and the automated test case data which enters the most in the list object list is taken out;
s3, the lua language script returns the automatic test case data to the execution machine;
and S4, the execution machine executes the automatic test case data to perform automatic test.
Optionally, before the step S1, the method further includes:
and judging whether an idle process exists according to a preset timing task execution machine, if so, executing the step S1, otherwise, not acting.
Optionally, before the step S1, the method further includes:
establishing at least one list object list in a redis database, wherein each list object list marks a corresponding key, and the value of the key corresponds to the type of the case.
Optionally, after the at least one list object is established in the redis database, the method further includes:
the redis database acquires at least one case set, wherein the case set comprises at least one piece of automatic test case data;
and the redis database distributes and pushes the automatic test case data to the corresponding list object list according to the case types of the automatic test case data in different case sets.
A second aspect of the present application provides a test case distribution processing system, which includes:
a redis database, a lua language script, and at least one execution engine;
when the execution machine has an idle thread, the execution machine sends a case distribution request to the lua language script, wherein the case distribution request carries a case type;
the lua language script single thread accesses the redis database, determines a list object list corresponding to the case type, and takes out the automated test case data which enters most in the list object list;
the lua language script returns the automated test case data to the execution machine;
and the execution machine executes the automatic test case data to carry out automatic test.
Optionally, the method further comprises:
and judging whether an idle process exists by the executing machine according to a preset time task, if so, executing the step S1, otherwise, not acting.
Optionally, the method further comprises:
establishing at least one list object list in the redis database, wherein each list object list marks a corresponding key, and the value of the key corresponds to the type of the case.
Optionally, the method further comprises:
the redis database acquires at least one case set, wherein the case set comprises at least one piece of automatic test case data;
and the redis database distributes and pushes the automatic test case data to the corresponding list object list according to the case types of the automatic test case data in different case sets.
A third aspect of the application provides a test case distribution processing apparatus, the apparatus comprising a processor and a memory:
the memory is used for storing program codes and transmitting the program codes to the processor;
the processor is adapted to perform the steps of the method of test case distribution processing as described in the first aspect above, according to instructions in the program code.
A fourth aspect of the present application provides a computer-readable storage medium for storing program code for performing the method of the first aspect.
According to the technical scheme, the embodiment of the application has the following advantages:
the application provides a method, a system, equipment and a storage medium for distributing and processing test cases, when an idle process exists in an execution machine, an lua language script is actively called to obtain an executed case, the lua language script accesses a redis database in a single thread mode, a corresponding list object list is determined from the redis database according to the type of the case which can be executed by the execution machine, and therefore automatic test case data which enters the most in the list object list are returned to the execution machine, and the execution machine executes a test. The case data is stored in the redis database, the situation data is prevented from being acquired by a plurality of execution machines in a message queue mode, the execution machines actively acquire simple profit, the passive waiting relation between case distribution and the execution machines is decoupled, the resources of the execution machines are effectively utilized, and the technical problem that if a case is directly placed in an MQ message queue, different execution machines can possibly acquire the same case information, so that the same case can be executed for a plurality of times is solved.
Drawings
FIG. 1 is a flowchart of a first method of test case distribution processing in an embodiment of the present application;
FIG. 2 is a flow chart of a second method of test case distribution processing in an embodiment of the present application;
FIG. 3 is a schematic structural diagram of a test case distribution processing system in an embodiment of the present application;
fig. 4 is a schematic structural diagram of a test case distribution processing apparatus in an embodiment of the present application.
Detailed Description
In order to make the technical solutions of the present application better understood, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The application designs a method, a system, equipment and a storage medium for distributing and processing test cases, and solves the technical problem that if the cases are directly placed in an MQ message queue, different execution machines may acquire the same case information, so that the same case can be executed for multiple times.
For convenience of understanding, please refer to fig. 1, fig. 1 is a flowchart of a first method of a test case distribution processing method in the embodiment of the present application, and as shown in fig. 1, specifically, the method includes:
s1, when an idle thread exists in an execution machine, the execution machine sends a case distribution request to a lua language script, wherein the case distribution request carries a case type;
it should be noted that, when the execution machine has an idle thread, the case distribution request may be actively sent to the lua language script, and the case distribution request carries a case type, so as to obtain the automated test case data of the case type fed back by the lua language script.
S2, accessing a redis database by a single thread of a lua language script, determining a list object list corresponding to the case type, and taking out the most advanced automatic test case data in the list object list;
it should be noted that, the lua language script single thread accesses the redis database, obtains the list object list corresponding to the case type, and takes out an automated test case data which enters the queue most first from the list object list. The Lua language script has the safety characteristic of thread access, and thread problems existing in concurrent access do not need to be considered.
S3, returning the automatic test case data to the execution machine by the lua language script;
it should be noted that the lua language script returns the acquired automated test case data to the execution machine corresponding to the request.
And S4, executing the automatic test case data by the executing machine to perform automatic test.
Further, step S1 is preceded by:
and judging whether an idle process exists according to a preset timing task execution machine, if so, executing the step S1, otherwise, not acting.
Further, referring to fig. 2, fig. 2 is a flowchart illustrating a second method of a test case distribution processing method in the embodiment of the present application, and as shown in fig. 2, step S1 further includes:
s01, establishing at least one list object list in a redis database, marking a corresponding key by each list object list, wherein the value of the key corresponds to the type of the case;
it should be noted that at least one list object list is established in the redis database, different list object lists are marked by different keys and represent different case types, that is, the subsequent automatic test cases of different case types enter the list object list of the corresponding key, so as to implement directional distribution. Meanwhile, a list object list is used instead of an MQ message queue, so that multiple execution machines are prevented from acquiring the same automatic test case.
S02, obtaining at least one case set by a redis database, wherein the case set comprises at least one piece of automatic test case data;
it should be noted that one case set includes at least one piece of automated test case data, and the case types of the automated test case data are the same in the same case set.
And S03, the redis database distributes and pushes the automatic test case data to a corresponding list object list according to the case types of the automatic test case data in different case sets.
Referring to fig. 3, fig. 3 is a schematic structural diagram of a test case distribution processing system in an embodiment of the present application, and as shown in fig. 3, the schematic structural diagram specifically includes:
a redis database 301, lua language scripts 302, and at least one execution machine 303;
when the execution machine 303 has an idle thread, the execution machine 303 sends a case distribution request to the lua language script 302, wherein the case distribution request carries a case type;
the lua language script 302 accesses the redis database 301 by a single thread, determines a list object list corresponding to the case type, and takes out the automated test case data which enters most first in the list object list;
the lua language script 302 returns the automated test case data to the execution machine 303;
the execution machine 303 executes the automated test case data to perform an automated test.
Further, still include:
and judging whether an idle process exists according to a preset time task executing machine 303, if so, executing the step S1, otherwise, not acting.
Further, still include:
at least one list object list is established in the redis database 301, each list object list marks a corresponding key, and the value of the key corresponds to the case type.
Further, still include:
the redis database 301 obtains at least one case set, where the case set includes at least one piece of automated test case data;
the redis database 301 distributes and pushes the automated test case data to the corresponding list object list according to the case types of the automated test case data in different case sets.
Taking fig. 3 as an example, case sets A1, A2, B1, B2, C1, and C2 are sent to the redis database 301 and stored in the list object list corresponding to the key value;
when an idle thread exists in the A execution machine 303, actively sending a request to the lua language script 302 to obtain an automatic test case of the type of the A case;
the Lua language script 302 single thread accesses the redis database 301, obtains a list object list of the A key, takes out an automatic test case data which is most advanced to the queue from the list object list, and returns the automatic test case data to the A execution machine 303;
the a execution engine 303 executes the test after receiving the automated test case data.
Meanwhile, when an idle thread exists, the B execution machine 303 actively sends a request to the lua language script 302 to obtain an automatic test case of the type of the B case;
the Lua language script 302 single thread accesses the redis database 301, acquires a list object list of the B key, takes out the automated test case data which enters the queue at the first time from the list object list, and returns the automated test case data to the B execution machine 303;
the B execution engine 303 executes the test after receiving the automated test case data.
The C-actuator 303 works the same way.
If another A execution machine 303 exists, the lua language script 302 will sequentially distribute the automated test case data in the list of the Akey list of the redis database 301 to the two A execution machines 303, so as to prevent the two A execution machines 303 from executing the same automated test case data.
Another test case distribution processing device is provided in the embodiment of the present application, as shown in fig. 4, for convenience of description, only the parts related to the embodiment of the present application are shown, and specific technical details are not disclosed, please refer to the method part in the embodiment of the present application. The terminal may be any terminal device including a mobile phone, a tablet computer, a Personal Digital Assistant (PDA, abbreviated as "Personal Digital Assistant"), a Sales terminal (POS, abbreviated as "Point of Sales"), a vehicle-mounted computer, etc., and the terminal is taken as a mobile phone as an example:
fig. 4 is a block diagram illustrating a partial structure of a mobile phone related to a terminal provided in an embodiment of the present application. Referring to fig. 4, the handset includes: radio Frequency (RF) circuit 1010, memory 1020, input unit 1030, display unit 1040, sensor 1050, audio circuit 1060, wireless fidelity (WiFi) module 1070, processor 1080, and power source 1090. Those skilled in the art will appreciate that the handset configuration shown in fig. 4 is not intended to be limiting and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
The following describes each component of the mobile phone in detail with reference to fig. 4:
RF circuit 1010 may be used for receiving and transmitting signals during information transmission and reception or during a call, and in particular, for processing downlink information of a base station after receiving the downlink information to processor 1080; in addition, the data for designing uplink is transmitted to the base station. In general, RF circuit 1010 includes, but is not limited to, an antenna, at least one Amplifier, a transceiver, a coupler, a Low Noise Amplifier (Low Noise Amplifier; LNA), a duplexer, and the like. In addition, the RF circuitry 1010 may also communicate with networks and other devices via wireless communications. The wireless communication may use any communication standard or protocol, including but not limited to Global System for Mobile communication (GSM), general Packet Radio Service (GPRS), code Division Multiple Access (CDMA), wideband Code Division Multiple Access (WCDMA), long Term Evolution (LTE), email), short Message Service (SMS), etc.
The memory 1020 can be used for storing software programs and modules, and the processor 1080 executes various functional applications and data processing of the mobile phone by operating the software programs and modules stored in the memory 1020. The memory 1020 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required by at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may store data (such as audio data, a phonebook, etc.) created according to the use of the cellular phone, and the like. Further, the memory 1020 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
The input unit 1030 may be used to receive input numeric or character information and generate key signal inputs related to user settings and function control of the cellular phone. Specifically, the input unit 1030 may include a touch panel 1031 and other input devices 1032. The touch panel 1031, also called a touch screen, may collect a touch operation performed by a user on or near the touch panel 1031 (e.g., an operation performed by a user on or near the touch panel 1031 using any suitable object or accessory such as a finger, a stylus, etc.) and drive the corresponding connection device according to a predetermined program. Alternatively, the touch panel 1031 may include two parts, a touch detection device and a touch controller. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch sensing device, converts the touch information into touch point coordinates, sends the touch point coordinates to the processor 1080, and can receive and execute commands sent by the processor 1080. In addition, the touch panel 1031 may be implemented by various types such as a resistive type, a capacitive type, an infrared ray, and a surface acoustic wave. The input unit 1030 may include other input devices 1032 in addition to the touch panel 1031. In particular, other input devices 1032 may include, but are not limited to, one or more of a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a track ball, a mouse, a joystick, or the like.
The display unit 1040 may be used to display information input by a user or information provided to the user and various menus of the cellular phone. The Display unit 1040 may include a Display panel 1041, and optionally, the Display panel 1041 may be configured by using a Liquid Crystal Display (LCD), an Organic Light-Emitting Diode (OLED), or the like. Further, the touch panel 1031 can cover the display panel 1041, and when the touch panel 1031 detects a touch operation on or near the touch panel 1031, the touch operation is transmitted to the processor 1080 to determine the type of the touch event, and then the processor 1080 provides a corresponding visual output on the display panel 1041 according to the type of the touch event. Although in fig. 4, the touch panel 1031 and the display panel 1041 are two independent components to implement the input and output functions of the mobile phone, in some embodiments, the touch panel 1031 and the display panel 1041 may be integrated to implement the input and output functions of the mobile phone.
The handset may also include at least one sensor 1050, such as a light sensor, motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor and a proximity sensor, wherein the ambient light sensor may adjust the brightness of the display panel 1041 according to the brightness of ambient light, and the proximity sensor may turn off the display panel 1041 and/or the backlight when the mobile phone moves to the ear. As one of the motion sensors, the accelerometer sensor can detect the magnitude of acceleration in each direction (generally, three axes), can detect the magnitude and direction of gravity when stationary, and can be used for applications of recognizing the gesture of the mobile phone (such as horizontal and vertical screen switching, related games, magnetometer gesture calibration), vibration recognition related functions (such as pedometer and tapping), and the like; as for other sensors such as a gyroscope, a barometer, a hygrometer, a thermometer, and an infrared sensor, which can be configured on the mobile phone, further description is omitted here.
Audio circuitry 1060, speaker 1061, and microphone 1062 may provide an audio interface between a user and a cell phone. The audio circuit 1060 can transmit the electrical signal converted from the received audio data to the speaker 1061, and the electrical signal is converted into a sound signal by the speaker 1061 and output; on the other hand, the microphone 1062 converts the collected sound signal into an electrical signal, which is received by the audio circuit 1060 and converted into audio data, which is then processed by the audio data output processor 1080 and then sent to, for example, another cellular phone via the RF circuit 1010, or output to the memory 1020 for further processing.
WiFi belongs to short-distance wireless transmission technology, and the mobile phone can help the user to send and receive e-mail, browse web pages, access streaming media, etc. through the WiFi module 1070, which provides wireless broadband internet access for the user. Although fig. 4 shows the WiFi module 1070, it is understood that it does not belong to the essential constitution of the handset, and can be omitted entirely as needed within the scope not changing the essence of the invention.
The processor 1080 is a control center of the mobile phone, connects various parts of the whole mobile phone by using various interfaces and lines, and executes various functions of the mobile phone and processes data by operating or executing software programs and/or modules stored in the memory 1020 and calling data stored in the memory 1020, thereby integrally monitoring the mobile phone. Optionally, processor 1080 may include one or more processing units; preferably, the processor 1080 may integrate an application processor, which handles primarily the operating system, user interfaces, applications, etc., and a modem processor, which handles primarily the wireless communications. It is to be appreciated that the modem processor described above may not be integrated into processor 1080.
The handset also includes a power source 1090 (e.g., a battery) for powering the various components, which may preferably be logically coupled to the processor 1080 via a power management system to manage charging, discharging, and power consumption via the power management system.
Although not shown, the mobile phone may further include a camera, a bluetooth module, etc., which will not be described herein.
In the embodiment of the present application, the processor 1080 included in the terminal further has the following functions:
s1, when an idle thread exists in an execution machine, the execution machine sends a case distribution request to a lua language script, wherein the case distribution request carries a case type;
s2, a single thread of the lua language script accesses a redis database, a list object list corresponding to the case type is determined, and the automatic test case data entering the most in the list object list are taken out;
s3, returning the automatic test case data to the execution machine by the lua language script;
and S4, executing the automatic test case data by the executing machine to perform automatic test.
The embodiment of the present application further provides a computer-readable storage medium, configured to store a program code, where the program code is configured to execute any one implementation manner of a test case distribution processing method in the foregoing embodiments.
In the embodiment of the application, a test case distribution processing method, a test case distribution processing system, test case distribution processing equipment and a storage medium are provided, when an idle process exists in an execution machine, an lua language script is actively called to obtain an executed case, the lua language script accesses a redis database in a single thread mode, a corresponding list object list is determined from the redis database according to the type of the case which can be executed by the execution machine, and therefore automatic test case data which enters the most in the list object list are returned to the execution machine, and the execution machine executes a test. The case data is stored in the redis database, the situation data is prevented from being acquired by a plurality of execution machines in a message queue mode, the execution machines actively acquire simple profit, the passive waiting relation between case distribution and the execution machines is decoupled, the resources of the execution machines are effectively utilized, and the technical problem that if a case is directly placed in an MQ message queue, different execution machines can possibly acquire the same case information, so that the same case can be executed for a plurality of times is solved.
Furthermore, the execution machine can dynamically expand the execution nodes of the execution machine, so that the extensibility is ensured; meanwhile, list object lists of different keys in a redis database can be dynamically expanded, and flexibility of expanding test types is improved.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
The terms "first," "second," "third," "fourth," and the like in the description of the application and the above-described figures, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the application described herein are, for example, capable of operation in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
It should be understood that in the present application, "at least one" means one or more, "a plurality" means two or more. "and/or" for describing an association relationship of associated objects, indicating that there may be three relationships, e.g., "a and/or B" may indicate: only A, only B and both A and B are present, wherein A and B may be singular or plural. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship. "at least one of the following" or similar expressions refer to any combination of these items, including any combination of single item(s) or plural items. For example, at least one (one) of a, b, or c, may represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", wherein a, b, c may be single or plural.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may be substantially implemented or contributed to by the prior art, or all or part of the technical solution may be embodied in a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The above embodiments are only used to illustrate the technical solutions of the present application, and not to limit the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions in the embodiments of the present application.

Claims (10)

1. A test case distribution processing method is characterized by comprising the following steps:
s1, when an idle thread exists in an execution machine, the execution machine sends a case distribution request to a lua language script, wherein the case distribution request carries a case type;
s2, the lua language script single thread accesses a redis database, a list object list corresponding to the case type is determined, and the automated test case data which enters the most in the list object list is taken out;
s3, the lua language script returns the automatic test case data to the execution machine;
and S4, the execution machine executes the automatic test case data to perform automatic test.
2. The test case distribution processing method according to claim 1, wherein the step S1 further comprises, before:
and judging whether an idle process exists according to a preset timing task execution machine, if so, executing the step S1, otherwise, not acting.
3. The test case distribution processing method according to claim 1, wherein the step S1 further comprises, before:
establishing at least one list object list in a redis database, wherein each list object list marks a corresponding key, and the value of the key corresponds to the type of the case.
4. The test case distribution processing method of claim 3, wherein after building at least one list object in a redis database, further comprising:
the redis database acquires at least one case set, wherein the case set comprises at least one piece of automatic test case data;
and the redis database distributes and pushes the automatic test case data to the corresponding list object list according to the case types of the automatic test case data in different case sets.
5. A test case distribution processing system, comprising:
a redis database, a lua language script, and at least one execution engine;
when the execution machine has an idle thread, the execution machine sends a case distribution request to the lua language script, wherein the case distribution request carries a case type;
the lua language script single thread accesses the redis database, determines a list object list corresponding to the case type, and takes out the automated test case data which enters most in the list object list;
the lua language script returns the automated test case data to the execution machine;
and the execution machine executes the automatic test case data to carry out automatic test.
6. The test case distribution processing system of claim 5, further comprising:
and judging whether an idle process exists by the executing machine according to a preset time task, if so, executing the step S1, otherwise, not acting.
7. The test case distribution processing system of claim 5, further comprising:
establishing at least one list object list in the redis database, wherein each list object list marks a corresponding key, and the value of the key corresponds to the type of the case.
8. The test case distribution processing system of claim 7, further comprising:
the redis database acquires at least one case set, wherein the case set comprises at least one piece of automatic test case data;
and the redis database distributes and pushes the automatic test case data to the corresponding list object list according to the case types of the automatic test case data in different case sets.
9. A test case distribution processing apparatus, the apparatus comprising a processor and a memory:
the memory is used for storing program codes and transmitting the program codes to the processor;
the processor is configured to execute the test case distribution processing method of any of claims 1-4 in accordance with instructions in the program code.
10. A computer-readable storage medium characterized in that the computer-readable storage medium is configured to store program code for executing the test case distribution processing method of any of claims 1-4.
CN202211652334.8A 2022-12-21 2022-12-21 Test case distribution processing method, system, equipment and storage medium Pending CN115794654A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211652334.8A CN115794654A (en) 2022-12-21 2022-12-21 Test case distribution processing method, system, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211652334.8A CN115794654A (en) 2022-12-21 2022-12-21 Test case distribution processing method, system, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN115794654A true CN115794654A (en) 2023-03-14

Family

ID=85426278

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211652334.8A Pending CN115794654A (en) 2022-12-21 2022-12-21 Test case distribution processing method, system, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN115794654A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116541301A (en) * 2023-06-05 2023-08-04 宁夏隆基宁光仪表股份有限公司 Design method of intelligent instrument function automatic test program

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116541301A (en) * 2023-06-05 2023-08-04 宁夏隆基宁光仪表股份有限公司 Design method of intelligent instrument function automatic test program

Similar Documents

Publication Publication Date Title
CN108255683B (en) Method for prompting message in terminal and terminal
CN108834132B (en) Data transmission method and equipment and related medium product
CN106911848B (en) Method for outputting prompt message and terminal equipment
CN108668328B (en) Network switching method and mobile terminal
CN104809055B (en) Application program testing method and device based on cloud platform
CN111273955B (en) Thermal restoration plug-in optimization method and device, storage medium and electronic equipment
CN115794654A (en) Test case distribution processing method, system, equipment and storage medium
CN106934003B (en) File processing method and mobile terminal
CN106851784B (en) network scanning method and terminal equipment
CN110602766B (en) Personal hotspot identification method and method for determining association relationship between terminals
CN110855807A (en) Method and equipment for adding contact person
CN111177612B (en) Page login authentication method and related device
CN108804434B (en) Message query method, server and terminal equipment
CN106777383B (en) File sorting method and intelligent terminal
CN106506623B (en) A kind of data transmission method and equipment
CN110908586A (en) Keyboard display method and device and terminal equipment
CN109286571A (en) The method, apparatus and storage device of mobile terminal and application program limit core and limit net
CN109002535B (en) Data updating method and device
CN108073508B (en) Compatibility detection method and device
CN106657278B (en) Data transmission method and device and computer equipment
CN112214699A (en) Page processing method and related device
CN106879046B (en) Network scanning method and terminal equipment
CN111367502A (en) Numerical value processing method and device
CN110809234A (en) Figure category identification method and terminal equipment
CN109242479A (en) A kind of method and apparatus that red packet is got based on integrating system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination