CN109976997A - Test method and device - Google Patents
Test method and device Download PDFInfo
- Publication number
- CN109976997A CN109976997A CN201711458320.1A CN201711458320A CN109976997A CN 109976997 A CN109976997 A CN 109976997A CN 201711458320 A CN201711458320 A CN 201711458320A CN 109976997 A CN109976997 A CN 109976997A
- Authority
- CN
- China
- Prior art keywords
- test
- generated
- parameter value
- parameter
- request message
- 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
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3684—Test management for test design, e.g. generating new test cases
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3688—Test management for test execution, e.g. scheduling of test suites
Abstract
The embodiment of the present application discloses test method and device.One specific embodiment of this method includes: reception test request, wherein test request includes the identification information of program segment to be measured and the parameter name of test parameter;The request message that client is sent in the program segment processing target period to be measured indicated by identification information;The parameter value of the test parameter generated when obtaining processing request message according to parameter name;Test result is generated according to generated parameter value.This embodiment offers the testing mechanisms that the parameter value generated when a kind of request message based on processing generates test result, enrich test method.
Description
Technical field
The invention relates to field of computer technology more particularly to test method and devices.
Background technique
As internet development use scope is more and more wider, present more and more systems provide website service, to website
The test of each functional module of system is also increasingly taken seriously;Under existing test system, often by manually rule of thumb
Judge the superiority and inferiority of each functional module in website.
Summary of the invention
The embodiment of the present application proposes test method and device.
In a first aspect, the embodiment of the present application provides a kind of test method, this method comprises: receiving test request, wherein
Test request includes the identification information of program segment to be measured and the parameter name of test parameter;The program to be measured indicated by identification information
The request message that client is sent in the section processing target period;The test generated when obtaining processing request message according to parameter name
The parameter value of parameter;Test result is generated according to generated parameter value.
In some embodiments, the length of target time section is whether to reach default according to the quantity of generated parameter value
What amount threshold determined.
In some embodiments, according to generated parameter value generate test result, comprising: to generated parameter value into
Line sampling;Test result is generated according to the parameter value sampled out.
In some embodiments, target time section included at least two sub- periods;And to generated parameter value into
Line sampling, comprising: the quantity of the parameter value generated when the request message that client is sent in statistical disposition each sub- period;Root
According to the quantity and pre-set sampling proportion counted, from when handling the request message of client transmission in each sub- period
Parameter value is extracted in the parameter value of generation.
In some embodiments, test request include at least two for realizing the program segment to be measured of same function mark
Information;And the request message that client is sent in the program segment processing target period to be measured indicated by identification information, packet
It includes: the request message that client in target time section is sent is distributed at the program segment to be measured indicated to each identification information
Reason.
In some embodiments, test result is generated according to generated parameter value, comprising: send out generated parameter value
It send to target device;Obtain target device return with the associated markup information of generated parameter value;According to acquired mark
It infuses information and generates test result.
It in some embodiments, include the first model obtained for realizing preparatory training initial model in program segment to be measured
Program;And after according to acquired markup information generating test result, method further include: believed based on acquired mark
Breath obtains the second model using machine learning method training initial model.
In some embodiments, the is obtained using machine learning method training initial model based on acquired markup information
Two models, comprising: screen the markup information in acquired markup information with predefined negative markup information type matching;It will
It is the markup information that filters out, associated with the associated request message of markup information filtered out and with the markup information that filters out
Parameter value is determined as negative sample data;It is spaced at predetermined time intervals, based on the negative sample data determined in the time interval, benefit
The second model is obtained with machine learning method training initial model.
In some embodiments, method further include: based at least one of following test set, generate the finger of the second model
Mark data: the test set of pre-set test set, history negative sample data composition;In response to generated achievement data and preset
Be used to indicate the achievement data commensurate in scope that passes through of test, pass through the request message that the second model treatment client is sent.
Second aspect, the embodiment of the present application provide a kind of test device, which includes: receiving unit, for receiving
Test request, wherein test request includes the identification information of program segment to be measured and the parameter name of test parameter;First processing is single
Member, the request message that client is sent in the program segment processing target period to be measured for being indicated by identification information;It obtains
Unit, the parameter value of the test parameter generated when for obtaining processing request message according to parameter name;Generation unit is used for basis
Generated parameter value generates test result.
In some embodiments, the length of target time section is whether to reach default according to the quantity of generated parameter value
What amount threshold determined.
In some embodiments, generation unit, comprising: sub-unit, for being sampled to generated parameter value;
Subelement is generated, for generating test result according to the parameter value sampled out.
In some embodiments, target time section included at least two sub- periods;And sub-unit, further match
It sets and is used for: the quantity of the parameter value generated when the request message that client is sent in statistical disposition each sub- period;According to institute
The quantity of statistics and pre-set sampling proportion generate when the request message of client transmission out of processing each sub- period
Parameter value in extract parameter value.
In some embodiments, test request include at least two for realizing the program segment to be measured of same function mark
Information;And first processing units, be further configured to: by target time section client send request message distribute to
The program segment to be measured of each identification information instruction is handled.
In some embodiments, generation unit is further configured to: generated parameter value being sent to target and is set
It is standby;Obtain target device return with the associated markup information of generated parameter value;It is generated according to acquired markup information
Test result.
It in some embodiments, include the first model obtained for realizing preparatory training initial model in program segment to be measured
Program;And device further include: training unit, for first using machine learning method training based on acquired markup information
Beginning model obtains the second model.
In some embodiments, training unit, comprising: screening subelement, for screen in acquired markup information with
The markup information of predefined negative markup information type matching;Determine subelement, for by the markup information filtered out, with sieve
The associated request message of the markup information selected and it is determined as negative sample number with the associated parameter value of markup information filtered out
According to;Training subelement, based on the negative sample data determined in the time interval, utilizes machine for being spaced at predetermined time intervals
Device learning method training initial model obtains the second model.
In some embodiments, device further include: test cell, for based at least one of following test set, life
At the achievement data of the second model: the test set of pre-set test set, history negative sample data composition;Second processing list
Member, in response to generated achievement data and it is preset be used to indicate the achievement data commensurate in scope that passes through of test, by the
The request message that two model treatment clients are sent.
The third aspect, the embodiment of the present application provide a kind of equipment, comprising: one or more processors;Storage device is used
In storing one or more programs, when said one or multiple programs are executed by said one or multiple processors, so that above-mentioned
One or more processors realize such as the above-mentioned method of first aspect.
Fourth aspect, the embodiment of the present application provide a kind of computer readable storage medium, are stored thereon with computer journey
Sequence, which is characterized in that such as first aspect above-mentioned method is realized when the program is executed by processor.
Test method provided by the embodiments of the present application and device are then referred to by identification information by receiving test request
The request message that client is sent in the program segment processing target period to be measured shown, and processing request is obtained according to parameter name and is disappeared
The parameter value of the test parameter generated when breath finally generates test result according to generated parameter value, to provide one kind
The parameter value generated when based on processing request message generates the testing mechanism of test result, enriches test method.
Detailed description of the invention
By reading a detailed description of non-restrictive embodiments in the light of the attached drawings below, the application's is other
Feature, objects and advantages will become more apparent upon:
Fig. 1 is that this application can be applied to exemplary system architecture figures therein;
Fig. 2 is the flow chart according to one embodiment of the test method of the application;
Fig. 3 is a schematic diagram according to the application scenarios of the test method of the application;
Fig. 4 is the flow chart according to another embodiment of the test method of the application;
Fig. 5 is the structural schematic diagram according to one embodiment of the test device of the application;
Fig. 6 is adapted for the structural schematic diagram for the computer system for realizing the server of the embodiment of the present application.
Specific embodiment
The application is described in further detail with reference to the accompanying drawings and examples.It is understood that this place is retouched
The specific embodiment stated is used only for explaining related invention, rather than the restriction to the invention.It also should be noted that in order to
Convenient for description, part relevant to related invention is illustrated only in attached drawing.
It should be noted that in the absence of conflict, the features in the embodiments and the embodiments of the present application can phase
Mutually combination.The application is described in detail below with reference to the accompanying drawings and in conjunction with the embodiments.
Fig. 1 is shown can be using the exemplary system architecture of the embodiment of the test method or test device of the application
100。
As shown in Figure 1, system architecture 100 may include terminal device 101,102,103, network 104 and server 105,
106.Network 104 between terminal device 101,102,103 and server 105,106 to provide the medium of communication link.Net
Network 104 may include various connection types, such as wired, wireless communication link or fiber optic cables etc..
User 110 can be used terminal device 101,102,103 and be interacted by network 104 with server 105,106, to connect
Receive or send data etc..Various applications, such as the application of shopping class, map class can be installed on terminal device 101,102,103
Using, payment class application, social category application, web browser applications, search engine class apply, mobile phone assistant's class apply etc..
Terminal device 101,102,103 can be with display screen and the various electronics of data communication function supported to set
It is standby, including but not limited to smart phone, tablet computer, E-book reader, MP3 player (Moving Picture
Experts Group Audio Layer III, dynamic image expert's compression standard audio level 3), MP4 (Moving
Picture Experts Group Audio Layer IV, dynamic image expert's compression standard audio level 4) player, knee
Mo(u)ld top half portable computer and desktop computer etc..User can be asked by terminal device 101,102,103 to server transmission
Seek message.
Server 105,106 can be to provide the server of various services, such as to pacifying on terminal device 101,102,103
The application of dress provides the background server supported, server 105,106 can receive test request;It is indicated by identification information
The request message that client is sent in the program segment processing target period to be measured;It is produced when obtaining processing request message according to parameter name
The parameter value of raw test parameter;Test result is generated according to generated parameter value.
It should be noted that test method provided by the embodiment of the present application can be executed by server 105,106, accordingly
Ground, test device can be set in server 105,106.
It should be understood that the number of terminal device, network and server in Fig. 1 is only schematical.According to realization need
It wants, can have any number of terminal device, network and server.
With continued reference to Fig. 2, the process 200 of one embodiment of the test method according to the application is shown.The test side
Method, comprising the following steps:
Step 201, test request is received.
In the present embodiment, the electronic equipment (such as server shown in FIG. 1) of test method operation thereon can lead to
It crosses wired connection mode or radio connection receives test request.Test request includes identification information and the survey of program segment to be measured
Try the parameter name of parameter.Program segment to be measured can be one section of program for realizing specific function in website or application, for example, certain
The program of one module or program for realizing some model, model can be for some practical problem or objective things, rule
Rule carries out a kind of Formal Representation mode after being abstracted.The identification information of program segment to be measured can be file where program segment to be measured
Title, the position etc. of the title of method in program, program segment storage to be measured can identify the information of program segment to be measured.
As an example, tester can be according to its testing requirement by the identification information of program segment to be measured and test parameter
Parameter name inputs above-mentioned electronic equipment to generate test request, and tester can also be by the identification information of program segment to be measured and survey
The parameter name of examination parameter inputs other electronic equipments to generate test request, and then other electronic equipments are by the test request of generation
It is sent to above-mentioned electronic equipment.
Step 202, the request that client is sent in the program segment processing target period to be measured indicated by identification information
Message.
In the present embodiment, above-mentioned electronic equipment can pass through mark included by test request received in step 201
The request message that client is sent in the program segment processing target period to be measured of information instruction.Request message may include to money
The requesting method in source, the identifier of resource and the agreement used etc., specifically can be used hypertext transfer protocol (HTTP,
HyperText Transfer Protocol) etc. agreements.Program segment to be measured operation there may be when problem, pass through mark
The request message that client is sent in the program segment processing target period to be measured of information instruction, can be and referred to by identification information
The request message that the client of preset ratio is sent in the program segment processing target period to be measured shown will not influence big with this
Use of the most users to website or application.Preset ratio can be configured according to actual needs, with preset ratio for 10%
For, the background server of website has received 1000 request messages altogether, 100 request messages therein can be passed through
Program segment processing to be measured.
In some optional implementations of the present embodiment, the length of target time section is according to generated parameter value
Whether quantity reaches what preset quantity threshold value determined.It may need a certain number of parameter values that could generate accurate test
As a result, therefore, determining that the length of target time section can further improve testing efficiency according to the quantity of generated parameter value.
In some optional implementations of the present embodiment, test request includes at least two for realizing same function
The identification information of program segment to be measured;And client is sent out in the program segment processing target period to be measured indicated by identification information
The request message sent, comprising: distribute the request message that client in target time section is sent to the instruction of each identification information
Program segment to be measured is handled.In this implementation, at least two can form for realizing the program segment to be measured of same function
Control experiment, the subsequent parameter value that can be generated by both comparisons operation, compares the superiority and inferiority of the two.
Step 203, the parameter value of the test parameter generated when obtaining processing request message according to parameter name.
In the present embodiment, above-mentioned electronic equipment can pass through parameter included by test request received in step 201
The parameter value of the test parameter generated when handling request message in name obtaining step 202.It can be by burying at the modes acquisition such as a little
The parameter value of the test parameter generated when managing request message.
Step 204, test result is generated according to generated parameter value.
In the present embodiment, above-mentioned electronic equipment can generate test result according to the parameter value generated in step 203.It is raw
Can be configured according to actual needs at the mode of test result, for example, when parameter value be session amount, size of message, clicking rate,
When satisfaction rate, parameter value within a preset range when, the test result of generation can be to pass through.In addition, test request can also wrap
The create-rule that test result is generated according to generated parameter value is included, it can be raw according to create-rule and generated parameter value
Test result is generated at test result.Create-rule can be under the conditions of what kind of, and test result is to pass through or do not pass through.
In some optional implementations of the present embodiment, test result is generated according to generated parameter value, comprising: right
Generated parameter value is sampled;Test result is generated according to the parameter value sampled out.Specific sampling prescription can basis
Actual needs is configured, and sampling prescription can be used for describing the data set to be sampled, and the beginning and ending time section of sampling is final it is expected
Sampling results data volume, and other business rule.
In some optional implementations of the present embodiment, target time section included at least two sub- periods;And it is right
Generated parameter value is sampled, comprising: is generated when the request message that client is sent in statistical disposition each sub- period
Parameter value quantity;According to the quantity and pre-set sampling proportion counted, the client out of processing each sub- period
Parameter value is extracted in the parameter value generated when holding the request message sent.Because the parameter value of generation may be more, by assuming that number
More parts are cut into according in being just distributed very much, then the time in some cycles, then is taken out at random in proportion by calculating Time Density
A certain number of samples are taken, sampling efficiency can be improved.
With continued reference to the schematic diagram that Fig. 3, Fig. 3 are according to the application scenarios of the test method of the present embodiment.Fig. 3's
In application scenarios, electronic equipment 301 receives the identification information of the program segment to be measured of tester's input and the ginseng of test parameter
Several 302, it then generates and the test request 305 including identification information and parameter name, server 303 occurs to server 303
The request message 304 that client is sent in the program segment processing target period to be measured indicated by identification information, and according to ginseng
Several parameter values of test parameter generated when obtaining processing request message are finally generated according to generated parameter value and to electricity
Sub- equipment 301 sends test result 306.
The method provided by the above embodiment of the application by receive test request, then by identification information indicate to
It is produced when surveying the request message that client is sent in the program segment processing target period, and obtaining processing request message according to parameter name
The parameter value of raw test parameter finally generates test result according to generated parameter value, to provide a kind of based on place
The parameter value generated when managing request message generates the testing mechanism of test result, enriches test method.
With further reference to Fig. 4, it illustrates the processes 400 of another embodiment of test method.The stream of the test method
Journey 400, comprising the following steps:
Step 401, test request is received.
In the present embodiment, the electronic equipment (such as server shown in FIG. 1) of test method operation thereon can lead to
It crosses wired connection mode or radio connection receives test request.Test request includes identification information and the survey of program segment to be measured
Try the parameter name of parameter.
Step 402, the request that client is sent in the program segment processing target period to be measured indicated by identification information
Message.
In the present embodiment, above-mentioned electronic equipment can pass through mark included by test request received in step 401
The request message that client is sent in the program segment processing target period to be measured of information instruction.May include in program segment to be measured
For realizing the program for the first model that preparatory training initial model obtains.Initial model can be logistic regression (Logistic
Regression), random forest (random forest), iteration decision tree (gradient boosting decision
Tree) or the model for classification such as model for classification such as support vector machines (Support Vector Machine), k are equal
The model for cluster such as value cluster (K-means) generates confrontation network (GAN, Generative Adversarial
Network) model, neural network model etc. are also possible to composite model made of being combined by the above various models.
Step 403, the parameter value of the test parameter generated when obtaining processing request message according to parameter name.
In the present embodiment, above-mentioned electronic equipment can pass through parameter included by test request received in step 401
The parameter value of the test parameter generated when handling request message in name obtaining step 402.
Step 404, generated parameter value is sent to target device.
In the present embodiment, the parameter value generated in step 403 can be sent to target device by above-mentioned electronic equipment.Mesh
Marking device can be client or the equipment for carrying out data mark.As an example, when target device is client, to ranging
Include the program for realizing chat robots in sequence section, when that can not judge that user is intended to, can be sent to client several
A option is clicked according to user for user's click and generates markup information.Also can establish mark task, distribute to for into
The equipment of row data mark, by machine or is manually labeled.
Step 405, obtain target device return with the associated markup information of generated parameter value.
In the present embodiment, the available target device of above-mentioned electronic equipment return with the parameter that is sent in step 404
It is worth associated markup information.Markup information can simply be divided into positive markup information and negative markup information, can also be with
Need to be arranged the type of markup information according to business.
Step 406, test result is generated according to acquired markup information.
In the present embodiment, above-mentioned electronic equipment can generate test result according to the markup information obtained in step 405.
For example, markup information is divided into positive markup information and negative markup information, then according to positive markup information and can bear
The ratio of the ratio generation test result of the markup information in face, positive markup information and negative markup information is more than default threshold
The test result that test passes through can be generated when value.Negative markup information can also include the reason of causing negative results.
Step 407, the second model is obtained using machine learning method training initial model based on acquired markup information.
In the present embodiment, above-mentioned electronic equipment can utilize machine learning based on the markup information obtained in step 405
Method training initial model obtains the second model.The input and output of trained model can be determined according to specific business, be inputted defeated
The parameter name of parameter also may include being inputted in test request, or through other approach by user out, for example, can be by client
Hold the related data for including in the solicited message sent as input, markup information is instructed as output using machine learning method
Practice initial model and obtains the second model.
In some optional implementations of the present embodiment, instructed based on acquired markup information using machine learning method
Practice initial model and obtain the second model, comprising: screen in acquired markup information with predefined negative markup information type
Matched markup information;By the markup information filtered out, with the associated request message of markup information that filters out and with screening
The associated parameter value of markup information out is determined as negative sample data;It is spaced at predetermined time intervals, based on true in the time interval
The negative sample data made obtain the second model using machine learning method training initial model.Interval weight at predetermined time intervals
New training pattern can continue to optimize model, with the operational effect being optimal.Predetermined time interval can be according to the sample of acquisition
This amount determines that sample size is sufficiently large, can suitably shorten.
Step 408, the achievement data of the second model is generated based on test set.
In the present embodiment, above-mentioned electronic equipment can be based on the second mould that training obtains in test set generation step 407
The achievement data of type.Test set comprises at least one of the following: the test of pre-set test set, history negative sample data composition
Collection.Pre-set test set can be the criterion evaluation collection (baseline) of business personnel's foundation, and history negative sample data can
To be the negative sample data determined in the past period.The assessment of second model can be and carry out offline.To every class
Weight can be set in markup information, is weighted according to weight to obtain final achievement data.As an example, for chatting machine
Device people, achievement data can be divided into overall effect, response effect, the types such as conversation strategy.
Step 409, in response to generated achievement data and the preset achievement data range for being used to indicate test and passing through
Match, the request message sent by the second model treatment client.
In the present embodiment, above-mentioned electronic equipment can be used in response to generating achievement data in step 408 with preset
Indicate the achievement data commensurate in scope that test passes through, the request message sent by the second model treatment client.Assessment can be with
Macro average value is calculated using sample weighting.This step can produce one can be with the Effect value of evaluation model effect.Effect value can
It, can if fluctuation range is within a preset range to be used to compare with the Effect value (such as Effect value of the first model) of history
To think that the second model may bring counter productive.The differentiation of modelling effect can not singly see a certain index, by it is multiple because
The index that element influences can determine its achievement data range by the data analyst of profession.Pass through the second model treatment client
The request message of transmission can be the second model and reach standard, true user's request on line can be handled by it, if not reaching
Mark then, can continue to use the request message of the first model treatment client transmission.
In the present embodiment, step 401, step 402, the operation of step 403 and step 201, step 202, step 203
Operate essentially identical, details are not described herein.
Figure 4, it is seen that compared with the corresponding embodiment of Fig. 2, in the process 400 of the test method in the present embodiment
The model being related to by the markup information re -training program segment to be measured of acquisition, and the model obtained to training is assessed, and is led to
It crosses assessment and client request is then handled by it, take full advantage of test data in the scheme of the present embodiment description as a result, and mention
The scheme actively optimized has been supplied, it can the continual effect for generating iteration optimization.
With further reference to Fig. 5, as the realization to method shown in above-mentioned each figure, this application provides a kind of test devices
One embodiment, the Installation practice is corresponding with embodiment of the method shown in Fig. 2, which specifically can be applied to various electricity
In sub- equipment.
As shown in figure 5, the test device 500 of the present embodiment includes: receiving unit 501, first processing units 502, obtains
Unit 503, generation unit 504.Wherein, receiving unit 501, for receiving test request, wherein test request includes to ranging
The identification information of sequence section and the parameter name of test parameter;First processing units 502, for by identification information indicate to ranging
The request message that client is sent in the sequence section processing target period;Acquiring unit 503, for being asked according to parameter name acquisition processing
The parameter value of the test parameter generated when seeking message;Generation unit 504, for generating test knot according to generated parameter value
Fruit.
In the present embodiment, the receiving unit 501 of test device 500, first processing units 502, acquiring unit 503, life
It can be with reference to step 201, step 202, step 203 and the step 204 in Fig. 2 corresponding embodiment at the specific processing of unit 504.
In some optional implementations of the present embodiment, the length of target time section is according to generated parameter value
Whether quantity reaches what preset quantity threshold value determined.
In some optional implementations of the present embodiment, generation unit 504, comprising: sub-unit (does not show in figure
Out), for being sampled to generated parameter value;Subelement (not shown) is generated, for according to the parameter sampled out
Value generates test result.
In some optional implementations of the present embodiment, target time section included at least two sub- periods;And it takes out
Sub-unit (not shown), is further configured to: the request that client is sent in statistical disposition each sub- period disappears
The quantity of the parameter value generated when breath;According to the quantity and pre-set sampling proportion counted, from processing each sub- time
Parameter value is extracted in the parameter value generated when the request message that client is sent in section.
In some optional implementations of the present embodiment, test request includes at least two for realizing same function
The identification information of program segment to be measured;And first processing units 502, it is further configured to: by client in target time section
The request message of transmission is distributed to the program segment to be measured that each identification information indicates and is handled.
In some optional implementations of the present embodiment, generation unit 504 is further configured to: will be generated
Parameter value is sent to target device;Obtain target device return with the associated markup information of generated parameter value;According to institute
The markup information of acquisition generates test result.
It include for realizing preparatory training introductory die in program segment to be measured in some optional implementations of the present embodiment
The program for the first model that type obtains;And device further include: training unit (not shown), for based on acquired mark
Note use of information machine learning method training initial model obtains the second model.
In some optional implementations of the present embodiment, training unit (not shown), comprising: screening subelement
(not shown) is believed for screening in acquired markup information with the mark of predefined negative markup information type matching
Breath;Determine subelement (not shown), for by the markup information filtered out, with the associated request of markup information that filters out
Message and it is determined as negative sample data with the associated parameter value of markup information filtered out;Training subelement (does not show in figure
Out), for being spaced at predetermined time intervals, based on the negative sample data determined in the time interval, machine learning method is utilized
Training initial model obtains the second model.
In some optional implementations of the present embodiment, device further include: test cell (not shown) is used for base
In at least one of following test set, the achievement data of the second model: pre-set test set, history negative sample number is generated
According to the test set of composition;The second processing unit (not shown), for being used in response to generated achievement data with preset
Indicate the achievement data commensurate in scope that test passes through, the request message sent by the second model treatment client.
The device provided by the above embodiment of the application, by receiving test request, wherein test request includes to ranging
The identification information of sequence section and the parameter name of test parameter;In the program segment processing target period to be measured indicated by identification information
The request message that client is sent;The parameter value of the test parameter generated when obtaining processing request message according to parameter name;According to
Generated parameter value generates test result, and the parameter value generated when to providing a kind of request message based on processing, which generates, to be surveyed
The testing mechanism of test result, enriches test method.
Below with reference to Fig. 6, it illustrates the computer systems 600 for the electronic equipment for being suitable for being used to realize the embodiment of the present application
Structural schematic diagram.Electronic equipment shown in Fig. 6 is only an example, function to the embodiment of the present application and should not use model
Shroud carrys out any restrictions.
As shown in fig. 6, computer system 600 includes central processing unit (CPU) 601, it can be read-only according to being stored in
Program in memory (ROM) 602 or be loaded into the program in random access storage device (RAM) 603 from storage section 608 and
Execute various movements appropriate and processing.In RAM 603, also it is stored with system 600 and operates required various programs and data.
CPU 601, ROM 602 and RAM 603 are connected with each other by bus 604.Input/output (I/O) interface 605 is also connected to always
Line 604.
I/O interface 605 is connected to lower component: the importation 606 including keyboard, mouse etc.;It is penetrated including such as cathode
The output par, c 607 of spool (CRT), liquid crystal display (LCD) etc. and loudspeaker etc.;Storage section 608 including hard disk etc.;
And the communications portion 609 of the network interface card including LAN card, modem etc..Communications portion 609 via such as because
The network of spy's net executes communication process.Driver 610 is also connected to I/O interface 605 as needed.Detachable media 611, such as
Disk, CD, magneto-optic disk, semiconductor memory etc. are mounted on as needed on driver 610, in order to read from thereon
Computer program be mounted into storage section 608 as needed.
Particularly, in accordance with an embodiment of the present disclosure, it may be implemented as computer above with reference to the process of flow chart description
Software program.For example, embodiment of the disclosure includes a kind of computer program product comprising be carried on computer-readable medium
On computer program, which includes the program code for method shown in execution flow chart.In such reality
It applies in example, which can be downloaded and installed from network by communications portion 609, and/or from detachable media
611 are mounted.When the computer program is executed by central processing unit (CPU) 601, limited in execution the present processes
Above-mentioned function.It should be noted that computer-readable medium described herein can be computer-readable signal media or
Computer readable storage medium either the two any combination.Computer readable storage medium for example can be --- but
Be not limited to --- electricity, magnetic, optical, electromagnetic, infrared ray or semiconductor system, device or device, or any above combination.
The more specific example of computer readable storage medium can include but is not limited to: have one or more conducting wires electrical connection,
Portable computer diskette, hard disk, random access storage device (RAM), read-only memory (ROM), erasable type may be programmed read-only deposit
Reservoir (EPROM or flash memory), optical fiber, portable compact disc read-only memory (CD-ROM), light storage device, magnetic memory
Part or above-mentioned any appropriate combination.In this application, computer readable storage medium, which can be, any include or stores
The tangible medium of program, the program can be commanded execution system, device or device use or in connection.And
In the application, computer-readable signal media may include in a base band or the data as the propagation of carrier wave a part are believed
Number, wherein carrying computer-readable program code.The data-signal of this propagation can take various forms, including but not
It is limited to electromagnetic signal, optical signal or above-mentioned any appropriate combination.Computer-readable signal media can also be computer
Any computer-readable medium other than readable storage medium storing program for executing, the computer-readable medium can send, propagate or transmit use
In by the use of instruction execution system, device or device or program in connection.Include on computer-readable medium
Program code can transmit with any suitable medium, including but not limited to: wireless, electric wire, optical cable, RF etc., Huo Zheshang
Any appropriate combination stated.
The calculating of the operation for executing the application can be write with one or more programming languages or combinations thereof
Machine program code, described program design language include object oriented program language-such as Java, Smalltalk, C+
+, it further include conventional procedural programming language-such as C language or similar programming language.Program code can be with
It fully executes, partly execute on the user computer on the user computer, being executed as an independent software package, portion
Divide and partially executes or executed on a remote computer or server completely on the remote computer on the user computer.?
Be related in the situation of remote computer, remote computer can pass through the network of any kind --- including local area network (LAN) or
Wide area network (WAN)-be connected to subscriber computer, or, it may be connected to outer computer (such as mentioned using Internet service
It is connected for quotient by internet).
Flow chart and block diagram in attached drawing are illustrated according to the system of the various embodiments of the application, method and computer journey
The architecture, function and operation in the cards of sequence product.In this regard, each box in flowchart or block diagram can generation
A part of one module, program segment or code of table, a part of the module, program segment or code include one or more use
The executable instruction of the logic function as defined in realizing.It should also be noted that in some implementations as replacements, being marked in box
The function of note can also occur in a different order than that indicated in the drawings.For example, two boxes succeedingly indicated are actually
It can be basically executed in parallel, they can also be executed in the opposite order sometimes, and this depends on the function involved.Also it to infuse
Meaning, the combination of each box in block diagram and or flow chart and the box in block diagram and or flow chart can be with holding
The dedicated hardware based system of functions or operations as defined in row is realized, or can use specialized hardware and computer instruction
Combination realize.
Being described in unit involved in the embodiment of the present application can be realized by way of software, can also be by hard
The mode of part is realized.Described unit also can be set in the processor, for example, can be described as: a kind of processor packet
Include receiving unit, first processing units, acquiring unit, generation unit.Wherein, the title of these units is not under certain conditions
The restriction to the unit itself is constituted, for example, receiving unit is also described as " for receiving the unit of test request ".
As on the other hand, present invention also provides a kind of computer-readable medium, which be can be
Included in device described in above-described embodiment;It is also possible to individualism, and without in the supplying device.Above-mentioned calculating
Machine readable medium carries one or more program, when said one or multiple programs are executed by the device, so that should
Device: test request is received, wherein test request includes the identification information of program segment to be measured and the parameter name of test parameter;It is logical
Cross the request message that client is sent in the program segment processing target period to be measured of identification information instruction;It is obtained according to parameter name
The parameter value of the test parameter generated when handling request message;Test result is generated according to generated parameter value.
Above description is only the preferred embodiment of the application and the explanation to institute's application technology principle.Those skilled in the art
Member is it should be appreciated that invention scope involved in the application, however it is not limited to technology made of the specific combination of above-mentioned technical characteristic
Scheme, while should also cover in the case where not departing from foregoing invention design, it is carried out by above-mentioned technical characteristic or its equivalent feature
Any combination and the other technical solutions formed.Such as features described above has similar function with (but being not limited to) disclosed herein
Can technical characteristic replaced mutually and the technical solution that is formed.
Claims (12)
1. a kind of test method, comprising:
Receive test request, wherein the test request includes the identification information of program segment to be measured and the parameter name of test parameter;
The request message that client is sent in the program segment processing target period to be measured indicated by the identification information;
The parameter value of the test parameter generated when obtaining according to the parameter name and handle the request message;
Test result is generated according to generated parameter value.
2. according to the method described in claim 1, wherein, the length of the target time section is according to generated parameter value
Whether quantity reaches what preset quantity threshold value determined.
3. according to the method described in claim 1, wherein, the parameter value according to caused by generates test result, comprising:
Generated parameter value is sampled;
Test result is generated according to the parameter value sampled out.
4. according to the method described in claim 3, wherein, the target time section included at least two sub- periods;And
It is described that generated parameter value is sampled, comprising:
The quantity of the parameter value generated when the request message that client is sent in statistical disposition each sub- period;
According to the quantity and pre-set sampling proportion counted, from the request for handling client transmission in each sub- period
Parameter value is extracted in the parameter value generated when message.
5. according to the method described in claim 1, wherein, the test request includes at least two for realizing same function
The identification information of program segment to be measured;And
The request message that client is sent in the program segment processing target period to be measured indicated by the identification information,
Include:
The request message that client in target time section is sent is distributed to the program segment to be measured that each identification information indicates and is carried out
Processing.
6. method according to any one of claims 1-5, wherein the parameter value according to caused by generates test knot
Fruit, comprising:
Generated parameter value is sent to target device;
Obtain target device return with the associated markup information of generated parameter value;
Test result is generated according to acquired markup information.
7. according to the method described in claim 6, wherein, in the program segment to be measured including for realizing preparatory training introductory die
The program for the first model that type obtains;And
After the markup information according to acquired in generates test result, the method also includes:
The second model is obtained using the machine learning method training initial model based on acquired markup information.
8. described to utilize machine learning method instruction based on acquired markup information according to the method described in claim 7, wherein
Practice the initial model and obtain the second model, comprising:
Markup information in the acquired markup information of screening with predefined negative markup information type matching;
By the markup information filtered out, with the associated request message of markup information that filters out and with the markup information that filters out
Associated parameter value is determined as negative sample data;
It is spaced at predetermined time intervals, based on the negative sample data determined in the time interval, utilizes machine learning method training
The initial model obtains the second model.
9. according to the method described in claim 8, wherein, the method also includes:
Based at least one of following test set, generate the achievement data of second model: pre-set test set is gone through
The test set of history negative sample data composition;
In response to generated achievement data and it is preset be used to indicate the achievement data commensurate in scope that passes through of test, pass through described the
The request message that two model treatment clients are sent.
10. a kind of test device, comprising:
Receiving unit, for receiving test request, wherein the test request includes identification information and the test of program segment to be measured
The parameter name of parameter;
First processing units, client is sent out in the program segment processing target period to be measured for being indicated by the identification information
The request message sent;
Acquiring unit, the parameter value of the test parameter generated when for obtaining according to the parameter name and handle the request message;
Generation unit, for generating test result according to generated parameter value.
11. a kind of electronic equipment, comprising:
One or more processors;
Storage device, for storing one or more programs;
When one or more of programs are executed by one or more of processors, so that one or more of processors
Realize the method as described in any in claim 1-9.
12. a kind of computer readable storage medium, is stored thereon with computer program, realized such as when which is executed by processor
Any method in claim 1-9.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711458320.1A CN109976997B (en) | 2017-12-28 | 2017-12-28 | Test method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711458320.1A CN109976997B (en) | 2017-12-28 | 2017-12-28 | Test method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109976997A true CN109976997A (en) | 2019-07-05 |
CN109976997B CN109976997B (en) | 2022-12-27 |
Family
ID=67074586
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201711458320.1A Active CN109976997B (en) | 2017-12-28 | 2017-12-28 | Test method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109976997B (en) |
Cited By (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111045919A (en) * | 2019-07-12 | 2020-04-21 | 华控清交信息科技(北京)有限公司 | Method, device, background server, storage medium and system for debugging program |
CN111045918A (en) * | 2019-07-12 | 2020-04-21 | 华控清交信息科技(北京)有限公司 | Method, device, client, storage medium and system for debugging program |
CN111061623A (en) * | 2019-07-12 | 2020-04-24 | 华控清交信息科技(北京)有限公司 | Method, device, middle platform server, storage medium and system for debugging program |
CN111625473A (en) * | 2020-07-01 | 2020-09-04 | 北京字节跳动网络技术有限公司 | Interface test case generation method and device, storage medium and electronic equipment |
CN111901310A (en) * | 2020-07-06 | 2020-11-06 | 北京达佳互联信息技术有限公司 | Website security testing method and device, electronic equipment and storage medium |
CN112241160A (en) * | 2020-10-20 | 2021-01-19 | 广州小鹏汽车科技有限公司 | Vehicle testing method and device, vehicle detection system and test board card |
CN112346425A (en) * | 2020-11-20 | 2021-02-09 | 宜宾市极米光电有限公司 | Factory automation test method, system, projection equipment and storage medium |
CN113472458A (en) * | 2021-06-30 | 2021-10-01 | 珠海泰芯半导体有限公司 | Method, device, equipment, storage medium and system for testing performance of wireless equipment |
WO2023045209A1 (en) * | 2021-09-27 | 2023-03-30 | Medtrum Technologies Inc. | Analyte detection device and detection method |
CN117149551A (en) * | 2023-10-30 | 2023-12-01 | 鹰驾科技(深圳)有限公司 | Test method of vehicle-mounted wireless communication chip |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5390325A (en) * | 1992-12-23 | 1995-02-14 | Taligent, Inc. | Automated testing system |
CN103019902A (en) * | 2012-12-13 | 2013-04-03 | 中国航空无线电电子研究所 | Automatic testing device and automatic testing method of ARINC 429 bus signal performance parameters |
CN104022913A (en) * | 2013-12-18 | 2014-09-03 | 深圳市腾讯计算机系统有限公司 | Test method and device for data cluster |
CN104035869A (en) * | 2014-06-19 | 2014-09-10 | 科大讯飞股份有限公司 | Application evaluation method, terminal, and server |
CN104424093A (en) * | 2013-08-26 | 2015-03-18 | 阿里巴巴集团控股有限公司 | Compatibility testing method and system |
CN105099988A (en) * | 2014-04-24 | 2015-11-25 | 阿里巴巴集团控股有限公司 | Method used for supporting gray releasing, access method, devices and system |
WO2017071369A1 (en) * | 2015-10-31 | 2017-05-04 | 华为技术有限公司 | Method and device for predicting user unsubscription |
CN107194427A (en) * | 2017-05-26 | 2017-09-22 | 温州大学 | A kind of milling cutter malfunction monitoring and recognition methods and system |
-
2017
- 2017-12-28 CN CN201711458320.1A patent/CN109976997B/en active Active
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5390325A (en) * | 1992-12-23 | 1995-02-14 | Taligent, Inc. | Automated testing system |
CN103019902A (en) * | 2012-12-13 | 2013-04-03 | 中国航空无线电电子研究所 | Automatic testing device and automatic testing method of ARINC 429 bus signal performance parameters |
CN104424093A (en) * | 2013-08-26 | 2015-03-18 | 阿里巴巴集团控股有限公司 | Compatibility testing method and system |
CN104022913A (en) * | 2013-12-18 | 2014-09-03 | 深圳市腾讯计算机系统有限公司 | Test method and device for data cluster |
CN105099988A (en) * | 2014-04-24 | 2015-11-25 | 阿里巴巴集团控股有限公司 | Method used for supporting gray releasing, access method, devices and system |
CN104035869A (en) * | 2014-06-19 | 2014-09-10 | 科大讯飞股份有限公司 | Application evaluation method, terminal, and server |
WO2017071369A1 (en) * | 2015-10-31 | 2017-05-04 | 华为技术有限公司 | Method and device for predicting user unsubscription |
CN107194427A (en) * | 2017-05-26 | 2017-09-22 | 温州大学 | A kind of milling cutter malfunction monitoring and recognition methods and system |
Cited By (18)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111045918A (en) * | 2019-07-12 | 2020-04-21 | 华控清交信息科技(北京)有限公司 | Method, device, client, storage medium and system for debugging program |
CN111061623A (en) * | 2019-07-12 | 2020-04-24 | 华控清交信息科技(北京)有限公司 | Method, device, middle platform server, storage medium and system for debugging program |
CN111045919A (en) * | 2019-07-12 | 2020-04-21 | 华控清交信息科技(北京)有限公司 | Method, device, background server, storage medium and system for debugging program |
CN111045918B (en) * | 2019-07-12 | 2023-09-22 | 华控清交信息科技(北京)有限公司 | Method, device, client, storage medium and system for debugging program |
CN111045919B (en) * | 2019-07-12 | 2023-08-22 | 华控清交信息科技(北京)有限公司 | Method, device, background server, storage medium and system for debugging program |
CN111061623B (en) * | 2019-07-12 | 2023-08-22 | 华控清交信息科技(北京)有限公司 | Method, device, middle server, storage medium and system for debugging program |
CN111625473B (en) * | 2020-07-01 | 2023-08-22 | 北京字节跳动网络技术有限公司 | Interface test case generation method and device, storage medium and electronic equipment |
CN111625473A (en) * | 2020-07-01 | 2020-09-04 | 北京字节跳动网络技术有限公司 | Interface test case generation method and device, storage medium and electronic equipment |
CN111901310A (en) * | 2020-07-06 | 2020-11-06 | 北京达佳互联信息技术有限公司 | Website security testing method and device, electronic equipment and storage medium |
CN112241160B (en) * | 2020-10-20 | 2022-02-11 | 广州小鹏汽车科技有限公司 | Vehicle testing method and device, vehicle detection system and test board card |
CN112241160A (en) * | 2020-10-20 | 2021-01-19 | 广州小鹏汽车科技有限公司 | Vehicle testing method and device, vehicle detection system and test board card |
CN112346425A (en) * | 2020-11-20 | 2021-02-09 | 宜宾市极米光电有限公司 | Factory automation test method, system, projection equipment and storage medium |
CN112346425B (en) * | 2020-11-20 | 2024-01-16 | 宜宾市极米光电有限公司 | Factory automation testing method, system, projection equipment and storage medium |
CN113472458A (en) * | 2021-06-30 | 2021-10-01 | 珠海泰芯半导体有限公司 | Method, device, equipment, storage medium and system for testing performance of wireless equipment |
CN113472458B (en) * | 2021-06-30 | 2023-09-26 | 珠海泰芯半导体有限公司 | Radio frequency performance test method, device, storage medium and system |
WO2023045209A1 (en) * | 2021-09-27 | 2023-03-30 | Medtrum Technologies Inc. | Analyte detection device and detection method |
CN117149551A (en) * | 2023-10-30 | 2023-12-01 | 鹰驾科技(深圳)有限公司 | Test method of vehicle-mounted wireless communication chip |
CN117149551B (en) * | 2023-10-30 | 2024-02-09 | 鹰驾科技(深圳)有限公司 | Test method of vehicle-mounted wireless communication chip |
Also Published As
Publication number | Publication date |
---|---|
CN109976997B (en) | 2022-12-27 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109976997A (en) | Test method and device | |
CN109460513B (en) | Method and apparatus for generating click rate prediction model | |
CN107832468B (en) | Demand recognition methods and device | |
CN109325541A (en) | Method and apparatus for training pattern | |
CN108520324A (en) | Method and apparatus for generating information | |
CN107944481A (en) | Method and apparatus for generating information | |
CN108805594A (en) | Information-pushing method and device | |
CN108989882A (en) | Method and apparatus for exporting the snatch of music in video | |
CN106484766B (en) | Searching method and device based on artificial intelligence | |
CN109492160A (en) | Method and apparatus for pushed information | |
CN109254917B (en) | Method and apparatus for test data flow system | |
CN110457476A (en) | Method and apparatus for generating disaggregated model | |
CN110929136A (en) | Personalized recommendation method and device | |
CN108182472A (en) | For generating the method and apparatus of information | |
CN110020162A (en) | User identification method and device | |
CN109299477A (en) | Method and apparatus for generating text header | |
CN109711733A (en) | For generating method, electronic equipment and the computer-readable medium of Clustering Model | |
CN108062416B (en) | Method and apparatus for generating label on map | |
CN109284342A (en) | Method and apparatus for output information | |
CN109785072A (en) | Method and apparatus for generating information | |
CN109190123A (en) | Method and apparatus for output information | |
CN109002385A (en) | Method for testing pressure and device for data flow system | |
CN108573054A (en) | Method and apparatus for pushed information | |
CN110473042A (en) | For obtaining the method and device of information | |
CN109614549B (en) | Method and apparatus for pushed information |
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 |