CN101739334A - Automatic testing method of embedded software - Google Patents

Automatic testing method of embedded software Download PDF

Info

Publication number
CN101739334A
CN101739334A CN200810203104A CN200810203104A CN101739334A CN 101739334 A CN101739334 A CN 101739334A CN 200810203104 A CN200810203104 A CN 200810203104A CN 200810203104 A CN200810203104 A CN 200810203104A CN 101739334 A CN101739334 A CN 101739334A
Authority
CN
China
Prior art keywords
test
software
interface
flow chart
embedded software
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN200810203104A
Other languages
Chinese (zh)
Inventor
邹毅军
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
SHANGHAI KELIANG INFORMATION ENGINEERING Co Ltd
Original Assignee
SHANGHAI KELIANG INFORMATION ENGINEERING Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by SHANGHAI KELIANG INFORMATION ENGINEERING Co Ltd filed Critical SHANGHAI KELIANG INFORMATION ENGINEERING Co Ltd
Priority to CN200810203104A priority Critical patent/CN101739334A/en
Publication of CN101739334A publication Critical patent/CN101739334A/en
Pending legal-status Critical Current

Links

Images

Abstract

The invention relates to an automatic testing method of embedded software, which is realized through the following steps of: editing and establishing a test case base; establishing a test flow framework in a flow chart editing interface; inserting various test cases into a test flow chart according to the requirement of a test task; converting the edited flow chart into a test sequence on a simulated test platform by utilizing a script generator; and driving an I/O interface and a communication interface on the simulated test platform, exciting the software to be tested and receiving a feedback control signal. The automatic testing method of the embedded software has the advantages that open-loop testing and closed-loop testing can be carried out; a peripheral environment simulation base and an interface module base with strong functions can be formed through continuously adding interface modules to reduce subsequent secondary development, so that resources are recycled.

Description

Automatic testing method of embedded software
Technical field
The present invention relates to a kind of software test, relate in particular to a kind of automatic testing method of embedded software.
Background technology
Software test is an important link of engineering of software development project.Particularly increasingly sophisticated at the built-in applied system in fields such as aerospace, the proportion of software is increasing in the embedded system, and to the reliability of built-in system software, security, the requirement of accuracy and stability are also strict day by day.Simultaneously hardware advances is stable day by day, and software fault becomes increasingly conspicuous, and therefore the importance to the software test of embedded system causes people's great attention.
The method of software test and technology are diversified, can classify from different angles.From whether needing to carry out the angle of tested software, can be divided into static test and dynamic test; Whether at the inner structure of system and the angle of specific implementation algorithm, can be divided into white-box testing and Black-box Testing from test.The main test foundation of Black-box Testing is a software requirement.It is conceived to the external structure of software, does not consider the logical organization and the bulk properties of program, and only according to the Specification of software, whether the function of scrutiny program meets the requirements on software interface.
The instrument that automatic test is to use automatic test integrates software unit or functional module and total system and carries out whole test.This method of testing mainly is primarily focused on utilizes automatic testing instrument to help improve the efficient that those take labours' test, thereby improves software quality.The automatic test flow process should comprise following two conditions at least: 1, detailed test case: the test case of writing according to business function demand and design documentation comprises foreseeable expected results: 2, test environment independently: comprise the test environment that can recover test data, so that can repeat the test case that these write in advance after substituting in that application program is each.
Most of method for testing software can be used for the test of embedded software directly or indirectly, but because the real-time and embedded characteristic of operating system, embedded software test also faces some special problems.Though some test and debugging acids at embedded software have been arranged a few days ago, still there is deficiency aspect some, comprise software abstract of the test of concurrent, non-intrusion type of many task operatings system and debugging, embedded system etc.Remain to be developed for embedded software test Study on Technology person testing tool, still need do a lot of further work.
The entire work process of embedded software is moved automatically according to the flow process of predefined, does not generally have manual intervention.Fault to this class software generally can't accurately be located.Be the function of further verifying software, performance, indexs such as reliability and security just need it to confirm test.
Confirm that test is called validity test again.Its task is whether the function of verifying software is consistent with user's requirement with performance and other characteristics.After integration testing, software assembles fully, and the mistake of interface aspect is also got rid of, confirms that test can begin.Confirm to test and to check whether can software according to the contract require to carry out work, promptly satisfy the affirmation standard in the software requirements specification.Simultaneously, to true his demand of software, as portable, compatible, make mistakes recoverys automatically, maintainability etc., all will test, whether affirmation meets the demands.
Existing to the common processes such as definite test procedure, design test case, setup test environment that need of embedded software affirmation test.Its method of testing mainly is with a cover emulator test environment, the test case that writes is carried out on the emulator environment according to the rule that realizes definition, and by corresponding interface measured target is encouraged.Therefore from essence, this is a kind of Black-box Testing.
The test environment of the test of Aero-Space embedded software affirmation at present mainly contains following several, and a kind of is common simulation hardware test environment; Another kind is the Digital Simulation test environment.The simulation hardware test environment usually causes test job not finish smoothly owing to can not be general to different model software.Digital emulation testing environment is exactly the mode of emulation of using a computer, and structure needed hardware environment of embedded software running and external data source constitute digital embedded software running environment, and carry out various test jobs on this environment.
Existing embedded software Digital Simulation test environment mainly comprises dSPACE and RT-LAB half-physical simulation test platform.The common feature of these test environments is to simulate as the controlling object of tested software by the system model of real time execution.Then by in model, add needing the test case of operation, encourage the software on the tested target machine and the feedback control signal of collection tested target machine software by I/O and the communication interface that drives the correspondence on the simulation test platform.
But such half-physical simulation test platform in use exists following deficiency:
A) automatic test course is not directly perceived
On dSPACE and RT-LAB half-physical simulation test platform, all need the editing system realistic model.These models all are to build with Simulink, and are translated into the code that moves on the real-time platform.This explanation half-physical simulation test platform more lays particular emphasis on the dynamics and control modeling of system, but also lacks open-loop test ability and fault injectability to crosslinked tested controller and software thereof.Can not well realize automatic test.
B) shortage is to the managerial ability of test case
No matter being dSPACE or RT-LAB, all is the simulation that lays particular emphasis on the controlling object system of tested software.They lack the editor to test case, tissue and the managerial ability of carrying out.In use, how neither one goes to control test case according to the order of test plan regulation with carry out constantly at the interface clearly.
Summary of the invention
The technical issues that need to address of the present invention have provided a kind of automatic testing method of embedded software, are intended to solve the above problems.
In order to solve the problems of the technologies described above, the present invention realizes by following steps:
Editor also sets up test case library;
In the process flow diagram editing interface, set up the testing process framework;
According to the test assignment demand, in test flow chart, insert various test cases;
Utilize script generator that editor's process flow diagram is converted to cycle tests on the simulation test platform;
Drive I/O and communication interface on the simulation test platform, the excitation tested software also receives the feedback control signal.
Compared with prior art, the invention has the beneficial effects as follows: owing to adopt process flow diagram mode scheduling tests use-case, can describe the operational scheme of tested software easily, test case is effectively managed, conveniently carry out robotization and confirm test; Do not need to carry out the modeling work of Simulink, directly use the flowcharting testing process.Can carry out open-loop test and closed loop test; Can form powerful peripheral environment simulated library and interface module storehouse by constantly adding interface model,, make the resource recycling to reduce follow-up secondary development.
Description of drawings
Fig. 1 is that the whole software test macro is formed;
Fig. 2 adopts the present invention to be applied in the process flow diagram of step 2 in the specific embodiment;
Fig. 3 adopts the present invention to be applied in the process flow diagram of step 3 in the specific embodiment.
Embodiment
Below in conjunction with the drawings and specific embodiments the present invention is described in further detail:
The present invention has added the test case management function of process flow diagram mode on the basis of half-physical simulation test platform.
The present invention realizes by following steps:
1. edit and set up test case library;
2. in the process flow diagram editing interface, set up the testing process framework;
3. according to the test assignment demand, in test flow chart, insert various test cases;
4. utilize script generator that editor's process flow diagram is converted to cycle tests on the simulation test platform;
5. I/O and the communication interface on the driving simulation test platform encourages tested software also to receive the feedback control signal.
Formulate test case
According to the requirement of testing scheme, design various test cases.Test case is divided into following a few class:
The test of-conventional func: this class testing use-case is the conventionally test that is used for the test function quality, works out according to " software requirement specification document ".Owing to be under half environment in kind, to work, so these test cases bias toward the test of I/O and communication interface.
-performance test: this class performance test lays particular emphasis on the excitation to certain instruction of injection of tested software, estimates the corresponding speed of tested software then by the control signal that receives.
-limit testing: when determining the input and output parameter, in most cases all be the boundary value analysis method of using, adopt the test case discovery procedure mistake ability of boundary value analysis design the strongest.
-unusual and fault injection: to possible input parameter fault, operating troubles, and the simulation of possible communication failure.
Above-mentioned test case is made the mode of functional module with script, and storage becomes test case library, can browse from tree list.
The establishment test flow chart
Establishment mainly focuses on the correctness that test mode shifts based on the test flow chart of state machine.
The process flow diagram editing machine is with the mode and the user interactions of figure.The user only need add corresponding segment simply and this segment is done some basic setups, can convert test script to by script generation instrument, and order is carried out on simulation test platform then.
From the kind branch of segment, process flow diagram mainly contains two big classes:
The first, general segment
This class segment comprises starting block, execution block, the decision block that is similar to general flow figure, and inside does not have special setting, and concrete function body needs the user manually to import.
The second, special segment
This class segment is that inside has embedded the specific function body towards some specific application, does not need user's input function body, as long as do the setting of a little.As open serial ports, serial data transmission, acceptance etc.
Divide from combination, also mainly contain six classes:
The first, there is not combination.This class segment with the form of monomer add, operation such as deletion.
The second, FOR combination.This class segment occurs with a monoblock For structure, the user can only be in inside suitable place add, operation such as deletion.
Three, IF combination.
Four, DO ... ..WHILE combination.
Five, WHILE ... .DO combination.
Six, SWITCH combination.
The method of operating of process flow diagram.View of the every interpolation of user just is equivalent to add a power function.At the start page place of view, system can add a Start and the initial sum stop piece of End and the connecting line between them automatically.
In process flow diagram, add test case
After interpolation is finished, double-click this segment and enter editing interface, can be provided with or directly import corresponding test case and relevant parameters its relevant parameters.Because being the functional module mode with script, test case realizes.Therefore be easy in process flow diagram, add test case.
The operation of automatic test
As shown in Figure 1: convert the test case in the process flow diagram framework of said process generation to script by script generation instrument, can upload on the simulation test platform server by TCP/IP then.The test script sequence drives and communication interface by the I/O that drives on the simulation test platform when operation, carries out communication with tested software.The excitation tested software is made various responses.The data that produce in test process can be preserved it selectively, make things convenient for ex-post analysis.
The following applying step that said method is described according to the actual Test Application that adopts said method to carry out.
Tested object:
Adopt certain model missile-borne computer as measurand (UUT).Test computer is undertaken by RS422 serial ports and missile-borne machine alternately.The automatic test of test computer is organized by process flow diagram.The software flow of the corresponding missile-borne machine of each flow process Control Software of process flow diagram.Test case embeds in test flow chart.Manage sending Frame in the test case.The function that test case realizes contains the various test functions of above mentioning substantially.
Test process:
Step 1: according to the input/output signal specified data structure of missile-borne machine.Send data structure and be assumed to be T1, receive data structure and be assumed to be R1.
Step 2: according to the course of normal operation and the test case load(ing) point of missile-borne machine, the normal course of operation of missile-borne machine is divided into N stage, at first need to load corresponding test case before each stage operation, and this test case may influence some stages thereafter.
In the phase one of flow process, several typical test cases schematically as follows:
Test I D Test name Send data Delivery time Receive data The time of reception
??1.1 Normal data ??T1 ??ts ??T2 ??tr
??1.2 Minimum data ??T1,T1.data(0)=min ??ts ??T2 ??tr
??1.3 Maximum data ??T1,T1.data(0)=max ??ts ??T2 ??tr
??1.4 The frame head mistake ??T1,T1.head^0xFFFF ??ts ??T2 ??tr
The performance time index t=tr-ts of performance test correspondence.
Above test case can Control Circulation be injected in test flow chart.
The loading of test case is carried out automatically.After each test case loaded, program run was intact, and control UUT is the automatic rollback of its working procedure, moves next test case, finished up to all test case operations.
Step 3: as subroutine, utilize process flow diagram with its whole realizations with each loading procedure.
Step 4: process flow diagram is converted to script and uploads to STE computer run, obtain missile-borne machine service data and status information under the various test cases, and in the chart of interface, these information are analyzed.

Claims (1)

1. automatic testing method of embedded software, realize by following steps:
Editor also sets up test case library;
In the process flow diagram editing interface, set up the testing process framework;
According to the test assignment demand, in test flow chart, insert various test cases;
Utilize script generator that editor's process flow diagram is converted to cycle tests on the simulation test platform;
Drive I/O and communication interface on the simulation test platform, the excitation tested software also receives the feedback control signal.
CN200810203104A 2008-11-21 2008-11-21 Automatic testing method of embedded software Pending CN101739334A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN200810203104A CN101739334A (en) 2008-11-21 2008-11-21 Automatic testing method of embedded software

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN200810203104A CN101739334A (en) 2008-11-21 2008-11-21 Automatic testing method of embedded software

Publications (1)

Publication Number Publication Date
CN101739334A true CN101739334A (en) 2010-06-16

Family

ID=42462850

Family Applications (1)

Application Number Title Priority Date Filing Date
CN200810203104A Pending CN101739334A (en) 2008-11-21 2008-11-21 Automatic testing method of embedded software

Country Status (1)

Country Link
CN (1) CN101739334A (en)

Cited By (23)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101968770A (en) * 2010-11-01 2011-02-09 北京航空航天大学 Reusable embedded software testing and developing method and system
CN102156784A (en) * 2011-04-18 2011-08-17 烽火通信科技股份有限公司 Verifying environment patterned chip verifying method and device
CN102402484A (en) * 2011-11-30 2012-04-04 北京航空航天大学 Automatic experimental device and method for reliability growth test of embedded software
CN102591780A (en) * 2012-01-13 2012-07-18 广州广电运通金融电子股份有限公司 Device driver software test method and test system
CN102890499A (en) * 2012-09-21 2013-01-23 北京智行鸿远汽车技术有限公司 Method for loop testing of vehicle control unit software of pure electric automobile
CN102915242A (en) * 2012-09-26 2013-02-06 北京广利核系统工程有限公司 Method for implementing code programming by graphical operations
CN103034227A (en) * 2012-09-20 2013-04-10 北京智行鸿远汽车技术有限公司 Testing method in circuit of battery electric vehicle vehicle-control unit model
CN103220186A (en) * 2013-03-21 2013-07-24 大唐联仪科技有限公司 Communication equipment testing method and system
CN103257925A (en) * 2013-04-28 2013-08-21 株洲南车时代电气股份有限公司 Automatic testing device, system and method for train operation monitoring record software
CN104615541A (en) * 2015-02-10 2015-05-13 上海创景计算机系统有限公司 Simulation testing modeling system and method based on flow chart
CN104657262A (en) * 2015-02-10 2015-05-27 上海创景计算机系统有限公司 High-real-time automatic testing system and testing method
CN105335177A (en) * 2014-07-23 2016-02-17 比亚迪股份有限公司 Test method, test device and test system of embedded system
CN105577475A (en) * 2015-12-28 2016-05-11 上海瀚之友信息技术服务有限公司 Automatic performance test system and method
CN105718372A (en) * 2016-01-22 2016-06-29 珠海市精实测控技术有限公司 Black-box test case generation and automatic test method for electric control board
CN105808432A (en) * 2015-03-04 2016-07-27 中车株洲电力机车研究所有限公司 Software automated testing system and method for rail traffic drive control unit/ tractive control unit (DCU/TCU)
CN106133537A (en) * 2014-12-30 2016-11-16 京微雅格(北京)科技有限公司 A kind of FPGA function module emulation verification method and system thereof
CN106201891A (en) * 2016-07-19 2016-12-07 意昂神州(北京)科技有限公司 A kind of model automatization method of testing and device
CN106842988A (en) * 2017-03-02 2017-06-13 深圳市尧天科技有限公司 One kind teaching graphical programming system and method
CN109828914A (en) * 2018-12-28 2019-05-31 宁波瓜瓜农业科技有限公司 Whole process distributed system automated testing method and test macro
US10429811B2 (en) 2016-04-08 2019-10-01 Toyota Motor Engineering & Manufacturing North America, Inc. Systems and methods for testing convergence of closed-loop control systems
CN111176989A (en) * 2019-12-22 2020-05-19 同济大学 Fault injection test scenario case model and framework based on service arrangement
CN112632883A (en) * 2020-12-21 2021-04-09 南京华大九天科技有限公司 Method, device, equipment and medium for testing simulation result of device model
CN115629996A (en) * 2022-12-21 2023-01-20 深圳市微克科技有限公司 Automatic testing method for embedded software

Cited By (31)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101968770A (en) * 2010-11-01 2011-02-09 北京航空航天大学 Reusable embedded software testing and developing method and system
CN102156784A (en) * 2011-04-18 2011-08-17 烽火通信科技股份有限公司 Verifying environment patterned chip verifying method and device
CN102402484A (en) * 2011-11-30 2012-04-04 北京航空航天大学 Automatic experimental device and method for reliability growth test of embedded software
CN102402484B (en) * 2011-11-30 2014-04-02 北京航空航天大学 Automatic experimental device and method for reliability growth test of embedded software
CN102591780A (en) * 2012-01-13 2012-07-18 广州广电运通金融电子股份有限公司 Device driver software test method and test system
CN102591780B (en) * 2012-01-13 2015-04-15 广州广电运通金融电子股份有限公司 Device driver software test method and test system
CN103034227A (en) * 2012-09-20 2013-04-10 北京智行鸿远汽车技术有限公司 Testing method in circuit of battery electric vehicle vehicle-control unit model
CN102890499A (en) * 2012-09-21 2013-01-23 北京智行鸿远汽车技术有限公司 Method for loop testing of vehicle control unit software of pure electric automobile
CN102915242B (en) * 2012-09-26 2016-01-13 北京广利核系统工程有限公司 A kind of method utilizing graphical operation code to programme
CN102915242A (en) * 2012-09-26 2013-02-06 北京广利核系统工程有限公司 Method for implementing code programming by graphical operations
CN103220186A (en) * 2013-03-21 2013-07-24 大唐联仪科技有限公司 Communication equipment testing method and system
CN103257925B (en) * 2013-04-28 2016-01-20 株洲南车时代电气股份有限公司 Train operation monitoring logging software automatic testing equipment, system and method thereof
CN103257925A (en) * 2013-04-28 2013-08-21 株洲南车时代电气股份有限公司 Automatic testing device, system and method for train operation monitoring record software
CN105335177A (en) * 2014-07-23 2016-02-17 比亚迪股份有限公司 Test method, test device and test system of embedded system
CN106133537B (en) * 2014-12-30 2019-03-05 京微雅格(北京)科技有限公司 A kind of FPGA function module emulation verification method and its system
CN106133537A (en) * 2014-12-30 2016-11-16 京微雅格(北京)科技有限公司 A kind of FPGA function module emulation verification method and system thereof
CN104615541A (en) * 2015-02-10 2015-05-13 上海创景计算机系统有限公司 Simulation testing modeling system and method based on flow chart
CN104657262A (en) * 2015-02-10 2015-05-27 上海创景计算机系统有限公司 High-real-time automatic testing system and testing method
CN105808432B (en) * 2015-03-04 2019-05-10 中车株洲电力机车研究所有限公司 Rail traffic Traction Drive control unit software automated testing system and method
CN105808432A (en) * 2015-03-04 2016-07-27 中车株洲电力机车研究所有限公司 Software automated testing system and method for rail traffic drive control unit/ tractive control unit (DCU/TCU)
CN105577475A (en) * 2015-12-28 2016-05-11 上海瀚之友信息技术服务有限公司 Automatic performance test system and method
CN105577475B (en) * 2015-12-28 2019-07-05 上海瀚之友信息技术服务有限公司 Automated performance testing system and method
CN105718372B (en) * 2016-01-22 2018-05-18 珠海市精实测控技术有限公司 A kind of electric-controlled plate Black-box testing Cases generation and automatic test approach
CN105718372A (en) * 2016-01-22 2016-06-29 珠海市精实测控技术有限公司 Black-box test case generation and automatic test method for electric control board
US10429811B2 (en) 2016-04-08 2019-10-01 Toyota Motor Engineering & Manufacturing North America, Inc. Systems and methods for testing convergence of closed-loop control systems
CN106201891A (en) * 2016-07-19 2016-12-07 意昂神州(北京)科技有限公司 A kind of model automatization method of testing and device
CN106842988A (en) * 2017-03-02 2017-06-13 深圳市尧天科技有限公司 One kind teaching graphical programming system and method
CN109828914A (en) * 2018-12-28 2019-05-31 宁波瓜瓜农业科技有限公司 Whole process distributed system automated testing method and test macro
CN111176989A (en) * 2019-12-22 2020-05-19 同济大学 Fault injection test scenario case model and framework based on service arrangement
CN112632883A (en) * 2020-12-21 2021-04-09 南京华大九天科技有限公司 Method, device, equipment and medium for testing simulation result of device model
CN115629996A (en) * 2022-12-21 2023-01-20 深圳市微克科技有限公司 Automatic testing method for embedded software

Similar Documents

Publication Publication Date Title
CN101739334A (en) Automatic testing method of embedded software
CN110851356B (en) Selenium-based Web application automatic test framework and construction method and system thereof
CN101241467B (en) Automatized white box test system and method facing to WEB application
CN106446412B (en) Model-based test method for avionics system
Forster et al. Verification of business process quality constraints based on visual process patterns
CN104407971A (en) Method for automatically testing embedded software
US8930758B2 (en) Automated testing of mechatronic systems
CN102866944B (en) Pressure testing system and method
CN101571802A (en) Visualization automatic generation method of embedded software test data and system thereof
CN109933521A (en) Automated testing method, device, computer equipment and storage medium based on BDD
CN109740222A (en) A kind of test device and system for grid motor connectionization scene
CN104461854A (en) General simulation testing platform for software of ship equipment and construction method of general simulation testing platform
CN104360951A (en) Script testing method and device
CN105591779A (en) Method and device for inspecting network element
Weißleder et al. An evaluation of model-based testing in embedded applications
CN102486749A (en) Method and system for data driving test
CN103576667B (en) The method of testing of master control borad, Apparatus and system
Han et al. Automated warship software testing system based on loadrunner automation API
Tang et al. Towards adaptive framework of keyword driven automation testing
Mlynarski et al. Model-based testing: achievements and future challenges
CN112199273B (en) Virtual machine pressure/performance testing method and system
CN109144849A (en) A kind of embedded software adjusting, measuring method
CN116302901A (en) Method and device for generating universal verification methodology UVM verification platform
Na et al. Extension and application based on robot testing framework
KR20130044700A (en) Simulator system for power plant

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C02 Deemed withdrawal of patent application after publication (patent law 2001)
WD01 Invention patent application deemed withdrawn after publication

Open date: 20100616