CN105446882A - Testing method of black-box testing system for software evaluation of household and similar electric appliances - Google Patents

Testing method of black-box testing system for software evaluation of household and similar electric appliances Download PDF

Info

Publication number
CN105446882A
CN105446882A CN201510868968.0A CN201510868968A CN105446882A CN 105446882 A CN105446882 A CN 105446882A CN 201510868968 A CN201510868968 A CN 201510868968A CN 105446882 A CN105446882 A CN 105446882A
Authority
CN
China
Prior art keywords
control device
detected
input
communication
program
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.)
Granted
Application number
CN201510868968.0A
Other languages
Chinese (zh)
Other versions
CN105446882B (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.)
Hefei General Electromechanical Products Testing Institute Co Ltd
Hefei General Machinery Research Institute Co Ltd
Original Assignee
Hefei General Machinery Product Inspect Institute Co Ltd
Hefei General Machinery Research Institute 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 Hefei General Machinery Product Inspect Institute Co Ltd, Hefei General Machinery Research Institute Co Ltd filed Critical Hefei General Machinery Product Inspect Institute Co Ltd
Priority to CN201510868968.0A priority Critical patent/CN105446882B/en
Publication of CN105446882A publication Critical patent/CN105446882A/en
Application granted granted Critical
Publication of CN105446882B publication Critical patent/CN105446882B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing

Abstract

The invention relates to a testing method of a black-box testing system for software evaluation of household and similar electric appliances. The black-box testing system comprises a computer test unit, an auxiliary test unit and a detected controller unit, wherein the computer test unit is in bidirectional communication connection with the detected controller unit through an emulator; the computer test unit is in bidirectional communication connection with the auxiliary test unit; and the auxiliary test unit is in bidirectional communication connection with the detected controller unit. The testing method includes two testing methods for software implantation failures and hardware implantation failures. The testing system does not need enterprises to provide corresponding source program codes, so that the risk of software secret leakage is avoided and the security is high; and the testing system can automatically finish a testing process, and is high in testing efficiency, true and accurate in testing result and relatively high in testing universality and consistency.

Description

The method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system
Technical field
The invention belongs to computer software assessment technology field, particularly the method for testing of a kind of family expenses and similar applications electrical equipment software evaluation Black-box Testing system.
Background technology
According to existing software evaluation standard-required, current testing agency generally adopts the mode of white-box testing for fail-safe software assessment test, white-box testing is a kind of system detection method test data being incorporated into program, namely examines assembly such as register, clock, reservoir, the input and output periphery etc. of controller, detects.Current software test adopts white-box testing mode mainly to there is following shortcoming:
1, because different household appliances may adopt different controllers, identical household appliances may adopt different controller, same controller also may use different language compilation software, therefore the repeatability of software evaluation is poor, each assessment is all equivalent to customized, waste a large amount of time, man power and material, this is that enterprise and testing agency are all difficult to bear.
In addition, the controller of Some Enterprises is development & production abroad, and from evaluation process, if software security test all adopts white-box testing, often need to be arranged in external software developer and test, testing cost is very high.
Whether 2, white-box testing requires that enterprise provides core source program code and core data, testing staff could be allowed to carry out dynamic and static state checkout to source program and examine related measure software to work.And this way is owing to existing potential risk kernel software and technology may being brought to divulge a secret to enterprise, and allow enterprise worry very much and to worry, to such an extent as to be difficult between enterprise and testing agency coordinate.
3, the professional of software evaluation need of work, but software control is the behavior of microcosmic, there is diversified combination in its software logic, its program function and hardware mechanism brought close, also vary, also will consider the working condition of the assembly of controller, as whether register, clock, reservoir, input and output periphery can break down, what's wrong in meeting.Therefore be a very difficult and complicated job to the analysis of software, setting and inspection.This just needs professional system engineer, Hardware Engineer and software engineer, even if but it is professional again, for in whole test process, check by artificial mode after all, can not ensure that all software all meets the requirements of the standard, the measure method provided is all very appropriate, suitable, effective.
4, the standard that relates to of household electrical appliances software evaluation is many and complicated, comprises electrically, electronics, software, has both comprised the complete machine safety standard of household electrical appliances, and has also comprised part-subassemble standard; Should universal standard requirement, also to consider particular criteria requirement.In so many standards, the overwhelming majority only has requirement not have method, and the judgement of this test mode of using to supervisory personnel in checking process and test result causes certain difficulty.Also may cause different supervisory personnel, have different understanding, different result of determination can be caused, unnecessary trouble may be brought to enterprise.
Summary of the invention
The object of the invention is to overcome above-mentioned the deficiencies in the prior art, provide the method for testing of a kind of family expenses and similar applications electrical equipment software evaluation Black-box Testing system, the method of testing of this test macro does not need enterprise to provide corresponding source program code, stopped the risk that software is divulged a secret, security is good.
For achieving the above object, present invention employs following technical measures:
The method of testing of a kind of family expenses and similar applications electrical equipment software evaluation Black-box Testing system, Black-box Testing system comprises computer testing unit, subtest unit and detected controller unit, connected by emulator two-way communication between computer testing unit and detected controller unit, between described computer testing unit and subtest unit, two-way communication connects, and between described subtest unit and detected controller unit, two-way communication connects;
Preferably, described computer testing unit comprises following ingredient:
Test control device, for receiving the machine code program that detected controller unit runs, also for being received from the trial and error data message of input-output unit input, the described machine code program received is sent in the detected controller in detected controller unit by data and fault input device, emulator communication device, emulator by test control device successively, test control device by the trial and error data information memory that receives in data storage device; Described test control device also all forms two-way communication with subtest communication device and is connected;
Data and fault input device, receive the trial and error data message that test control device sends, and trial and error data message is sent to emulator communication device, the trial and error feedback data information simultaneously sent by emulator communication device is sent to test control device;
Data storage device, is connected with test control device two-way communication, for storing the trial and error data message and trial and error feedback data information that self-test control device sends;
Subtest communication device, is connected with the two-way communication of subtest unit, for transmission information between test control device and subtest unit;
Emulator communication device, is connected with emulator two-way communication, at data and transmission information between fault input device and emulator;
Input-output unit, for inputting trial and error data message in test control device, and receives the next trial and error feedback data information of test control device transmission.
Described subtest unit comprises following ingredient:
Subtest microprocessor, be connected with the two-way communication of described subtest communication device, for receiving the instruction and data information that test control device is sent by subtest communication device, and by the instruction and data message transport received to being detected controller unit; The hardware status information of the detected controller unit received and process data are also sent to test control device through subtest communication device by described subtest microprocessor;
Output control circuit, its input end is connected with the output terminal of described subtest microprocessor, and output terminal is connected with the input end of detected controller unit, for passing on the instruction and data information that self-test control device sends to detected controller unit;
Input capture circuit, its input end is connected with the output terminal of described detected controller unit, output terminal is connected with the input end of subtest microprocessor, for the hardware status information of the detected controller unit received and process data are sent to test control device through subtest communication device;
Communication control circuit, is connected with two-way communication between subtest microprocessor, and the signal output part of described communication control circuit connects the signal input part of detected controller unit.
Described detected controller unit comprises following ingredient:
Detected controller, is connected with emulator two-way communication, and the input end of detected controller is also connected with the output terminal of input circuit, and the detected output terminal of controller is connected with the input end of output circuit; For storing described machine code program and running according to the program of machine code program setting;
Input circuit, its input end is connected with the output terminal of described output control circuit, for receiving circuit abnormal information;
Output circuit, its output terminal is connected with the input end of described input capture circuit, for receiving and forwarding the hardware status information of the detected controller unit received.
The software implantation fault test flow process of this method of testing is as follows:
S1, utilize test control device, first download the machine code program needing test, then by machine code program successively by data and fault input device, emulator communication device, emulator transmission be stored in the detected controller in detected controller unit;
S2, input-output unit is utilized to select the software project to be detected of machine code program, then in software project to be detected, input detection method program entry address, safeguard measure program entry address, the start-stop address of software project to be detected and trial and error data message, above-mentioned input information is kept in described data storage device by test control device;
S3, run the machine code program in detected controller, test control device is successively by data and fault input device simultaneously, emulator communication device, emulator monitors and the operation of control machine coded program, when machine code program runs to the entry address of detection method program, trial and error data message in data storage device is passed through data and fault input device by test control device successively, emulator communication device, in the software project to be detected of emulator according to the detected controller of start-stop address write of described software project to be detected, test control device record is detected the operation information in the whole service process of controller before write trial and error data message and after write trial and error data message,
S4, described test control device, according to described operation information, judge whether the course of work of detected controller meets setting program;
Described operation information and judged result are derived formation test record by input-output unit by S5, described test control device.
Preferably, described detected controller unit also comprises communication controler, the signal output part of described detected controller is connected with the signal input part of described communication controler, the signal input part of described detected controller connects the signal output part of communication control circuit, and the signal output part of described communication controler connects the signal input part of communication control circuit.
Preferably, in step S3, when machine code program runs to the entrance of detection method program, the single step run of test control device control machine coded program, namely machine code program often runs a step, trial and error data message in data storage device is all detected in the software project to be detected of controller according to the start-stop address write of described software project to be detected by test control device, guarantee that the trial and error data message write can not be modified before detection method program compares judgement, until machine code program runs jump to the outlet that safeguard measure program or machine code program move to detection method program.
Further, in step S3, described machine code program circular flow, in each circular flow cycle, when machine code program runs to the entrance of detection method program, the single step run of test control device equal control machine coded program.
The hardware implantation fault test flow process of this method of testing is as follows:
S1, utilize test control device, first download the machine code program needing test, then by machine code program successively by data and fault input device, emulator communication device, emulator transmission be stored in the detected controller in detected controller unit;
S2, input-output unit is utilized to select the item of hardware to be detected of machine code program, described item of hardware to be detected at least comprises digital I/O test item, in digital I/O test item, input the passage of detection method program entry address, safeguard measure program entry address, control abnormal circuit, this input information is kept in described data storage device by test control device;
S3, run the machine code program in detected controller, test control device is successively by data and fault input device simultaneously, emulator communication device, emulator monitors and the operation of control machine coded program, when machine code program runs to the entrance of detection method program, test control device is according to the passage of the control abnormal circuit in data storage device and switching information, control command is sent to subtest microprocessor by subtest communication device, described subtest microprocessor is successively by described output control circuit, the corresponding circuit abnormality that described input circuit is opened in detected controller unit is arranged, test control device record is detected the operation information in the whole service process of controller before abnormal circuit is arranged and after abnormal circuit setting,
S4, described test control device, according to described operation information, judge whether the course of work of detected controller meets setting program;
Described operation information and judged result are derived formation test record by input-output unit by S5, described test control device.
Item of hardware to be detected in step S2 also comprises communication data test item, and the testing procedure of communication data test item is as follows:
S21, input detection method program entry address, safeguard measure program entry address, switch the passage of communicating circuit and trial and error communication data information in communication data test item, this input information is kept in described data storage device by test control device;
S22, run the machine code program in detected controller, test control device is successively by data and fault input device simultaneously, emulator communication device, emulator monitors and the operation of control machine coded program, when machine code program runs to the entrance of detection method program, test control device is according to the input information in data storage device, control command is sent to subtest microprocessor by subtest communication device, described subtest microprocessor opens the passage of the switching communicating circuit in detected controller unit by described communication control circuit, subtest microprocessor captures the communication data between detected controller in detected controller unit and communication controler by communication controller circuit, the communication data received is added described trial and error communication data information and obtains mixing trial and error data by described subtest microprocessor, described mixing trial and error data are sent to tested controller by subtest microprocessor, test control device record is detected the operation information in the whole service process of controller before abnormal circuit channel setting and after abnormal circuit channel setting,
S23, described test control device, according to described operation information, judge whether the course of work of detected controller meets setting program;
Described operation information and judged result are derived formation test record by input-output unit by S24, described test control device.
Beneficial effect of the present invention is:
1) the Black-box Testing system, in the present invention does not need enterprise to provide corresponding source program code, thoroughly solves the worry of household appliances enterprise to Software Intellectual Property Rights, is the developing direction of future secure software evaluation test yet.
2) the method for testing efficiency of the Black-box Testing system, in the present invention is high, hand inspection source program code is not needed during checkout, but automatically completed by computer testing unit and subtest unit, thus the program thread of the programming language of testing staff and source program, programming personnel, controller kind do not have direct relation, favorable repeatability, can save a large amount of time and efforts for testing agency, enterprise.
3), Security of test is good, because enterprise no longer needs the source program code providing household appliances controller, but the executable program file download after compilation of source code or burning are entered in controller, controller will be housed and be supplied to testing agency, by testing staff according to the information material provided, automatically tested by test macro.Enterprise can use and disuse the risk of divulging a secret worried because open source program code brings.
4), ease for use is good, because test macro completes the fault-injection inspection to controller automatically, supervisory personnel does not need to open source program code inspection again, to block analysis, the software inspection of controller, arrange and completed by computer system, require to reduce to the inspection workload of supervisory personnel like this, specialized to require that degree can reduce, flase drop looks into probability almost nil, the result of inspection can directly print.
5), consistance is good, because test macro is according to standard organizational system, testing staff is unified to be tested according to job instruction clause, judgement for test case and test result is then completed automatically by test macro, therefore can not understand standard different because of tester, cause the inconsistent appearance of test result.
6) method of testing, in the present invention adopts software to implant fault and fault two kinds of test modes implanted by hardware, not only can realize the full test of the item of hardware of the software project treating detection control device, and test comprehensively, test result true and accurate.
Accompanying drawing explanation
Fig. 1 is schematic diagram of the present invention;
Fig. 2 is the process flow diagram that software mode of the present invention implants fault;
Fig. 3 is the process flow diagram that hardware mode of the present invention implants the port test of fault;
Fig. 4 is the process flow diagram that hardware mode of the present invention implants the communication test of fault.
Reference numeral implication in figure is as follows:
10-computer testing unit, 11-test control device, 12-data storage device
13-data and fault input device 14-subtest communicator
15-emulator communication device, 16-input-output unit, 20-subtest unit
21-subtest microprocessor, 22-output control circuit, 23-input capture circuit
24-communication control circuit, 30-detected controller unit
31-detected controller 32-input circuit 33-output circuit
34-communication controler, 40-emulator
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, be clearly and completely described the technical scheme in the embodiment of the present invention, obviously, described embodiment is only the present invention's part embodiment, instead of whole embodiments.Based on the embodiment in the present invention, those of ordinary skill in the art, not making the every other embodiment obtained under creative work prerequisite, belong to the scope of protection of the invention.
As shown in Figure 1, the Black-box Testing system in the method for testing of a kind of family expenses and similar applications electrical equipment software evaluation Black-box Testing system comprises computer testing unit 10, subtest unit 20, detected controller unit 30 and emulator 40.
Described computer testing unit 10 comprises test control device 11, data storage device 12, data and fault input device 13, subtest communication device 14, emulator communication device 15 and input-output unit 16, described test control device 11 respectively with data and fault input device 13, subtest communication device 14, data storage device 12 is bi-directionally connected, the output terminal of described test control device 11 is connected with the printer in input-output unit 16 by communication interface, testing staff by the human-computer interaction interface input corresponding information in input-output unit 16 and can check testing result, described data and two-way communication connection between fault input device 13 and emulator communication device 15, described emulator communication device 15 is connected with emulator 40 two-way communication by communication interface, and described subtest communication device 14 is bi-directionally connected by communication interface and subtest unit 20.
Described subtest unit 20 comprises subtest microprocessor 21, output control circuit 22, input capture circuit 23 and communication control circuit 24, and described subtest microprocessor 21 is connected with the two-way communication of described subtest communication device 14; The output terminal of described subtest microprocessor 21 and the input end of output control circuit 22 be connected, the output terminal of output control circuit 22 is connected with the input end of detected controller unit 30; The input end of described input capture circuit 23 is connected with the output terminal of described detected controller unit 30, and output terminal is connected with the input end of subtest microprocessor 21; Described communication control circuit 24 is connected with the two-way communication of described subtest microprocessor 21.
Described detected controller unit 30 comprises detected controller 31, input circuit 32, output circuit 33 and communication controler 34, described detected controller 31 is connected with emulator 40 two-way communication, the input end of detected controller 31 is also connected with the output terminal of input circuit 32, and the output terminal of detected controller 31 is connected with the input end of output circuit 33; The signal output part of described detected controller 31 is connected with the signal input part of described communication controler 34, the signal input part of described detected controller 31 connects the signal output part of communication control circuit 24, and the signal output part of described communication controler 34 connects the signal input part of communication control circuit 24.
The present invention has two kinds and implants fault testing method, and wherein a kind of is software implantation fault testing method, and another kind of is that fault testing method implanted by hardware, its testing procedure is described respectively below:
1. fault testing method is implanted for software
S1, utilize input-output unit 16 and test control device 11, first download or receive the machine code program needing test, then machine code program transmitted by data and fault input device 13, emulator communication device 15, emulator 40 and is stored in the detected controller 31 in detected controller unit 30 successively;
S2, input-output unit 16 is utilized to select the software project to be detected of machine code program, then in software project to be detected, input detection method program entry address, safeguard measure program entry address, the start-stop address of software project to be detected and trial and error data message, above-mentioned input information is kept in described data storage device 12 by test control device 11;
S3, run the machine code program in detected controller 31, test control device 11 is successively by data and fault input device 13 simultaneously, emulator communication device 15, emulator 40 monitors and the operation of control machine coded program, when machine code program runs to the entrance of detection method program, trial and error data message in data storage device 12 is passed through data and fault input device 13 by test control device 11 successively, emulator communication device 15, in the software project to be detected of emulator 40 according to the detected controller 31 of start-stop address write of described software project to be detected, test control device 11 records the operation information in the whole service process of detected controller 31 before write trial and error data message and after write trial and error data message,
What illustrate is, when machine code program runs to the entrance of detection method program, the single step run of test control device 11 control machine coded program, namely machine code program often runs a step, trial and error data message in data storage device 12 is all detected in the software project to be detected of controller 31 according to the start-stop address write of described software project to be detected by test control device 11, guarantee that the trial and error data message write can not be modified before detection method program compares judgement, until machine code program runs jump to the outlet that safeguard measure program or machine code program move to detection method program.
S4, described test control device 11, according to described operation information, judge whether the course of work of detected controller 31 meets setting program;
Described operation information and judged result are derived formation test record by input-output unit 16 by S5, described test control device 11.
2. fault testing method is implanted for hardware
Item of hardware comprises PERCOM peripheral communication parts, input and output peripheral components, pick-up unit and comparer parts, conventional integrated package parts, certainly, do not have PERCOM peripheral communication parts in some tested controller unit, that just can not do the test of PERCOM peripheral communication parts test item.
2.1 for the input and output periphery in hardware, pick-up unit and comparer, custom integrated circuit parts
S1, utilize input-output unit 16 and test control device 11, first download or receive the machine code program needing test, then machine code program transmitted by data and fault input device 13, emulator communication device 15, emulator 40 and is stored in the detected controller 31 in detected controller unit 30 successively;
S2, utilize input-output unit 16 to select the input and output of detected controller 31 are peripheral, pick-up unit and comparer, test item in custom integrated circuit parts, in this test item, input the passage of detection method program entry address, safeguard measure program entry address, control abnormal circuit, this input information is kept in described data storage device 12 by test control device 11;
S3, run the machine code program in detected controller 31, test control device 11 is successively by data and fault input device 13 simultaneously, emulator communication device 15, emulator 40 monitors and the operation of control machine coded program, when machine code program runs to the entrance of detection method program, test control device 11 is according to the channel information of the control abnormal circuit in data storage device 12, control command is sent to subtest microprocessor 21 by subtest communication device 14, described subtest microprocessor 21 is successively by described output control circuit 22, the abnormal setting of related circuit in detected controller unit 30 opened by described input circuit 32, test control device 11 records the operation information in the whole service process of detected controller 31 before abnormal circuit channel setting and after abnormal circuit channel setting,
S4, described test control device 11, according to described operation information, judge whether the course of work of detected controller 31 meets setting program;
Described operation information and judged result are derived formation test record by input-output unit 16 by S5, described test control device 11.
2.2 for the PERCOM peripheral communication parts in hardware
S1, utilize input-output unit 16 and test control device 11, first download or receive the machine code program needing test, then machine code program transmitted by data and fault input device 13, emulator communication device 15, emulator 40 and is stored in the detected controller 31 in detected controller unit 30 successively;
S2, the test item utilizing input-output unit 16 to select in the PERCOM peripheral communication parts of machine code program, in this test item, input detection method program entry address, safeguard measure program entry address, the passage switching communicating circuit and trial and error communication data information, this input information is kept in described data storage device 12 by test control device 11;
S3, run the machine code program in detected controller 31, test control device 11 is successively by data and fault input device 13 simultaneously, emulator communication device 15, emulator 40 monitors and the operation of control machine coded program, when machine code program runs to the entrance of detection method program, test control device 11 is according to the input information in data storage device 12, control command is sent to subtest microprocessor 21 by subtest communication device 14, described subtest microprocessor 21 opens the passage of the switching communicating circuit in detected controller unit 30 by described communication control circuit 24, subtest microprocessor 21 captures the communication data between detected controller 31 in detected controller unit 30 and communication controler 34 by communication control circuit 24, the communication data received is added described trial and error communication data information and obtains mixing trial and error data by described subtest microprocessor 21, described mixing trial and error data are sent to tested controller 31 by subtest microprocessor 21, test control device 11 records the operation information in the whole service process of detected controller 31 before abnormal circuit channel setting and after abnormal circuit channel setting,
S4, described test control device 11, according to described operation information, judge whether the course of work of detected controller 31 meets setting program;
Described operation information and judged result are derived formation test record by input-output unit 16 by S5, described test control device 11.
As a rule, data storage device 12 in described computer testing unit 10, altogether 9 component projects of controller are detected, be respectively CPU item, interrupt processing and execution item, clock item, reservoir item, internal data paths item, PERCOM peripheral communication item, the peripheral item of I/O, pick-up unit and comparer item, conventional integrated package item, these assemblies are provided with again respectively, immutable reservoir item, variable reservoir item, E2PROM item, programmable counter item, interrupt processing and execution item, clock item, PERCOM peripheral communication data item, numeral I/O item etc., the mode that front 1-7 item in these 9 assemblies implants fault by software detects, then 2 then need the mode being implanted fault by hardware to detect.These 9 assemblies all can be checked by human-computer interaction interface, and are undertaken implanting corresponding trial and error data message or arranging wrong configuration by test control device 11.
Below by specific embodiment, the method that software implants fault and hardware implantation fault is illustrated respectively.
Fault test implanted by embodiment 1 software
The present embodiment is that example is described by the variable reservoir detection of reservoir test item variable in detection part to washing machine controller.
As shown in Figure 2,
1) the computer testing unit 10 being provided with testing software is connected to the detected controller 31 in detected controller unit 30 by emulator 40.
2) at the human-computer interaction interface of computer testing unit 10, the machine code of production is downloaded by input-output unit 16, click " downloading ", open the machine code and tested program that need to download, click " opening ", if test procedure successfully downloads in controller, system display " downloading successfully ", otherwise display " failed download ", can record download time, download file name in detection record; This process also namely test control device 11 described machine code is downloaded in controller by data and fault input device 13, emulator communication device 15, emulator 40 successively.
3) click in the check box on test item one hurdle; select " test item "; " variable reservoir " is selected in the present embodiment; click " variable reservoir "; eject " variable reservoir detection " and configure the page; according to the data of enterprise; fill in corresponding detection method program entry address, safeguard measure program entry address, the start-stop address needing the variable reservoir detected and trial and error data message; select " fault category " that variable reservoir there will be; click " preservation ", this configuration store is in data storage device 12.
4) machine code program in detected controller 31 brings into operation, according to the operation instructions of detected controller 31, opening device enters dehydration mode, detected controller 31 load exports, human-computer interaction interface display translation state, start detection program, test control device 11 is successively by data and fault input device 13, emulator communication device 15, emulator 40 monitors and the operation of control machine coded program, when machine code program runs to the entrance of detection method program, the single step run of test control device 11 control machine coded program, namely machine code program often runs a step, the trial and error data message configured in the equal called data memory storage 12 of test control device 11, deliver in data and fault input device 13, logic control and process is carried out by data and fault input device 13 pairs of trial and error data messages, and the trial and error data after process are passed to emulator communication device 15, these data transformations are emulation command by emulator communication device 15, again these emulation commands are converted into communication data, communicated with emulator 40 by USB interface, the variable reservoir district of controller is sent to by emulator 40, and the start-stop address of the variable reservoir detected as required writes variable reservoir district, after trial and error data message writes variable reservoir district, machine code program continues to run, test control device 11 monitors and the operation of control machine coded program always, until machine code program runs to the entrance that the outlet of detection method software or machine code program jump to safeguard measure software, after machine code program runs to the outlet of detection method software or the entrance of safeguard measure software, test control device 11 just discharges monitoring, and machine code program also just exits single step run state.
For the inspection measure software of cyclic check, machine code program meeting circular flow, until again enter detection method software, repeats above operation.
In above process, controller feedback information is divided into two parts, a part passes to emulator communication device 15 by emulator 40, test control device 11 is entered again through data and fault input device 13, another part passes to microprocessor 21 by input capture circuit, enter test control device 11 through subtest communication device 14 again, by test control device 11 stored in data storage device 12 with show on human-computer interaction interface, test result is printed by input-output unit 16; Described feedback information had both comprised the operation information of machine code program; also comprise detected controller 31 perform output protection action (as close all output or close dehydration electric motor export or Program reset) information, test control device 11 by above-mentioned feedback information judge the measure method of this detected controller 31 and measure program whether qualified.
5) detection progress and detection record all have corresponding display, when test is passed through, detection record has corresponding display, during test crash, detection record also has corresponding display, test by time, detected controller load output state can be closed by display device, and detection record and output state can store or print by derive test record as test record.
Fault test implanted by embodiment 2 hardware
The present embodiment is detected as example by the door switch circuit of digital I/O test item to washing machine controller in detection part and is described.
As shown in Figure 3,
1) the computer testing unit 10 being provided with testing software is connected to the detection control device 31 in detected controller unit 30 by emulator 40.
2) at the human-computer interaction interface of computer testing unit 10, the machine code of production is downloaded by input-output unit 16, click " downloading ", open the machine code and test procedure that need to download, click " opening ", if test procedure has downloaded in controller, system display " downloading successfully ", otherwise display " failed download ", can record download time, download file name in detection record; This process also namely test control device 11 described machine code is downloaded in controller by data and fault input device 13, emulator communication device 15, emulator 40 successively.
3) click in the check box on test item one hurdle; select " test item "; digital I/O is selected to detect in the present embodiment; following information is configured: check the entry address of measure software, the entry address of safeguard measure software, the passage of control abnormal circuit to needing the digital I/O test item detected; click " preservation ", this configuration information is stored in data storage device 12.
4) machine code program in detected controller 31 brings into operation, according to the operation instructions of detected controller 31, opening device runs dehydration mode, detected controller 31 load exports, display device output state, start detection program, test control device 11 is successively by data and fault input device 13, emulator communication device 15, emulator 40 monitors and the operation of control machine coded program, when machine code program runs to the entrance of detection method program, test control device 11 is according to the configuration information in human-computer interaction interface, control command is sent to subtest microprocessor 21 by subtest communication device 14, subtest microprocessor 21 is successively by output control circuit 22, input circuit 32 open circuit arranges abnormal passage, input circuit Zhong You mono-tunnel by the door switch of tested controller 31 is set to abnormal, as a road high level input signal, another road is set to low imput, during detected controller 31 rolling inspection measure software, test control device 11 monitors and the operation of control machine coded program always, until machine code program runs to the entrance that the outlet of detection method software or machine code program jump to safeguard measure software, after machine code program runs to the outlet of detection method software or the entrance of safeguard measure software, test control device 11 just discharges monitoring.
For the inspection measure software of cyclic check, machine code program meeting circular flow, until again enter detection method software, repeats above operation.
In above process, subtest microprocessor 21 catches the status information (exporting as cut out dehydration electric motor) of the output circuit of detected controller 31 in real time by input capture circuit 23, the status information captured also is passed to test control device 11 by subtest communication device 14 by subtest microprocessor 21, the detecting information of detected controller 31 is passed through emulator communication device 15 by emulator 40 simultaneously, test control device (as entering measure defence program or Program reset) is passed to again through data and fault input device 13, by test control device 11 stored in data storage device 12 with show on human-computer interaction interface, test result is printed by input-output unit 16, test control device 11 by above-mentioned status information judge the measure method of this detected controller 31 and measure program whether qualified.
5) detection progress and detection record all have corresponding display, when test is passed through, detection record has corresponding display, during test crash, detection record also has corresponding display, test by time, detected controller load output state can be closed by display device, and detection record and output state can store or print by derive test record as test record.
Fault test implanted by embodiment 3 hardware
The present embodiment is that example is described by the Data Detection project of the PERCOM peripheral communication in detection part to the communication detection of washing machine controller.
As shown in Figure 3,
1) the computer testing unit 10 being provided with testing software is connected to the detected controller 31 in detected controller unit 30 by emulator 40.
2) at the human-computer interaction interface of computer testing unit 10, the machine code of production is downloaded by input-output unit 16, click " downloading ", open the machine code and test procedure that need to download, click " opening ", if test procedure has downloaded in controller, system display " downloading successfully ", otherwise display " failed download ", can record download time, download file name in detection record; This process also namely test control device 11 described machine code is downloaded in controller by data and fault input device 13, emulator communication device 15, emulator 40 successively.
3) click in the check box on test item one hurdle; select " test item "; Data Detection in PERCOM peripheral communication is selected in the present embodiment; to the following information of Data Detection project configuration in the PERCOM peripheral communication needing to detect: check the entry address of measure software, the entry address of safeguard measure software, the passage of control abnormal circuit; click " preservation ", this configuration information is stored in data storage device 12.
4) machine code program in detected controller 31 brings into operation, according to the operation instructions of detected controller 31, opening device runs dehydration mode, detected controller 31 load exports, display device output state, meanwhile, test control device 11 is successively by data and fault input device 13, emulator communication device 15, emulator 40 monitors and the operation of control machine coded program, when machine code program runs to the entrance of detection method program, test control device 11 is according to the configuration information in human-computer interaction interface, control command is sent to subtest microprocessor 21 by subtest communication device 14, the passage switching telecommunication circuit opened by subtest microprocessor 21, real-time seizure is detected the communication data between controller 31 and communication controler 34, and the communication data captured is added the trial and error data message of human-computer interaction interface setting, then successively by subtest communication device 14, subtest microprocessor 21, communication control circuit 24 sends to detected controller 31, during detected controller 31 rolling inspection measure software, test control device 11 monitors and the operation of control machine coded program always, until machine code program runs to the entrance that the outlet of detection method software or machine code program jump to safeguard measure software, after machine code program runs to the entrance of outlet safeguard measure software of detection method software, test control device 11 just discharges monitoring.
For the inspection measure software of cyclic check, machine code program meeting circular flow, until again enter detection method software, repeats above operation.
In above process, subtest microprocessor 21 catches the status information (as dehydration electric motor stops exporting) of the output circuit of detected controller 31 in real time by input capture circuit 23, the status information captured is passed to test control device 11 by subtest communication device 14 by subtest microprocessor 21, the detecting information of detected controller 31 is passed through emulator communication device 15 by emulator 40 simultaneously, test control device (as entering measure defence program or Program reset) is passed to again through data and fault input device 13, by test control device 11 stored in data storage device 12 with show on human-computer interaction interface, test result is printed by input-output unit 16, test control device 11 by above-mentioned status information judge the measure method of this detected controller 31 and measure program whether qualified.
5) detection progress and detection record all have corresponding display, when test is passed through, detection record has corresponding display, during test crash, detection record also has corresponding display, test by time, the controller load that is captured stops exporting, and detection record and output state can store or print by derive test record as test record.

Claims (6)

1. the method for testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system, it is characterized in that: Black-box Testing system comprises computer testing unit (10), subtest unit (20) and detected controller unit (30), connected by emulator (40) two-way communication between computer testing unit (10) and detected controller unit (30), between described computer testing unit (10) and subtest unit (20), two-way communication connects, between described subtest unit (20) and detected controller unit (30), two-way communication connects,
Described computer testing unit (10) comprises following ingredient:
Test control device (11), for receiving the machine code program that detected controller unit (30) runs, also for being received from the trial and error data message that input-output unit (16) inputs, test control device (11) by the described machine code program that receives successively by data and fault input device (13), emulator communication device (15), emulator (40) is sent in the detected controller (31) in detected controller unit (30), test control device (11) by the trial and error data information memory that receives in data storage device (12), described test control device (11) also all forms two-way communication with subtest communication device (14) and is connected,
Data and fault input device (13), receive the trial and error data message that test control device (11) sends, and trial and error data message is sent to emulator communication device (15), the trial and error feedback data information that emulator communication device (15) sends is sent to test control device (11) simultaneously;
Data storage device (12), is connected with test control device (11) two-way communication, for storing the trial and error data message and trial and error feedback data information that self-test control device (11) sends;
Subtest communication device (14), is connected with subtest unit (20) two-way communication, for transmission information between test control device (11) and subtest unit (20);
Emulator communication device (15), is connected with emulator (40) two-way communication, at data and transmission information between fault input device (13) and emulator (40);
Input-output unit (16), for input trial and error data message in test control device (11), and receives the next trial and error feedback data information of test control device (11) transmission.
Described subtest unit (20) comprises following ingredient:
Subtest microprocessor (21), be connected with the two-way communication of described subtest communication device (14), for receiving the instruction and data information that test control device (11) is sent by subtest communication device (14), and by the instruction and data message transport received to being detected controller unit (30); The hardware status information of the detected controller unit (30) received and process data are also sent to test control device (11) through subtest communication device (14) by described subtest microprocessor (21);
Output control circuit (22), its input end is connected with the output terminal of described subtest microprocessor (21), output terminal is connected with the input end of detected controller unit (30), for passing on the instruction and data information that self-test control device (11) sends to detected controller unit (30);
Input capture circuit (23), its input end is connected with the output terminal of described detected controller unit (30), output terminal is connected with the input end of subtest microprocessor (21), for the hardware status information of the detected controller unit received (30) and process data are sent to test control device (11) through subtest communication device (14);
Communication control circuit (24), be connected with two-way communication between subtest microprocessor (21), the signal output part of described communication control circuit (24) connects the signal input part of detected controller unit (30).
Described detected controller unit (30) comprises following ingredient:
Detected controller (31), be connected with emulator (40) two-way communication, the input end of detected controller (31) is also connected with the output terminal of input circuit (32), and the output terminal of detected controller (31) is connected with the input end of output circuit (33); For storing described machine code program and running according to the program of machine code program setting;
Input circuit (32), its input end is connected with the output terminal of described output control circuit (22), for receiving circuit abnormal information;
Output circuit (33), its output terminal is connected with the input end of described input capture circuit (23), for receiving and forwarding the hardware status information of the detected controller unit (30) received.
The software implantation fault test flow process of this method of testing is as follows:
S1, utilize test control device (11), first download the machine code program needing test, then machine code program is transmitted by data and fault input device (13), emulator communication device (15), emulator (40) and is stored in the detected controller (31) in detected controller unit (30) successively;
S2, input-output unit (16) is utilized to select the software project to be detected of machine code program, then in software project to be detected, input detection method program entry address, safeguard measure program entry address, the start-stop address of software project to be detected and trial and error data message, above-mentioned input information is kept in described data storage device (12) by test control device (11);
S3, run the machine code program in detected controller (31), test control device (11) is successively by data and fault input device (13) simultaneously, emulator communication device (15), emulator (40) monitors and the operation of control machine coded program, when machine code program runs to the entry address of detection method program, trial and error data message in data storage device (12) is passed through data and fault input device (13) by test control device (11) successively, emulator communication device (15), in the software project to be detected of emulator (40) according to the detected controller (31) of start-stop address write of described software project to be detected, operation information in the whole service process of the detected controller (31) of test control device (11) record before write trial and error data message and after write trial and error data message,
S4, described test control device (11), according to described operation information, judge whether the course of work of detected controller (31) meets setting program;
Described operation information and judged result are derived formation test record by input-output unit (16) by S5, described test control device (11).
2. the method for testing of family expenses as claimed in claim 1 and similar applications electrical equipment software evaluation Black-box Testing system, it is characterized in that: described detected controller unit (30) also comprises communication controler (34), the signal output part of described detected controller (31) is connected with the signal input part of described communication controler (34), the signal input part of described detected controller (31) connects the signal output part of communication control circuit (24), the signal output part of described communication controler (34) connects the signal input part of communication control circuit (24).
3. the method for testing of family expenses as claimed in claim 1 and similar applications electrical equipment software evaluation Black-box Testing system, it is characterized in that: in step S3, when machine code program runs to the entrance of detection method program, the single step run of test control device (11) control machine coded program, namely machine code program often runs a step, trial and error data message in data storage device (12) is all detected in the software project to be detected of controller (31) according to the start-stop address write of described software project to be detected by test control device (11), guarantee that the trial and error data message write can not be modified before detection method program compares judgement, until machine code program runs jump to the outlet that safeguard measure program or machine code program move to detection method program.
4. the method for testing of family expenses as claimed in claim 3 and similar applications electrical equipment software evaluation Black-box Testing system, it is characterized in that: in step S3, described machine code program circular flow, in each circular flow cycle, when machine code program runs to the entrance of detection method program, test control device (11) all control machine coded program single step runs.
5. the method for testing of family expenses as claimed in claim 1 or 2 and similar applications electrical equipment software evaluation Black-box Testing system, is characterized in that fault test flow process implanted by the hardware of this method of testing as follows:
S1, utilize test control device (11), first download the machine code program needing test, then machine code program is transmitted by data and fault input device (13), emulator communication device (15), emulator (40) and is stored in the detected controller (31) in detected controller unit (30) successively;
S2, input-output unit (16) is utilized to select the item of hardware to be detected of machine code program, described item of hardware to be detected at least comprises digital I/O test item, in digital I/O test item, input the passage of detection method program entry address, safeguard measure program entry address, control abnormal circuit, this input information is kept in described data storage device (12) by test control device (11);
S3, run the machine code program in detected controller (31), test control device (11) is successively by data and fault input device (13) simultaneously, emulator communication device (15), emulator (40) monitors and the operation of control machine coded program, when machine code program runs to the entrance of detection method program, test control device (11) is according to the passage of the control abnormal circuit in data storage device (12) and switching information, control command is sent to subtest microprocessor (21) by subtest communication device (14), described subtest microprocessor (21) is successively by described output control circuit (22), the corresponding circuit abnormality that described input circuit (32) is opened in detected controller unit (30) is arranged, operation information in the whole service process of the detected controller (31) of test control device (11) record before abnormal circuit is arranged and after abnormal circuit setting,
S4, described test control device (11), according to described operation information, judge whether the course of work of detected controller (31) meets setting program;
Described operation information and judged result are derived formation test record by input-output unit (16) by S5, described test control device (11).
6. the method for testing of family expenses as claimed in claim 5 and similar applications electrical equipment software evaluation Black-box Testing system, is characterized in that: the item of hardware to be detected in step S2 also comprises communication data test item, and the testing procedure of communication data test item is as follows:
S21, input detection method program entry address, safeguard measure program entry address, switch the passage of communicating circuit and trial and error communication data information in communication data test item, this input information is kept in described data storage device (12) by test control device (11);
S22, run the machine code program in detected controller (31), test control device (11) is successively by data and fault input device (13) simultaneously, emulator communication device (15), emulator (40) monitors and the operation of control machine coded program, when machine code program runs to the entrance of detection method program, test control device (11) is according to the input information in data storage device (12), control command is sent to subtest microprocessor (21) by subtest communication device (14), described subtest microprocessor (21) opens the passage of the switching communicating circuit in detected controller unit (30) by described communication control circuit (24), subtest microprocessor (21) captures the communication data between detected controller (31) in detected controller unit (30) and communication controler (34) by communication controller circuit (24), the communication data received is added described trial and error communication data information and obtains mixing trial and error data by described subtest microprocessor (21), described mixing trial and error data are sent to tested controller (31) by subtest microprocessor (21), operation information in the whole service process of the detected controller (31) of test control device (11) record before abnormal circuit channel setting and after abnormal circuit channel setting,
S23, described test control device (11), according to described operation information, judge whether the course of work of detected controller (31) meets setting program;
Described operation information and judged result are derived formation test record by input-output unit (16) by S24, described test control device (11).
CN201510868968.0A 2015-11-27 2015-11-27 The method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system Active CN105446882B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510868968.0A CN105446882B (en) 2015-11-27 2015-11-27 The method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510868968.0A CN105446882B (en) 2015-11-27 2015-11-27 The method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system

Publications (2)

Publication Number Publication Date
CN105446882A true CN105446882A (en) 2016-03-30
CN105446882B CN105446882B (en) 2017-11-07

Family

ID=55557111

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510868968.0A Active CN105446882B (en) 2015-11-27 2015-11-27 The method of testing of family expenses and similar applications electrical equipment software evaluation Black-box Testing system

Country Status (1)

Country Link
CN (1) CN105446882B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110674028A (en) * 2019-08-20 2020-01-10 华为技术有限公司 Fault injection method and device and business service system thereof
CN110826292A (en) * 2019-11-08 2020-02-21 航天柏克(广东)科技有限公司 Digital control visual graphical auxiliary analysis method

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6571389B1 (en) * 1999-04-27 2003-05-27 International Business Machines Corporation System and method for improving the manageability and usability of a Java environment
CN102629229A (en) * 2012-03-02 2012-08-08 南京大学 Co-diversified random testing (CAT) method

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6571389B1 (en) * 1999-04-27 2003-05-27 International Business Machines Corporation System and method for improving the manageability and usability of a Java environment
CN102629229A (en) * 2012-03-02 2012-08-08 南京大学 Co-diversified random testing (CAT) method

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
ANDREA CALVAGNA 等: "Automated Conformance Testing of Java Virtual Machines", 《2013 SEVENTH INTERNATIONAL CONFERENCE ON COMPLEX,INTELLIGENT,AND SOFTWARE INTENSIVE SYSTEMS》 *
万年红 等: "软件黑河测试的方法与实践", 《计算机工程》 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110674028A (en) * 2019-08-20 2020-01-10 华为技术有限公司 Fault injection method and device and business service system thereof
CN110826292A (en) * 2019-11-08 2020-02-21 航天柏克(广东)科技有限公司 Digital control visual graphical auxiliary analysis method

Also Published As

Publication number Publication date
CN105446882B (en) 2017-11-07

Similar Documents

Publication Publication Date Title
CN109840207B (en) AutoSAR-based network management automation test system and test method
CN104281520B (en) Tracking and method, the apparatus and system of debugging
Kormann et al. Automated test case generation approach for PLC control software exception handling using fault injection
CN101286129A (en) Embedded systems debugging
CN101158847B (en) Electric power substation software emulation platform building method and no power off upgrading improved method
CN109062152A (en) A kind of Loacl variable on-line monitoring method that logic-based configuration generates
CN104216746B (en) Monitor in real time and method of calibration of a kind of on-board equipment DSP programs ground in line writing
CN106980576B (en) A kind of built-in system software debugging system based on run time verification technology
CN105223897A (en) A kind of rolling stock electrical control cabinet proving installation and method of testing
CN110764036B (en) Intelligent distribution transformer terminal test method and system
CN105446882A (en) Testing method of black-box testing system for software evaluation of household and similar electric appliances
CN102063367B (en) Off-line analysis method and device aiming at computer crash program
CN202693709U (en) Test tool and test system of electric equipment
CN205139905U (en) Domestic and similar usage electrical apparatus software aassessment black box test system
CN105468526A (en) Black box test system for software evaluation of household and similar appliances
CN105179156A (en) Offline control program testing system and method of pump storage group
CN102306109B (en) Method for realizing logic programming in communication management machine
Jamro et al. Communication performance tests in distributed control systems
Sun et al. A model-based testing process for enhancing structural coverage in functional testing
CN112732552A (en) Automatic detection system and method for platform area intelligent terminal application APP
CN113495545A (en) System and method for testing vehicle equipment controller using in-loop hardware
Santoso et al. Real-time software testing for microprocessor-based protective relays
CN114415622B (en) Control system user program logic online verification method and system
US20240037016A1 (en) Computer readable storage medium, debugging support device, debugging support method, and machine learning device
KR100206992B1 (en) The method of plc diagnosis

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
CP01 Change in the name or title of a patent holder
CP01 Change in the name or title of a patent holder

Address after: 230031 No. 888 Changjiang West Road, Shushan District, Anhui, Hefei

Patentee after: HEFEI GENERAL MACHINERY RESEARCH INSTITUTE Co.,Ltd.

Patentee after: Hefei General Electromechanical Products Testing Institute Co., Ltd

Address before: 230031 No. 888 Changjiang West Road, Shushan District, Anhui, Hefei

Patentee before: HEFEI GENERAL MACHINERY Research Institute

Patentee before: Hefei General Electromechanical Products Testing Institute Co., Ltd