CN110196804A - The test method and device of business, storage medium, electronic device - Google Patents
The test method and device of business, storage medium, electronic device Download PDFInfo
- Publication number
- CN110196804A CN110196804A CN201810375217.9A CN201810375217A CN110196804A CN 110196804 A CN110196804 A CN 110196804A CN 201810375217 A CN201810375217 A CN 201810375217A CN 110196804 A CN110196804 A CN 110196804A
- Authority
- CN
- China
- Prior art keywords
- business
- case
- test
- service environment
- abnormal patterns
- 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
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Hardware Design (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Debugging And Monitoring (AREA)
Abstract
The invention discloses a kind of test methods of business and device, storage medium, electronic device.Wherein, this method comprises: obtaining test request, test request carries out operational trials to the first business in the service environment being configured under the first abnormal patterns for requesting;In response to test request, the first test case corresponding with the first abnormal patterns is searched, the first test case is used to configure the first abnormal patterns for the operational mode of service environment;The first abnormal patterns are configured by the operational mode of service environment by executing the first test case;Operational trials is carried out to the first business in the service environment being configured under the first abnormal patterns, and obtains in service environment the test information of generation when to the progress operational trials of the first business.The present invention solves the higher technical problem of time cost tested in the related technology business.
Description
Technical field
The present invention relates to internet areas, test method and device, storage medium in particular to a kind of business,
Electronic device.
Background technique
Abnormality test is an important component of software test, especially the condition in the rapid development of current internet
Under, it is desirable that abnormality test can sufficiently be surveyed for various abnormal conditions various under complicated Distributed Application scene
Examination improves test accuracy rate and coverage rate, and then improves system reliability.It can be seen that how to carry out abnormality test with non-
Often important meaning.
In the related art, it in order to accurately carry out abnormality test to software, hardware, tends to rely on code compilation and beats
Stake is inserted into fault statistics code in code, achievees the purpose that test by driving piles to code.So that whenever needs pair
When one new hardware or software are tested, it is necessary to rewrite test code, increase write with compilation time cost,
To which the time cost and the human cost that ultimately increase test are higher.
For above-mentioned problem, currently no effective solution has been proposed.
Summary of the invention
The embodiment of the invention provides a kind of test methods of business and device, storage medium, electronic device, at least to solve
The higher technical problem of time cost that certainly business is tested in the related technology.
According to an aspect of an embodiment of the present invention, a kind of test method of business is provided, comprising: obtain test and ask
It asks, test request carries out operational trials to the first business in the service environment being configured under the first abnormal patterns for requesting;
In response to test request, the first test case corresponding with the first abnormal patterns is searched, the first test case is used for business ring
The operational mode in border is configured to the first abnormal patterns;The operational mode of service environment is configured to by executing the first test case
First abnormal patterns;Operational trials is carried out to the first business in the service environment being configured under the first abnormal patterns, and is obtained
The test information of generation when in service environment to the progress operational trials of the first business.
According to another aspect of an embodiment of the present invention, a kind of test device of business is additionally provided, comprising: first obtains list
Member, for obtaining test request, test request is for requesting in the service environment being configured under the first abnormal patterns to first
Business carries out operational trials;Searching unit, for searching the first test corresponding with the first abnormal patterns in response to test request
Use-case, the first test case are used to configure the first abnormal patterns for the operational mode of service environment;Configuration unit, for passing through
It executes the first test case and configures the first abnormal patterns for the operational mode of service environment;Second acquisition unit, for matching
It is set in the service environment under the first abnormal patterns and operational trials is carried out to the first business, and obtain in service environment to first
Business carries out the test information of generation when operational trials.
According to another aspect of an embodiment of the present invention, a kind of storage medium is additionally provided, which includes storage
Program, program execute above-mentioned method when running.
According to another aspect of an embodiment of the present invention, it additionally provides a kind of electronic device, including memory, processor and deposits
The computer program that can be run on a memory and on a processor is stored up, processor executes above-mentioned side by computer program
Method.
In embodiments of the present invention, when obtaining test request, corresponding with the first abnormal patterns reusable the is searched
One test case configures the first abnormal patterns for the operational mode of service environment by executing the first test case;It is configuring
To carry out operational trials to the first business in the service environment under the first abnormal patterns, and obtains and pass through execution in service environment
The test information of generation is used in entire test process when first business use-case to carry out operational trials to the first business
The first test case and the first business use-case be edit in advance it is reusable, in other words, do not have to every time test when it is equal
New test case and business use-case are updated, it is higher to can solve the time cost tested in the related technology to business
The technical issues of, and then reach the technical effect for improving testing efficiency.
Detailed description of the invention
The drawings described herein are used to provide a further understanding of the present invention, constitutes part of this application, this hair
Bright illustrative embodiments and their description are used to explain the present invention, and are not constituted improper limitations of the present invention.In the accompanying drawings:
Fig. 1 is the schematic diagram of the hardware environment of the test method of business according to an embodiment of the present invention;
Fig. 2 is a kind of flow chart of the test method of optional business according to an embodiment of the present invention;
Fig. 3 is a kind of schematic diagram of the test case of optional business according to an embodiment of the present invention;
Fig. 4 is a kind of schematic diagram of the exceptional interface of optional business according to an embodiment of the present invention;
Fig. 5 is a kind of schematic diagram of the test method of optional business according to an embodiment of the present invention;
Fig. 6 is a kind of schematic diagram of the abnormal restoring of optional business according to an embodiment of the present invention;
Fig. 7 is a kind of schematic diagram of the test result of optional business according to an embodiment of the present invention;
Fig. 8 is a kind of schematic diagram of the test result of optional business according to an embodiment of the present invention;
Fig. 9 is a kind of schematic diagram of the test device of optional business according to an embodiment of the present invention;
And
Figure 10 is a kind of structural block diagram of terminal according to an embodiment of the present invention.
Specific embodiment
In order to enable those skilled in the art to better understand the solution of the present invention, below in conjunction in the embodiment of the present invention
Attached drawing, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described embodiment is only
The embodiment of a part of the invention, instead of all the embodiments.Based on the embodiments of the present invention, ordinary skill people
The model that the present invention protects all should belong in member's every other embodiment obtained without making creative work
It encloses.
It should be noted that description and claims of this specification and term " first " in above-mentioned attached drawing, "
Two " etc. be to be used to distinguish similar objects, without being used to describe a particular order or precedence order.It should be understood that using in this way
Data be interchangeable under appropriate circumstances, so as to the embodiment of the present invention described herein can in addition to illustrating herein or
Sequence other than those of description is implemented.In addition, term " includes " and " having " and their any deformation, it is intended that cover
Cover it is non-exclusive include, for example, the process, method, system, product or equipment for containing a series of steps or units are not necessarily limited to
Step or unit those of is clearly listed, but may include be not clearly listed or for these process, methods, product
Or other step or units that equipment is intrinsic.
Firstly, the part noun or term that occur during the embodiment of the present invention is described are suitable for as follows
It explains:
Ambient condition inspection: with the presence or absence of abnormal setting in inspection environment, for example be provided with IPTABLES etc., IPTABLES
It is the integrated IP packet filtration system of linux kernel, if linux system is connected to internet or LAN, server, or even
Connect the proxy server of LAN and internet, then the system be conducive to preferably to control on linux system IP packet filtration and
Firewall configuration.
Abnormal scene build: in the environment according to scene build exception, for example setting db is read-only, network is unavailable, network
Delay etc.
Abnormal restoring: the contrary operation of abnormal scene build.
Abnormality test library: the service exception scene set of existing net failure or important abnormal scene is accumulated.
One side according to an embodiment of the present invention provides a kind of embodiment of the method for the test method of business.
Optionally, in the present embodiment, the test method of above-mentioned business can be applied to as shown in Figure 1 by the second equipment
In 101 hardware environment constituted, optionally, which may also include the first equipment 103, as shown in Figure 1, the second equipment
101 are attached by network with the first equipment 103, data can be arranged in the second equipment 101 or independently of the second equipment 101
Library 105, for providing data storage service for the second equipment 101, above-mentioned network includes but is not limited to: wide area network, Metropolitan Area Network (MAN) or
Local area network, above equipment (such as the second equipment 101 or the first equipment 103) are not limited to PC, mobile phone, tablet computer, intelligence electricity
Depending on, desktop computer, server etc..The test method of the business of the embodiment of the present invention can be executed by the second equipment 101, and first
The test method that equipment 103 executes the business of the embodiment of the present invention is also possible to be executed by client mounted thereto.
Fig. 2 is a kind of flow chart of the test method of optional business according to an embodiment of the present invention, as shown in Fig. 2, should
Method may comprise steps of:
Step S202, the second equipment obtain test request, and test request is for requesting in the case where being configured to the first abnormal patterns
Service environment in the first business carry out operational trials.
Step S204, the second equipment search the first test case corresponding with the first abnormal patterns in response to test request,
First test case is used to configure the first abnormal patterns for the operational mode of service environment.
It is alternatively possible to pre-establish abnormality test library (i.e. first set), what preservation write in the first aggregate can
The test case of multiplexing accumulates the service exception scene set of existing net failure or important abnormal scene.
Step S206, by the operational mode of service environment to configure first different by executing the first test case for the second equipment
Norm formula.
I.e. by executing the first test case come structural anomaly scene, in the environment according to scene build exception, test is used
Example is a kind of business scenario use-case, for example, quick payment, remaining sum payment etc., abnormal such as setting quick payment, the number of remaining sum payment
According to library db is read-only, network is unavailable, network delay etc..
Step S208, the instruction of the second equipment carry out the first business in the service environment being configured under the first abnormal patterns
Operational trials, and the test information of generation when to the progress operational trials of the first business is obtained in service environment.
It is alternatively possible to operational trials namely abnormality test are carried out by executing the corresponding business use-case of the first business,
The purpose of abnormality test is in order to test some abnormal conditions for being difficult to cover, if program is subdivided into logic unit
Combination, the purpose of test is exactly to change the trend of logic by a variety of different approach (data or code) to test difference
Abnormal conditions.
Above-mentioned business use-case is one group of test input, execution condition and the expected results worked out for some target, with
Just it tests some Program path or verifies and whether meet some demand, business use-case can be the exception point in normal operation flow
In branch, such as simulation quick payment process, access database db is abnormal, and business needs to carry out specially treated to abnormal at this time.
In the above-described embodiments, it is said so that the test method of the business of the application is executed by the second equipment 101 as an example
It is bright, receive test request, the equipment that carries out operational trials can be the second equipment, it in other words, can be directly local
Second equipment is triggered and is tested;Optionally, test request is received, the equipment of progress operational trials can set for difference
Standby, such as the second equipment receives test request, tests according to the request of the test request the first equipment namely the application
The test method of business can also be and executed jointly by the second equipment 101 and the first equipment 103.
S202 to step S208 through the above steps is searched corresponding with the first abnormal patterns when obtaining test request
Reusable first test case configures the first abnormal mould for the operational mode of service environment by executing the first test case
Formula;Operational trials is carried out to the first business in the service environment being configured under the first abnormal patterns, and is obtained in service environment
In by execute the first business use-case come to the first business carry out operational trials when generation test information, in entire test process
In, used first test case and the first business use-case are to edit in advance reusable, in other words, are not had to each
New test case and business use-case are updated when test, can solve the time tested in the related technology business
The technical issues of higher cost, and then reach the technical effect for improving testing efficiency.
In the technical solution that step S202 is provided, the second equipment obtains test request, and test request is being matched for requesting
It is set in the service environment under the first abnormal patterns and operational trials is carried out to the first business.
The operational trials of the application can be performed locally, in other words, can be directly in equipment in need of test
Test request is triggered, such as triggers test request on the second device.
The operational trials of the application can execute on the remote server, and remote server proposes various businesses testing service
User is supplied, user can select the failure environment needed in remote server (i.e. the second equipment) and test industry accordingly
Business, to trigger above-mentioned test request.
In the technical solution that step S204 is provided, the second equipment is searched and the first abnormal patterns in response to test request
Corresponding first test case, the first test case are used to configure the first abnormal patterns for the operational mode of service environment.
Test case in the related technology may be implemented to test without architecture operation, and in the technical solution of the application
The architecture operation of use-case, such as before searching the first test case corresponding with the first abnormal patterns, creation includes multiple surveys
The first set of example is tried out, includes the first test case in multiple test cases.After creating first set, timing can be passed through
Device triggers the test case that above-mentioned test request carrys out pull-up service exception, carries out the test of batch service and tracks operation, and
And can real-time servicing use-case completeness and correctness.
It optionally, include the first collection of multiple test cases in creation in order to enrich test case library (i.e. first set)
After conjunction: can be operated in the database to test case in a manner of database manipulation, receive the first addition instruction
In the case where, the indicated test case of the first addition instruction is added, in the first aggregate to supplement new test case;It is connecing
In the case where receiving the first modification instruction, the test case indicated to the first modification instruction is modified in the first aggregate,
Such as increase the configuration of new demand, modification mistake;In the case where receiving the first deletion instruction, delete the in first set
One deletes the indicated test case of instruction, and the test case being such as no longer required can delete.
In embodiments herein, lookup the first test case corresponding with the first abnormal patterns includes: can be from survey
The first keyword for indicating the first abnormal patterns is obtained in examination request;Then it is searched from the database where first set
With the first test case of the first keyword match, multiple test cases are preserved in first set, multiple test cases include
First test case.
In the technical solution that step S206 is provided, the second equipment is by executing the first test case for the fortune of service environment
Row pattern configurations are the first abnormal patterns.
It should be noted that anomalous structure can be generated and be influenced each other in related art scheme, if on a machine
Surface construction does not restore extremely, such as the network provided with machine A to machine B is unavailable, if not by abnormal restoring, this
All business of a machine all can be impacted, in order to overcome the problem, in above-described embodiment, by executing the first test case
When configuring the first abnormal patterns for the operational mode of service environment, the locating operational mode of service environment can detecte;?
In the case where detecting that the locating operational mode of service environment is not abnormal patterns, by executing the first test case for industry
The operational mode of business environment is configured to the first abnormal patterns, and the exception before avoiding impacts this test.
Optionally, the technical solution of the application can be logical by refining the classification of abnormal scene building method for general-purpose interface
Abnormal use-case set can be formed (such as the first set including test case and/or the including business use-case second collection with interface
Close), also directly directly constructed from web page, the operational mode of service environment is configured by executing the first test case
When for the first abnormal patterns, general-purpose interface can obtain the access information of service environment, and access information is used to indicate service environment institute
The first equipment, such as IP address, the MAC Address of the first equipment;Access information is filled into the first test case, and is led to
It crosses the first test case of execution and configures the first abnormal patterns for the operational mode of service environment in the first equipment, it is seen that this Shen
Business use-case please is general use-case, and the access information for inserting equipment to be tested is only needed when needing to test business
(or being suction parameter).
In the above-described embodiments, a kind of optionally by executing the first test case for service environment in the first equipment
The embodiment that operational mode is configured to the first abnormal patterns includes at least one of:
1) the second equipment sends the first instruction to the first equipment by executing the process in the first test case, by the
One instruction is to configure the hardware of the first equipment, such as chained address, link interface;
2) the second equipment sends the second instruction to the first equipment by executing the process in the first test case, by the
It is configured in the service environment of two instruction instructions on the first device, such as distorts and service into packet and go out packet, environment parameter;
3) third instruction is sent to the second equipment by executing the process in the first test case, is referred to by third
Show and configured on the second device, can configure the hardware environment and software environment in the second equipment, the second equipment is and the
There are the equipment of communication connection, specific settings can attack to disconnect with the link of two equipment, to the transmission of the second equipment for one equipment
It hits packet, stop providing service etc. for the second equipment.
In the above-described embodiments, complicated abnormal scene build may be implemented, such as network packet is distorted, and unification is provided
Interface encapsulation provides the ability of unified call, and abnormal scene can be executed directly, is low using difficulty, is conducive to Automation Construction, efficiency
It is high.
In the technical solution that step S208 is provided, the second equipment is in the service environment being configured under the first abnormal patterns
Operational trials is carried out to the first business, and the test for obtaining generation when carrying out operational trials to the first business in service environment is believed
Breath.
Abnormal scene build and business use-case are mixed in together in the related technology, if it is desired to rapid expansion business use-case, needs
Rewrite use-case;And service exception automation is only write and is used in demand test, no architecture operation causes use-case long
Do not have to and fail long.In order to overcome the above problem, the business use-case of the application is to separate, and can quickly expand with test case
Business use-case, and architecture operation are filled, business is carried out to the first business in the service environment being configured under the first abnormal patterns
Before test, business use-case library (i.e. second set) can be pre-created.
It, can be in the following way to business use-case in order to optimize management to second set, rapid expansion business use-case
Library is managed: in the case where receiving the second addition instruction, is added indicated by the second addition instruction in second set
Business use-case;In the case where receiving the second modification instruction, the business indicated to the second modification instruction in second set
Use-case is modified;In the case where receiving second deleting instruction, delete in second set indicated by second deleting instruction
Business use-case.
Optionally, after establishing above-mentioned second set, in the service environment being configured under the first abnormal patterns
Operational trials is carried out to the first business can include: the second keyword for indicating the first business is obtained from test request;From
The first business use-case with the second keyword match is searched in second set, wherein preserve multiple business in second set and use
Example, multiple business use-cases include the first business use-case;By the first business use-case being executed in service environment come to the first business
Carry out operational trials.
Optionally, the first above-mentioned business can be multiple, by executed in service environment the first business use-case come pair
It includes being carried out as follows test that first business, which carries out operational trials:
1) by being performed simultaneously (or parallel execution) multiple first business use-cases in service environment, simultaneously to first
Business carries out operational trials, and the first business use-case is identical as the quantity of the first business, and each first business use-case is used for corresponding
First business carry out operational trials;
2) multiple first business use-cases are executed in service environment according to the acquisition sequence of multiple first business use-cases, with right
Multiple first business carry out operational trialss, in other words, for the first equipment or the second equipment, the first business for first receiving
Use-case is first performed, and correspondingly, which is first tested, and the first business that evening receives is used
It is performed after example;
3) multiple first business use-cases are executed in service environment according to the first precedence information, to multiple first business
Carry out operational trials, the priority configured with each business use-case in second set in the first precedence information, for example, the second collection
In conjunction, it is configured with corresponding priority for each business use-case in advance, the priority of configuration can be stored in the first priority letter
In breath, it can be inquired in second set one by one when the first equipment or the second equipment receive above-mentioned multiple first business use-cases
Then the priority of each first business use-case executes the first business use-case according to the sequence of priority from high to low one by one;
4) it other than can be according to the priority for configuring each business use-case in second set in advance, be being tested
When, user oneself can also configure the priority of this multiple first business use-case, for the first equipment or the second equipment, user
There may be in the second precedence information, the first equipment or the second equipment can exist the priority of configuration according to the second precedence information
Multiple first business use-cases are executed in service environment, to carry out operational trials to multiple first business, the second precedence information is
The information of the priority for indicating multiple first business indicated to the first equipment or the second equipment.
If abnormal scene is to be configured, in public environment without restoring abnormal in time or restoring abnormal failure, can
The execution for influencing all use-cases, in the technical solution of the application, on case designing, to one industry of abnormal scene constitution realization
Operation closed loop in business use-case forms abnormal self-recovery, during so that the anomalous effects time is shorten to abnormal use-case execution, can lead to
Following several detection modes are crossed to realize:
1) data information in the first equipment of timing acquisition in database indicates the operation mould of service environment in data information
In the case that formula is the second abnormal patterns and does not revert to normal mode, executes corresponding with the second test case first and restore to use
The operational mode of service environment is reverted to normal mode by example, wherein the second test case is for configuring service environment to
Second abnormal patterns, can be in business system by daily O&M persistence maintenance use-case by service exception automation use-case timing pull-up
It is efficient to construct service exception automatic test, maximize service exception use-case value when system abnormality test, discovery system deep layer
Secondary failure bug;
2) if it is detected that locating for service environment before configuring the first abnormal patterns for the operational mode of service environment
Operational mode be third abnormal patterns, then execute the second recovery use-case corresponding with third test case for service environment
Operational mode reverts to normal mode, wherein third test case is used to configure third abnormal patterns for service environment;
It, will if 3) occur the case where configuration failure when configuring the first abnormal patterns for the operational mode of service environment
The operational mode of service environment reverts to normal mode;
4) it in the case where completing the operational trials to the first business, executes third corresponding with the first test case and restores
The operational mode of service environment is reverted to normal mode by use-case.
In the above-described embodiments, it realizes abnormal scene build to be encapsulated as automating respectively by Exception Type, be formed abnormal
Use-case set (i.e. first set), abnormal test case and business use-case quickly generate service exception use using modularized design
Example, service exception use-case pollute the environment when executing, and restore the abnormal operation in environment using automatic Restoration Mechanism, finally by industry
The abnormal use-case normalization operation of business and maintenance form a service exception test library that can directly execute, the abnormal use-case of long-actingization
Value.
As a kind of optional embodiment, the technical solution of the application is described in detail below with more specifically embodiment.
Abnormal use-case is for structural anomaly scene.For example the case where constructing a kind of network delay is needed, Fig. 3 can be used
Shown in use-case, may specify that source machine and purpose machine, delay time etc., operation use-case can simulate the exception in use-case,
User is not required to it is to be understood that how specific network delay constructs.
The application extracts encapsulation to abnormal scene build by technological means, is encapsulated as difference respectively by Exception Type
Automation use-case, while environmental test, abnormal scene build, abnormal restoring being supported to form abnormal use-case set, reaches efficient
Carry out the purpose of efficient operational trials.
A kind of exceptional interface that Fig. 4 shows the application is encapsulated as the method for automating use-case, abnormal scene build in Fig. 4
The process for being encapsulated as automation use-case specifically includes that
Step 1, access layer provides calling according to different abnormal scenes respectively, and the user for automating use-case can only need
Suction parameter is provided, and does not have to the specific implementation for being concerned about abnormal logic layer etc..
Step 2, after unified call interface receives request, according to different abnormal scenes, different operations is executed respectively, than
When such as requesting to carry out network delay test, Telnet machine, exectorial atomic operation are executed;Or request carries out network
When altering packet test, executes Telnet machine, deployment program, executes the atomic operations such as order.
Above-mentioned execution order can be the orders such as start-stop process, deletion shared drive;Deployment program can be in remote machine
Device removes installation plug-in card program, such as installs plug-in unit on the first device.
From fig. 4, it can be seen that the construction of abnormal scene is fully transparent to outer layer, using simple, while being encapsulated as automating
It after use-case, can directly execute, not need the specific implementation details for understanding anomalous structure, it is simple and fast.
The application uses modularization programming thought, as shown in figure 5, by abnormal use-case (or test case) and business use-case
Realize that abnormal use-case and business use-case are completely isolated as standalone module, the advantage of doing so is that, abnormal use-case only carries out different
Often construction, business use-case carry out business logic processing.Lower coupling, high cohesion between module and module.Abnormal use-case is made simultaneously
Gather for one, business use-case is gathered as one.It only needs to draw abnormal use-case set and business when service exception use-case is write
Writing for use-case can be rapidly completed in use-case in use-case set.
The process of service exception test automation design is as follows:
Step 1, ambient condition inspection pulls the ambient condition inspection in abnormal use-case set, whether judges current environment
There are anomalous structure record, with determine test environment be it is normal or abnormal, abnormal restoring is then carried out if abnormal, if normally then
It performs the next step rapid.
Step 2, abnormal scene build pulls the abnormal scene build in abnormal use-case set, carries out anomalous structure.Setting
After success, test environment will become an abnormal environment.
Step 3, business use-case is executed, the business use-case in business use-case set is pulled, business execution is carried out, at this time one
Business is executed in a abnormal environment, hooks can be gone to, to achieve the purpose that service exception is tested.
Step 4, abnormal expected results inspection after business use-case runs succeeded, checks the result of business use-case, sentences
Whether disconnected hooks logic is correct.The effect of detection is the correctness for guaranteeing use-case and executing, this is data examination
A part.
Step 5, abnormal restoring carries out abnormal restoring after the completion of use-case executes, and is health status by environment restoration.It is abnormal
Restore the contrary operation for being regarded as construction, is such as reconfigured, this is a kind of fairly simple recovery, it may be possible to instauration net
Network, recovery abnormal data etc..
In abnormal automatic recovery, the application is using the try-catch model in code programming, certainly to abnormal scene build
It is dynamic to restore, realize that anomalous structure is lossless to environment.It can achieve a large amount of abnormal use-cases in this way to execute, and keep compared with high success rate,
Be independent of each other between use-case, if without this mechanism, abnormal use-case can only single execute or be performed a plurality of times unstable result.This
The value of sample automation use-case extremely is given a discount significantly, and maintenance cost can also be got higher.Above-mentioned a large amount of abnormal use-cases refer to a timing
In, in the same environment, execute multiple abnormal use-cases.
From fig. 6, it can be seen that abnormal restoring reaches the ability restored automatically using dual pledge system.
In real-time link, after use-case starts, the exception of any one of use-case implementation procedure link failure all can be by
It captures, after construction failure, execution interface call when such as detecting environmental abnormality, abnormal scene build in ambient condition inspection
Deng carrying out abnormal restoring, avoid not being resumed so as to cause abnormal scene build in the failure of any one node, reach abnormal
The ability of self-recovery, then use-case terminates.It, then can be by bypass link if still restoring failure in abnormal restoring
Mechanism restored.
In bypass link, in such a way that timed task pulls, triggering monitoring programme pulls the number of anomalous structure record
According to if there is anomalous structure is not resumed, then there are anomalous structure data in database db, can carry out abnormal restoring again at this time.
As shown in fig. 7, after the completion of the construction of the abnormal use-case of service availability, it can be by the technical solution application of the application
The link of the fund security involved in payment link such as plans " service security-authentication verification-short message authentication " that ID is 250248
Link, abnormal use-case can also be added to timing batch and run, and safeguard daily success rate.These abnormal use-cases, in daily version
Use-case formation abnormality test library can be directly used simultaneously or constantly supplemented in this.Abnormal use-case modular simultaneously
It can be opened to and, directly be used for other business team, maximise the value of abnormal use-case, it is that part is different that Fig. 8, which is shown,
The batch operating condition of common example, such as always using number of cases is 209, and total success rate is 92.34% etc..
This use the application technical solution, can be applied to by Network Abnormal construct service exception automate use-case, its
Use-case set can be carried out to continue construction, dynamic is perfect by continuous supplementary service scene use-case.
It should be noted that for the various method embodiments described above, for simple description, therefore, it is stated as a series of
Combination of actions, but those skilled in the art should understand that, the present invention is not limited by the sequence of acts described because
According to the present invention, some steps may be performed in other sequences or simultaneously.Secondly, those skilled in the art should also know
It knows, the embodiments described in the specification are all preferred embodiments, and related actions and modules is not necessarily of the invention
It is necessary.
Through the above description of the embodiments, those skilled in the art can be understood that according to above-mentioned implementation
The method of example can be realized by means of software and necessary general hardware platform, naturally it is also possible to by hardware, but it is very much
In the case of the former be more preferably embodiment.Based on this understanding, technical solution of the present invention is substantially in other words to existing
The part that technology contributes can be embodied in the form of software products, which is stored in a storage
In medium (such as ROM/RAM, magnetic disk, CD), including some instructions are used so that a terminal device (can be mobile phone, calculate
Machine, server or network equipment etc.) execute method described in each embodiment of the present invention.
Other side according to an embodiment of the present invention additionally provides a kind of for implementing the test method of above-mentioned business
The test device of business.Fig. 9 is a kind of schematic diagram of the test device of optional business according to an embodiment of the present invention, such as Fig. 9
It is shown, the apparatus may include:
First acquisition unit 901, for obtaining test request, wherein test request is for requesting to be configured to first different
Operational trials is carried out to the first business in service environment under norm formula;
Searching unit 903, for searching the first test case corresponding with the first abnormal patterns in response to test request,
Wherein, the first test case is used to configure the first abnormal patterns for the operational mode of service environment;
Configuration unit 905, it is different for configuring first for the operational mode of service environment by the first test case of execution
Norm formula;
Second acquisition unit 907, for being carried out in the service environment being configured under the first abnormal patterns to the first business
Operational trials, and the test information of generation when to the progress operational trials of the first business is obtained in service environment.
It should be noted that the first acquisition unit 901 in the embodiment can be used for executing in the embodiment of the present application
Step S202, the searching unit 903 in the embodiment can be used for executing the step S204 in the embodiment of the present application, the embodiment
In configuration unit 905 can be used for executing the step S206 in the embodiment of the present application, the second acquisition unit in the embodiment
907 can be used for executing the step S208 in the embodiment of the present application.
Herein it should be noted that above-mentioned module is identical as example and application scenarios that corresponding step is realized, but not
It is limited to above-described embodiment disclosure of that.It should be noted that above-mentioned module as a part of device may operate in as
In hardware environment shown in FIG. 1, hardware realization can also be passed through by software realization.
By above-mentioned module, when obtaining test request, searches corresponding with the first abnormal patterns reusable first and survey
Example on probation configures the first abnormal patterns for the operational mode of service environment by executing the first test case;It is being configured to
Operational trials is carried out to the first business in service environment under one abnormal patterns, and is obtained in service environment by executing first
Business use-case to carry out the first business the test information of generation when operational trials, in entire test process, used the
One test case and the first business use-case be edit in advance it is reusable, in other words, do not have to every time test when again
New test case and business use-case are edited, can solve the higher skill of time cost tested in the related technology business
Art problem, and then reach the technical effect for improving testing efficiency.
Above-mentioned searching unit can include: first obtains module, for being obtained from test request for indicating that first is different
First keyword of norm formula;First searching module is surveyed for searching from first set with the first of the first keyword match
Example on probation, wherein multiple test cases are preserved in first set, multiple test cases include the first test case.
Optionally, the device of the application may also include that the first creating unit, for corresponding with the first abnormal patterns in lookup
The first test case before, creation include multiple test cases first set.
Optionally, the device of the application may also include that the first administrative unit, for including multiple test cases in creation
After first set, in the case where receiving the first addition instruction, added indicated by the first addition instruction in the first aggregate
Test case;In the case where receiving the first modification instruction, the survey indicated to the first modification instruction in the first aggregate
Example on probation is modified;In the case where receiving the first deletion instruction, delete in first set indicated by the first deletion instruction
Test case.
Above-mentioned configuration unit can include: detection module, for detecting the locating operational mode of service environment;First executes
Module, for being surveyed by executing first in the case where detecting the locating operational mode of service environment is not abnormal patterns
The operational mode of service environment is configured the first abnormal patterns by example on probation.
The first above-mentioned execution module can also be used in: obtain the access information of service environment, wherein access information is for referring to
Show the first equipment where service environment;Access information is filled into the first test case, and is used by executing the first test
The operational mode of service environment in the first equipment is configured the first abnormal patterns by example.
Optionally, the first above-mentioned execution module can also be used in: by executing the process in the first test case come to the
One equipment sends the first instruction, wherein the first instruction, which is used to indicate, configures the first equipment;It is used by executing the first test
Process in example to send the second instruction to the first equipment, wherein the second instruction is used to indicate business ring on the first device
It is configured in border;Third instruction is sent to the second equipment by executing the process in the first test case, wherein third refers to
Order is used to indicate to be configured on the second device, and the second equipment is that there are the equipment of communication connection with the first equipment.
Above-mentioned second acquisition unit can include: second obtains module, for obtaining from test request for indicating the
Second keyword of one business;Second searching module, for searching the first industry with the second keyword match from second set
Business use-case, wherein multiple business use-cases are preserved in second set, multiple business use-cases include the first business use-case;Second holds
Row module, for carrying out operational trials to the first business by executing the first business use-case in service environment.
Optionally, above-mentioned first business is multiple, wherein the second execution module can also be used in: by service environment
Multiple first business use-cases are performed simultaneously, to carry out operational trials to the first business simultaneously, wherein each first business use-case is used
In to the progress operational trials of corresponding first business;According to the acquisition sequence of multiple first business use-cases in service environment
Multiple first business use-cases are executed, to carry out operational trials to multiple first business;According to the first precedence information in business ring
Multiple first business use-cases are executed in border, to carry out operational trials to multiple first business, wherein match in the first precedence information
It is equipped with the priority of each business use-case in second set;Multiple first are executed in service environment according to the second precedence information
Business use-case, to carry out operational trials to multiple first business, wherein the second precedence information is the use indicated to the first equipment
In the information for the priority for indicating multiple first business.
The device of the application may also include that the second creating unit, for creating second set.
Optionally, the device of the application may also include that the second administrative unit, be used for: receive the second addition instruction
In the case of, the indicated business use-case of the second addition instruction is added in second set;In the feelings for receiving the second modification instruction
Under condition, the business use-case indicated to the second modification instruction is modified in second set;Receiving second deleting instruction
In the case where, delete business use-case indicated by second deleting instruction in second set.
Optionally, the device of the application may also include recovery unit, be used for: in the first equipment of timing acquisition in database
Data information indicates that the operational mode of service environment is the second abnormal patterns and the feelings for not reverting to normal mode in data information
Under condition, the first recovery use-case corresponding with the second test case is executed by the operational mode of service environment and reverts to normal mode
Formula, wherein the second test case is used to configure the second abnormal patterns for service environment;Match by the operational mode of service environment
It is set to before the first abnormal patterns if it is detected that the locating operational mode of service environment is third abnormal patterns, executes and the
The operational mode of service environment is reverted to normal mode by the corresponding second recovery use-case of three test cases, wherein third is surveyed
Example on probation is used to configure third abnormal patterns for service environment;If abnormal configuring first for the operational mode of service environment
Occur the case where configuration failure when mode, then the operational mode of service environment is reverted into normal mode;It completes to the first industry
In the case where the operational trials of business, executes third corresponding with the first test case and restore use-case for the operation mould of service environment
Formula reverts to normal mode.
It should be noted that anomalous structure can be generated and be influenced each other in related art scheme, if on a machine
Surface construction does not restore extremely, such as the network provided with machine A to machine B is unavailable, if not by abnormal restoring, this
All business of a machine all can be impacted, in order to overcome the problem, in above-described embodiment, by executing the first test case
When configuring the first abnormal patterns for the operational mode of service environment, the locating operational mode of service environment can detecte;?
In the case where detecting that the locating operational mode of service environment is not abnormal patterns, by executing the first test case for industry
The operational mode of business environment is configured to the first abnormal patterns, and the exception before avoiding impacts this test.
Optionally, the technical solution of the application can be logical by refining the classification of abnormal scene building method for general-purpose interface
Abnormal use-case set can be formed (such as the first set including test case and/or the including business use-case second collection with interface
Close), also directly directly constructed from web page, the operational mode of service environment is configured by executing the first test case
When for the first abnormal patterns, general-purpose interface can obtain the access information of service environment, and access information is used to indicate service environment institute
The first equipment, such as IP address, the MAC Address of the first equipment;Access information is filled into the first test case, and is led to
It crosses the first test case of execution and configures the first abnormal patterns for the operational mode of service environment in the first equipment, it is seen that this Shen
Business use-case please is general use-case, and the access information for inserting equipment to be tested is only needed when needing to test business
(or being suction parameter).
Herein it should be noted that above-mentioned module is identical as example and application scenarios that corresponding step is realized, but not
It is limited to above-described embodiment disclosure of that.It should be noted that above-mentioned module as a part of device may operate in as
In hardware environment shown in FIG. 1, hardware realization can also be passed through by software realization, wherein hardware environment includes network
Environment.
Other side according to an embodiment of the present invention additionally provides a kind of for implementing the test method of above-mentioned business
Server or terminal.
Figure 10 is a kind of structural block diagram of terminal according to an embodiment of the present invention, and as shown in Figure 10, which may include:
One or more (one is only shown in Figure 10) processors 1001, memory 1003 and (such as above-mentioned implementation of transmitting device 1005
Sending device in example), as shown in Figure 10, which can also include input-output equipment 1007.
Wherein, memory 1003 can be used for storing software program and module, such as the survey of the business in the embodiment of the present invention
Method for testing and the corresponding program instruction/module of device, the software journey that processor 1001 is stored in memory 1003 by operation
Sequence and module realize the test method of above-mentioned business thereby executing various function application and data processing.Memory
1003 may include high speed random access memory, can also include nonvolatile memory, as one or more magnetic storage device,
Flash memory or other non-volatile solid state memories.In some instances, memory 1003 can further comprise relative to processing
The remotely located memory of device 1001, these remote memories can pass through network connection to terminal.The example packet of above-mentioned network
Include but be not limited to internet, intranet, local area network, mobile radio communication and combinations thereof.
Above-mentioned transmitting device 1005 is used to that data to be received or sent via network, can be also used for processor with
Data transmission between memory.Above-mentioned network specific example may include cable network and wireless network.In an example,
Transmitting device 1005 includes a network adapter (Network Interface Controller, NIC), can pass through cable
It is connected with other network equipments with router so as to be communicated with internet or local area network.In an example, transmission dress
1005 are set as radio frequency (Radio Frequency, RF) module, is used to wirelessly be communicated with internet.
Wherein, specifically, memory 1003 is for storing application program.
The application program that processor 1001 can call memory 1003 to store by transmitting device 1005, it is following to execute
Step:
Obtain test request, wherein test request is for requesting in the service environment being configured under the first abnormal patterns
Operational trials is carried out to the first business;
In response to test request, the first test case corresponding with the first abnormal patterns is searched, wherein the first test case
For configuring the first abnormal patterns for the operational mode of service environment;
The first abnormal patterns are configured by the operational mode of service environment by executing the first test case;
Operational trials is carried out to the first business in the service environment being configured under the first abnormal patterns, and is obtained in business
The test information of generation when in environment to the progress operational trials of the first business.
Processor 1001 is also used to execute following step:
Data information in the first equipment of timing acquisition in database indicates the operational mode of service environment in data information
In the case where for the second abnormal patterns and not reverting to normal mode, the first recovery use-case corresponding with the second test case is executed
The operational mode of service environment is reverted into normal mode, wherein the second test case is used to configure service environment to the
Two abnormal patterns;
Before configuring the first abnormal patterns for the operational mode of service environment if it is detected that service environment it is locating
Operational mode is third abnormal patterns, then executes corresponding with third test case second and restore use-case for the fortune of service environment
Row pattern recovery is normal mode, wherein third test case is used to configure third abnormal patterns for service environment;
If there is the case where configuration failure when configuring the first abnormal patterns for the operational mode of service environment, by industry
The operational mode of business environment reverts to normal mode;
In the case where completing the operational trials to the first business, executes third corresponding with the first test case and restore to use
The operational mode of service environment is reverted to normal mode by example.
Using the embodiment of the present invention, when obtaining test request, corresponding with the first abnormal patterns reusable the is searched
One test case configures the first abnormal patterns for the operational mode of service environment by executing the first test case;It is configuring
To carry out operational trials to the first business in the service environment under the first abnormal patterns, and obtains and pass through execution in service environment
The test information of generation is used in entire test process when first business use-case to carry out operational trials to the first business
The first test case and the first business use-case be edit in advance it is reusable, in other words, do not have to every time test when it is equal
New test case and business use-case are updated, it is higher to can solve the time cost tested in the related technology to business
The technical issues of, and then reach the technical effect for improving testing efficiency.
Optionally, the specific example in the present embodiment can be with reference to example described in above-described embodiment, the present embodiment
Details are not described herein.
It will appreciated by the skilled person that structure shown in Fig. 10 is only to illustrate, terminal can be smart phone
(such as Android phone, iOS mobile phone), tablet computer, palm PC and mobile internet device (Mobile Internet
Devices, MID), the terminal devices such as PAD.Figure 10 it does not cause to limit to the structure of above-mentioned electronic device.For example, terminal is also
May include than shown in Figure 10 more perhaps less component (such as network interface, display device) or have and Figure 10 institute
Show different configurations.
Those of ordinary skill in the art will appreciate that all or part of the steps in the various methods of above-described embodiment is can
It is completed with instructing the relevant hardware of terminal device by program, which can store in a computer readable storage medium
In, storage medium may include: flash disk, read-only memory (Read-Only Memory, ROM), random access device (Random
Access Memory, RAM), disk or CD etc..
The embodiments of the present invention also provide a kind of storage mediums.Optionally, in the present embodiment, above-mentioned storage medium can
With the program code of the test method for executing business.
Optionally, in the present embodiment, above-mentioned storage medium can be located at multiple in network shown in above-described embodiment
On at least one network equipment in the network equipment.
Optionally, in the present embodiment, storage medium is arranged to store the program code for executing following steps:
S11 obtains test request, wherein test request is for requesting in the business ring being configured under the first abnormal patterns
Operational trials is carried out to the first business in border;
S12 searches the first test case corresponding with the first abnormal patterns in response to test request, wherein the first test
Use-case is used to configure the first abnormal patterns for the operational mode of service environment;
S13 configures the first abnormal patterns for the operational mode of service environment by executing the first test case;
S14 carries out operational trials to the first business in the service environment being configured under the first abnormal patterns, and obtains
The test information of generation when in service environment to the progress operational trials of the first business.
Optionally, storage medium is also configured to store the program code for executing following steps:
S21, the data information in the first equipment of timing acquisition in database indicate the operation of service environment in data information
In the case that mode is the second abnormal patterns and does not revert to normal mode, executes corresponding with the second test case first and restore
The operational mode of service environment is reverted to normal mode by use-case, wherein the second test case is for configuring service environment
For the second abnormal patterns;
S22, if it is detected that the institute of service environment before configuring the first abnormal patterns for the operational mode of service environment
The operational mode at place is third abnormal patterns, then executes corresponding with third test case second and restore use-case for service environment
Operational mode revert to normal mode, wherein third test case is used to by service environment configure third abnormal patterns;
S23, if there is the case where configuration failure when configuring the first abnormal patterns for the operational mode of service environment,
The operational mode of service environment is reverted into normal mode;
It is extensive to execute third corresponding with the first test case in the case where completing the operational trials to the first business by S24
It is multiplexed example and the operational mode of service environment is reverted into normal mode.
Optionally, the specific example in the present embodiment can be with reference to example described in above-described embodiment, the present embodiment
Details are not described herein.
Optionally, in the present embodiment, above-mentioned storage medium can include but is not limited to: USB flash disk, read-only memory (ROM,
Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or
The various media that can store program code such as CD.
The serial number of the above embodiments of the invention is only for description, does not represent the advantages or disadvantages of the embodiments.
If the integrated unit in above-described embodiment is realized in the form of SFU software functional unit and as independent product
When selling or using, it can store in above-mentioned computer-readable storage medium.Based on this understanding, skill of the invention
Substantially all or part of the part that contributes to existing technology or the technical solution can be with soft in other words for art scheme
The form of part product embodies, which is stored in a storage medium, including some instructions are used so that one
Platform or multiple stage computers equipment (can be personal computer, server or network equipment etc.) execute each embodiment institute of the present invention
State all or part of the steps of method.
In the above embodiment of the invention, it all emphasizes particularly on different fields to the description of each embodiment, does not have in some embodiment
The part of detailed description, reference can be made to the related descriptions of other embodiments.
In several embodiments provided herein, it should be understood that disclosed client, it can be by others side
Formula is realized.Wherein, the apparatus embodiments described above are merely exemplary, such as the division of the unit, and only one
Kind of logical function partition, there may be another division manner in actual implementation, for example, multiple units or components can combine or
It is desirably integrated into another system, or some features can be ignored or not executed.Another point, it is shown or discussed it is mutual it
Between coupling, direct-coupling or communication connection can be through some interfaces, the INDIRECT COUPLING or communication link of unit or module
It connects, can be electrical or other forms.
The unit as illustrated by the separation member may or may not be physically separated, aobvious as unit
The component shown may or may not be physical unit, it can and it is in one place, or may be distributed over multiple
In network unit.It can select some or all of unit therein according to the actual needs to realize the mesh of this embodiment scheme
's.
It, can also be in addition, the functional units in various embodiments of the present invention may be integrated into one processing unit
It is that each unit physically exists alone, can also be integrated in one unit with two or more units.Above-mentioned integrated list
Member both can take the form of hardware realization, can also realize in the form of software functional units.
The above is only a preferred embodiment of the present invention, it is noted that for the ordinary skill people of the art
For member, various improvements and modifications may be made without departing from the principle of the present invention, these improvements and modifications are also answered
It is considered as protection scope of the present invention.
Claims (15)
1. a kind of test method of business characterized by comprising
Obtain test request, wherein the test request is for requesting in the service environment being configured under the first abnormal patterns
Operational trials is carried out to the first business;
In response to the test request, the first test case corresponding with first abnormal patterns is searched, wherein described first
Test case is used to configure first abnormal patterns for the operational mode of the service environment;
First abnormal patterns are configured by the operational mode of the service environment by executing first test case;
Operational trials is carried out to first business in the service environment being configured under first abnormal patterns, and is obtained
The test information of generation when to first business progress operational trials is taken in the service environment.
2. the method according to claim 1, wherein searching the first test corresponding with first abnormal patterns
Use-case includes:
The first keyword for indicating first abnormal patterns is obtained from the test request;
First test case with first keyword match is searched from first set, wherein the first set
In preserve multiple test cases, the multiple test case includes first test case.
3. according to the method described in claim 2, it is characterized in that, being surveyed searching corresponding with first abnormal patterns first
Before example on probation, which comprises
Creation includes the first set of the multiple test case.
4. according to the method described in claim 3, it is characterized in that, including described the first of the multiple test case in creation
After set, the method also includes at least one of:
In the case where receiving the first addition instruction, added in the first set indicated by the first addition instruction
Test case;
In the case where receiving the first modification instruction, the survey indicated to the first modification instruction in the first set
Example on probation is modified;
In the case where receiving the first deletion instruction, the survey that the first deletion instruction is indicated described in the first set is deleted
Example on probation.
5. method as claimed in any of claims 1 to 4, which is characterized in that used by executing first test
Example configures first abnormal patterns for the operational mode of the service environment and includes:
Detect the locating operational mode of the service environment;
In the case where detecting the locating operational mode of the service environment is not abnormal patterns, by executing described first
The operational mode of the service environment is configured first abnormal patterns by test case.
6. according to the method described in claim 5, it is characterized in that, by executing first test case for the business
The operational mode of environment is configured to first abnormal patterns
Obtain the access information of the service environment, wherein the access information is used to indicate where the service environment
One equipment;
The access information is filled into first test case, by executing first test case for described the
The operational mode of the service environment is configured to first abnormal patterns in one equipment.
7. according to the method described in claim 6, it is characterized in that, by executing first test case for described first
It includes at least one of that the operational mode of the service environment, which is configured to first abnormal patterns, in equipment:
The first instruction is sent to first equipment by executing the process in first test case, wherein described the
One instruction, which is used to indicate, configures first equipment;
The second instruction is sent to first equipment by executing the process in first test case, wherein described the
Two instructions, which are used to indicate in the service environment on said first device, to be configured;
Third instruction is sent to the second equipment by executing the process in first test case, wherein the third refers to
Order is used to indicate to be configured in second equipment, and second equipment is that there are communication connections with first equipment
Equipment.
8. method as claimed in any of claims 1 to 4, which is characterized in that be configured to the described first abnormal mould
Carrying out operational trials to first business in the service environment under formula includes:
The second keyword for indicating first business is obtained from the test request;
The first business use-case with second keyword match is searched from second set, wherein protect in the second set
There are multiple business use-cases, the multiple business use-case includes the first business use-case;
Operational trials is carried out to first business by executing the first business use-case in the service environment.
9. according to the method described in claim 8, it is characterized in that, first business is multiple, wherein by the industry
The first business use-case is executed in business environment to include at least one of to first business progress operational trials:
By being performed simultaneously multiple first business use-cases in the service environment, simultaneously to multiple first business
Carry out operational trials, wherein each first business use-case is used to carry out business survey to corresponding one first business
Examination;
Multiple first business are executed in the service environment according to the acquisition sequence of multiple first business use-cases to use
Example, to carry out operational trials to multiple first business;
Multiple first business use-cases are executed in the service environment according to the first precedence information, to multiple described
One business carries out operational trials, wherein configured with each business use-case in the second set in first precedence information
Priority;
Multiple first business use-cases are executed in the service environment according to the second precedence information, to multiple described
One business carries out operational trials, wherein second precedence information is to be indicated to the first equipment for indicating multiple described
The information of the priority of first business.
10. according to the method described in claim 8, it is characterized in that, the method also includes at least one of:
In the case where receiving the second addition instruction, added in the second set indicated by the second addition instruction
Business use-case;
In the case where receiving the second modification instruction, the industry indicated to the second modification instruction in the second set
Business use-case is modified;
In the case where receiving second deleting instruction, industry indicated by second deleting instruction described in the second set is deleted
Business use-case.
11. the method according to claim 1, wherein the method also includes:
Data information in the first equipment of timing acquisition in database indicates the operation of the service environment in the data information
In the case that mode is the second abnormal patterns and does not revert to normal mode, executes corresponding with the second test case first and restore
The operational mode of the service environment is reverted to normal mode by use-case, wherein second test case is used for will be described
Service environment is configured to second abnormal patterns;
If it is detected that the service environment before configuring first abnormal patterns for the operational mode of the service environment
Locating operational mode is third abnormal patterns, then executes corresponding with third test case second and restore use-case for the industry
The operational mode of business environment reverts to normal mode, wherein the third test case is for configuring the service environment to
The third abnormal patterns;
If there is the case where configuration failure when configuring first abnormal patterns for the operational mode of the service environment,
The operational mode of the service environment is reverted into normal mode;
In the case where completing the operational trials to first business, it is extensive to execute third corresponding with first test case
It is multiplexed example and the operational mode of the service environment is reverted into normal mode.
12. a kind of test device of business characterized by comprising
First acquisition unit, for obtaining test request, wherein the test request is being configured to the first abnormal mould for requesting
Operational trials is carried out to the first business in service environment under formula;
Searching unit, for searching the first test case corresponding with first abnormal patterns in response to the test request,
Wherein, first test case is used to configure first abnormal patterns for the operational mode of the service environment;
Configuration unit, for configuring described for the operational mode of the service environment by executing first test case
One abnormal patterns;
Second acquisition unit, in the service environment being configured under first abnormal patterns to first business
Operational trials is carried out, and the test for obtaining generation when carrying out operational trials to first business in the service environment is believed
Breath.
13. device according to claim 12, which is characterized in that the searching unit includes:
First obtains module, for obtaining the first key for indicating first abnormal patterns from the test request
Word;
First searching module, for searching first test case with first keyword match from first set,
Wherein, multiple test cases are preserved in the first set, the multiple test case includes first test case.
14. a kind of storage medium, which is characterized in that the storage medium includes the program of storage, wherein when described program is run
Execute method described in 1 to 11 any one of the claims.
15. a kind of electronic device, including memory, processor and it is stored on the memory and can transports on the processor
Capable computer program, which is characterized in that the processor executes the claims 1 to 11 by the computer program
Method described in one.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810375217.9A CN110196804B (en) | 2018-04-24 | 2018-04-24 | Service testing method and device, storage medium and electronic device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810375217.9A CN110196804B (en) | 2018-04-24 | 2018-04-24 | Service testing method and device, storage medium and electronic device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN110196804A true CN110196804A (en) | 2019-09-03 |
CN110196804B CN110196804B (en) | 2022-03-11 |
Family
ID=67751063
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810375217.9A Active CN110196804B (en) | 2018-04-24 | 2018-04-24 | Service testing method and device, storage medium and electronic device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110196804B (en) |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111309627A (en) * | 2020-03-08 | 2020-06-19 | 苏州浪潮智能科技有限公司 | Method and system for preventing test conflict in software test |
CN112328498A (en) * | 2020-11-27 | 2021-02-05 | 京东数字科技控股股份有限公司 | Service testing method and device, storage medium and electronic device |
CN112988565A (en) * | 2021-01-25 | 2021-06-18 | 杭州衣科云科技有限公司 | Interface automation test method and device, computer equipment and storage medium |
CN113300912A (en) * | 2021-05-21 | 2021-08-24 | 湖南快乐阳光互动娱乐传媒有限公司 | Equipment testing method and device and electronic equipment |
CN114741274A (en) * | 2021-01-08 | 2022-07-12 | 腾讯科技(深圳)有限公司 | Abnormity testing method and device |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1866219A (en) * | 2005-12-09 | 2006-11-22 | 华为技术有限公司 | System and method for testing measured object based on automatic test script |
CN101212362A (en) * | 2006-12-26 | 2008-07-02 | 中兴通讯股份有限公司 | Automatic testing device and method incorporating a variety of testing tools |
WO2014082908A1 (en) * | 2012-11-28 | 2014-06-05 | Siemens Aktiengesellschaft | Method and apparatus for generating test case for fuzz test |
CN106021093A (en) * | 2016-05-05 | 2016-10-12 | 北京思特奇信息技术股份有限公司 | Test case reuse method and system |
CN107135390A (en) * | 2017-05-08 | 2017-09-05 | 湖南快乐阳光互动娱乐传媒有限公司 | The automated testing method and system of a kind of TV applications |
-
2018
- 2018-04-24 CN CN201810375217.9A patent/CN110196804B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1866219A (en) * | 2005-12-09 | 2006-11-22 | 华为技术有限公司 | System and method for testing measured object based on automatic test script |
CN101212362A (en) * | 2006-12-26 | 2008-07-02 | 中兴通讯股份有限公司 | Automatic testing device and method incorporating a variety of testing tools |
WO2014082908A1 (en) * | 2012-11-28 | 2014-06-05 | Siemens Aktiengesellschaft | Method and apparatus for generating test case for fuzz test |
CN106021093A (en) * | 2016-05-05 | 2016-10-12 | 北京思特奇信息技术股份有限公司 | Test case reuse method and system |
CN107135390A (en) * | 2017-05-08 | 2017-09-05 | 湖南快乐阳光互动娱乐传媒有限公司 | The automated testing method and system of a kind of TV applications |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111309627A (en) * | 2020-03-08 | 2020-06-19 | 苏州浪潮智能科技有限公司 | Method and system for preventing test conflict in software test |
CN111309627B (en) * | 2020-03-08 | 2022-11-29 | 苏州浪潮智能科技有限公司 | Method and system for preventing test conflict in software test |
CN112328498A (en) * | 2020-11-27 | 2021-02-05 | 京东数字科技控股股份有限公司 | Service testing method and device, storage medium and electronic device |
CN114741274A (en) * | 2021-01-08 | 2022-07-12 | 腾讯科技(深圳)有限公司 | Abnormity testing method and device |
CN112988565A (en) * | 2021-01-25 | 2021-06-18 | 杭州衣科云科技有限公司 | Interface automation test method and device, computer equipment and storage medium |
CN112988565B (en) * | 2021-01-25 | 2024-01-02 | 杭州衣科信息技术股份有限公司 | Interface automatic test method, device, computer equipment and storage medium |
CN113300912A (en) * | 2021-05-21 | 2021-08-24 | 湖南快乐阳光互动娱乐传媒有限公司 | Equipment testing method and device and electronic equipment |
Also Published As
Publication number | Publication date |
---|---|
CN110196804B (en) | 2022-03-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN110196804A (en) | The test method and device of business, storage medium, electronic device | |
CN109218139B (en) | Gateway test system | |
CN106528395B (en) | The generation method and device of test case | |
US10997063B1 (en) | System testing from production transactions | |
CN105095059B (en) | A kind of method and apparatus of automatic test | |
CN106326219B (en) | Method, device and system for checking business system data | |
CN102880532B (en) | Cloud technology-based test system and method | |
CN111831548B (en) | Dependency relationship topological graph drawing method and device | |
CN106302008A (en) | Data-updating method and device | |
CN107317695A (en) | Mthods, systems and devices for debugging network node Intranet failure | |
CN108363662A (en) | A kind of applied program testing method, storage medium and terminal device | |
CN105378493A (en) | Cloud based infrastructure for supporting protocol reconfigurations in protocol independent device testing systems | |
CN103178996A (en) | Distributed packet-switching chip model verification system and method | |
CN105450476A (en) | Regression test system and test method | |
CN108415820A (en) | The test method and device of application installation package | |
CN103530225A (en) | Automatic compilation testing method and automatic compilation testing platform for realizing same | |
CN110489324A (en) | Method, apparatus that test page jumps, storage medium, electronic device | |
CN103455313B (en) | Method and device for associating input information with output information of detected system | |
CN105912937A (en) | Root detection processing method and device, and terminal | |
CN111651352B (en) | Warehouse code merging method and device | |
CN103026337B (en) | The extraction of dispensing assembly and reconstruct | |
US20230246913A1 (en) | System and method for commissioning a network element | |
CN106528429A (en) | UI testing method and device | |
CN106204164A (en) | Method of testing that web advertisement presents and device | |
CN105045717B (en) | Test environment dispositions method, device and system |
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 |