CN104021083B - Test method and device - Google Patents

Test method and device Download PDF

Info

Publication number
CN104021083B
CN104021083B CN201410271415.2A CN201410271415A CN104021083B CN 104021083 B CN104021083 B CN 104021083B CN 201410271415 A CN201410271415 A CN 201410271415A CN 104021083 B CN104021083 B CN 104021083B
Authority
CN
China
Prior art keywords
test
orthogonal
path set
test path
module
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
CN201410271415.2A
Other languages
Chinese (zh)
Other versions
CN104021083A (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.)
Gree Electric Appliances Inc of Zhuhai
Original Assignee
Gree Electric Appliances Inc of Zhuhai
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 Gree Electric Appliances Inc of Zhuhai filed Critical Gree Electric Appliances Inc of Zhuhai
Priority to CN201410271415.2A priority Critical patent/CN104021083B/en
Publication of CN104021083A publication Critical patent/CN104021083A/en
Application granted granted Critical
Publication of CN104021083B publication Critical patent/CN104021083B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Design And Manufacture Of Integrated Circuits (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The invention discloses a test method and a test device. The test method comprises the following steps: calculating a test path set of a plurality of test cases by using an orthogonal test algorithm; acquiring navigation data corresponding to the test path set; and testing by using the navigation data, the test cases and the test path set. By adopting the method and the device, the problem of high test omission rate when the software is subjected to function test in the prior art is solved, the integrity of a test path and the closed loop of quality control are ensured, and the test efficiency is greatly improved.

Description

Method of testing and device
Technical field
The present invention relates to software test field, in particular to a kind of method of testing and device.
Background technology
At present to equipment carry out logic function test, be by being manually combined to logic function book, then manually or Person is tested according to test software function, and complete logic testing path is not combined with software, realizes test navigation Function.So this test mode can cause phenomena such as test leakage, few survey, test content false, and substantial amounts of test can be wasted Cycle.
The problem of false pass rate is high is tested during for carrying out functional test to software in the prior art, not yet being proposed at present effective Solution.
The content of the invention
The problem of false pass rate is high is tested during for carrying out functional test in correlation technique to software, not yet being proposed at present effective Solution, therefore, it is a primary object of the present invention to provide a kind of method of testing and device, to solve the above problems.
To achieve these goals, according to an aspect of the invention, there is provided a kind of method of testing, the method for testing bag Include:The test path set of multiple test cases is calculated using orthogonal test algorithm;Obtain lead corresponding with test path set Boat data;Tested using navigation data, test case and test path set.
Further, the test path set of multiple test cases is calculated using orthogonal test algorithm to be included:Parsing test Use-case obtains test data;The two-level orthogonal array of test data and multilevel orthogonal arrage are calculated using orthogonal test algorithm;Make The orthogonal array of two-level orthogonal array and multilevel orthogonal arrage is calculated with orthogonal test algorithm;Using parameter preset to mixing just Friendship table is modified to obtain test path set.
Further, carrying out test using navigation data, test case and test path set includes:Use navigation data Determine the order of test path in test path set;In sequence test path is extracted from test path set;According to survey Examination path is tested using test case.
Further, carrying out test using test case according to test path includes:Obtain survey corresponding with test path Example on probation;
Obtain test configurations interface corresponding with test case;By the implementation of test cases of test configurations interface, to carry out Test.
To achieve these goals, according to another aspect of the present invention, there is provided a kind of test device, the test device bag Include:Computing module, for calculating the test path set of multiple test cases using orthogonal test algorithm;First acquisition module, For obtaining navigation data corresponding with test path set;Test module, for using navigation data, test case and test Set of paths is tested.
Further, computing module includes:Parsing module, test data is obtained for parsing test case;First calculates Submodule, for calculating the two-level orthogonal array of test data and multilevel orthogonal arrage using orthogonal test algorithm;Second calculates Submodule, for calculating the orthogonal array of two-level orthogonal array and multilevel orthogonal arrage using orthogonal test algorithm;Correct mould Block, for being modified to obtain test path set to orthogonal array using parameter preset.
Further, test module includes:Determining module, for determining to test in test path set using navigation data The order in path;Abstraction module, for extracting test path from test path set in sequence;Submodule is tested, is used for Tested according to test path using test case.
Further, test submodule includes:Second acquisition module, used for obtaining test corresponding with test path Example;3rd acquisition module, for obtaining test configurations interface corresponding with test case;Execution module, for being matched somebody with somebody by test Interface implementation of test cases is put, to be tested.
Using the present invention, test combination (the test road i.e. in above-described embodiment can be calculated according to orthogonal test algorithm Test path in the set of footpath), and test path is combined with software gui interface, realize the navigation feature that software performs automatically. Using the present invention, function logic during test is formed complete no longer by artificial combination, but according to orthogonal experiment method Automatic Combined Test path, prevented test leakage existing for artificial combination, it is few survey, the wrong phenomenon surveyed, solve and software entered in the prior art The problem of false pass rate is high is tested during row functional test, the integrality of test path is ensure that, the closed loop of quality control, greatly improves Testing efficiency.
Brief description of the drawings
Accompanying drawing described herein is used for providing a further understanding of the present invention, forms the part of the application, this hair Bright schematic description and description is used to explain the present invention, does not form inappropriate limitation of the present invention.In the accompanying drawings:
Fig. 1 is the structural representation of test device according to embodiments of the present invention;
Fig. 2 is the flow chart of method of testing according to embodiments of the present invention;And
Fig. 3 is a kind of flow chart of method of testing according to embodiments of the present invention.
Embodiment
In order that those skilled in the art more fully understand the present invention program, below in conjunction with the embodiment of the present invention Accompanying drawing, the technical scheme in the embodiment of the present invention is clearly and completely described, it is clear that described embodiment is only The embodiment of a part of the invention, rather than whole embodiments.Based on the embodiment in the present invention, ordinary skill people The every other embodiment that member is obtained under the premise of creative work is not made, it should all belong to the model that the present invention protects Enclose.
It should be noted that term " first " in description and claims of this specification and above-mentioned accompanying drawing, " Two " etc. be for distinguishing similar object, without for describing specific order or precedence.It should be appreciated that so use Data can exchange in the appropriate case, so as to embodiments of the invention described herein can with except illustrating herein or Order beyond those of description is implemented.In addition, term " comprising " and " having " and their any deformation, it is intended that cover Cover it is non-exclusive include, be not necessarily limited to for example, containing the process of series of steps or unit, method, system, product or equipment Those steps or unit clearly listed, but may include not list clearly or for these processes, method, product Or the intrinsic other steps of equipment or unit.
Fig. 1 is the structural representation of test device according to embodiments of the present invention.As shown in figure 1, the test device can be with Including:Computing module 10, for calculating the test path set of multiple test cases using orthogonal test algorithm;First obtains mould Block 20, for obtaining navigation data corresponding with test path set;Test module 30, for being used using navigation data, test Example is tested with test path set.
Using the present invention, test combination (the test road i.e. in above-described embodiment can be calculated according to orthogonal test algorithm Test path in the set of footpath), and test path is combined with software gui interface, realize the navigation feature that software performs automatically. Using the present invention, function logic during test is formed complete no longer by artificial combination, but according to orthogonal experiment method Automatic Combined Test path, prevented test leakage existing for artificial combination, it is few survey, the wrong phenomenon surveyed, solve and software entered in the prior art The problem of false pass rate is high is tested during row functional test, the integrality of test path is ensure that, the closed loop of quality control, greatly improves Testing efficiency.
According to the abovementioned embodiments of the present invention, computing module can include:Parsing module, obtained for parsing test case Test data;First calculating sub module, for calculating the two-level orthogonal array of test data and more water using orthogonal test algorithm Flat orthogonal arrage;Second calculating sub module, for calculating two-level orthogonal array and multilevel orthogonal arrage using orthogonal test algorithm Orthogonal array;Correcting module, for being modified to obtain test path set to orthogonal array using parameter preset.
Further, test module can include:Determining module, for being determined using navigation data in test path set The order of test path;Abstraction module, for extracting test path from test path set in sequence;Test submodule, For being tested according to test path using test case.
Need to be that test submodule can include with further illustrating:Second acquisition module, for acquisition and test path Corresponding test case;3rd acquisition module, for obtaining test configurations interface corresponding with test case;Execution module, use In by the implementation of test cases of test configurations interface, to be tested.
Each processing module in above-described embodiment can be next to correspond to the implementation method of step in application method embodiment Realize, will not be repeated here.
Fig. 2 is the flow chart of method of testing according to embodiments of the present invention, and this method as shown in Figure 2 comprises the following steps:
Step S202, the test path set of multiple test cases is calculated using orthogonal test algorithm.
Step S204, obtain navigation data corresponding with test path set.
Step S206, tested using navigation data, test case and test path set.
Using the present invention, test combination (the test road i.e. in above-described embodiment can be calculated according to orthogonal test algorithm Test path in the set of footpath), and test path is combined with software gui interface, realize the navigation feature that software performs automatically. Using the present invention, function logic during test is formed complete no longer by artificial combination, but according to orthogonal experiment method Automatic Combined Test path, prevented test leakage existing for artificial combination, it is few survey, the wrong phenomenon surveyed, solve and software entered in the prior art The problem of false pass rate is high is tested during row functional test, the integrality of test path is ensure that, the closed loop of quality control, greatly improves Testing efficiency.
Wherein, in the above-described embodiments, by taking disturbed test frock as an example, disturbed test content coverage rate has reached 99%, Efficiency improves 90%.
Can be by orthogonal arrage property to therein when determining test path using orthogonal test algorithm in the above-described embodiments Test path is checked to obtain test path set, wherein, orthogonal arrage property (i.e. preparatory condition) can include:
1. once combine all standing:Any one row must include all levels, not leak item.
2. secondary combination all standing:Certain during any screening one arranges is horizontal, then the full level of remaining row is all present after screening, and does not have There is leakage item
3. same level is once combined and is uniformly distributed:Each horizontal occurrence number is impartial in any one row.
4. the horizontal secondary combination of same type is uniformly distributed:Certain horizontal factor in any row of screening one, then after screening remaining Each horizontal number occurred is impartial in row.Wherein, horizontal factor can be test case in test parameter, as blower fan temperature, The parameters such as environment temperature.
Duplicate removal is merged according to test path set of the above-mentioned preparatory condition to initial acquisition to handle to obtain test road Gather in footpath.
According to the abovementioned embodiments of the present invention, the test path set of multiple test cases is calculated using orthogonal test algorithm It can include:Parsing test case obtains test data;The two-level orthogonal array of test data is calculated using orthogonal test algorithm With multilevel orthogonal arrage;The orthogonal array of two-level orthogonal array and multilevel orthogonal arrage is calculated using orthogonal test algorithm;Make Orthogonal array is modified with parameter preset to obtain test path set.
As shown in figure 3, this method can be achieved by the steps of:
Step S301:Obtain test case.
Step S302:Test case is screened using orthogonal test algorithm and combines to obtain test path set.
Specifically, test case screening combination, it can read input data first by Matlab programming realizations and solved Analysis, writes algorithm and calculates satisfactory two-level orthogonal array and multilevel orthogonal arrage, then writes algorithm and calculate hybrid orthogonal Table, calculating are brought the data of input into form after finishing and correcting and arranged, and export a complete test path set.
Wherein, the input data in above-described embodiment is the test parameter in test case, and test parameter includes environment temperature Spend the data such as test data, blower fan temperature test data.The data need to carry out all elements of quadrature analysis, can be from survey Extracted in the logic of example on probation.
Satisfactory two-level orthogonal array is calculated in above-described embodiment and multilevel orthogonal arrage can be by such as lower section Method is realized:1st, the orthogonal arrage number of levels and factor number (quantity of the test parameter i.e. in above-described embodiment) selected all cannot be less than Input value (input value herein is in above-described embodiment).2nd, when having 2 or more than 2 orthogonal arrages can be chosen, Selection principle is that orthogonal arrage for selecting test number (TN) minimum, and the path that can so cause test case is most succinct and most complete It is whole.
Step S303:All test paths are made navigation feature using software.
Wherein, test path function is realized and developed by labview development platforms, and every kind of test path includes combination, Software function is combined with test path by way of state machine, namely software calls test road from database in sequence Footpath;Navigation feature embodies in gui interface, realizes self-navigation function.
According to the abovementioned embodiments of the present invention, carrying out test using navigation data, test case and test path set can With including:The order of test path in test path set is determined using navigation data;In sequence from test path set Extract test path;Tested according to test path using test case.It can specifically be realized by the step shown in Fig. 3:
Step S304:The automated randomized test path extracted in test path set of software.
Further, carrying out test using test case according to test path includes:Obtain survey corresponding with test path Example on probation;Obtain test configurations interface corresponding with test case;By the implementation of test cases of test configurations interface, to be surveyed Examination.
Specifically, can be realized by the step S305 shown in Fig. 3 to step S308:
Step S305:Eject test configurations interface.
Step S306:It is automatic to perform test content.
Step S307:Detect whether all test paths test completion.
In the case where all test path tests are completed, step S308 is performed:Generate test report;In all surveys In the case that completion is not tested in examination path, return and perform step S304.
By the above embodiment of the present invention, the content and function of software test are no longer guided by tester, and It is by navigation feature Automatic Combined, execution step by step, guides test man's easy configuration, realize the complete of test path Property, be not in test leakage, few survey, the wrong phenomenon surveyed, after navigation content test is completed, software automatically generates test report.
It should be noted that can be in such as one group of computer executable instructions the flow of accompanying drawing illustrates the step of Performed in computer system, although also, show logical order in flow charts, in some cases, can be with not The order being same as herein performs shown or described step.
As can be seen from the above description, the present invention realizes following technique effect:
Using the present invention, test combination (the test road i.e. in above-described embodiment can be calculated according to orthogonal test algorithm Test path in the set of footpath), and test path is combined with software gui interface, realize the navigation feature that software performs automatically. Using the present invention, function logic during test is formed complete no longer by artificial combination, but according to orthogonal experiment method Automatic Combined Test path, prevented test leakage existing for artificial combination, it is few survey, the wrong phenomenon surveyed, solve and software entered in the prior art The problem of false pass rate is high is tested during row functional test, the integrality of test path is ensure that, the closed loop of quality control, greatly improves Testing efficiency.
Obviously, those skilled in the art should be understood that above-mentioned each module of the invention or each step can be with general Computing device realize that they can be concentrated on single computing device, or be distributed in multiple computing devices and formed Network on, alternatively, they can be realized with the program code that computing device can perform, it is thus possible to they are stored Performed in the storage device by computing device, either they are fabricated to respectively each integrated circuit modules or by they In multiple modules or step be fabricated to single integrated circuit module to realize.So, the present invention is not restricted to any specific Hardware and software combines.
The preferred embodiments of the present invention are the foregoing is only, are not intended to limit the invention, for the skill of this area For art personnel, the present invention can have various modifications and variations.Within the spirit and principles of the invention, that is made any repaiies Change, equivalent substitution, improvement etc., should be included in the scope of the protection.

Claims (6)

  1. A kind of 1. method of testing, it is characterised in that including:
    The test path set of multiple test cases is calculated using orthogonal test algorithm, wherein, use the orthogonal test algorithm When determining the test path in the test path set, the test path of initial acquisition check by orthogonal arrage property To the test path set;
    Obtain navigation data corresponding with the test path set;
    Tested using the navigation data, the test case and the test path set;
    Wherein, the test path set of multiple test cases is calculated using orthogonal test algorithm to be included:
    Parse the test case and obtain test data;
    The two-level orthogonal array of the test data and multilevel orthogonal arrage are calculated using orthogonal test algorithm;
    The orthogonal array of the two-level orthogonal array and the multilevel orthogonal arrage is calculated using orthogonal test algorithm;
    The orthogonal array is modified using parameter preset to obtain the test path set.
  2. 2. method of testing according to claim 1, it is characterised in that using the navigation data, the test case with The test path set, which carries out test, to be included:
    The order of test path in the test path set is determined using the navigation data;
    According to the order test path is extracted from the test path set;
    Tested according to the test path using the test case.
  3. 3. method of testing according to claim 2, it is characterised in that use the test case according to the test path Carrying out test includes:
    Obtain the test case corresponding with the test path;
    Obtain test configurations interface corresponding with the test case;
    The test case is performed by the test configurations interface, to be tested.
  4. A kind of 4. test device, it is characterised in that including:
    Computing module, for calculating the test path set of multiple test cases using orthogonal test algorithm, wherein, using described When orthogonal test algorithm determines the test path in the test path set, by test road of the orthogonal arrage property to initial acquisition Checked to obtain the test path set in footpath;
    First acquisition module, for obtaining navigation data corresponding with the test path set;
    Test module, for being tested using the navigation data, the test case and the test path set;
    Wherein, the computing module includes:
    Parsing module, test data is obtained for parsing the test case;
    First calculating sub module, for calculating the two-level orthogonal array of the test data and multilevel using orthogonal test algorithm Orthogonal arrage;
    Second calculating sub module, for calculating the two-level orthogonal array and the multilevel orthogonal arrage using orthogonal test algorithm Orthogonal array;
    Correcting module, for being modified to obtain the test path set to the orthogonal array using parameter preset.
  5. 5. test device according to claim 4, it is characterised in that the test module includes:
    Determining module, for determining the order of test path in the test path set using the navigation data;
    Abstraction module, for extracting the test path from the test path set according to the order;
    Submodule is tested, for being tested according to the test path using the test case.
  6. 6. test device according to claim 5, it is characterised in that test submodule includes:
    Second acquisition module, for obtaining the test case corresponding with the test path;
    3rd acquisition module, for obtaining test configurations interface corresponding with the test case;
    Execution module, for performing the test case by the test configurations interface, to be tested.
CN201410271415.2A 2014-06-17 2014-06-17 Test method and device Active CN104021083B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410271415.2A CN104021083B (en) 2014-06-17 2014-06-17 Test method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410271415.2A CN104021083B (en) 2014-06-17 2014-06-17 Test method and device

Publications (2)

Publication Number Publication Date
CN104021083A CN104021083A (en) 2014-09-03
CN104021083B true CN104021083B (en) 2017-11-28

Family

ID=51437848

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410271415.2A Active CN104021083B (en) 2014-06-17 2014-06-17 Test method and device

Country Status (1)

Country Link
CN (1) CN104021083B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105677667A (en) * 2014-11-19 2016-06-15 珠海格力电器股份有限公司 Data processing method and device for orthogonal test
CN109558310A (en) * 2018-10-25 2019-04-02 北京仁科互动网络技术有限公司 Method for generating test case and device
CN110111911A (en) * 2019-03-15 2019-08-09 国联汽车动力电池研究院有限责任公司 Experimental design management method and device

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103428739A (en) * 2012-05-17 2013-12-04 上海手机测试公共服务平台有限公司 Off-site testing method

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3722206B2 (en) * 2000-06-30 2005-11-30 日本電気株式会社 Software test work support method, apparatus, and recording medium recording software test work support program
CN100377109C (en) * 2005-11-07 2008-03-26 华为技术有限公司 Method for completing product automation test utilizing test kit
CN101593145B (en) * 2008-05-29 2012-08-08 福建升腾资讯有限公司 Designing method of high-efficiency high-coverage-rate function test case
CN102096631B (en) * 2009-12-11 2013-09-25 华为技术有限公司 Interface testing method and device

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103428739A (en) * 2012-05-17 2013-12-04 上海手机测试公共服务平台有限公司 Off-site testing method

Also Published As

Publication number Publication date
CN104021083A (en) 2014-09-03

Similar Documents

Publication Publication Date Title
CN110134588B (en) Test case priority ordering method and test system based on code and combination coverage
CN103530228A (en) Software testing method based on model
CN105786678B (en) A kind of testability prediction method based on correlation models
CN106294174B (en) The various dimensions measure and device of testing adequacy
CN104346278A (en) Matrix-model-based software testing method
CN104021083B (en) Test method and device
CN107544905A (en) The optimization method and system of regression test case collection
CN106021113A (en) Method for realizing accurate test
CN106708723A (en) Testing and verifying methods and apparatuses
CN111475402A (en) Program function testing method and related device
Serrestou et al. Functional verification of rtl designs driven by mutation testing metrics
CN104063307A (en) Software testing method and system
CN107703773A (en) A kind of method for testing software and device based on hardware-in-loop simulation system
CN105159826B (en) A kind of method and apparatus of wrong sentence in positioning target program
US8402421B2 (en) Method and system for subnet defect diagnostics through fault compositing
CN106294106A (en) The method of testing of Web application system and device
George Constructing covering arrays using parallel computing and grid computing
CN107402883B (en) A kind of data test treating method and apparatus
Akkouche et al. Analog/RF test ordering in the early stages of production testing
CN109597744A (en) Data unusual fluctuation analysis method and device
CN105868099A (en) Branch submit difference detection method and device
CN109214272A (en) A kind of image-recognizing method and device
US20140215418A1 (en) Digital Circuit Verification Monitor
US10338137B1 (en) Highly accurate defect identification and prioritization of fault locations
Gladston et al. Test suite reduction using HGS based heuristic approach

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