CN105373476B - Method and system for generating automatic test case in automobile controller - Google Patents
Method and system for generating automatic test case in automobile controller Download PDFInfo
- Publication number
- CN105373476B CN105373476B CN201510792418.5A CN201510792418A CN105373476B CN 105373476 B CN105373476 B CN 105373476B CN 201510792418 A CN201510792418 A CN 201510792418A CN 105373476 B CN105373476 B CN 105373476B
- Authority
- CN
- China
- Prior art keywords
- name
- test case
- replaced
- signal
- map names
- 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
Links
- 238000012360 testing method Methods 0.000 title claims abstract description 74
- 238000000034 method Methods 0.000 title claims abstract description 26
- 238000013101 initial test Methods 0.000 claims abstract description 66
- 238000013507 mapping Methods 0.000 claims abstract description 63
- 238000013100 final test Methods 0.000 claims abstract description 37
- 238000011156 evaluation Methods 0.000 claims description 25
- 238000006467 substitution reaction Methods 0.000 claims description 21
- 238000005259 measurement Methods 0.000 claims description 8
- 238000012545 processing Methods 0.000 claims description 7
- 230000005540 biological transmission Effects 0.000 claims description 4
- 238000013461 design Methods 0.000 description 6
- 230000000694 effects Effects 0.000 description 3
- 230000006870 function Effects 0.000 description 3
- 238000011161 development Methods 0.000 description 2
- 230000009471 action Effects 0.000 description 1
- 230000008901 benefit Effects 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 238000010586 diagram Methods 0.000 description 1
- 238000009434 installation Methods 0.000 description 1
- 230000003993 interaction Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012795 verification Methods 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
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)
- Testing And Monitoring For Control Systems (AREA)
Abstract
The invention discloses a method and a system for generating an automatic test case in an automobile controller, wherein the method comprises the following steps: and generating an initial test case, wherein the initial test case comprises a signal name and an assignment name corresponding to the signal name, acquiring a replacement rule between a sending signal and a measuring signal, wherein the replacement rule comprises a logical relationship formed by the signal name, the assignment name, a mapping name, a mutual relationship between the mapping names and the assignment mapping name, and performing replacement operation on the initial test case according to the replacement rule to generate a final test case. The method for generating the automatic test case in the automobile controller can improve the readability of the test case and can enable the test case to be reused.
Description
Technical field
The present invention relates to smart machine field, and in particular in a kind of automobile controller the generation method of automatic test case and
System.
Background technology
With the continuous popularization of automobile, the function of automobile is more and more, and the various softwares in automobile also become increasingly complex, because
, in order to ensure the reliability of automobile, it is the survey in essential automobile controller that test is carried out to the control system in automobile for this
Example on probation, the specific functional design of application program in automobile controller can be tested.Generally, a certain spy of application program
Determine Functional Design and need to write corresponding test case to be tested.That is, the network development for carrying out brand-new platform with
And during hardware development, for the existing test case of the specific functional design of automobile controller application program, it is difficult to directly use,
Therefore cause the reusability of test case poor.
In addition, even if when the Functional Design of brand-new platform is similar to what it is before, although automatic test case need not be changed
Main part, but the signal name due to test case, number of signals, assignment etc. can change, so as to cause to weigh
Write the expression of appropriate section.And in the automatic test case write, generally require and fill in network interface or hardwire interface
On title, and the signal name in test case is mostly English name, and everyone name custom differs again so that institute
The test case readability write is excessively poor.So as to result in developer when understanding the test thinking of test case expression,
It is difficult to be mapped with some specific Functional Design so that developer can not verification test personnel test design.
The content of the invention
It is contemplated that at least solves one of technical problem in correlation technique to a certain extent.Therefore, the present invention
For one purpose in a kind of generation method of the automatic test case in automobile controller is proposed, this method can improve test case
Legibility, and test case can be reused.
Generation system of the second object of the present invention in the automatic test case in a kind of automobile controller is proposed.
The embodiment of first aspect present invention proposes a kind of generation method of automatic test case in automobile controller, bag
Include following steps:Initial test case is generated, wherein, the initial test case is included corresponding to signal name and the signal name
Assignment name;The Substitution Rules between transmission signal and measurement signal are obtained, wherein, the Substitution Rules are included by the signal
The logical relation that name, the correlation between the assignment name, Map Names, Map Names and evaluation mapping name are formed;According to institute
State Substitution Rules and operation is replaced to the initial test case to generate final test case.
The generation method of automatic test case in the automobile controller of the embodiment of the present invention, believe according to sending signal and measuring
Substitution Rules between number are replaced operation to initial test case, generate final test case, improve test case
Readability, and the reuse of test case can be made.
In addition, the generation method of automatic test case can also have in automobile controller according to the above embodiment of the present invention
There is technical characteristic additional as follows:
According to one embodiment of present invention, it is described that the initial test case is replaced according to the Substitution Rules
Operation is specifically included with generating final test case:Signal name to be replaced is determined, and is indexed in the initial test case
The signal name to be replaced;Judge whether the number of Map Names corresponding to the signal name to be replaced is equal to 1;If so, then by institute
State signal name to be replaced described in initial test case and replace with the Map Names, and the assignment name is replaced with into corresponding institute
Evaluation mapping name is stated, to generate the final test case;If it is not, then judge multiple institutes corresponding to the signal name to be replaced
State the correlation between Map Names;If the multiple mapping it is entitled and relation, will be each in the initial test case
Signal name to be replaced replaces with the set of all Map Names, and the assignment name is replaced with into the corresponding evaluation mapping name,
To generate the final test case;If it is the multiple mapping it is entitled or relation, generation and the Map Names quantity phase
The derivative file of the same initial test case, and the signal name to be replaced in the derivative file is replaced with into the mapping
Name, and assignment name is replaced with into the corresponding evaluation mapping name, to obtain the final test case.
According to one embodiment of present invention, it is used in the entitled initial test case of the signal to be used to express
The spoken and written languages of signal, some entitled specific described signal name of the assignment are involved in all initial test cases
Assignment name.
According to one embodiment of present invention, in the initial test case corresponding to multiple signal names to be replaced
Correlation between Map Names be or when, it is exhaustive derivative that permutation and combination are carried out to multiple signal names to be replaced.Arrangement
The exhaustive derivative thinking of combination is simple, and programming and debugging are convenient.
According to one embodiment of present invention, the title of the initial test case and the final test case and/
Or sequence number is corresponding.
The embodiment of second aspect of the present invention proposes a kind of generation system of automatic test case in automobile controller, bag
Include:Generation module, for generating initial test case, wherein, the initial test case includes signal name and the signal name
Corresponding assignment name;Acquisition module, for obtaining the Substitution Rules between transmission signal and measurement signal, wherein, the replacement
Rule includes what is be made up of correlation and evaluation mapping name between the signal name, the assignment name, Map Names, Map Names
Logical relation;Replacement module, operated for being replaced according to the Substitution Rules to the initial test case to generate most
Whole test case.
The generation system of automatic test case in the automobile controller of the embodiment of the present invention, surveyed by replacement module to initial
Example on probation is replaced operation, generates final test case, improves the readability of test case, and can make test case
Reuse.
In addition, the generation system of automatic test case can also have in automobile controller according to the above embodiment of the present invention
There is technical characteristic additional as follows:
According to one embodiment of present invention, the replacement module includes:Index module, for determining signal to be replaced
Name, and the signal name to be replaced is indexed in the initial test case;Judge module, for judging the signal to be replaced
Whether the number in Map Names corresponding to name is equal to 1, and judges multiple Map Names corresponding to the signal name to be replaced
Between correlation;Processing module, for when the number in Map Names corresponding to the signal name to be replaced is equal to 1, inciting somebody to action
Signal name to be replaced described in the initial test case replaces with the Map Names, and corresponding to the assignment name replaced with
The evaluation mapping name, to generate the final test case.
According to one embodiment of present invention, the processing module is additionally operable to:Mapped corresponding to the signal name to be replaced
Name in number be more than 1, and it is the multiple mapping it is entitled and relation when, by each letter to be replaced in the initial test case
Number name replaces with the set of all Map Names, and by the assignment name replace with corresponding to the evaluation mapping name, to generate
State final test case;And the number in Map Names corresponding to the signal name to be replaced is more than 1, and the multiple mapping
It is entitled or relation when, generation with the Map Names quantity identical described in initial test case derivative file, and will described in
Signal name to be replaced in derivative file replaces with the Map Names, and assignment name is replaced with into the corresponding evaluation mapping
Name, to obtain the final test case.
According to one embodiment of present invention, it is used in the entitled test case of the signal to be used for expression signal
Spoken and written languages, the assignment name refers to some specific described signal name assignment involved in all test cases
Name.
According to one embodiment of present invention, in the initial test case corresponding to multiple signal names to be replaced
Correlation between Map Names be or when, it is exhaustive derivative that permutation and combination are carried out to multiple signal names to be replaced.Arrangement
The exhaustive derivative thinking of combination is simple, and programming and debugging are convenient.
According to one embodiment of present invention, the title of the initial test case and the final test case and/
Or sequence number is corresponding.
Brief description of the drawings
The above-mentioned and/or additional aspect and advantage of the present invention will become in the description from combination accompanying drawings below to embodiment
Substantially and it is readily appreciated that, wherein:
Fig. 1 is the flow of the generation method of automatic test case in automobile controller according to an embodiment of the invention
Figure;
Fig. 2 is that according to an embodiment of the invention be replaced according to Substitution Rules to initial test case is operated with life
Into the flow chart of the method for final test case;
Fig. 3 is the structural frames of the generation system of automatic test case in automobile controller according to an embodiment of the invention
Figure;
Fig. 4 is the knot of the generation system of automatic test case in the automobile controller according to a specific embodiment of the invention
Structure block diagram.
Embodiment
Embodiments of the invention are described below in detail, the example of the embodiment is shown in the drawings, wherein from beginning to end
Same or similar label represents same or similar element or the element with same or like function.Below with reference to attached
The embodiment of figure description is exemplary, it is intended to for explaining the present invention, and is not considered as limiting the invention.
Below with reference to the accompanying drawings describe the generation method of automatic test case in the automobile controller of the embodiment of the present invention and be
System.
Fig. 1 is the flow of the generation method of automatic test case in automobile controller according to an embodiment of the invention
Figure.
As shown in figure 1, the generation method of automatic test case comprises the following steps in the automobile controller:
S101, generate initial test case.
Wherein, initial test case includes assignment name corresponding to signal name and signal name.
Specifically, when writing initial test case, can directly using readability spoken and written languages writing signal name and its
Assignment name, ways of writing can be " signal names=assignment name ", such as gas pedal=step on suddenly, key=ON shelves, engine failure
=3 grades of failures, battery tension=12V etc., writing is simple and convenient, and readability.
S102, obtain the Substitution Rules sent between signal and measurement signal.
In an embodiment of the present invention, transmission signal refers to all signals for including signal name in initial test case,
Measurement signal refers to all signals for including signal name in the test case available for new software functional test, wherein, hair
Corresponding relation between the number of delivering letters and measurement signal be present.Substitution Rules include by signal name, assignment name, Map Names, Map Names it
Between the logical relation that is formed of correlation and evaluation mapping name.The Substitution Rules can be represented with form, such as can use table 1
Represent:
Table 1
As shown in table 1, the used spoken and written languages for expression signal name in the entitled initial test case of signal, i.e. table
Chinese name 1 in 1, can be gas pedal, key, engine failure etc..Some entitled signal specific name of assignment is all
Involved assignment name, assignment name can have any number of, i.e., assignment 1, assignment 2, assignment 3 in table 1 in initial test case
Three kinds of assignment names, can be oil step on suddenly, ON shelves, 3 grades of failures.Map Names must be the recognizable title of test software, and one is believed
Number name can correspond to multiple Map Names, there is 4 Map Names, i.e. Map Names 1, Map Names 2, Map Names 3, Map Names 4 in table 1.Reflect
The correlation penetrated between name have or and with two kinds expression, its effect is that multiple Map Names can be made to be provided simultaneously with some signal name
Effect, or with the synergy of multiple Map Names come the effect of equivalent signal name.Evaluation mapping name must be initial testing
The recognizable title of use-case, can be specific numerical value, or relational expression or certain curve, possibly even
Some complicated function, i.e., the mapping value 1 that is shown in table 1, mapping value 2 ..., mapping value 7.
S103, operation is replaced to initial test case according to Substitution Rules to generate final test case.
Wherein, initial test case is corresponding with the title and/or sequence number of final test case.
Specifically, as shown in Fig. 2 being replaced operation to initial test case according to Substitution Rules to generate final survey
Example on probation comprises the following steps:
S201, signal name to be replaced is determined, and signal name to be replaced is indexed in initial test case.
Wherein, signal name to be replaced can be the Chinese name 1 in table 1.
S202, judges whether the number of Map Names corresponding to signal name to be replaced is equal to 1.
S203, if so, signal name to be replaced in initial test case then is replaced with into Map Names, and assignment name is replaced with
Corresponding evaluation mapping name, to generate final test case.
Specifically, if the number in Map Names is equal to 1, as shown in table 1, there was only Map Names 1 in Map Names, then can be by
Literary fame 1 replaces with Map Names 1, and assignment name is replaced with into corresponding evaluation mapping name, i.e. " Chinese name 1=assignment 1, Chinese name 1=
Assignment 2, Chinese name 1=assignment 3 " will replace with:Map Names 1=mapping values 1, Map Names 1=mapping values 2, Map Names 1=mappings
Value 3.Terminate after the completion of replacement, the final test case of generation includes Map Names and its corresponding mapping assignment after replacing
Name.
S204, if it is not, then judging the correlation between multiple Map Names corresponding to signal name to be replaced.
S205, if it is multiple mapping it is entitled and relation, each signal name to be replaced in initial test case is replaced with
The set of all Map Names, and assignment name is replaced with into corresponding evaluation mapping name, to generate final test case.
For example, as shown in table 1, if the correlation between multiple Map Names is and the general of Chinese name 1=assignment 1
Replace with:Map Names 1=mapping values 1, Map Names 2=mapping values 4, Map Names 3=mapping values 6, Map Names 4=mapping values 7 this 4
Individual set;Chinese name 1=assignment 2 will replace with:Map Names 1=mapping values 2, Map Names 2=mapping values 5, Map Names 3=are assigned
Value 2, Map Names 4=assignment 2 this 4 set;Chinese name 1=assignment 3 will replace with, Map Names 1=mapping values 3, Map Names 2
=assignment 3, Map Names 3=assignment 3, Map Names 4=assignment 3 this 4 set.
S206, if multiple mappings it is entitled or relation, generate and spread out with Map Names quantity identical initial test cases
Raw file, and the signal name to be replaced in derivative file is replaced with into Map Names, and assignment name is replaced with into corresponding assignment and reflected
Name is penetrated, to obtain final test case.
For example, as shown in table 1, if the correlation between multiple Map Names be or, if can generate following 4 respectively
Derivative test case:
First derivative use-case, Chinese name 1=assignment 1 replace with:Map Names 1=mapping values 1, Chinese name 1=assignment 2 are replaced
It is changed to:Map Names 1=mapping values 2, Chinese name 1=assignment 3 replace with:Map Names 1=mapping values 3.
Second diffraction use-case, Chinese name 1=assignment 1 replace with:Map Names 2=mapping values 4, Chinese name 1=assignment 2 are replaced
It is changed to:Map Names 2=mapping values 5, Chinese name 1=assignment 3 replace with:Map Names 2=assignment 3.
3rd diffraction use-case, Chinese name 1=assignment 1 replace with:Map Names 3=mapping values 6, Chinese name 1=assignment 2 are replaced
It is changed to:Map Names 3=assignment 2, Chinese name 1=assignment 3 replace with:Map Names 3=assignment 3.
4th diffraction use-case, Chinese name 1=assignment 1 replace with:Map Names 4=mapping values 7, Chinese name 1=assignment 2 are replaced
It is changed to:Map Names 4=assignment 2, Chinese name 1=assignment 3 replace with:Map Names 4=assignment 3.
In an embodiment of the present invention, if between Map Names in initial test case corresponding to multiple signal names to be replaced
Correlation be or when, it is exhaustive derivative that multiple signal names to be replaced are carried out with permutation and combination.Using permutation and combination exhaustion side
Method is derived, and thinking is simple, and programming and debugging are convenient.
The generation method of automatic test case in the automobile controller of the embodiment of the present invention, believe according to sending signal and measuring
Substitution Rules between number are replaced operation to initial test case, generate final test case, improve test case
Readability, and test case can be reused.
Fig. 3 is the structural frames of the generation system of automatic test case in automobile controller according to an embodiment of the invention
Figure.
As shown in figure 3, the generation system of automatic test case includes in the automobile controller:Generation module 10, obtain mould
Block 20 and replacement module 30.
Specifically, generation module 10 is used to generate initial test case, wherein, initial test case includes signal name and letter
Number assignment name corresponding to name.Acquisition module 20 is used to obtain the Substitution Rules sent between signal and measurement signal, wherein, replace
Rule includes being closed by the logic that correlation and evaluation mapping name are formed between signal name, assignment name, Map Names, Map Names
System.Replacement module 30 is used to be replaced initial test case according to Substitution Rules operation to generate final test case.
Wherein, the used spoken and written languages for expression signal in the entitled test case of signal, assignment name refer to some
Signal specific name assignment name involved in all test cases.The title of initial test case and final test case
And/or sequence number is corresponding.
In an embodiment of the present invention, replacement module 30 includes index module 31, judge module 32 and processing module 33.Its
In, index module 31 is used to determine signal name to be replaced, and signal name to be replaced is indexed in initial test case;Judge module
Whether 32 numbers being used to judge in Map Names corresponding to signal name to be replaced are equal to 1, and judge that signal name to be replaced is corresponding
Multiple Map Names between correlation;The number that processing module 33 is used in Map Names corresponding to signal name to be replaced is equal to
When 1, signal name to be replaced in initial test case is replaced with into Map Names, and assignment name is replaced with into corresponding evaluation mapping
Name, to generate final test case.
In an embodiment of the present invention, processing module 33 is additionally operable to:Number in Map Names corresponding to signal name to be replaced
More than 1, and it is multiple mapping it is entitled and relation when, each signal name to be replaced in initial test case is replaced with into all mappings
The set of name, and assignment name is replaced with into corresponding evaluation mapping name, to generate final test case;And signal to be replaced
Number corresponding to name in Map Names is more than 1, and multiple mappings it is entitled or relation when, at the beginning of generation and Map Names quantity identical
The derivative file of beginning test case, and the signal name to be replaced in derivative file is replaced with into Map Names, and assignment name is replaced
For corresponding evaluation mapping name, to obtain final test case.
Preferably, if the correlation between Map Names in initial test case corresponding to multiple signal names to be replaced is equal
For or when, it is exhaustive derivative that multiple signal names to be replaced are carried out with permutation and combination.Derived using permutation and combination exhaustive method, thought
Road is simple, and programming and debugging are convenient.
It should be noted that the generation system of automatic test case and the present invention in the automobile controller of the embodiment of the present invention
The embodiment of the generation method of automatic test case is identical in the automobile controller of first aspect embodiment, superfluous to reduce
It is remaining, do not repeat herein.
The generation system of automatic test case in the automobile controller of the embodiment of the present invention, surveyed by replacement module to initial
Example on probation is replaced operation, generates final test case, improves the readability of test case, and can make test case
Reuse.
In the description of the invention, it is to be understood that term " " center ", " longitudinal direction ", " transverse direction ", " length ", " width ",
" thickness ", " on ", " under ", "front", "rear", "left", "right", " vertical ", " level ", " top ", " bottom " " interior ", " outer ", " up time
The orientation or position relationship of the instruction such as pin ", " counterclockwise ", " axial direction ", " radial direction ", " circumference " be based on orientation shown in the drawings or
Position relationship, it is for only for ease of and describes the present invention and simplify description, rather than indicates or imply that signified device or element must
There must be specific orientation, with specific azimuth configuration and operation, therefore be not considered as limiting the invention.
In addition, term " first ", " second " are only used for describing purpose, and it is not intended that instruction or hint relative importance
Or the implicit quantity for indicating indicated technical characteristic.Thus, define " first ", the feature of " second " can be expressed or
Implicitly include at least one this feature.In the description of the invention, " multiple " are meant that at least two, such as two, three
It is individual etc., unless otherwise specifically defined.
In the present invention, unless otherwise clearly defined and limited, term " installation ", " connected ", " connection ", " fixation " etc.
Term should be interpreted broadly, for example, it may be fixedly connected or be detachably connected, or integrally;Can be that machinery connects
Connect or electrically connect;Can be joined directly together, can also be indirectly connected by intermediary, can be in two elements
The connection in portion or the interaction relationship of two elements, limited unless otherwise clear and definite.For one of ordinary skill in the art
For, the concrete meaning of above-mentioned term in the present invention can be understood as the case may be.
In the present invention, unless otherwise clearly defined and limited, fisrt feature can be with "above" or "below" second feature
It is that the first and second features directly contact, or the first and second features pass through intermediary mediate contact.Moreover, fisrt feature exists
Second feature " on ", " top " and " above " but fisrt feature are directly over second feature or oblique upper, or be merely representative of
Fisrt feature level height is higher than second feature.Fisrt feature second feature " under ", " lower section " and " below " can be
One feature is immediately below second feature or obliquely downward, or is merely representative of fisrt feature level height and is less than second feature.
In the description of this specification, reference term " one embodiment ", " some embodiments ", " example ", " specifically show
The description of example " or " some examples " etc. means specific features, structure, material or the spy for combining the embodiment or example description
Point is contained at least one embodiment or example of the present invention.In this manual, to the schematic representation of above-mentioned term not
Identical embodiment or example must be directed to.Moreover, specific features, structure, material or the feature of description can be with office
Combined in an appropriate manner in one or more embodiments or example.In addition, in the case of not conflicting, the skill of this area
Art personnel can be tied the different embodiments or example and the feature of different embodiments or example described in this specification
Close and combine.
Although embodiments of the invention have been shown and described above, it is to be understood that above-described embodiment is example
Property, it is impossible to limitation of the present invention is interpreted as, one of ordinary skill in the art within the scope of the invention can be to above-mentioned
Embodiment is changed, changed, replacing and modification.
Claims (10)
1. the generation method of automatic test case in a kind of automobile controller, it is characterised in that comprise the following steps:
Initial test case is generated, wherein, the initial test case includes assignment name corresponding to signal name and the signal name;
The Substitution Rules between transmission signal and measurement signal are obtained, wherein, the Substitution Rules are included by the signal name, institute
State the logical relation that the correlation between assignment name, Map Names, Map Names and evaluation mapping name are formed;
Signal name to be replaced is determined, and the signal name to be replaced is indexed in the initial test case;
Judge whether the number in Map Names corresponding to the signal name to be replaced is equal to 1;
If the number in Map Names corresponding to the signal name to be replaced is equal to 1, described in the initial test case
Signal name to be replaced replaces with the Map Names, and the assignment name is replaced with into the corresponding evaluation mapping name, with generation
Final test case;
If the number of Map Names corresponding to the signal name to be replaced is not equal to 1, judge that the signal name to be replaced is corresponding
Multiple Map Names between correlation, and between multiple Map Names according to corresponding to the signal name to be replaced
Correlation generate the final test case, wherein, multiple Map Names corresponding to the signal name to be replaced it
Between correlation include with relation and/or relation.
2. the generation method of automatic test case in automobile controller as claimed in claim 1, it is characterised in that the basis
Correlation between multiple Map Names corresponding to the signal name to be replaced generates the final test case, bag
Include:
If it is the multiple mapping it is entitled and relation, each signal name to be replaced in the initial test case is replaced with into institute
There is the set of Map Names, and the assignment name is replaced with into the corresponding evaluation mapping name, to generate the final test
Use-case;
If the multiple mapping it is entitled or relation, generation and initial test case described in the Map Names quantity identical
Derivative file, and the signal name to be replaced in the derivative file is replaced with into the Map Names, and assignment name is replaced with pair
The evaluation mapping name answered, to obtain the final test case.
3. the generation method of automatic test case in automobile controller as claimed in claim 1, it is characterised in that the signal
The used spoken and written languages for expression signal in the entitled initial test case, some entitled specific institute of the assignment
State signal name assignment name involved in all initial test cases.
4. the generation method of automatic test case in automobile controller as claimed in claim 2, it is characterised in that described initial
The correlation between Map Names in test case corresponding to multiple signal names to be replaced be or when, to multiple described
It is exhaustive derivative that signal name to be replaced carries out permutation and combination.
5. the generation method of automatic test case in automobile controller as claimed in claim 1, it is characterised in that described initial
Test case is corresponding with the title and/or sequence number of the final test case.
A kind of 6. generation system of automatic test case in automobile controller, it is characterised in that including:
Generation module, for generating initial test case, wherein, the initial test case includes signal name and the signal name
Corresponding assignment name;
Acquisition module, Substitution Rules between signal and measurement signal are sent for obtaining, wherein, the Substitution Rules include by
The logical relation that correlation and evaluation mapping name are formed between the signal name, the assignment name, Map Names, Map Names;
Replacement module, operated for being replaced according to the Substitution Rules to the initial test case to generate final survey
Example on probation, wherein, the replacement module includes:
Index module, for determining signal name to be replaced, and the signal name to be replaced is indexed in the initial test case;
Judge module, for judging whether the number in Map Names corresponding to the signal name to be replaced is equal to 1, and treated described
When replacing the number corresponding to signal name in Map Names and being not equal to 1, judge it is multiple corresponding to the signal name to be replaced described in reflect
The correlation penetrated between name;
Processing module, when being equal to 1 for the number in Map Names corresponding to the signal name to be replaced, by the initial testing
Signal name to be replaced described in use-case replaces with the Map Names, and the assignment name is replaced with into the corresponding evaluation mapping
Name, to generate between the final test case, and multiple Map Names according to corresponding to the signal name to be replaced
Correlation generate the final test case.
7. the generation system of automatic test case in automobile controller as claimed in claim 6, it is characterised in that the processing
Module is additionally operable to:
Number in Map Names corresponding to the signal name to be replaced is more than 1, and the multiple mapping it is entitled and relation when, will
Each signal name to be replaced replaces with the set of all Map Names in the initial test case, and the assignment name is replaced with
The corresponding evaluation mapping name, to generate the final test case;And
Number in Map Names corresponding to the signal name to be replaced is more than 1, and the multiple mapping it is entitled or relation when, it is raw
Into the derivative file with initial test case described in the Map Names quantity identical, and will be to be replaced in the derivative file
Signal name replaces with the Map Names, and by assignment name replace with corresponding to the evaluation mapping name, it is described final to obtain
Test case.
8. the generation system of automatic test case in automobile controller as claimed in claim 6, it is characterised in that the signal
The used spoken and written languages for expression signal in the entitled test case, the assignment name refer to some specific described letter
Number name assignment name involved in all test cases.
9. the generation system of automatic test case in automobile controller as claimed in claim 7, it is characterised in that described initial
The correlation between Map Names in test case corresponding to multiple signal names to be replaced be or when, to multiple described
It is exhaustive derivative that signal name to be replaced carries out permutation and combination.
10. the generation system of automatic test case in automobile controller as claimed in claim 6, it is characterised in that described first
Beginning test case is corresponding with the title and/or sequence number of the final test case.
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510792418.5A CN105373476B (en) | 2015-11-17 | 2015-11-17 | Method and system for generating automatic test case in automobile controller |
PCT/CN2016/102400 WO2017084462A1 (en) | 2015-11-17 | 2016-10-18 | Method and system for generating automatic test case in automobile controller |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510792418.5A CN105373476B (en) | 2015-11-17 | 2015-11-17 | Method and system for generating automatic test case in automobile controller |
Publications (2)
Publication Number | Publication Date |
---|---|
CN105373476A CN105373476A (en) | 2016-03-02 |
CN105373476B true CN105373476B (en) | 2018-01-19 |
Family
ID=55375694
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510792418.5A Active CN105373476B (en) | 2015-11-17 | 2015-11-17 | Method and system for generating automatic test case in automobile controller |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN105373476B (en) |
WO (1) | WO2017084462A1 (en) |
Families Citing this family (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105373476B (en) * | 2015-11-17 | 2018-01-19 | 北京新能源汽车股份有限公司 | Method and system for generating automatic test case in automobile controller |
CN105955887B (en) * | 2016-05-04 | 2018-10-19 | 重庆长安汽车股份有限公司 | A kind of generation method and system of test data |
CN106326125B (en) * | 2016-08-26 | 2019-04-05 | 上海合福信息科技有限公司 | A kind of method for generating test case |
CN108490922B (en) * | 2018-04-27 | 2020-03-24 | 北京新能源汽车股份有限公司 | Generation method and device of unified diagnostic service test case |
CN109088780B (en) * | 2018-10-25 | 2021-11-12 | 北京新能源汽车股份有限公司 | Signal detection method and detection device |
CN109669436B (en) * | 2018-12-06 | 2021-04-13 | 广州小鹏汽车科技有限公司 | Test case generation method and device based on functional requirements of electric automobile |
CN110888803B (en) * | 2019-11-08 | 2023-08-22 | 北京国家新能源汽车技术创新中心有限公司 | Method and system for converting test decision table into test case |
CN110928790B (en) * | 2019-11-27 | 2024-02-02 | 中国银行股份有限公司 | Test case construction method and device and test equipment |
CN113267702A (en) * | 2021-06-24 | 2021-08-17 | 广东电网有限责任公司 | Method and device for generating test case of power distribution network fault self-healing system |
CN114741289B (en) * | 2022-03-31 | 2024-06-04 | 深蓝汽车科技有限公司 | Automatic generation method and system for test cases aiming at controller software storage function |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104035873A (en) * | 2014-06-30 | 2014-09-10 | 青岛海信电器股份有限公司 | Method and device for generating testing codes |
CN104850111A (en) * | 2014-10-16 | 2015-08-19 | 北汽福田汽车股份有限公司 | Hardware-in-loop test method and system |
Family Cites Families (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20110208501A1 (en) * | 2010-02-25 | 2011-08-25 | Gm Global Technology Operations, Inc. | Functional test generation through model inversion |
CN105373476B (en) * | 2015-11-17 | 2018-01-19 | 北京新能源汽车股份有限公司 | Method and system for generating automatic test case in automobile controller |
-
2015
- 2015-11-17 CN CN201510792418.5A patent/CN105373476B/en active Active
-
2016
- 2016-10-18 WO PCT/CN2016/102400 patent/WO2017084462A1/en active Application Filing
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104035873A (en) * | 2014-06-30 | 2014-09-10 | 青岛海信电器股份有限公司 | Method and device for generating testing codes |
CN104850111A (en) * | 2014-10-16 | 2015-08-19 | 北汽福田汽车股份有限公司 | Hardware-in-loop test method and system |
Also Published As
Publication number | Publication date |
---|---|
CN105373476A (en) | 2016-03-02 |
WO2017084462A1 (en) | 2017-05-26 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN105373476B (en) | Method and system for generating automatic test case in automobile controller | |
CN104965507B (en) | Generate the method and device of open diagnostic data switching database | |
CN101867501B (en) | Method and system for automatically testing consistence of SNMP (Simple Network Management Protocol) interface information model | |
CN107135210B (en) | Automobile simulation communication protocol analyzer and analysis method thereof | |
BR112014017135B1 (en) | SYSTEM AND METHOD TO PROVIDE DIAGNOSIS FAILURE INFORMATION | |
CN105138461A (en) | Interface testing method and device for application program | |
CN103197666A (en) | General-type handheld automobile fault diagnostic instrument | |
CN107678936A (en) | The advance checking method of operation system, server and computer-readable recording medium | |
CN107544463A (en) | Automatic test method and test device for diagnosis function of vehicle controller | |
RU2601141C2 (en) | System and method for providing diagnostic information on faults | |
CN109634600A (en) | A kind of code generating method based on security extension SysML and AADL model | |
CN106647716A (en) | Universal automobile health diagnosis system and application method thereof | |
CN107966648B (en) | A kind of embedded failure diagnosis method based on correlation matrix | |
CN113359657B (en) | ECU diagnosis configuration code verification method and system and electronic control unit thereof | |
CN110287470A (en) | Urban rail transit vehicles structure buffering apparatus detects form generation system, method, server and storage medium | |
Boulanger | Requirements engineering in a model-based methodology for embedded automotive software | |
CN110688823A (en) | XML file verification method and device | |
CN103778153B (en) | A kind of method and system generating nominal data storehouse based on ASAP standard | |
CN101673200B (en) | The detection method of user input model and device | |
CN108776723A (en) | Test System self-test adapter line generation method, device, equipment and storage medium | |
CN102147618B (en) | Memory corruption detection in engine control system | |
CN103699682B (en) | Method for verifying structural logics of databases | |
KR20150137055A (en) | Method for managing data relative to motor vehicles with a view to the subsequent graphic generation of electrical diagrams of electrical systems | |
CN107203466A (en) | API method of testings and device | |
CN110455377A (en) | Fuel vehicle course continuation mileage display matching rack and test method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |