CN109408304A - Block chain introduces test method, device, equipment and readable storage medium storing program for executing - Google Patents

Block chain introduces test method, device, equipment and readable storage medium storing program for executing Download PDF

Info

Publication number
CN109408304A
CN109408304A CN201811135647.XA CN201811135647A CN109408304A CN 109408304 A CN109408304 A CN 109408304A CN 201811135647 A CN201811135647 A CN 201811135647A CN 109408304 A CN109408304 A CN 109408304A
Authority
CN
China
Prior art keywords
interface
block chain
test
target
case
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201811135647.XA
Other languages
Chinese (zh)
Inventor
金慧智
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
OneConnect Smart Technology Co Ltd
Original Assignee
OneConnect Smart Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by OneConnect Smart Technology Co Ltd filed Critical OneConnect Smart Technology Co Ltd
Priority to CN201811135647.XA priority Critical patent/CN109408304A/en
Priority to PCT/CN2018/122717 priority patent/WO2020062639A1/en
Publication of CN109408304A publication Critical patent/CN109408304A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/22Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
    • G06F11/2273Test methods

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The present invention provides a kind of block chain introducing test method, comprising: when receiving the interface testing data of input, accesses set of tags according to the interface in the interface testing data, determines target generic interface and target block chain interface;According to the interface testing use-case in the interface testing data, the target generic interface and the target block chain interface are tested respectively;It according to the first test result information of the target generic interface and the second test result information of the target block chain interface, generates block chain and introduces report, and show that the block chain introduces report.The present invention also provides a kind of block chains to introduce test device, equipment and readable storage medium storing program for executing.The present invention can fast and accurately determine whether service server can introduce block chain technology, reduce time and human cost.

Description

Block chain introduces test method, device, equipment and readable storage medium storing program for executing
Technical field
The present invention relates to the technical field of block chain more particularly to a kind of block chain introduce test method, device, equipment and Readable storage medium storing program for executing.
Background technique
Block chain technology is that algorithm of knowing together with storing data, using distributed node is verified using block linked data structure Guarantee the safety of data transmission and access with more new data, in the way of cryptography, using by automatized script generation to generate The intelligent contract of code composition programs the completely new distributed basis framework and calculation of one kind with operation data.Due to block Chain technology have the characteristics that decentralization, can not tamper and Privacy Safeguarding, be therefore widely used in every field.
Different business scene has difference to the average response time of service server, handling capacity and request unnatural proportions etc. Requirement, in service server introduce block chain technology, although safety can be improved, exist influence service server The case where energy, such as average response time is elongated, handling capacity reduces or request unnatural proportions increase, and whether influences industry uncertain It is engaged in introducing block chain technology in the case where server performance, is easy to bring unpredictable problem to production, currently, mainly passing through Developer analyzes business demand, it is determined whether can introduce block chain technology, however developer can not be based on industry Business demand fast and accurately determines whether service server can introduce block chain technology, and needs to expend more time and people Power.
Therefore, how fast and accurately to determine whether service server can introduce block chain technology, reduce time and people Power cost is current urgent problem to be solved.
Summary of the invention
The main purpose of the present invention is to provide a kind of block chains to introduce test method, device, equipment and readable storage medium Matter, it is intended to how fast and accurately to determine whether service server can introduce block chain technology, reduce time and human cost.
To achieve the above object, the present invention provides a kind of block chain introducing test method, and the block chain introduces test side Method the following steps are included:
When receiving the interface testing data of input, set of tags is accessed according to the interface in the interface testing data, Determine target generic interface and target block chain interface;
According to the interface testing use-case in the interface testing data, respectively to the target generic interface and the target Block chain interface is tested;
Second test of the first test result information and the target block chain interface according to the target generic interface Result information generates block chain and introduces report, and shows that the block chain introduces report.
Optionally, set of tags is accessed according to the interface in the interface testing data, determines target generic interface and target The step of block chain interface includes:
Interface is read from the interface testing data and accesses set of tags, and is read and contained from interface access set of tags There are the first test interface label of the first preset field and the second test interface label containing the second preset field;
The corresponding interface of the first test interface label is determined as target generic interface, and second test is connect The corresponding interface of mouth label is determined as target block chain interface.
Optionally, according to the interface testing use-case in the interface testing data, respectively to the target generic interface and The step of target block chain interface is tested include:
Each interface testing use-case is read from the interface testing data, and suitable according to the execution of each interface testing use-case Sequence successively selects an interface testing use-case;
The access request of corresponding number is generated according to the interface testing use-case of selection, and is commonly connect by the target respectively Mouth and the target block chain interface, are transmitted to service server for each access request;
The interface of each access request according to service server return accesses as a result, calculating the target generic interface With each performance indicator of the target block chain interface under the interface testing use-case of selection;
Summarize each performance indicator of the target generic interface under each interface testing use-case, obtains the first test result letter Breath summarizes each performance indicator of the target block chain interface under each interface testing use-case, obtains the second test result information.
Optionally, according to the first test result information of the target generic interface and the target block chain interface Two test result informations, generating the step of block chain introduces report includes:
By each performance indicator in first test result information and each performance in second test result information Index carries out corresponding comparison, to obtain the first comparison result of each performance indicator;
Each performance indicator in second test result information is compared with corresponding preset threshold, to obtain Take the second comparison result of each performance indicator;
According to first comparison result and second comparison result, generates block chain and introduce report.
Optionally, set of tags is accessed according to the interface in the interface testing data, determines target generic interface and target After the step of block chain interface, further includes:
Each interface testing use-case is read from the interface testing data, and determines in database whether be stored with the mesh Mark historic test results information of the generic interface under each interface testing use-case;
If being stored with historic test results of the target generic interface under each interface testing use-case in database Information then tests the target block chain interface according to each interface testing use-case;
According to the test result information of the historic test results information and the target block chain interface, block chain is generated Report is introduced, and shows that the block chain introduces report.
Optionally, the target generic interface whether is stored in the determining database in each interface testing use-case Under historic test results information the step of include:
The use-case identification code of each interface testing use-case is obtained, and reads from the interface testing data and is preset containing first First test interface label of field;
The test result information for being marked with the first test interface label is read from database, and determines the test Whether result information is associated with the use-case identification code of each interface testing use-case;
If the test result information is associated with the use-case identification code of each interface testing use-case, it is determined that database In be stored with historic test results information of the target generic interface under each interface testing use-case.
Optionally, set of tags is accessed according to the interface in the interface testing data, determines target generic interface and target Before the step of block chain interface, further includes:
When receiving the interface testing data of input, determine in the interface testing data whether carry fixed time test Label;
If carrying fixed time test label in the interface testing data, determine reaching in the interface testing data When time point when, execute step: according in the interface testing data interface access set of tags, determine target generic interface and Target block chain interface;
If not carrying fixed time test label in the interface testing data, then follow the steps: according to the interface testing Interface in data accesses set of tags, determines target generic interface and target block chain interface.
In addition, to achieve the above object, the present invention also provides a kind of block chains to introduce test device, the block chain is introduced Test device includes:
Interface determining module, for when receiving the interface testing data of input, according in the interface testing data Interface access set of tags, determine target generic interface and target block chain interface;
Interface testing module, for according to the interface testing use-case in the interface testing data, respectively to the target Generic interface and the target block chain interface are tested;
Report generation module, for according to the target generic interface the first test result information and the target block Second test result information of chain interface generates block chain and introduces report, and shows that the block chain introduces report.
In addition, to achieve the above object, the present invention also provides a kind of block chains to introduce test equipment, the block chain is introduced Test equipment includes processor, memory and is stored in the block chain that can be executed on the memory and by the processor Test program is introduced, wherein realizing such as above-mentioned block chain when block chain introducing test program is executed by the processor The step of introducing test method.
In addition, to achieve the above object, the present invention also provides a kind of readable storage medium storing program for executing, being deposited on the readable storage medium storing program for executing It contains block chain and introduces test program, wherein realizing when block chain introducing test program is executed by processor as above-mentioned Block chain introduces the step of test method.
The present invention provides a kind of block chain and introduces test method, device, equipment and readable storage medium storing program for executing, and the present invention is when receiving To input interface testing data when, access set of tags according to the interface in interface testing data, determine target generic interface and Target block chain interface, and according to the interface testing use-case in interface testing data, respectively to target generic interface and target area Block chaining mouth is tested, then according to target generic interface the first test result information and target block chain interface second Test result information generates block chain and introduces report, and display block chain introduces report, and through the above scheme, developer is only It needs input interface test data that the automatic pressure test of corresponding block chain interface and generic interface can be realized, obtains two and connect The test result information of mouth, while automatically relatively, it obtains block chain and introduces report, developer passes through the introducing report of block chain can Fast and accurately to determine whether service server can introduce block chain technology, time and human cost are effectively reduced.
Detailed description of the invention
Fig. 1 is the hardware structural diagram that the block chain that various embodiments of the present invention are related to introduces test equipment;
Fig. 2 is the flow diagram that block chain of the present invention introduces test method first embodiment;
Fig. 3 is the flow diagram that block chain of the present invention introduces test method second embodiment;
Fig. 4 is the functional block diagram that block chain of the present invention introduces test device first embodiment.
The embodiments will be further described with reference to the accompanying drawings for the realization, the function and the advantages of the object of the present invention.
Specific embodiment
It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, it is not intended to limit the present invention.
The present embodiments relate to block chain introduce test method be mainly used in block chain introduce test equipment, the area Block chain, which introduces test equipment, can be the tool such as PC (personal computer personal computer), portable computer, mobile terminal There is the equipment of display and processing function.
Referring to Fig.1, Fig. 1 is the hardware configuration signal that block chain involved in the embodiment of the present invention introduces test equipment Figure.In the embodiment of the present invention, it may include (such as the central processing unit Central of processor 1001 that block chain, which introduces test equipment, Processing Unit, CPU), communication bus 1002, user interface 1003, network interface 1004, memory 1005.Wherein, Communication bus 1002 is for realizing the connection communication between these components;User interface 1003 may include display screen (Display), input unit such as keyboard (Keyboard);Network interface 1004 optionally may include that the wired of standard connects Mouth, wireless interface (such as WI-FI interface);Memory 1005 can be high speed RAM memory, be also possible to stable memory (non-volatile memory), such as magnetic disk storage, memory 1005 optionally can also be independently of aforementioned processor 1001 storage device.It will be understood by those skilled in the art that hardware configuration shown in Fig. 1 is not constituted to limit of the invention It is fixed, it may include perhaps combining certain components or different component layouts than illustrating more or fewer components.
With continued reference to Fig. 1, the memory 1005 in Fig. 1 as a kind of readable storage medium storing program for executing may include operating system, net Network communication module and block chain introduce test program.In Fig. 1, network communication module is mainly used for connecting server, with clothes Business device carries out data communication;And processor 1001 can call the block chain stored in memory 1005 to introduce test program, and It executes block chain provided in an embodiment of the present invention and introduces test method.
The embodiment of the invention provides a kind of block chains to introduce test method.
It is the flow diagram that block chain of the present invention introduces test method first embodiment referring to Fig. 2, Fig. 2.
In the present embodiment, which introduces test method and introduces test equipment realization by block chain, which introduces Test equipment can be the terminal devices such as PC, palm PC and tablet computer, be chosen as equipment shown in FIG. 1, the block chain Introduce test method the following steps are included:
Step S101 accesses mark according to the interface in interface testing data when receiving the interface testing data of input Label group determines target generic interface and target block chain interface;
Step S102, according to the interface testing use-case in interface testing data, respectively to target generic interface and target area Block chaining mouth is tested;
Step S103, the second test of the first test result information and target block chain interface according to target generic interface Result information generates block chain and introduces report, and display block chain introduces report.
Block chain technology is introduced in the server, although safety can be improved, there are the feelings for influencing server performance Condition, such as average response time is elongated, handling capacity reduces with or unnatural proportions is requested to increase, and whether influences business clothes uncertain Block chain technology is introduced in the case where device performance of being engaged in, is easy to bring unpredictable problem to production, currently, mainly passing through exploitation Personnel analyze business demand, it is determined whether can introduce block chain technology, however developer can not be needed based on business Ask fast and accurately determining service server whether can introduce block chain technology, and need to expend more time and manpower. In view of the above problem, propose that a kind of block chain introduces test method in the present embodiment, block chain described in detail below, which introduces, to be surveyed The specific steps of method for testing:
Step S101 accesses mark according to the interface in interface testing data when receiving the interface testing data of input Label group determines target generic interface and target block chain interface;
In the present embodiment, when receiving the input of interface testing data of tester instruction, display interface tests number According to input interface, it is defeated that the input interface of the interface testing data shows test interface option, Thread Count input frame, number of request Enter frame, testing time input frame and test case number input frame etc., tester can be based on the input of the interface testing data Interface input interface test data, i.e. test interface label, Thread Count, number of request, testing time and test case number etc..Its In, which includes but is not limited to interface access set of tags, interface testing use-case and testing time, and interface accesses Set of tags is made of the corresponding label of target generic interface and the corresponding label of target block chain interface, the interface testing use-case Including but not limited to Thread Count and number of request, the performance indicator of test include but is not limited to average response time, handling capacity and ask Seek error rate;The block chain interface be developer generic interface is transformed, in the server introduce block chain technology it Block chain interface afterwards brings unpredictable problem to production in order to prevent, needs the application interface to transformation, i.e. block chain Interface is tested, it is determined whether can introduce block chain technology.
In the present embodiment, when receiving the interface testing data of tester's input, according in the interface testing data Interface access set of tags, determine target generic interface and target block chain interface.Specifically, it is read from the interface testing data It takes interface to access set of tags, and reads the first test interface label containing the first preset field from interface access set of tags With the second test interface label containing the second preset field, the corresponding interface of the first test interface label is then determined as mesh Generic interface is marked, and the corresponding interface of the second test interface label is determined as target block chain interface.On it should be noted that Stating the first preset field and the second preset field can be configured by those skilled in the art based on actual conditions, the present embodiment pair This is not especially limited, and optionally, which is " common ", and the second preset field is " block chain ".
Further, the input interface of interface testing data also shows test sart point in time input frame, tester The settable test time started, after the test time started is arranged in tester, when completing the input of interface testing data, Fixed time test label is stamped to interface testing data.When receiving the interface testing data of input, the interface testing is first determined Fixed time test label whether is carried in data, if carrying fixed time test label in the interface testing data, is being reached When timing point in the interface testing data, set of tags is accessed according to the interface in the interface testing data, determines target Generic interface and target block chain interface, if not carrying fixed time test label in interface testing data, direct basis should Interface in interface testing data accesses set of tags, determines target generic interface and target block chain interface.
Step S102, according to the interface testing use-case in interface testing data, respectively to target generic interface and target area Block chaining mouth is tested;
In the present embodiment, equipment is after determining target generic interface and target block chain interface, according to interface testing number Interface testing use-case in respectively tests target generic interface and target block chain interface, i.e., from interface testing number Each interface testing use-case is read according to middle, and executes each interface testing use-case, is linked with test target generic interface and target block Mouthful.
Specifically, equipment reads each interface testing use-case from interface testing data, and according to each interface testing use-case Sequence is executed, an interface testing use-case is successively selected, the access of corresponding number is then generated according to the interface testing use-case of selection Request, and each access request is transmitted to by service server by the target generic interface and the target block chain interface respectively, And the interface access of each access request of service server return is received as a result, including generic interface access result and block chain Interface accesses response time and solicited status as a result, including but not limited to each access request;
Subsequently according to service server return each access request interface access as a result, calculate target generic interface and Each performance indicator of the target block chain interface under the interface testing use-case of selection is accessed according to generic interface as a result, calculating Each performance indicator of the target generic interface under the interface testing use-case of selection is accessed according to foundation block chain interface as a result, counting Each performance indicator of the calculation target block chain interface under the interface testing use-case of selection, including but not limited to average response time, The response time of each request is specially added by request error rate and handling capacity, and divided by number of request, to obtain average response Time, and statistics solicited status are the request number of error condition, and divided by number of request, to obtain request error rate;
Finally summarize each performance indicator of the target generic interface under each interface testing use-case, obtains the first test result letter Breath, and summarize each performance indicator of the target block chain interface under each interface testing use-case, obtain the second test result information. Wherein, the first test result information include but is not limited to target generic interface each test case under the first average response when Between, the first handling capacity and the first request error rate, the second test result information include but is not limited to each of target block chain interface The second average response time, the second handling capacity and the second request error rate under test case.
Step S103, the second test of the first test result information and target block chain interface according to target generic interface Result information generates block chain and introduces report, and display block chain introduces report.
In the present embodiment, equipment according to target generic interface the first test result information and target block chain interface the Two test result informations generate block chain and introduce report, and display block chain introduces report.Specifically, by the first test result Each performance indicator in information is referred to compared with each performance indicator in the second test result information correspond to obtaining each performance First average response time is compared with the second average response time, obtains average response by the first comparison result of target First handling capacity is compared by time comparison result with the second handling capacity, is obtained handling capacity comparison result, is requested mistake for first Accidentally rate is compared with the second request error rate, obtains request error rate comparison result;It then will be in the second test result information Each performance indicator be compared with corresponding preset threshold, to obtain the second comparison result of each performance indicator, i.e., will Second average response time is compared with default average response time, the second handling capacity is compared with preset throughputs, And the second request error rate is compared with default request error rate;It is last to compare knot according to the first comparison result and second Fruit generates block chain and introduces report, i.e., newly-built blank report, and the first comparison result and the second comparison result are filled to newly-built The corresponding position of blank report introduces report to generate block chain.
Further, block chain can also be obtained according to the second comparison result and introduce court verdict, i.e., if second is average Response time is higher than default average response time and the second handling capacity is higher than preset throughputs and the second request error rate is low In default request error rate, then can determine that block chain introduces court verdict is that can introduce;If in each performance indicator result Exception occur there are at least one performance indicator result, (the second average response time is gulped down higher than default average response time, second The amount of spitting is not located at preset throughputs section or the second request error rate is higher than default request error rate), then it can determine block It is that cannot introduce that chain, which introduces court verdict,.
It should be noted that above-mentioned default average response time, preset throughputs and default request error rate are by specific industry Scene of being engaged in determines that in specific implementation, which further includes service label, surveys in obtain target generic interface first After second test result information of test result information and target block chain interface, business mark is read from the interface testing data Label, and inquire the mapping table of the service label and each performance indicator threshold value that prestore, i.e., when service label is with average response Between threshold value, the mapping table of throughput threshold and request error rate threshold value, obtain the corresponding threshold value of each performance indicator, i.e., it is flat Equal response time threshold value, throughput threshold and request error rate threshold value, then determine whether the second average response time is lower than this Average response time threshold value determines whether the second handling capacity is higher than the throughput threshold and determines that the second request error rate is It is no to be lower than the request error rate threshold value.
In the present embodiment, the present invention is when receiving the interface testing data of input, according to connecing in interface testing data Mouth access set of tags, determines target generic interface and target block chain interface, and according to the interface testing in interface testing data Use-case respectively tests target generic interface and target block chain interface, and then first according to target generic interface is surveyed Second test result information of test result information and target block chain interface generates block chain and introduces report, and display block chain Introduce report, through the above scheme, developer only need input interface test data can be realized corresponding block chain interface and The automatic pressure of generic interface is tested, and obtains the test result information of two interfaces, while automatically relatively, obtains the introducing of block chain Report, developer, which introduces report by block chain, fast and accurately to determine whether service server can introduce block chain Technology effectively reduces time and human cost.
Further, referring to Fig. 3, it is based on above-mentioned first embodiment, block chain of the present invention is proposed and introduces test method Second embodiment, the difference with previous embodiment are, after step S101, which introduces test method further include:
Whether step S104 reads each interface testing use-case from interface testing data, and determines and be stored in database Historic test results information of the target generic interface under each interface testing use-case;
In the present embodiment, equipment reads each interface testing use-case from interface testing data, and determine in database whether It is stored with historic test results information of the target generic interface under each interface testing use-case.Specifically, each interface testing is obtained The use-case identification code of use-case, and the first test interface label containing the first preset field is read from the interface testing data, That is then the label of target generic interface reads the test result letter for being marked with the first test interface label from database Breath, and determine whether the test result information is associated with the use-case identification code of each interface testing use-case, if test result is believed Breath is associated with the use-case identification code of each interface testing use-case, it is determined that target generic interface is stored in database in each interface Historic test results information under test case.Wherein, which is used for unique identification interface testing use-case.
Step S105, if being stored with history test of the target generic interface under each interface testing use-case in database Result information then tests target block chain interface according to each interface testing use-case;
In the present embodiment, if being stored with history test of the target generic interface under each interface testing use-case in database Result information then only needs test target block chain interface, i.e., surveys according to each interface testing use-case to target block chain interface Examination.Further, if at least in the presence of the use-case identification code of an interface testing use-case and the test knot in each interface testing use-case Fruit information is not associated with, it is determined that the not stored history test knot for having target generic interface under each interface testing use-case in database Fruit information reads and closes with use-case identification code at this point, part historic test results information can be read from the test result information The test result information of connection, then determines pending interface testing use-case, i.e. use-case identification code is not related to test result information The interface testing use-case of connection, and target generic interface is tested according to pending interface testing use-case.
Step S106 generates block according to the test result information of historic test results information and target block chain interface Chain introduces report, and display block chain introduces report.
In the present embodiment, test result information of the equipment according to historic test results information and target block chain interface is raw It introduces and reports at block chain, and display block chain introduces report, i.e., by each performance indicator and mesh in historic test results information Each performance indicator marked in the test result information of block chain interface is compared, and the first comparison result is obtained, then by second Each performance indicator in test result information is compared with corresponding preset threshold, to obtain the second of each performance indicator Comparison result, it is last to generate block chain according to the first comparison result and the second comparison result and introduce report, and display block chain draws Enter report.
In the present embodiment, it is relevant whether the present invention is stored with after determining target generic interface, in validation database Historic test results information only needs if being stored with relevant historic test results information to test target block chain interface, Improve testing efficiency.
In addition, the embodiment of the present invention also provides a kind of block chain introducing test device.
It is the functional block diagram that block chain of the present invention introduces test device first embodiment referring to Fig. 4, Fig. 4.
It is virtual bench that block chain of the present invention, which introduces test device, is stored in block chain shown in Fig. 1 and introduces test equipment In memory 1005, the institute for introducing test program for realizing block chain is functional;When the interface testing data for receiving input When, set of tags is accessed according to the interface in the interface testing data, determines target generic interface and target block chain interface;According to According to the interface testing use-case in the interface testing data, respectively to the target generic interface and the target block chain interface It is tested;Second test of the first test result information and the target block chain interface according to the target generic interface Result information generates block chain and introduces report, and shows that the block chain introduces report.
Specifically, the block chain introduces test device and includes: in the present embodiment
Interface determining module 101, for when receiving the interface testing data of input, according to the interface testing data In interface access set of tags, determine target generic interface and target block chain interface;
Interface testing module 102, for according to the interface testing use-case in the interface testing data, respectively to the mesh Mark generic interface and the target block chain interface are tested;
Report generation module 103, for according to the target generic interface the first test result information and the target Second test result information of block chain interface generates block chain and introduces report, and shows that the block chain introduces report.
Further, the interface determining module 101 is also used to:
Interface is read from the interface testing data and accesses set of tags, and is read and contained from interface access set of tags There are the first test interface label of the first preset field and the second test interface label containing the second preset field;
The corresponding interface of the first test interface label is determined as target generic interface, and second test is connect The corresponding interface of mouth label is determined as target block chain interface.
Further, the interface testing module 102 is also used to:
Each interface testing use-case is read from the interface testing data, and suitable according to the execution of each interface testing use-case Sequence successively selects an interface testing use-case;
The access request of corresponding number is generated according to the interface testing use-case of selection, and is commonly connect by the target respectively Mouth and the target block chain interface, are transmitted to service server for each access request;
The interface of each access request according to service server return accesses as a result, calculating the target generic interface With each performance indicator of the target block chain interface under the interface testing use-case of selection;
Summarize each performance indicator of the target generic interface under each interface testing use-case, obtains the first test result letter Breath summarizes each performance indicator of the target block chain interface under each interface testing use-case, obtains the second test result information.
Further, the report generation module 103 is also used to:
By each performance indicator in first test result information and each performance in second test result information Index carries out corresponding comparison, to obtain the first comparison result of each performance indicator;
Each performance indicator in second test result information is compared with corresponding preset threshold, to obtain Take the second comparison result of each performance indicator;
According to first comparison result and second comparison result, generates block chain and introduce report.
Further, the block chain introduces test device further include:
Test result determining module for reading each interface testing use-case from the interface testing data, and determines number According to whether being stored with historic test results information of the target generic interface under each interface testing use-case in library;
The interface testing module 102 respectively connects if being also used to be stored with the target generic interface in database described Historic test results information under mouthful test case, then according to each interface testing use-case to the target block chain interface into Row test;
The report generation module 103 is also used to link according to the historic test results information and the target block The test result information of mouth generates block chain and introduces report, and shows that the block chain introduces and report.
Further, the test result determining module is also used to:
The use-case identification code of each interface testing use-case is obtained, and reads from the interface testing data and is preset containing first First test interface label of field;
The test result information for being marked with the first test interface label is read from database, and determines the test Whether result information is associated with the use-case identification code of each interface testing use-case;
If the test result information is associated with the use-case identification code of each interface testing use-case, it is determined that database In be stored with historic test results information of the target generic interface under each interface testing use-case.
Further, the block chain introduces test device further include:
Label determining module, for determining in the interface testing data when receiving the interface testing data of input Whether fixed time test label is carried;
The interface determining module 101, if being also used to carry fixed time test label in the interface testing data, When reaching the timing point in the interface testing data, set of tags is accessed according to the interface in the interface testing data, Determine target generic interface and target block chain interface;
The interface determining module 101, if being also used to not carry fixed time test label in the interface testing data, Set of tags is accessed according to the interface in the interface testing data, determines target generic interface and target block chain interface.
Wherein, the function that above-mentioned block chain is introduced into modules in test device, which is realized, introduces test side with above-mentioned block chain Each step is corresponding in method embodiment, and function and realization process no longer repeat one by one here.
In addition, the embodiment of the present invention also provides a kind of readable storage medium storing program for executing.
It is stored with block chain on readable storage medium storing program for executing of the present invention and introduces test program, wherein the block chain introduces test journey When sequence is executed by processor, the step of introducing test method such as above-mentioned block chain is realized.
Wherein, block chain introducing test program, which is performed realized method, can refer to block chain introducing test of the present invention Each embodiment of method, details are not described herein again.
It should be noted that, in this document, the terms "include", "comprise" or its any other variant are intended to non-row His property includes, so that the process, method, article or the system that include a series of elements not only include those elements, and And further include other elements that are not explicitly listed, or further include for this process, method, article or system institute it is intrinsic Element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that including being somebody's turn to do There is also other identical elements in the process, method of element, article or system.
The serial number of the above embodiments of the invention is only for description, does not represent the advantages or disadvantages of the embodiments.
Through the above description of the embodiments, those skilled in the art can be understood that above-described embodiment side Method can be realized by means of software and necessary general hardware platform, naturally it is also possible to by hardware, but in many cases The former is more preferably embodiment.Based on this understanding, technical solution of the present invention substantially in other words does the prior art The part contributed out can be embodied in the form of software products, which is stored in one as described above In storage medium (such as ROM/RAM, magnetic disk, CD), including some instructions are used so that terminal device (it can be mobile phone, Computer, server, air conditioner or network equipment etc.) execute method described in each embodiment of the present invention.
The above is only a preferred embodiment of the present invention, is not intended to limit the scope of the invention, all to utilize this hair Equivalent structure or equivalent flow shift made by bright specification and accompanying drawing content is applied directly or indirectly in other relevant skills Art field, is included within the scope of the present invention.

Claims (10)

1. a kind of block chain introduces test method, which is characterized in that the block chain introduce test method the following steps are included:
When receiving the interface testing data of input, set of tags is accessed according to the interface in the interface testing data, is determined Target generic interface and target block chain interface;
According to the interface testing use-case in the interface testing data, respectively to the target generic interface and the target block Chain interface is tested;
According to the first test result information of the target generic interface and the second test result of the target block chain interface Information generates block chain and introduces report, and shows that the block chain introduces report.
2. block chain as described in claim 1 introduces test method, which is characterized in that according in the interface testing data Interface accesses set of tags, and the step of determining target generic interface and target block chain interface includes:
Interface is read from the interface testing data and accesses set of tags, and is read from interface access set of tags and contained the First test interface label of one preset field and the second test interface label containing the second preset field;
The corresponding interface of the first test interface label is determined as target generic interface, and by the second test interface mark It signs corresponding interface and is determined as target block chain interface.
3. block chain as described in claim 1 introduces test method, which is characterized in that according in the interface testing data Interface testing use-case, the step of testing respectively the target generic interface and the target block chain interface include:
Each interface testing use-case is read from the interface testing data, and executes sequence according to each interface testing use-case, according to One interface testing use-case of secondary selection;
According to selection interface testing use-case generate corresponding number access request, and respectively by the target generic interface with Each access request is transmitted to service server by the target block chain interface;
The interface of each access request according to service server return accesses as a result, calculating the target generic interface and institute State each performance indicator of the target block chain interface under the interface testing use-case of selection;
Summarize each performance indicator of the target generic interface under each interface testing use-case, obtain the first test result information, Summarize each performance indicator of the target block chain interface under each interface testing use-case, obtains the second test result information.
4. block chain as described in claim 1 introduces test method, which is characterized in that the according to the target generic interface Second test result information of one test result information and the target block chain interface generates the step of block chain introduces report Include:
By each performance indicator in first test result information and each performance indicator in second test result information Corresponding comparison is carried out, to obtain the first comparison result of each performance indicator;
Each performance indicator in second test result information is compared with corresponding preset threshold, it is each to obtain Second comparison result of performance indicator;
According to first comparison result and second comparison result, generates block chain and introduce report.
5. as block chain of any of claims 1-4 introduces test method, which is characterized in that surveyed according to the interface After the step of trying the interface access set of tags in data, determining target generic interface and target block chain interface, further includes:
Each interface testing use-case is read from the interface testing data, and it is general whether to be stored with the target in determining database Connect historic test results information of the mouth under each interface testing use-case;
If being stored with historic test results information of the target generic interface under each interface testing use-case in database, Then the target block chain interface is tested according to each interface testing use-case;
According to the test result information of the historic test results information and the target block chain interface, generates block chain and introduce Report, and show that the block chain introduces report.
6. block chain as claimed in claim 5 introduces test method, which is characterized in that whether stored in the determining database The step of having historic test results information of the target generic interface under each interface testing use-case includes:
The use-case identification code of each interface testing use-case is obtained, and is read from the interface testing data and contains the first preset field The first test interface label;
The test result information for being marked with the first test interface label is read from database, and determines the test result Whether information is associated with the use-case identification code of each interface testing use-case;
If the test result information is associated with the use-case identification code of each interface testing use-case, it is determined that deposited in database Contain historic test results information of the target generic interface under each interface testing use-case.
7. as block chain of any of claims 1-4 introduces test method, which is characterized in that surveyed according to the interface Before the step of trying the interface access set of tags in data, determining target generic interface and target block chain interface, further includes:
When receiving the interface testing data of input, determine in the interface testing data whether carry fixed time test mark Label;
If carrying fixed time test label in the interface testing data, when reaching the timing in the interface testing data Between when putting, execute step: accessing set of tags according to the interface in the interface testing data, determine target generic interface and target Block chain interface;
If not carrying fixed time test label in the interface testing data, then follow the steps: according to the interface testing data In interface access set of tags, determine target generic interface and target block chain interface.
8. a kind of block chain introduces test device, which is characterized in that the block chain introduces test device and includes:
Interface determining module, for when receiving the interface testing data of input, according to connecing in the interface testing data Mouth access set of tags, determines target generic interface and target block chain interface;
Interface testing module, it is common to the target respectively for according to the interface testing use-case in the interface testing data Interface and the target block chain interface are tested;
Report generation module, for according to the target generic interface the first test result information and the target block link Second test result information of mouth generates block chain and introduces report, and shows that the block chain introduces and report.
9. a kind of block chain introduces test equipment, which is characterized in that it includes processor, storage that the block chain, which introduces test equipment, It device and is stored on the memory and test program can be introduced by the block chain that the processor executes, wherein the area When block chain introducing test program is executed by the processor, realize that the block chain as described in any one of claims 1 to 7 introduces The step of test method.
10. a kind of readable storage medium storing program for executing, which is characterized in that be stored with block chain on the readable storage medium storing program for executing and introduce test journey Sequence, wherein being realized as described in any one of claims 1 to 7 when block chain introducing test program is executed by processor Block chain introduces the step of test method.
CN201811135647.XA 2018-09-27 2018-09-27 Block chain introduces test method, device, equipment and readable storage medium storing program for executing Pending CN109408304A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201811135647.XA CN109408304A (en) 2018-09-27 2018-09-27 Block chain introduces test method, device, equipment and readable storage medium storing program for executing
PCT/CN2018/122717 WO2020062639A1 (en) 2018-09-27 2018-12-21 Blockchain introduction testing method and apparatus, device, and computer-readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811135647.XA CN109408304A (en) 2018-09-27 2018-09-27 Block chain introduces test method, device, equipment and readable storage medium storing program for executing

Publications (1)

Publication Number Publication Date
CN109408304A true CN109408304A (en) 2019-03-01

Family

ID=65465384

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811135647.XA Pending CN109408304A (en) 2018-09-27 2018-09-27 Block chain introduces test method, device, equipment and readable storage medium storing program for executing

Country Status (2)

Country Link
CN (1) CN109408304A (en)
WO (1) WO2020062639A1 (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110046091A (en) * 2019-03-12 2019-07-23 阿里巴巴集团控股有限公司 A kind of automatic test approach and device
CN110162470A (en) * 2019-04-28 2019-08-23 阿里巴巴集团控股有限公司 A kind of test method and device of block chain
CN111367813A (en) * 2020-03-17 2020-07-03 深圳市卡牛科技有限公司 Automatic testing method and device for decision engine, server and storage medium

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130117609A1 (en) * 2011-11-03 2013-05-09 Tata Consultancy Services Limited System and Method for Testing and Analyses of the Computer Applications
CN104516809A (en) * 2013-09-26 2015-04-15 方正宽带网络服务股份有限公司 Automated testing system and method
CN106598824A (en) * 2016-11-25 2017-04-26 深圳前海微众银行股份有限公司 Performance analysis method and device for block chain
CN107592238A (en) * 2017-08-07 2018-01-16 千寻位置网络有限公司 Automatic test approach and system, service terminal, the memory of interface
US20180075453A1 (en) * 2016-09-15 2018-03-15 American Express Travel Related Services Company, Inc. Systems and methods for blockchain based payment networks
US20180089072A1 (en) * 2016-09-23 2018-03-29 International Business Machines Corporation Automated testing of application program interface
US9934138B1 (en) * 2016-12-07 2018-04-03 International Business Machines Corporation Application testing on a blockchain
CN108170590A (en) * 2017-12-12 2018-06-15 北京大学深圳研究生院 A kind of test system and method for block catenary system
CN108304307A (en) * 2018-01-24 2018-07-20 深圳圣马歌科技有限公司 The method for testing performance of intelligent contract on a kind of block chain
CN108509337A (en) * 2018-03-15 2018-09-07 链家网(北京)科技有限公司 The dynamic testing method and device called based on interface

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TW200719140A (en) * 2005-11-04 2007-05-16 Hon Hai Prec Ind Co Ltd Automatic testing system and method
CN106991040B (en) * 2016-07-20 2020-05-05 平安科技(深圳)有限公司 Data interface testing method and device

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130117609A1 (en) * 2011-11-03 2013-05-09 Tata Consultancy Services Limited System and Method for Testing and Analyses of the Computer Applications
CN104516809A (en) * 2013-09-26 2015-04-15 方正宽带网络服务股份有限公司 Automated testing system and method
US20180075453A1 (en) * 2016-09-15 2018-03-15 American Express Travel Related Services Company, Inc. Systems and methods for blockchain based payment networks
US20180089072A1 (en) * 2016-09-23 2018-03-29 International Business Machines Corporation Automated testing of application program interface
CN106598824A (en) * 2016-11-25 2017-04-26 深圳前海微众银行股份有限公司 Performance analysis method and device for block chain
US9934138B1 (en) * 2016-12-07 2018-04-03 International Business Machines Corporation Application testing on a blockchain
CN107592238A (en) * 2017-08-07 2018-01-16 千寻位置网络有限公司 Automatic test approach and system, service terminal, the memory of interface
CN108170590A (en) * 2017-12-12 2018-06-15 北京大学深圳研究生院 A kind of test system and method for block catenary system
CN108304307A (en) * 2018-01-24 2018-07-20 深圳圣马歌科技有限公司 The method for testing performance of intelligent contract on a kind of block chain
CN108509337A (en) * 2018-03-15 2018-09-07 链家网(北京)科技有限公司 The dynamic testing method and device called based on interface

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
傅晓阳: "区块链技术应用探索", 《中国金融》 *
王成等: "区块链技术综述及铁路应用展望", 《中国铁路》 *

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110046091A (en) * 2019-03-12 2019-07-23 阿里巴巴集团控股有限公司 A kind of automatic test approach and device
CN110162470A (en) * 2019-04-28 2019-08-23 阿里巴巴集团控股有限公司 A kind of test method and device of block chain
CN110162470B (en) * 2019-04-28 2023-08-18 创新先进技术有限公司 Block chain testing method and device
CN111367813A (en) * 2020-03-17 2020-07-03 深圳市卡牛科技有限公司 Automatic testing method and device for decision engine, server and storage medium
CN111367813B (en) * 2020-03-17 2024-04-02 深圳市卡牛科技有限公司 Automatic testing method and device for decision engine, server and storage medium

Also Published As

Publication number Publication date
WO2020062639A1 (en) 2020-04-02

Similar Documents

Publication Publication Date Title
CN107894952A (en) Generation method, device, equipment and the readable storage medium storing program for executing of interface testing use-case
CN108090755A (en) Billing model defines method, data system for settling account and computer readable storage medium
CN107645562A (en) Data transmission processing method, device, equipment and system
CN108628748B (en) Automatic test management method and automatic test management system
CN109408304A (en) Block chain introduces test method, device, equipment and readable storage medium storing program for executing
CN105183630B (en) Applied program testing method and device
CN106326120B (en) Regression testing method and device for application software and electronic equipment
CN109684052A (en) Transaction analysis method, apparatus, equipment and storage medium
CN109062807B (en) Method and device for testing application program, storage medium and electronic device
CN107943697A (en) Problem distribution method, device, system, server and computer-readable storage medium
CN108536580A (en) Utilize the system and method for lightweight device authentication protocol test equipment
CN107577622A (en) Back end interface analogy method, equipment and storage medium
CN108170608A (en) Compatibility test method, test terminal and storage medium
CN109194689A (en) Abnormal behaviour recognition methods, device, server and storage medium
WO2020238965A1 (en) Production environment performance evaluation method and apparatus, and storage medium
CN109389492A (en) Method, system, equipment and the storage medium of probability of cheating are calculated based on micro- expression
CN110059002A (en) Generation method, test equipment, storage medium and the device of test data
CN110515755A (en) Interface function verification method, device, equipment and computer readable storage medium
CN108763051A (en) Electronic device, transaction software operation risk method for early warning and storage medium
CN107038120A (en) A kind of method for testing software and equipment
CN109739700A (en) A kind of interface test method and device
CN113448834A (en) Buried point testing method and device, electronic equipment and storage medium
CN108170600A (en) The coverage rate statistical method of front-end code test, apparatus and system
CN111078563A (en) Coverage rate data processing method, terminal device and computer readable storage medium
CN110502531A (en) Report data method of calibration, device, computer equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
REG Reference to a national code

Ref country code: HK

Ref legal event code: DE

Ref document number: 40001004

Country of ref document: HK

SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20190301

RJ01 Rejection of invention patent application after publication