CN111367790B - Meta heuristic test case ordering method based on mixed model - Google Patents

Meta heuristic test case ordering method based on mixed model Download PDF

Info

Publication number
CN111367790B
CN111367790B CN202010092901.3A CN202010092901A CN111367790B CN 111367790 B CN111367790 B CN 111367790B CN 202010092901 A CN202010092901 A CN 202010092901A CN 111367790 B CN111367790 B CN 111367790B
Authority
CN
China
Prior art keywords
test
test case
steps
brightness
following
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.)
Active
Application number
CN202010092901.3A
Other languages
Chinese (zh)
Other versions
CN111367790A (en
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.)
Chongqing University of Post and Telecommunications
Original Assignee
Chongqing University of Post and Telecommunications
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 Chongqing University of Post and Telecommunications filed Critical Chongqing University of Post and Telecommunications
Priority to CN202010092901.3A priority Critical patent/CN111367790B/en
Publication of CN111367790A publication Critical patent/CN111367790A/en
Priority to PCT/CN2021/081496 priority patent/WO2021160190A1/en
Application granted granted Critical
Publication of CN111367790B publication Critical patent/CN111367790B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3684Test management for test design, e.g. generating new test cases
    • 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

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer And Data Communications (AREA)
  • Debugging And Monitoring (AREA)
  • Monitoring And Testing Of Transmission In General (AREA)

Abstract

The invention relates to a meta heuristic test case ordering method based on a hybrid model, and belongs to the technical field of wireless communication. The method comprises the following steps: s1: collecting communication protocol test cases related to test requirements of tested party, and calculating testSimilarity factor S between use cases i,j And a importance TF-IDF value of the test data; s2: initializing Brightness Brightness of Firefly Agent (FA) based on TF-IDF value i,j Design objective function f (x i,j ) The method comprises the steps of carrying out a first treatment on the surface of the S3: according to the editing distance and Brightness i,j Searching a node candidate Set to be reached next to the FA by using an improved firefly algorithm in a global searching mode candidate The method comprises the steps of carrying out a first treatment on the surface of the S4: from candidate Set candidate Based on similarity factor S by local search i,j Selecting an optimal solution; s5: changing the starting point position of the test case, repeating the steps S2 to S4, searching and recording the optimal moving path of the FA, and outputting an optimal test sequence. The invention improves the testing efficiency of the industrial wireless communication protocol and reduces the testing cost.

Description

Meta heuristic test case ordering method based on mixed model
Technical Field
The invention belongs to the technical field of wireless communication, and relates to a meta heuristic test case ordering method based on a hybrid model.
Background
In the communication protocol test process of the industrial wireless sensor network, with the version change of the tested system and the repair of the system defects, the regression test is required to ensure that the modified part has no influence on the unmodified part or no new fault is introduced. In the case of limited resources, re-executing all test cases is time consuming, labor intensive, and capital intensive. There is a need to select a more valuable test case from the library of test cases for preferential execution for earlier feedback to the tester. The test case prioritization technology prioritizes the test cases with different contribution degrees according to the given targets and importance degrees, so that the requirement coverage rate and the fault detection rate of the regression test can be improved.
The study objectives of the test case prioritization technique are defined as: for a given test suite T, the total ranking result of T is PT, the ranking objective function f, and the purpose of test case prioritization is: for the following
Figure GDA0004119169790000011
All have f (T'). Gtoreq.f (T) established.
At present, the communication protocol test of the industrial wireless sensor network lacks an effective test case priority ranking method, and because of the specificity of the communication protocol test input data, an effective method is difficult to find to measure the priority relation among the test cases. Therefore, in conventional software test case prioritization, although research and application of meta-heuristic test case prioritization methods have achieved many results in regression testing. However, the space searching mode of the priority of the test case is single, so that the searching result is not ideal. Therefore, how to determine the priority sequence among test cases faster and better becomes a problem of the communication protocol test of the industrial wireless sensor network.
Disclosure of Invention
In view of the above, the present invention is directed to a meta-heuristic test case ordering method based on a hybrid model.
In order to achieve the above purpose, the present invention provides the following technical solutions:
a meta heuristic test case ordering method based on a mixed model comprises the following steps:
s1: collecting communication protocol test cases related to test requirements of tested party, and calculating similarity factors S among the test cases i,j And a importance TF-IDF value of the test data;
s2: initializing Brightness Brightness of firefly agent FA according to TF-IDF value of test data i,j Design objective function f (x i,j );
S3: starting with the current test case, according to the edit distance Levenshtein distance and Brightness i,j Searching a node candidate Set to be reached next to the FA by using an improved firefly algorithm in a global searching mode candidate
S4: from candidate Set candidate Based on similarity factor S by local search i,j Selecting an optimal solution, recording the path of FA movement and updating the node distance
Figure GDA0004119169790000021
S5: changing the starting point position of the test case, repeating the steps S2 to S4, searching and recording the optimal moving path of the FA, and outputting an optimal test sequence.
Optionally, in the step S1, calculating the similarity between test cases and the importance of the test data specifically includes the following steps:
1) Preprocessing, and filtering test data; in the case of communication protocol testing, since the test data is presented in the form of byte arrays and contains a number of user-set parameters, including source and destination addresses, the influence factor alpha is used for such invalid data i Filtration, alpha i The value is 0 or 1, i represents the number of the measured protocol field; alpha of the field i When 0, the field is invalid data; the data used in the following calculation process have all been using alpha i Filtering;
2) The method specifically comprises the following steps of:
s11: the content in the test cases is measured by the character string spacing, and the character string spacing of different test cases is measured by the editing distance; the following formula is used for the measurement:
Figure GDA0004119169790000022
wherein lev is a,b (i, j) represents the edit distance, a, between two test cases a, b when the number of bytes is i, j, respectively i Represents the ith byte in a, b j Represents the j-th byte in b;
s12: from the calculated edit distance between a and b, the overlap distance between a and b is max (i, j) -lev a,b (i, j), denoted as P i Edit distance lev a,b (i, j) is denoted as Q i The method comprises the steps of carrying out a first treatment on the surface of the Obtain balance ofSimilarity coefficient S between test cases with different quantities i,j The method comprises the following steps:
Figure GDA0004119169790000023
s13: according to similarity coefficient S i,j Obtaining the similarity between the ith test case and the jth test case, thereby obtaining a similarity coefficient matrix M s
Figure GDA0004119169790000031
3) Determining the importance of the test data by calculating the TF-IDF value of the test data for each piece of test data i,j The method specifically comprises the following steps:
s14: counting the number n of times each piece of test data appears in all test cases k,j For a particular test case, its importance is expressed as:
Figure GDA0004119169790000032
in the above, n i,j Is the item in test case d i The number of occurrences in (b) and the denominator in (d) are in test case d i The sum of the occurrence times of all words in the list;
s15: the inverse text frequency IDF is a measure for measuring the general importance of a piece of test data, and the IDF of a specific test data is obtained by dividing the total number of test cases by the number of test cases containing the test data, and taking the logarithm of the obtained result:
Figure GDA0004119169790000033
where |D| represents the total number of test cases,
Figure GDA0004119169790000034
representing the inclusion of test data t i,j Test case number t of (2) i,j The j-th test data representing the i-th test case;
s16: the importance of the balance test case is calculated by the following formula:
Figure GDA0004119169790000035
optionally, in the step S2, the Brightness bright of the firefly agent FA is initialized i,j Design objective function f (x i,j ) The method specifically comprises the following steps:
s21: the importance degree coefficient of each piece of test data calculated according to the S1 is taken as the initial brightness of each intelligent agent, and the calculation formula is as follows:
Figure GDA0004119169790000036
wherein W is i The weight of the test case i is represented; the brightness update of the current intelligent agent is based on the product of the current position weight of the firefly intelligent agent FA and the correlation coefficient of other intelligent agents;
s22: the luminance is formulated by correlating it with the objective function to be optimized, so that the fitness function of the new optimization algorithm is formulated:
Figure GDA0004119169790000041
wherein W is i-1 The weight of the test case i-1 is represented, order represents the test case sequence number with determined priority, unOrder represents the test case sequence number with undetermined priority, and Random (= { N-2 < [ [ N ]) ] i -i]-0.1]< N, N represents the total number of test cases; x is x i,j The fitness value f (x) i,j ) Is affected by the point to be reached next, and is thus found from the test cases that have not yet been added to OrderK nodes with maximum fitness value are added into the candidate Set candidate
Optionally, in the step S22, the Brightness Brightness of the firefly agent FA i,j Objective function f (x i,j ) Updating rules specifically comprises the following steps:
s221: setting fitness function/objective function f (x i,j ),x i,j A j-th agent representing an i-th test case;
s222: initializing x using equation (7) i,j As an entry for firefly agents;
S223:X i the node distance update formula is as follows, which represents the node reached by the firefly agent:
Figure GDA0004119169790000042
where β and α are constants, β is the absorptivity of light, usually 1, α ε [0,1]Epsilon is a random factor obeying uniform distribution, gamma represents the attraction coefficient, S i,j Representing node X i And X is j Is formed by a matrix M s Is given;
all FAs are monoscopic, each FA attracts or is attracted by other FAs, the attraction of an FA being proportional to its brightness; when FAs are attracted by other peers, their brightness becomes the magnitude of the attraction.
Optionally, in the step S4, the selection strategy of the node that the firefly agent reaches next specifically includes the following steps:
s41: calculated according to the formula (9)
Figure GDA0004119169790000043
And aggregate Set candidate Distances of all nodes inside;
s42: selecting a distance
Figure GDA0004119169790000044
The smallest node is the (i+1) th sequence;
S43: recording the path of FA movement and updating node distance with mixed model
Figure GDA0004119169790000045
S44: this is repeated until unOrder is empty.
Optionally, in the step S5, an optimal test sequence is output, which specifically includes the following steps:
s51: changing the starting point position of the test case and restoring the initial condition before the test case is restored;
s52: repeating the process from the step S2 to the step S4;
s53: and finding out the optimal test sequence in all flight paths.
The invention has the beneficial effects that: the method provided by the invention can meet the demands of sequencing the priorities of the test cases of the communication protocol of the wireless sensor network, can improve the test efficiency of the program and the test suite, and reduces the test cost.
Additional advantages, objects, and features of the invention will be set forth in part in the description which follows and in part will become apparent to those having ordinary skill in the art upon examination of the following or may be learned from practice of the invention. The objects and other advantages of the invention may be realized and obtained by means of the instrumentalities and combinations particularly pointed out in the specification.
Drawings
For the purpose of making the objects, technical solutions and advantages of the present invention more apparent, the present invention will be described in the following preferred detail with reference to the accompanying drawings, in which:
FIG. 1 is a general flow chart of a test case prioritization method in accordance with the present invention.
Fig. 2 is a schematic diagram of a hybrid model based on edit distance and TF-IDF according to the present invention.
FIG. 3 is a flow chart of a firefly algorithm based on a hybrid model according to the present invention.
Detailed Description
Other advantages and effects of the present invention will become apparent to those skilled in the art from the following disclosure, which describes the embodiments of the present invention with reference to specific examples. The invention may be practiced or carried out in other embodiments that depart from the specific details, and the details of the present description may be modified or varied from the spirit and scope of the present invention. It should be noted that the illustrations provided in the following embodiments merely illustrate the basic idea of the present invention by way of illustration, and the following embodiments and features in the embodiments may be combined with each other without conflict.
Wherein the drawings are for illustrative purposes only and are shown in schematic, non-physical, and not intended to limit the invention; for the purpose of better illustrating embodiments of the invention, certain elements of the drawings may be omitted, enlarged or reduced and do not represent the size of the actual product; it will be appreciated by those skilled in the art that certain well-known structures in the drawings and descriptions thereof may be omitted.
The same or similar reference numbers in the drawings of embodiments of the invention correspond to the same or similar components; in the description of the present invention, it should be understood that, if there are terms such as "upper", "lower", "left", "right", "front", "rear", etc., that indicate an azimuth or a positional relationship based on the azimuth or the positional relationship shown in the drawings, it is only for convenience of describing the present invention and simplifying the description, but not for indicating or suggesting that the referred device or element must have a specific azimuth, be constructed and operated in a specific azimuth, so that the terms describing the positional relationship in the drawings are merely for exemplary illustration and should not be construed as limiting the present invention, and that the specific meaning of the above terms may be understood by those of ordinary skill in the art according to the specific circumstances.
As shown in FIG. 1, a meta-heuristic test case ordering method based on a hybrid model is divided into three stages: the first stage is a process on the raw test case data, called a preprocessing stage. And filtering invalid fields according to different fields defined by the standard specifications of the measured protocol, so as to avoid the influence of invalid data on a final result. The second stage is to construct a mixed space search model stage, and the local search and the global search are respectively carried out by the firefly agent for measuring the importance degree of the test data and the correlation coefficient matrix among the test cases, so as to construct a mixed search space. The third stage is a firefly algorithm implementation stage based on a mixed model, and the best flight path is obtained by calculating and selecting the mixed model by taking each test case as a starting point. Finally, the optimal test sequence is found through all flight paths, as shown in fig. 2.
The meta heuristic test case ordering method based on the hybrid model disclosed by the invention specifically comprises the following steps of:
step one: collecting communication protocol test cases related to test requirements of tested party, and calculating similarity factors s among the test cases i,j And the importance TF-IDF value of the test data. Firstly, preprocessing is carried out, test data are filtered, correlation among test cases is determined, and importance degree of the test data is determined.
1. Influence factor alpha for invalid data according to different fields of tested protocol i Filtering, alpha i The value is 0 or 1, i represents the number of the tested protocol field. Alpha of the field i A value of 0 indicates that the field is invalid data.
2. The method for calculating the correlation coefficient matrix among the test cases specifically comprises the following steps:
1) The content in the test cases is measured in terms of string spacing, and the string spacing of different test cases is measured in terms of edit distance. The following formula is used for the measurement:
Figure GDA0004119169790000061
wherein lev is a,b (i, j) represents the edit distance, a, between two test cases a, b when the number of bytes is i, j, respectively i Represents the ith byte in a, b j Representing the j-th byte in b.
2) From the above calculated edit distance between a and b, the overlap distance between a and b is max (i, j) -lev a,b (i, j), recordIs P i Edit distance Q i =lev a,b (i, j) is denoted as Q i . Therefore, the similarity coefficient S between different test cases can be measured i,j The method comprises the following steps:
Figure GDA0004119169790000062
3) According to similarity coefficient S i,j The similarity between the ith test case and the jth test case can be obtained, and thus a similarity coefficient matrix M is obtained s
Figure GDA0004119169790000063
3. The method for calculating the importance degree of the test data specifically comprises the following steps:
1) Counting the number n of times each piece of test data appears in all test cases k,j For a particular test case, its importance can be expressed as:
Figure GDA0004119169790000071
in the above, n i,j Is the item in test case d i The number of occurrences in (b) and the denominator in (d) are in test case d i The sum of the number of occurrences of all words in (a).
2) The inverse text frequency (IDF) is a measure of the general importance of a piece of test data, where the IDF of a particular test data can be obtained by dividing the total number of test cases by the number of test cases containing the test data, and taking the logarithm of the obtained result:
Figure GDA0004119169790000072
where |D| represents the total number of test cases,
Figure GDA0004119169790000073
representing the inclusion of test data t i,j Test case number t of (2) i,j The j-th test data representing the i-th test case.
3) The importance of the balance test case can be calculated by the following formula:
Figure GDA0004119169790000074
step two: initializing and updating Brightness Brightness of Firefly Agent (FA) i,j Objective function f (x i,j ) The method specifically comprises the following steps:
1. the importance degree coefficient of each piece of test data calculated according to the S1 is taken as the initial brightness of each intelligent agent, and the calculation formula is as follows:
Figure GDA0004119169790000075
wherein W is i The weight of test case i is represented. The brightness update of the current agent is based on the product of the Firefly Agent (FA) current location weight and the correlation coefficients of the other agents.
2. By correlating the luminance with the objective function to be optimized, it can be formulated such that the fitness function of the new optimization algorithm is formulated:
Figure GDA0004119169790000076
wherein W is i-1 The weight of the test case i-1 is represented, order represents the test case sequence number with determined priority, unOrder represents the test case sequence number with undetermined priority, and Random (= { N-2 < [ [ N ]) ] i -i]-0.1]< N, N represents the total number of test cases. X is x i,j The fitness value f (x) i,j ) Is affected by the point to be reached in the next step, and is thus never addedK nodes with maximum fitness value are found in the test case of Order to be added into the candidate Set candidate
3. Updating Brightness Brightness of Firefly Agent (FA) i,j Objective function f (x i,j ) The method specifically comprises the following steps:
1) Setting fitness function/objective function f (x i,j ),x i,j The jth agent representing the ith test case.
2) Initializing x using equation (7) i,j As an inlet for firefly agents.
3)X i The node distance update formula is as follows, which represents the node reached by the firefly agent:
Figure GDA0004119169790000081
where β and α are constants, β is the absorptivity of light, usually 1, α ε [0,1]Epsilon is a random factor obeying uniform distribution, gamma represents the attraction coefficient, S i,j Representing node X i And X is j Is composed of matrix M s Given.
All FAs are monoscopic, each FA will attract or be attracted by other FAs, the attraction of an FA being proportional to its brightness. When FAs are attracted by other peers, their brightness becomes the magnitude of the attraction.
Step three: the selection strategy of the next reached node specifically comprises the following steps:
1) Calculated according to the formula (9)
Figure GDA0004119169790000082
And aggregate Set candidate Distances of all nodes inside.
2) Selecting a distance
Figure GDA0004119169790000083
The smallest node serves as the i+1st sequence.
3) Record the path of FA movement andupdating node distance with hybrid model
Figure GDA0004119169790000084
4) This is repeated until unOrder is empty.
Step four: outputting an optimal test sequence, which specifically comprises the following steps:
1) Changing the starting point position of the test case and restoring the initial condition before the test case.
2) Repeating the processes from the second step to the third step.
3) And finding out the optimal test sequence in all flight paths.
The execution of the method is shown in fig. 3.
Finally, it is noted that the above embodiments are only for illustrating the technical solution of the present invention and not for limiting the same, and although the present invention has been described in detail with reference to the preferred embodiments, it should be understood by those skilled in the art that modifications and equivalents may be made thereto without departing from the spirit and scope of the present invention, which is intended to be covered by the claims of the present invention.

Claims (2)

1. A meta heuristic test case ordering method based on a mixed model is characterized by comprising the following steps of: the method comprises the following steps:
s1: collecting communication protocol test cases related to test requirements of tested party, and calculating similarity factors S among the test cases i,j And a importance TF-IDF value of the test data;
s2: initializing Brightness Brightness of firefly agent FA according to TF-IDF value of test data i,j Design objective function f (x i,j );
S3: starting with the current test case, according to the edit distance Levenshtein distance and Brightness i,j Searching a node candidate Set to be reached next to the FA by using an improved firefly algorithm in a global searching mode candidate
S4: from candidate Set candidate Based on similarity factor by local searchSon S i,j Selecting an optimal solution, recording the path of FA movement and updating the node distance
Figure FDA0004119169780000011
S5: changing the starting point position of the test case, repeating the steps S2 to S4, searching and recording the optimal moving path of the FA, and outputting an optimal test sequence;
in the step S1, the step of calculating the similarity between test cases and the importance of the test data specifically includes the following steps:
1) Preprocessing, and filtering test data; in the case of communication protocol testing, since the test data is presented in the form of byte arrays and contains a number of user-set parameters, including source and destination addresses, the influence factor alpha is used for such invalid data i Filtration, alpha i The value is 0 or 1, i represents the number of the measured protocol field; alpha of the field i When 0, the field is invalid data; the data used in the following calculation process have all been using alpha i Filtering;
2) The method specifically comprises the following steps of:
s11: the content in the test cases is measured by the character string spacing, and the character string spacing of different test cases is measured by the editing distance; the following formula is used for the measurement:
Figure FDA0004119169780000012
wherein lev is a,b (j, j) represents the edit distance, a, between two test cases a, b when the number of bytes is i, j, respectively i Represents the ith byte in a, b j Represents the j-th byte in b;
s12: from the calculated edit distance between a and b, the overlap distance between a and b is max (i, j) -lev a,b (i, j), denoted as P i Edit distance lev a,b (i, j) is denoted as Q i The method comprises the steps of carrying out a first treatment on the surface of the Obtaining similarity coefficient S between different test cases i,j The method comprises the following steps:
Figure FDA0004119169780000021
s13: according to similarity coefficient S i,j Obtaining the similarity between the ith test case and the jth test case to obtain a similarity coefficient matrix M s
Figure FDA0004119169780000022
3) Determining the importance of the test data by calculating the TF-IDF value of the test data for each piece of test data i,j The method specifically comprises the following steps:
s14: counting the number n of times each piece of test data appears in all test cases k,j For a particular test case, its importance is expressed as:
Figure FDA0004119169780000023
in the above, n i,j Is the test data in the j-th test case in test case d i The number of occurrences in (b) and the denominator in (d) are in test case d i The sum of the occurrence times of all words in the list;
s15: the inverse text frequency IDF is a measure for measuring the general importance of a piece of test data, and the IDF of a specific test data is obtained by dividing the total number of test cases by the number of test cases containing the test data, and taking the logarithm of the obtained result:
Figure FDA0004119169780000024
where |D| represents the total number of test cases,
Figure FDA0004119169780000027
representing the inclusion of test data t i,j Test case number t of (2) i,j The j-th test data representing the i-th test case;
s16: the importance of the balance test case is calculated by the following formula:
Figure FDA0004119169780000025
in the step S2, the Brightness Brightness of the firefly agent FA is initialized i,j Design objective function f (x i,j ) The method specifically comprises the following steps:
s21: the importance degree coefficient of each piece of test data calculated according to the S1 is taken as the initial brightness of each intelligent agent, and the calculation formula is as follows:
Figure FDA0004119169780000026
wherein W is i The weight of the test case i is represented; the brightness update of the current intelligent agent is based on the product of the current position weight of the firefly intelligent agent FA and the correlation coefficient of other intelligent agents;
s22: the luminance is formulated by correlating it with the objective function to be optimized, so that the fitness function of the new optimization algorithm is formulated:
Figure FDA0004119169780000031
wherein W is i-1 The weight of the test case i-1 is represented, order represents the test case sequence number with determined priority, unOrder represents the test case sequence number with undetermined priority, and Random (={N-2<[[N i -j]-0.1]< N, N represents the total number of test cases; x is x i,j The fitness value f (x) i,j ) Is influenced by the point to be reached in the next step, and k nodes with the maximum fitness value are found from test cases which are not added into Order to be added into the candidate Set candidate
In S22, brightness Brightness of firefly agent FA i,j Objective function f (x i,j ) Updating rules specifically comprises the following steps:
s221: setting fitness function/objective function f (x i,j ),x i,j A j-th agent representing an i-th test case;
s222: initializing x using equation (7) i,j As an entry for firefly agents;
S223:X i the node distance update formula is as follows, which represents the node reached by the firefly agent:
Figure FDA0004119169780000032
wherein, beta and alpha are constants, beta is the absorptivity of light, 1 is taken, alpha is 0,1]Epsilon is a random factor obeying uniform distribution, gamma represents the attraction coefficient, S i,j Representing node X i And X is j Is formed by a matrix M s Is given;
all FAs are monoscopic, each FA attracts or is attracted by other FAs, the attraction of an FA being proportional to its brightness; when FAs are attracted by other congeners, their brightness becomes the magnitude of the attraction;
in the step S4, the selection strategy of the node reached by the firefly agent next step specifically includes the following steps:
s41: calculated according to the formula (9)
Figure FDA0004119169780000033
And aggregate Set candidate Distances of all nodes inside;
s42: selecting a distance
Figure FDA0004119169780000034
The smallest node is the i+1st sequence;
s43: recording the path of FA movement and updating node distance with mixed model
Figure FDA0004119169780000035
S44: this is repeated until unOrder is empty.
2. The meta-heuristic test case ordering method based on a mixed model as claimed in claim 1, wherein: in the step S5, an optimal test sequence is output, which specifically includes the following steps:
s51: changing the starting point position of the test case and restoring the initial condition before the test case is restored;
s52: repeating the processes of steps S2 to S4;
s53: and finding out the optimal test sequence in all flight paths.
CN202010092901.3A 2020-02-14 2020-02-14 Meta heuristic test case ordering method based on mixed model Active CN111367790B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202010092901.3A CN111367790B (en) 2020-02-14 2020-02-14 Meta heuristic test case ordering method based on mixed model
PCT/CN2021/081496 WO2021160190A1 (en) 2020-02-14 2021-03-18 Metaheuristic test case ranking method based on hybrid model

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010092901.3A CN111367790B (en) 2020-02-14 2020-02-14 Meta heuristic test case ordering method based on mixed model

Publications (2)

Publication Number Publication Date
CN111367790A CN111367790A (en) 2020-07-03
CN111367790B true CN111367790B (en) 2023-05-12

Family

ID=71208053

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010092901.3A Active CN111367790B (en) 2020-02-14 2020-02-14 Meta heuristic test case ordering method based on mixed model

Country Status (2)

Country Link
CN (1) CN111367790B (en)
WO (1) WO2021160190A1 (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111367790B (en) * 2020-02-14 2023-05-12 重庆邮电大学 Meta heuristic test case ordering method based on mixed model
CN112181849B (en) * 2020-10-23 2023-07-25 网易(杭州)网络有限公司 Test case identification method, device, equipment and storage medium
CN113345420B (en) * 2021-06-07 2022-07-08 河海大学 Anti-audio generation method and system based on firefly algorithm and gradient evaluation
CN114580864B (en) * 2022-02-21 2023-12-05 石河子大学 Multi-element energy storage distribution method, system and equipment for comprehensive energy system
CN114706769B (en) * 2022-03-30 2024-08-02 天津大学 Log-based black box test case ordering method oriented to regression test
CN114978974B (en) * 2022-05-20 2023-09-19 国网重庆市电力公司电力科学研究院 Wireless communication module testing method, device, equipment and storage medium
CN117234957B (en) * 2023-11-16 2024-02-06 山东科技大学 Test case priority ordering method based on improved firefly algorithm
CN118035125B (en) * 2024-04-11 2024-06-14 江西财经大学 Method and system for generating random test case based on double-level probability selection

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101551776A (en) * 2009-04-24 2009-10-07 北京航空航天大学 A measuring and assessment method for software credibility during the testing process
CN104572449A (en) * 2014-12-23 2015-04-29 中国移动通信集团广东有限公司 Automatic test method based on case library

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7043371B2 (en) * 2002-08-16 2006-05-09 American Museum Of Natural History Method for search based character optimization
US7552361B2 (en) * 2006-12-14 2009-06-23 International Business Machines Corporation Software testing optimization apparatus and method
CN105528289B (en) * 2015-12-04 2017-12-08 中国矿业大学 A kind of regression test case priority ordering method based on branch's covering with similitude
US10705943B2 (en) * 2017-09-08 2020-07-07 Devfactory Innovations Fz-Llc Automating identification of test cases for library suggestion models
CN108021509B (en) * 2017-12-27 2020-08-18 西安交通大学 Test case dynamic sequencing method based on program behavior network aggregation
CN108763055B (en) * 2018-04-19 2020-08-25 北京航空航天大学 Construction method of test case constraint control technology based on epigenetic inheritance
CN110647461B (en) * 2019-08-19 2023-03-28 江苏大学 Multi-information fusion regression test case sequencing method and system
CN111367790B (en) * 2020-02-14 2023-05-12 重庆邮电大学 Meta heuristic test case ordering method based on mixed model

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101551776A (en) * 2009-04-24 2009-10-07 北京航空航天大学 A measuring and assessment method for software credibility during the testing process
CN104572449A (en) * 2014-12-23 2015-04-29 中国移动通信集团广东有限公司 Automatic test method based on case library

Also Published As

Publication number Publication date
CN111367790A (en) 2020-07-03
WO2021160190A1 (en) 2021-08-19

Similar Documents

Publication Publication Date Title
CN111367790B (en) Meta heuristic test case ordering method based on mixed model
Abd Elaziz et al. Hyper-heuristic method for multilevel thresholding image segmentation
Orzack et al. A critical assessment of Levins's The strategy of model building in population biology (1966)
Alinezhad et al. Sensitivity analysis of TOPSIS technique: the results of change in the weight of one attribute on the final ranking of alternatives
Odenbaugh et al. Buyer beware: Robustness analyses in economics and biology
CN103324620B (en) A kind of method and apparatus that annotation results is rectified a deviation
CN111861909B (en) Network fine granularity image classification method
JP7294369B2 (en) Methods, devices, electronic devices and programs used for information processing
den Braanker et al. How to prepare spectral flow cytometry datasets for high dimensional data analysis: a practical workflow
CN106952190A (en) False source of houses typing Activity recognition and early warning system
CN115171916B (en) Experimental method, device, computer equipment and storage medium for reagent development
D'Ordine et al. Performance characteristics of Fungitell STAT™, a rapid (1→ 3)-β-D-glucan single patient sample in vitro diagnostic assay
CN107169264B (en) complex disease diagnosis system
CN115456707A (en) Method and device for providing commodity recommendation information and electronic equipment
CN110659199B (en) Class integration test sequence generation method based on transfer dependence
Oogi et al. Uchuu–ν2GC galaxies and AGN: cosmic variance forecasts of high-redshift AGN for JWST, Euclid, and LSST
Ahanor et al. DiversiTree: A new method to efficiently compute diverse sets of near-optimal solutions to mixed-integer optimization problems
CN111782978A (en) Method and device for processing point of interest data, electronic equipment and readable medium
CN111639194A (en) Knowledge graph query method and system based on sentence vectors
CN114898809B (en) Analysis method and storage medium for gene-environment interaction suitable for complex traits
CN116307216A (en) Uncertainty estimation method of neural network model and related equipment thereof
CN114048320B (en) Multi-label international disease classification training method based on course learning
Weiss et al. Neutral components show a hierarchical community structure in the genotype–phenotype map of RNA secondary structure
Moon et al. Mldeg: A machine learning approach to identify differentially expressed genes using network property and network propagation
Lyu et al. GESLM algorithm for detecting causal SNPs in GWAS with multiple phenotypes

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
GR01 Patent grant
GR01 Patent grant