CN109617757B - Test method, device and system of tested system - Google Patents
Test method, device and system of tested system Download PDFInfo
- Publication number
- CN109617757B CN109617757B CN201811417500.XA CN201811417500A CN109617757B CN 109617757 B CN109617757 B CN 109617757B CN 201811417500 A CN201811417500 A CN 201811417500A CN 109617757 B CN109617757 B CN 109617757B
- Authority
- CN
- China
- Prior art keywords
- test
- parameters
- tested
- data frames
- original data
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000010998 test method Methods 0.000 title claims abstract description 5
- 238000012360 testing method Methods 0.000 claims abstract description 275
- 238000000034 method Methods 0.000 claims description 38
- 230000005540 biological transmission Effects 0.000 claims description 7
- 238000003780 insertion Methods 0.000 claims description 5
- 230000037431 insertion Effects 0.000 claims description 5
- 230000001105 regulatory effect Effects 0.000 claims description 5
- 238000004891 communication Methods 0.000 claims description 3
- 230000003247 decreasing effect Effects 0.000 claims description 3
- 239000013307 optical fiber Substances 0.000 claims description 3
- 238000012545 processing Methods 0.000 abstract description 9
- 230000006870 function Effects 0.000 description 5
- 238000011056 performance test Methods 0.000 description 4
- 230000009286 beneficial effect Effects 0.000 description 3
- 238000010586 diagram Methods 0.000 description 3
- 238000011990 functional testing Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000000750 progressive effect Effects 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/08—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
- H04L43/0805—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability
- H04L43/0817—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability by checking functioning
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L1/00—Arrangements for detecting or preventing errors in the information received
- H04L1/0078—Avoidance of errors by organising the transmitted data in a format specifically designed to deal with errors, e.g. location
- H04L1/0083—Formatting with frames or packets; Protocol or part of protocol for error control
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/08—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
- H04L43/0823—Errors, e.g. transmission errors
- H04L43/0829—Packet loss
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/08—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
- H04L43/0823—Errors, e.g. transmission errors
- H04L43/0847—Transmission error
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/16—Threshold monitoring
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Environmental & Geological Engineering (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
The invention provides a test method, a test device and a test system, wherein the test method is applied to a programmable device and used for receiving test parameters for executing test operation on a tested system; wherein the test parameters comprise basic parameters and control parameters; constructing an original data frame by using the basic parameters, and determining a regulation attribute by using the control parameters; sending original data frames to a tested system in batch based on the regulation and control attribute, and receiving feedback data frames forwarded by the tested system in batch; and comprehensively analyzing the original data frames and the batch feedback data frames to obtain a comprehensive test result. The invention is applied to hardware, and compared with the upper computer software in the prior art, the hardware can greatly improve the processing rate, thereby improving the efficiency of constructing the original data frame and the efficiency of analyzing the comprehensive test result.
Description
Technical Field
The invention relates to the technical field of automatic testing, in particular to a testing method, a testing device and a testing system.
Background
At present, for the test of a system to be tested, an original data frame is generally constructed by upper computer software and is sent to the system to be tested, the system to be tested receives the original data frame and then forwards the original data frame to the upper computer software so that the upper computer software receives a feedback data frame, and the upper computer software analyzes the original data frame and the feedback data frame to obtain a test result.
However, the method is limited by the processing speed of the upper computer software, and cannot perform functional test and performance test on the system to be tested under large data volume and designated control parameters, and the testing efficiency is low because manual intervention of a user is required in the testing process.
Disclosure of Invention
In view of this, the present invention provides a testing method, apparatus and system, which can automatically perform function testing and performance testing on a system under test under large data volume and designated control parameters, thereby improving the testing range and testing efficiency of the system under test.
In order to achieve the above object, the following technical features are provided:
a testing method applied to a programmable device, the method comprising:
receiving test parameters for executing test operation on a tested system; wherein the test parameters comprise basic parameters and control parameters;
constructing an original data frame by using the basic parameters, and determining a regulation attribute by using the control parameters;
sending the original data frames to the tested system in batch based on the regulation and control attribute, and receiving feedback data frames forwarded by the tested system in batch;
and comprehensively analyzing the original data frames and the batch feedback data frames to obtain a comprehensive test result.
Optionally, if the basic parameters include a test mode and a message length, the constructing the original data frame using the basic parameters includes:
under the condition that the test mode is a fixed data mode, generating an original data frame corresponding to the message length according to the fixed data mode;
under the condition that the test mode is an accumulated data mode, generating an original data frame corresponding to the message length according to the accumulated data mode;
and under the condition that the test mode is a pseudo-random data mode, generating an original data frame corresponding to the message length according to the pseudo-random data mode.
Optionally, the control parameter includes a preset rate and a frame interval duration determined by using a preset bandwidth; then said determining a regulatory attribute using said control parameter comprises:
determining the preset rate as a sending rate for sending the original data frame to a tested system;
and determining the quotient of the frame interval duration and the unit duration of the idle data frames as the insertion quantity of the idle data frames required to be inserted between two adjacent original data frames.
Optionally, the sending the raw data frames to the system under test in batch based on the regulation and control attribute and receiving the feedback data frames forwarded by the system under test in batch includes:
sending the original data frame to the tested system according to the sending rate, and sending the inserted number of idle data frames to the tested system;
judging whether a test stopping condition is reached;
if the test stopping condition is not met, executing the step of sending the original data frame to the tested system according to the sending rate and sending the inserted number of idle data frames to the tested system;
if the test stopping condition is met, stopping sending the original data frame to the tested system;
and receiving the feedback data frame forwarded by the tested system in the process of sending the original data frame and the idle data frame to obtain the batch feedback data frame.
Optionally, the test parameters further include stop condition parameters, and the stop condition parameters include a stop parameter and a stop parameter threshold;
updating the value of the stopping parameter before judging whether the test stopping condition is reached;
the determining whether the test stop condition is reached includes:
judging whether the numerical value of the stopping parameter reaches the stopping parameter threshold value;
if so, determining that the test stopping condition is reached;
if not, determining that the test stopping condition is not reached.
Optionally, the stop parameter includes a test time or a test duration;
under the condition that the stopping parameter is the number of times of testing, updating the value of the stopping parameter comprises increasing the value of the number of times of testing or decreasing the value of the number of times of testing;
and under the condition that the stopping parameter is the testing time length, updating the numerical value of the stopping parameter comprises updating the numerical value of the testing time length.
Optionally, the comprehensively analyzing the original data frame and the batch feedback data frame to obtain a comprehensive test result includes:
counting the sending number of the original data frames and the feedback number of the batch feedback data frames;
comparing the batch feedback data frames with original data frames one by one to determine the error number of error data frames in the batch feedback data frames;
and comprehensively analyzing the sending quantity, the feedback quantity and the error quantity to obtain a comprehensive test result.
A test apparatus integrated with a programmable device, the test apparatus comprising:
the receiving module is used for receiving test parameters for executing test operation on the tested system; wherein the test parameters comprise basic parameters and control parameters;
the configuration module is used for constructing an original data frame by using the basic parameters and determining a regulation and control attribute by using the control parameters;
the sending module is used for sending the original data frames to the tested system in batches based on the regulation and control attribute;
the receiving module is used for receiving the feedback data frames forwarded in batches by the system to be tested;
and the analysis module is used for comprehensively analyzing the original data frames and the batch feedback data frames to obtain a comprehensive test result.
A test system, comprising:
the upper computer is used for issuing test parameters for executing test operation on the tested system;
the programmable device is used for receiving test parameters for executing test operation on the tested system; wherein the test parameters comprise basic parameters and control parameters; constructing an original data frame by using the basic parameters, and determining a regulation attribute by using the control parameters; sending the original data frames to the tested system in batch based on the regulation and control attribute, and receiving feedback data frames forwarded by the tested system in batch until a test stopping condition is reached; comprehensively analyzing the original data frames and the batch feedback data frames to obtain comprehensive test results;
and the tested system is used for receiving the original data frame and forwarding the original data frame to the programmable device.
Optionally, the programmable device includes an FPGA;
the upper computer and the FPGA are communicated by adopting high-speed serial point-to-point double-channel high-bandwidth transmission PCIE;
and under the condition that the tested system is used for realizing an FC-AE bus, the FPGA and the tested system adopt an FC-AE protocol to carry out optical fiber communication.
Through the technical means, the following beneficial effects can be realized:
the invention provides a testing method applied to a programmable device, namely the testing method is applied to hardware, and compared with the software of an upper computer in the prior art, the hardware can greatly improve the processing speed, so that the efficiency of constructing an original data frame and the efficiency of analyzing a comprehensive test result are improved.
The programmable device can determine the regulation and control attribute for calling the test scene based on the control parameter, and the programmable device has higher processing rate and can meet the requirements of function test and performance test of the tested system under test scenes such as large data volume, high bandwidth approaching speed limit and the like because the control parameter can be determined according to the test scene by a user.
Moreover, after the programmable device receives the test parameters, the programmable device can automatically execute the test process and obtain a comprehensive test result, and the whole process does not need the participation of a user except for determining the test parameters of the test scene, so that the automatic test process is realized, and the test efficiency is improved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a schematic structural diagram of a first embodiment of a test system according to the present invention;
FIG. 2 is a flowchart of a first embodiment of a testing method according to the present invention;
FIG. 3 is a schematic structural diagram of a second embodiment of a test system according to the disclosure of the present invention;
fig. 4 is a schematic structural diagram of a testing apparatus according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The present invention provides a first embodiment of a test system, referring to fig. 1, the test system includes:
an upper computer 100;
a programmable device 200 connected to the upper computer 100; the Programmable device includes a DSP (Digital Signal processing) chip, an FPGA (Field-Programmable Gate Array) chip, and the like, and preferably, an FPGA chip may be used.
A system under test 300 connected to the programmable device 200.
The present invention provides a first embodiment of a testing method, which is applied to the testing system shown in fig. 1. Referring to fig. 2, the following steps are included:
step S201: the upper computer generates test parameters for executing test operation on the tested system.
The upper computer can provide an interface for filling in test parameters so that a user can input the test parameters based on a scene to be tested, and after the user inputs the test parameters, the upper computer uses specific data values of the test parameters input by the user for testing the tested system.
Step S202: the programmable device receives test parameters for performing a test operation on a system under test.
The programmable device may store the test parameters, for example in a RAM (Random access Memory), for subsequent use. The test parameters may include three types of parameters: basic parameters, control parameters and stop condition parameters.
The basic parameters are used for constructing an original data frame, and may include a test pattern and a message length. The process of using the basic parameters is detailed in step S203.
The control parameter is used for determining a control attribute of a control scene, and may include a preset rate and a frame interval duration between two adjacent original data frames calculated by using a preset bandwidth. The process of using the control parameters is detailed in step S203. The stop condition parameters are used for setting stop conditions of the test, and may include a stop parameter and a stop parameter threshold, and the using process of the stop condition parameters is detailed in step S205.
Step S203: the programmable device constructs an original data frame by using the basic parameters, and determines a regulation attribute by using the control parameters.
The basic parameters can comprise a test mode and a message length, and the test mode can comprise a fixed data mode, an accumulated data mode and a pseudo-random data mode; then, the programmable device constructs the original data frame by using the basic parameters, which may include three cases:
in the first case: and under the condition that the test mode is a fixed data mode, generating an original data frame corresponding to the message length according to the fixed data mode.
In the second case: and under the condition that the test mode is an accumulated data mode, generating an original data frame corresponding to the message length according to the accumulated data mode.
In the third case: and under the condition that the test mode is a pseudo-random data mode, generating an original data frame corresponding to the message length according to the pseudo-random data mode.
The control parameters may include a preset rate and a frame interval duration determined using a preset bandwidth.
In the process that the programmable device sends a plurality of original data frames to a tested system, the shorter the frame interval duration of two adjacent original data frames is, the smaller the bandwidth is, and the longer the frame interval duration of two adjacent original data frames is, the larger the bandwidth is.
The idle data frame is a special character, and if the idle data frame is received by the system under test, the idle data frame is considered to be in an idle state. Taking FC-AE bus protocol as an example, the length of an idle data frame (also called an idle primitive) is 1 fixed byte, and according to the specification of 8B10B encoding of FC-AE, one byte, namely 8 bits, is converted into 10 bits on the network line.
The more idle data frames are inserted between two adjacent original data frames, the lower the occupancy rate of the original data frames representing the network line, that is, the lower the data bandwidth. Therefore, the frame interval duration of the idle data frame can be calculated after the transmission bandwidth between the programmable device and the tested system is determined.
The programmable device utilizes the control parameters to determine regulatory attributes, including:
determining the preset rate as a sending rate for sending the original data frame to a tested system;
and determining the quotient of the frame interval duration and the unit duration of the idle data frame as the insertion quantity of the idle data frame.
Assuming that the duration of the next transmission period of a certain transmission bandwidth is t1, the duration occupied by the original data frame is t2, then t1-t2 is the duration of the idle data frame to be inserted, the duration occupied by each idle data frame is t3, and then the number of the idle data frames inserted between two adjacent original data frames is (t1-t2)/t 3.
The programmable device sends the original data frames to the system to be tested in batch based on the regulation and control attribute, and receives feedback data frames forwarded by the system to be tested in batch, which is described in the following steps S204 to S207.
Step S204: the programmable device sends the original data frame to the tested system according to the sending rate and sends the inserted idle data frames to the tested system;
step S205: the programmable device updates the stop parameter.
The present embodiment provides two implementation manners of the stop parameter:
the first implementation mode comprises the following steps: the stop parameter is the test frequency, and the corresponding stop parameter threshold is the preset frequency.
The initial value of the test times can be zero, and the test times are increased by one every time the original data frame is sent to the tested system so as to record the sending times of the original data frame; the test is stopped when the number of transmissions increases to a preset number.
Or, the initial value of the test times is a preset number, and the test times are reduced by one every time the original data frame is sent to the tested system so as to record the sending times of the original data frame; and stopping the test when the reduction of the sending times reaches zero.
The second implementation mode comprises the following steps: the test parameter is the test time, and the corresponding stop parameter threshold is the preset duration.
The initial value of the test time is zero, and the test duration is recorded in the process of sending the original data frame; the test is stopped when the test time reaches a preset time.
Or the initial value of the test time is zero, the test duration is recorded in a countdown mode in the process of sending the original data frame, and the test is stopped when the test duration reaches zero.
Step S206: the programmable device sends the inserted number of idle data frames;
the programmable device may send idle data frames one by one until the number of idle data frames sent reaches the insertion number.
Step S207: the programmable device judges whether a test stop condition is reached; if so, the process proceeds to step S208, otherwise, the process proceeds to step S204.
The stopping condition parameters include stopping parameters and stopping parameter threshold values, and the judging whether the test stopping condition is reached includes:
judging whether the numerical value of the stopping parameter reaches the stopping parameter threshold value; if so, determining that a test stopping condition is reached; if not, determining that the test stopping condition is not reached.
And if the test stopping condition is not met, the step S204 is entered to continuously send the original data frame to the tested system according to the sending rate and send the inserted number of idle data frames to the tested system. And if the test stopping condition is met, stopping sending the original data frame to the tested system.
Step S208: and receiving the feedback data frame forwarded by the tested system in the process of sending the original data frame and the idle data frame to obtain the batch feedback data frame.
The process of sending the original data frame and the idle data frame by the programmable device and the process of forwarding the feedback data frame to the tested system after the tested system receives the original data frame are executed in parallel.
Therefore, one or more feedback data frames fed back by the system under test are obtained in the process of sending the original data frame and the idle data frame. All feedback data frames sent by the system under test to the system under test are called batch feedback data frames.
The programmable device comprehensively analyzes the original data frame and the batch feedback data frame to obtain a comprehensive test result, and the steps S209 to S211 can be included.
Step S209: and the programmable device counts the sending number of the original data frames and the feedback number of the batch feedback data frames.
The sending times, that is, the sending number, of the original data frames are counted, the receiving times, that is, the feedback number, of the received feedback data frames, that is, the batch feedback data frames are counted, and theoretically, the sending number and the feedback number should be equal.
In some cases, a packet loss occurs, that is, a feedback data frame sent by the system under test cannot reach the programmable device, so that the feedback number is less than or equal to the sending number.
Step S210: and the programmable device compares the batch feedback data frames with the original data frames one by one to determine the error number of the error data frames in the batch feedback data frames.
Since the original data frames sent by this embodiment are all consistent, and errors may occur in the received feedback data frames due to various situations, each feedback data frame is compared with the original data frame according to data bits, and if an error occurs in one data bit, it indicates that the feedback data frame is erroneous.
The programmable device can also count the number of error data frames in the batch feedback data frames, namely the number of errors.
Step S211: and comprehensively analyzing the sending quantity, the feedback quantity and the error quantity by the programmable device to obtain a comprehensive test result.
And the programmable device calculates the quotient of the feedback quantity and the sending quantity, and determines the quotient as the arrival rate.
And determining the difference value of the 1-arrival rate as the packet loss rate.
And determining the quotient of the error quantity and the feedback quantity as the error rate.
The comprehensive test result may include one or more of an arrival rate, a packet loss rate, and a bit error rate, and of course, the test result of the system under test may be determined from other aspects.
Step S212: and the programmable device sends the comprehensive test result to the upper computer.
Step S213: and the upper computer receives and displays the comprehensive test result.
Through the technical means, the following beneficial effects can be realized:
the invention provides a testing method applied to a programmable device, namely the testing method is applied to hardware, and compared with the software of an upper computer in the prior art, the hardware can greatly improve the processing speed, so that the efficiency of constructing an original data frame and the efficiency of analyzing a comprehensive test result are improved.
The programmable device can determine the regulation and control attribute for calling the test scene based on the control parameter, and the programmable device has higher processing rate and can meet the requirements of function test and performance test of the tested system under test scenes such as large data volume, high bandwidth approaching speed limit and the like because the control parameter can be determined according to the test scene by a user.
Moreover, after the programmable device receives the test parameters, the programmable device can automatically execute the test process and obtain a comprehensive test result, and the whole process does not need the participation of a user except for determining the test parameters of the test scene, so that the automatic test process is realized, and the test efficiency is improved.
According to one embodiment provided by the present invention, testing of an FC-AE bus is proposed. Referring to fig. 3, the second embodiment of the testing system according to the present invention is provided, and referring to fig. 3, the testing system includes:
an upper computer 100;
a programmable device 200 connected to the upper computer 100; the programmable device comprises a DSP, an FPGA and other devices, and preferably, the FPGA can be adopted.
The tested system 300 connected with the programmable device 200 adopts FC-AE bus protocol.
Wherein the programmable device comprises an FPGA;
the upper computer and the FPGA are communicated by adopting high-speed serial point-to-point double-channel high-bandwidth transmission PCIE;
under the condition that the tested system is used for realizing the FC-AE bus, the process of testing the FC-AE bus by adopting the FC-AE protocol to carry out optical fiber communication between the FPGA and the tested system is similar to the process of the testing method shown in the figure 2, and is not repeated herein.
The invention provides a testing device, which is integrated in a programmable device, and the testing device shown in figure 4 comprises:
a receiving module 41, configured to receive test parameters for performing a test operation on a system under test; wherein the test parameters comprise basic parameters and control parameters;
a configuration module 42, configured to construct an original data frame using the basic parameters, and determine a regulation attribute using the control parameters;
a sending module 43, configured to send the raw data frames to the system under test in batch based on the regulation and control attribute;
a receiving module 44, configured to receive feedback data frames forwarded in batch by the system under test;
and the analysis module 45 is used for comprehensively analyzing the original data frames and the batch feedback data frames to obtain a comprehensive test result.
Wherein, the basic parameters include a test mode and a message length, and then the constructing of the original data frame by using the basic parameters includes:
under the condition that the test mode is a fixed data mode, generating an original data frame corresponding to the message length according to the fixed data mode;
under the condition that the test mode is an accumulated data mode, generating an original data frame corresponding to the message length according to the accumulated data mode;
and under the condition that the test mode is a pseudo-random data mode, generating an original data frame corresponding to the message length according to the pseudo-random data mode.
The control parameters comprise a preset rate and a frame interval duration determined by utilizing a preset bandwidth; then said determining a regulatory attribute using said control parameter comprises:
determining the preset rate as a sending rate for sending the original data frame to a tested system;
and determining the quotient of the frame interval duration and the unit duration of the idle data frames as the insertion quantity of the idle data frames required to be inserted between two adjacent original data frames.
The sending module 43 sends the raw data frames to the system under test in batch based on the regulation and control attribute, which may include: sending the original data frame to the tested system according to the sending rate, and sending the inserted number of idle data frames to the tested system; judging whether a test stopping condition is reached; if the test stopping condition is not met, executing the step of sending the original data frame to the tested system according to the sending rate and sending the inserted number of idle data frames to the tested system; and if the test stopping condition is met, stopping sending the original data frame to the tested system.
The receiving module 44 is configured to receive a feedback data frame forwarded by the system under test in batch, and specifically, is configured to receive the feedback data frame forwarded by the system under test in the process of sending the original data frame and the idle data frame, so as to obtain the batch feedback data frame.
Optionally, the test parameters further include stop condition parameters, and the stop condition parameters include a stop parameter and a stop parameter threshold;
updating the value of the stopping parameter before judging whether the test stopping condition is reached;
the determining whether the test stop condition is reached includes:
judging whether the numerical value of the stopping parameter reaches the stopping parameter threshold value;
if so, determining that the test stopping condition is reached;
if not, determining that the test stopping condition is not reached.
Wherein the stopping parameter comprises the number of tests or the test duration;
under the condition that the stopping parameter is the number of times of testing, updating the value of the stopping parameter comprises increasing the value of the number of times of testing or decreasing the value of the number of times of testing;
and under the condition that the stopping parameter is the testing time length, updating the numerical value of the stopping parameter comprises updating the numerical value of the testing time length.
The analysis module 45 is configured to comprehensively analyze the raw data frames and the batch feedback data frames to obtain a comprehensive test result, and may include:
counting the sending number of the original data frames and the feedback number of the batch feedback data frames;
comparing the batch feedback data frames with original data frames one by one to determine the error number of error data frames in the batch feedback data frames;
and comprehensively analyzing the sending quantity, the feedback quantity and the error quantity to obtain a comprehensive test result.
Through the technical means, the following beneficial effects can be realized:
the invention provides a testing method applied to a programmable device, namely the testing method is applied to hardware, and compared with the software of an upper computer in the prior art, the hardware can greatly improve the processing speed, so that the efficiency of constructing an original data frame and the efficiency of analyzing a comprehensive test result are improved.
The programmable device can determine the regulation and control attribute for calling the test scene based on the control parameter, and the programmable device has higher processing rate and can meet the requirements of function test and performance test of the tested system under test scenes such as large data volume, high bandwidth approaching speed limit and the like because the control parameter can be determined according to the test scene by a user.
Moreover, after the programmable device receives the test parameters, the programmable device can automatically execute the test process and obtain a comprehensive test result, and the whole process does not need the participation of a user except for determining the test parameters of the test scene, so that the automatic test process is realized, and the test efficiency is improved.
Referring to fig. 1, the present invention also provides a test system, including:
the upper computer 100 is used for issuing test parameters for executing test operation on the tested system;
the programmable device 200 is used for receiving test parameters for executing test operation on a system under test; wherein the test parameters comprise basic parameters and control parameters; constructing an original data frame by using the basic parameters, and determining a regulation attribute by using the control parameters; sending the original data frames to the tested system in batch based on the regulation and control attribute, and receiving feedback data frames forwarded by the tested system in batch until a test stopping condition is reached; comprehensively analyzing the original data frames and the batch feedback data frames to obtain comprehensive test results;
and the system under test 300 is configured to receive the original data frame and forward the original data frame to the programmable device.
For a specific implementation of the test system, reference may be made to the embodiment shown in fig. 2, which is not described herein again.
The functions described in the method of the present embodiment, if implemented in the form of software functional units and sold or used as independent products, may be stored in a storage medium readable by a computing device. Based on such understanding, part of the contribution of the embodiments of the present invention to the prior art or part of the technical solution may be embodied in the form of a software product stored in a storage medium and including instructions for causing a computing device (which may be a personal computer, a server, a mobile computing device, a network device, or the like) to execute all or part of the steps of the method described in the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
The embodiments are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same or similar parts among the embodiments are referred to each other.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims (10)
1. A method of testing, the method comprising:
the upper computer generates test parameters for executing test operation on the tested system, wherein the upper computer provides an interface for filling the test parameters so that a user can input the test parameters based on a scene to be tested;
the programmable device receives test parameters which are sent by an upper computer, execute test operation on a tested system and correspond to a scene to be tested; wherein the test parameters include basic parameters, control parameters, and stop condition parameters;
the programmable device utilizes the basic parameters to construct an original data frame, and utilizes the control parameters to determine the regulation and control attributes, and the stop condition parameters are used for setting the stop conditions of the test;
the programmable device sends the original data frames to the system to be tested in batches based on the regulation and control attribute and receives feedback data frames forwarded by the system to be tested in batches;
and the programmable device comprehensively analyzes the original data frame and the feedback data frame forwarded by the tested system in batch to obtain a comprehensive test result.
2. The method of claim 1, wherein the basic parameters include a test pattern and a message length, and the constructing the original data frame using the basic parameters includes:
under the condition that the test mode is a fixed data mode, generating an original data frame corresponding to the message length according to the fixed data mode;
under the condition that the test mode is an accumulated data mode, generating an original data frame corresponding to the message length according to the accumulated data mode;
and under the condition that the test mode is a pseudo-random data mode, generating an original data frame corresponding to the message length according to the pseudo-random data mode.
3. The method of claim 1, wherein the control parameters include a preset rate and a frame interval duration determined using a preset bandwidth; then said determining a regulatory attribute using said control parameter comprises:
determining the preset rate as a sending rate for sending the original data frame to the tested system;
and determining the quotient of the frame interval duration and the unit duration of the idle data frames as the insertion quantity of the idle data frames required to be inserted between two adjacent original data frames.
4. The method of claim 3, wherein the sending the raw data frames to the system under test in bulk based on the regulatory attributes and receiving the feedback data frames forwarded by the system under test in bulk comprises:
sending the original data frame to the tested system according to the sending rate, and sending the inserted number of idle data frames to the tested system;
judging whether a test stopping condition is reached;
if the test stopping condition is not met, executing the step of sending the original data frame to the tested system according to the sending rate and sending the inserted number of idle data frames to the tested system;
if the test stopping condition is met, stopping sending the original data frame to the tested system;
and receiving feedback data frames forwarded in batch by the system to be tested in the process of sending the original data frames and the idle data frames.
5. The method of claim 4, wherein the test parameters further include a stop condition parameter, the stop condition parameter including a stop parameter and a stop parameter threshold;
updating the value of the stopping parameter before judging whether the test stopping condition is reached;
the determining whether the test stop condition is reached includes:
judging whether the numerical value of the stopping parameter reaches the stopping parameter threshold value;
if so, determining that the test stopping condition is reached;
if not, determining that the test stopping condition is not reached.
6. The method of claim 5, wherein the stopping parameters include a number of tests or a duration of tests;
under the condition that the stopping parameter is the number of times of testing, updating the value of the stopping parameter comprises increasing the value of the number of times of testing or decreasing the value of the number of times of testing;
and under the condition that the stopping parameter is the testing time length, updating the numerical value of the stopping parameter comprises updating the numerical value of the testing time length.
7. The method of claim 4, wherein the comprehensively analyzing the raw data frames and the feedback data frames forwarded by the system under test in bulk to obtain comprehensive test results comprises:
counting the sending quantity of the original data frames and the feedback quantity of the feedback data frames forwarded in batch by the system to be tested;
comparing the feedback data frames forwarded in batch by the system to be tested with the original data frames one by one, and determining the error number of error data frames in the feedback data frames forwarded in batch by the system to be tested;
and comprehensively analyzing the sending quantity, the feedback quantity and the error quantity to obtain a comprehensive test result.
8. A test apparatus, characterized in that the test apparatus comprises:
the system comprises a generating unit, a testing unit and a control unit, wherein the generating unit is used for generating testing parameters for executing testing operation on a tested system by an upper computer, and the upper computer provides an interface for filling the testing parameters so that a user can input the testing parameters based on a scene to be tested;
the receiving module is used for receiving the test parameters which are sent by the upper computer, execute the test operation on the tested system and correspond to the scene to be tested by the programmable device; wherein the test parameters include basic parameters, control parameters, and stop condition parameters;
the configuration module is used for the programmable device to construct an original data frame by using the basic parameters and determine the regulation and control attributes by using the control parameters, and the stop condition parameters are used for setting the stop conditions of the test;
the sending module is used for sending the original data frames to the tested system in batches by the programmable device based on the regulation and control attribute;
the receiving module is used for receiving the feedback data frames forwarded in batches by the system to be tested by the programmable device;
and the analysis module is used for comprehensively analyzing the original data frame and the feedback data frame forwarded by the tested system in batch by the programmable device to obtain a comprehensive test result.
9. A test system, comprising:
the upper computer is used for generating test parameters for executing test operation on the tested system and issuing the test parameters for executing the test operation on the tested system; the upper computer provides an interface for filling in test parameters, so that a user can input the test parameters based on a scene to be tested;
the programmable device is used for receiving test parameters which are sent by the upper computer, execute test operation on the tested system and correspond to the scene to be tested; wherein the test parameters include basic parameters, control parameters, and stop condition parameters; constructing an original data frame by using the basic parameters, determining a regulation attribute by using the control parameters, and setting a stopping condition parameter for the test; sending the original data frames to the tested system in batch based on the regulation and control attribute, and receiving feedback data frames forwarded by the tested system in batch; comprehensively analyzing the original data frames and the feedback data frames forwarded in batches by the tested system to obtain comprehensive test results;
and the tested system is used for receiving the original data frame and forwarding the feedback data frame to the programmable device in batches.
10. The system of claim 9,
the programmable device comprises an FPGA;
the upper computer and the FPGA are communicated by adopting high-speed serial point-to-point double-channel high-bandwidth transmission PCIE;
and under the condition that the tested system is used for realizing an FC-AE bus, the FPGA and the tested system adopt an FC-AE protocol to carry out optical fiber communication.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811417500.XA CN109617757B (en) | 2018-11-26 | 2018-11-26 | Test method, device and system of tested system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811417500.XA CN109617757B (en) | 2018-11-26 | 2018-11-26 | Test method, device and system of tested system |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109617757A CN109617757A (en) | 2019-04-12 |
CN109617757B true CN109617757B (en) | 2021-02-19 |
Family
ID=66005129
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811417500.XA Active CN109617757B (en) | 2018-11-26 | 2018-11-26 | Test method, device and system of tested system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109617757B (en) |
Family Cites Families (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US9917667B2 (en) * | 2015-12-21 | 2018-03-13 | Hamilton Sundstrand Corporation | Host-to-host test scheme for periodic parameters transmission in synchronized TTP systems |
CN108267683A (en) * | 2017-01-04 | 2018-07-10 | 中兴通讯股份有限公司 | The method and device that a kind of FPGA tests oneself |
CN106681313B (en) * | 2017-03-14 | 2019-12-06 | 南京南瑞继保电气有限公司 | Stability control system function test method and system |
CN108111367A (en) * | 2017-10-30 | 2018-06-01 | 深圳市风云实业有限公司 | Performance test methods and device |
CN108109567B (en) * | 2017-12-27 | 2021-08-13 | 苏州华兴源创科技股份有限公司 | Liquid crystal module aging testing device and equipment comprising same |
-
2018
- 2018-11-26 CN CN201811417500.XA patent/CN109617757B/en active Active
Also Published As
Publication number | Publication date |
---|---|
CN109617757A (en) | 2019-04-12 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN103746831A (en) | Alarm analysis method, device and system | |
CN106817314B (en) | Big data acquisition method, device and system | |
CN108390856B (en) | DDoS attack detection method and device and electronic equipment | |
CN110908940A (en) | Method for adjusting serial port communication parameters and terminal equipment | |
CN113938387A (en) | A communication method, device and readable storage medium | |
CN105282244A (en) | Data processing method and device, server and controller | |
CN109617757B (en) | Test method, device and system of tested system | |
CN105119814B (en) | A kind of information processing method and terminal | |
CN108777810B (en) | Video data storage method, device, equipment and storage medium | |
CN104219157A (en) | Determining method and determining equipment for counting time intervals | |
CN109560978B (en) | Network flow detection method, device and system and computer readable storage medium | |
CN112187481B (en) | User online record management method, device and system | |
CN104956614B (en) | The overload controlling method and device of opposite end network element | |
CN114428685A (en) | Data processing method, device, equipment and computer storage medium | |
CN115567448A (en) | Flow control method, device, equipment, medium and program product | |
CN114443537B (en) | A PCIE signal transmitter parameter configuration method, device, equipment and medium | |
CN115499287B (en) | Event analysis method and device | |
CN116132546A (en) | Method, device, equipment and medium for data transmission | |
CN112995060A (en) | Flow control method based on hardware counter | |
CN108650049B (en) | Channel detection method, device and base station | |
CN107122325B (en) | Data transmission system and method based on universal serial bus | |
CN113965445A (en) | A method, device, computer equipment and storage medium for locating the root cause of poor quality | |
CN110083583A (en) | Streaming events processing method and processing device | |
CN109873742B (en) | Simulation control method and device for FC-AE bus | |
CN114996004B (en) | Method and device for continuously deleting session |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |