CN109726111A - Test order customization method, unit and computer readable storage medium - Google Patents

Test order customization method, unit and computer readable storage medium Download PDF

Info

Publication number
CN109726111A
CN109726111A CN201810945137.2A CN201810945137A CN109726111A CN 109726111 A CN109726111 A CN 109726111A CN 201810945137 A CN201810945137 A CN 201810945137A CN 109726111 A CN109726111 A CN 109726111A
Authority
CN
China
Prior art keywords
test order
test
measured
order
information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201810945137.2A
Other languages
Chinese (zh)
Other versions
CN109726111B (en
Inventor
朱峰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ping An Puhui Enterprise Management Co Ltd
Original Assignee
Ping An Puhui Enterprise Management 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 Ping An Puhui Enterprise Management Co Ltd filed Critical Ping An Puhui Enterprise Management Co Ltd
Priority to CN201810945137.2A priority Critical patent/CN109726111B/en
Publication of CN109726111A publication Critical patent/CN109726111A/en
Application granted granted Critical
Publication of CN109726111B publication Critical patent/CN109726111B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The invention discloses a kind of test order customization method, test order customization method is the following steps are included: obtain the configuration information of test order;Object to be measured is obtained, according to object extraction to be measured content to be measured;Reflection measurement Regularia, to obtain the content information of test order;According to the configuration information and content information of test order, the content information of pending test order is obtained;Content to be measured is verified according to the content information of pending test order, and generates check results;Check results are written in test report, until the whole objects to be measured of traversal.The invention also discloses a kind of customized unit of test order and computer readable storage mediums.The simplicity that the present invention realizes test order is customized, improves the flexibility of test, improves testing efficiency.

Description

Test order customization method, unit and computer readable storage medium
Technical field
The present invention relates to the field of test technology more particularly to a kind of test order customization methods, unit and computer Readable storage medium storing program for executing.
Background technique
In order to improve the reliability of system, website etc., improves user experience, need to the related content in system, website It is tested.Before testing begins, specific test order is determined according to testing requirement, and corresponding test file is written In.During the test, content to be measured is verified according to the specific test order in test file, to meet test need It asks.However, testing requirement is not often unalterable, for example, in the test of website, it, may when being in Website development early stage It only needs to be tested for developed part website domain according to the specific test order in part, and is all developed in website After the completion, it needs to test whole website domains comprehensively for all specific test orders.Currently, test order is write in advance It in test file, when changing testing requirement, then needs to rewrite test file, to advise using different tests It is then tested, causes the flexibility of test poor, testing efficiency is low.
Above content is only used to facilitate the understanding of the technical scheme, and is not represented and is recognized that above content is existing skill Art.
Summary of the invention
The main purpose of the present invention is to provide a kind of test order customization methods, it is intended to solve above-mentioned testing requirement variation When need the technical issues of rewriting test file manually, to improve the flexibility of test, improve testing efficiency.
To achieve the above object, the present invention provides a kind of test order customization method, comprising the following steps:
Obtain the configuration information of test order;
Object to be measured is obtained, according to the object extraction content to be measured to be measured;
Reflection measurement Regularia, to obtain the content information of test order;
According to the configuration information and content information of the test order, the content information of pending test order is obtained;
The content to be measured is verified according to the content information of the pending test order, and generates check results;
The check results are written in test report, until the whole objects to be measured of traversal.
Preferably, the test order class includes test order parent and test order subclass, the test order parent It is regular to define common test, the customized test order of test order subclass definitions, and described in test order subclass succession Test order parent.
Preferably, in reflection measurement Regularia, the step of content information to obtain test order before, the test rule Then customization method is further comprising the steps of:
The test order parent is initialized, to obtain the content information of all common test rules;
The test order subclass is initialized, to obtain the content information of all customized test orders.
Preferably, the test order parent is being initialized, to obtain the step of the content information of all common test rules It is further comprising the steps of before rapid:
According to the configuration information of test order, test order parent is supplemented, to obtain updated test order parent; And/or
Initializing the test order subclass, the step of to obtain the content information of all customized test orders before, It is further comprising the steps of:
According to the configuration information of test order, test order subclass is supplemented, to obtain updated test order subclass.
Preferably, the step of obtaining the configuration information of test order include:
According to testing requirement, regular configuration file is obtained;
The regular configuration file is parsed, the configuration information of test order is obtained;
Wherein, the configuration information of the test order includes the switching information and directional information of test order, and described is opened It is corresponding with the testing requirement to close information.
Preferably, according to the configuration information and content information of the test order, the content of pending test order is obtained The step of information includes:
Obtain the switching information of test order;
When the switching information of the test order is to open, the directional information of the test order is obtained;
According to the directional information of the test order, the content letter of the test order is extracted from the test order class Breath, charges to the content information of pending test order.
Preferably, the object to be measured is based on chain table organization, and the data field of the chained list includes object to be measured, the chained list Pointer field include the pointer for being directed toward next object to be measured.
In addition, to achieve the above object, the present invention also proposes that a kind of customized equipment of test order, the test order are customized Equipment includes: memory, processor and is stored in the computer program that can be run on the memory and on the processor, The step of test order customization method is realized when the computer program is executed by the processor, the customized side of test order Method is the following steps are included: obtain the configuration information of test order;Object to be measured is obtained, it is to be measured interior according to the object extraction to be measured Hold;Reflection measurement Regularia, to obtain the content information of test order;Believed according to the configuration information of the test order and content Breath, obtains the content information of pending test order;It is described to be measured according to the content information verification of the pending test order Content, and generate check results;The check results are written in test report, until the whole objects to be measured of traversal.
In addition, to achieve the above object, the present invention also proposes a kind of customized device of test order, the test order is customized Device include test order configuration module, object acquisition module to be measured, test order reflecting module, test order matching module, Content authentication module and test report generation module to be measured, wherein test order configuration module is to obtain matching for test order Confidence breath;Object acquisition module to be measured is to obtain object to be measured, according to the object extraction content to be measured to be measured;Test order Reflecting module is to reflection measurement Regularia, to obtain the content information of test order;Test order matching module is to basis The configuration information and content information of the test order, obtain the content information of pending test order;Content authentication mould to be measured Block generates check results to verify the content to be measured according to the content information of the pending test order;Test report Generation module is accused the check results to be written in test report, until the whole objects to be measured of traversal.
In addition, to achieve the above object, the present invention also proposes a kind of computer readable storage medium, described computer-readable It is stored with the customized program of test order on storage medium, test rule are realized when the customized program of test order is executed by processor Then the step of customization method, the test order customization method is the following steps are included: obtain the configuration information of test order;It obtains Object to be measured, according to the object extraction content to be measured to be measured;Reflection measurement Regularia, to obtain the content letter of test order Breath;According to the configuration information and content information of the test order, the content information of pending test order is obtained;According to described The content information of pending test order verifies the content to be measured, and generates check results;The check results are written and are surveyed In examination report, until the whole objects to be measured of traversal.
In the technical solution of the present invention, test order customization method is the following steps are included: acquisition test order matches confidence Breath;Object to be measured is obtained, according to object extraction to be measured content to be measured;Reflection measurement Regularia, to obtain the content of test order Information;According to the configuration information and content information of test order, the content information of pending test order is obtained;According to pending The content information of test order verifies content to be measured, and generates check results;Check results are written in test report, until time Go through all objects to be measured.By obtaining the configuration information of test order, it can easily control and specifically test rule in test process It enabling then and deactivates, when needing using a certain test order, enables the test order by changing configuration information, in conjunction with Content information in test order class extracts the content information of pending test order, verifies to content to be measured;Work as nothing When need to use a certain test order, the test order is deactivated by changing configuration information.In the technical solution of the present invention, lead to Pending test order can be modified by crossing modification configuration information, without rewriting in test file in the whole of test order Hold information, enormously simplifies the enabling and deactivated control process of test order, realize the customized of test order, so as to improve The flexibility of test, improves testing efficiency.
Detailed description of the invention
Fig. 1 is the flow diagram of test order customization method first embodiment of the present invention;
Fig. 2 is the flow diagram of test order customization method second embodiment of the present invention;
Fig. 3 is the refinement flow diagram of step S100 in test order customization method fourth embodiment of the present invention;
Fig. 4 is the refinement flow diagram of step S400 in the 5th embodiment of test order customization method of the present invention;
Fig. 5 is the structural representation of the customized equipment of test order for the hardware running environment that the embodiment of the present invention is related to Figure.
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 primary solutions of the embodiment of the present invention are: according to the configuration information of test order, controlling opening for test order With with deactivate, to realize the customized of test order.
Test file is write according to testing requirement manually due to relying primarily on tester in the prior art, to control survey Adopted test order needs tester to rewrite test file when testing requirement changes during examination, leads Cause the flexibility of test poor, testing efficiency is lower.
The present invention provides a solution, according to the configuration information of test order, controls the enabling of test order and stops With to improve testing efficiency according to the customized test order of testing requirement so as to improve the flexibility of test.
First embodiment of the invention provides a kind of test order customization method, as shown in Figure 1, test order customization method packet Include following steps:
Step S100, the configuration information of test order is obtained;
During the test, the development phase according to locating for system, website etc. often has different testing requirements, and Corresponding different testing requirement, there are at least one or one group of corresponding test orders.The configuration information of test order usually may be used To be obtained according to testing requirement, configuration information specifically includes the title of the test order of required use in such as this test, deposits Storage space is set, to obtain test order according to configuration informations such as the title of test order, storage locations in the next steps Whole particular contents.And when testing requirement changes, as long as first obtaining the test after change according to the variation of testing requirement The configuration information of rule, without writing whole particular contents of test order manually again, to simplify test order Subscription process.
Step S200, object to be measured is obtained, according to object extraction to be measured content to be measured;
Object to be measured includes the website of subsystem in examining system, functional module or the domain of dependence in website to be measured Deng.After getting object to be measured, content to be measured is gone out according to object extraction to be measured, such as specifically to measurement of power in examining system Specific uniform resource locator (Uniform Resource Locator, URL) link etc. in energy or website to be measured.To Surveying content once can all obtain, and be stored according to certain structure, to call during the test;It can also be Primary content to be measured is obtained in test loop of every execution, until completing all traversal tests, hereinafter also will be apparent from.
Step S300, reflection measurement Regularia, to obtain the content information of test order;
The content information of test order is created according to test order class, by reflection measurement Regularia, can be surveyed Try the content information of rule.Herein, the content information of test order includes the tool of all possible adopted test orders Body content information.
Step S400, according to the configuration information of test order and content information, the content letter of pending test order is obtained Breath;
In a certain specific test, the test order using part is often only needed, wherein which test order will be by Using which test order is not used, and can be obtained according to the configuration information of test order.Further, in conjunction with according to survey The content information for the test order that examination Regularia obtains, filters out test used by this fc-specific test FC from all test orders The content information of rule, that is, obtained the content information of pending test order.
Step S500, content to be measured is verified according to the content information of pending test order, and generates check results;
Under the premise of the content information for having obtained pending test order and content to be measured, according to pending test order Content information, content to be measured is verified, that is, execute specific test process, and generate check results.
Step S600, check results are written in test report, until the whole objects to be measured of traversal.
By the way that check results are written in test report, so that tester is by checking that test report obtains system, net The test result stood etc..After traversal completes test whole object to be measured, complete test is formed.It should be noted that time During going through, in one example, circulation can be from step S100 to step S600, that is, is directed to each object to be measured, all may be used There can be the configuration information of different test orders, according to different configuration informations, obtain for the pending of the object to be measured The check results of the object to be measured are written in test report after verification, then opened from step S100 by the content information of test order Beginning executes the circulation of next object to be measured.Alternatively, in another example, circulation can be from step S200 to step S600, also It is the configuration information for disposably obtaining all test orders, usually in this case, the pending survey of all objects to be measured Examination rule is consistent, and then, is started the cycle over from step S200.Alternatively, in another example, circulation can from step S400 to Step S600, that is, the disposable configuration information for obtaining whole test orders, object to be measured and test order it is specific Content obtains the pending test order of each object to be measured, verification further according to the content information of configuration information and test order Check results are written in test report afterwards, then execute the circulation of next object to be measured since step S400.Certainly, above-mentioned It, can also be after generating whole check results in each example, all check results are written in test report property again, with Personnel to be tested check.
In the present embodiment, test order customization method is the following steps are included: obtain the configuration information of test order;It obtains Object to be measured, according to object extraction to be measured content to be measured;Reflection measurement Regularia, to obtain the content information of test order;Root According to the configuration information and content information of test order, the content information of pending test order is obtained;It is advised according to pending test Content information then verifies content to be measured, and generates check results;Check results are written in test report, until traversal is all Object to be measured.By obtaining the configuration information of test order, opening for specific test order in test process can be easily controlled With with deactivate, when needing using a certain test order, enable the test order by changing configuration information, advised in conjunction with test The then content information in class extracts the content information of pending test order, verifies to content to be measured;When without When a certain test order, the test order is deactivated by changing configuration information.In the present solution, passing through modification configuration information Pending test order can be modified, it is significantly simple without rewriting the whole content information of test order in test file The enabling and deactivated control process for having changed test order, the simplicity for realizing test order is customized, so as to improve test Flexibility improves testing efficiency.
Based on above-mentioned first embodiment, in the second embodiment of the present invention, test order class includes test order parent With test order subclass, test order parent defines common test rule, the customized test order of test order subclass definitions, and surveys Try regular subclass Inherit Testing rule parent.Wherein, common test rule is the shared survey that may be used in all tests Examination rule, and customized test order is the test order of the personalization according to set by specific test process, often and specifically Testing requirement it is related.Succession refers to derives test order subclass from test order parent, and test order subclass absorbs The data attribute of test order parent and behavior, and there is certain scalability, so that it is clear to be more clear test order Hierarchy, convenient for the later period to it is all may used by test order arrangement and maintenance.
Further, as shown in Fig. 2, in the second embodiment of the present invention, before step S300, test order is customized Method is further comprising the steps of:
Step S710, initialization test rule parent, to obtain the content information of all common test rules;
Step S720, initialization test rule subclass, to obtain the content information of all customized test orders.
By initialization test rule parent and test order subclass, all common test rules and customized test rule are obtained Content information then, that is to say write-in all may adopted test order content information, to basis in subsequent step The configuration information of test order is called, to ensure the normal execution of test.In fact, due to test order subclass be after Test order parent has been held, therefore, in test order subclass has been the common test rule for including all test order parents Content information, while content information including all customized test orders, thus it is subsequent according to configuration information obtain to When executing the content information of test order, can directly it be obtained according to test order subclass.
Based on above-mentioned second embodiment, in the third embodiment of the present invention, before step S710, further includes:
Step S730, according to the configuration information of test order, test order parent is supplemented, to obtain updated test rule Then parent;And/or
Before step S720, further includes:
Step S740, according to the configuration information of test order, test order subclass is supplemented, to obtain updated test rule Then subclass.
In general, having included most possible adopted test rule in test order parent and test order subclass Then, still, it is contemplated that the development of test may generate new testing requirement, will accordingly generate new test order, Huo Zheji In existing testing requirement, it is also possible to the test order after generating new optimization.In this case, test order match confidence The content information that may include the test order lacked in current test order class in breath, by supplementing test order parent With test order subclass, test order class is optimized and safeguarded, to meet the testing requirement continued to develop.
Based on the various embodiments described above, as shown in figure 3, in the fourth embodiment of the present invention, step S100 includes:
Step S110, according to testing requirement, regular configuration file is obtained;
Step S120, resolution rules configuration file obtains the configuration information of test order;
Wherein, the configuration information of test order includes the switching information and directional information of test order, and switching information with Testing requirement is corresponding.
During the test, test order used by reality is obtained according to testing requirement after all, according to survey Examination demand obtains regular configuration file, that is, writes or alteration ruler configuration file, so as to the execution of subsequent step.Pass through Resolution rules configuration file obtains the configuration information of test order.The configuration information of test order includes the switch of test order Information, switching information play the role of switch, and to control the enabling of corresponding test order and deactivate, configuration information further includes surveying The directional information of rule, that is, the storage location of test order are tried, to obtain the content information of the test order.By obtaining The configuration information of test order, title, the storage location etc. of available pending test order are taken, further specific determination is The no verification for executing whole test orders, if a certain specific test order is enabled, according to the storage location of test order Configure test order and load corresponding test order class etc..
Based on above-mentioned fourth embodiment, as shown in figure 4, in the fifth embodiment of the present invention, step S400 includes:
Step S410, the switching information of test order is obtained;
Step S420, when the switching information of test order is to open, the directional information of test order is obtained;
Step S430, according to the directional information of test order, the content information of test order is extracted from test order class, Charge to the content information of pending test order.
In the present embodiment, when the switching information of test order is to open, show to need in this test using correspondence Test order, further obtain the directional information of the test order, from test order class extract test order content letter Breath, charges to the content information of pending test order.The switching information for obtaining next test order, by recycling above-mentioned steps S410 to step S420, obtains test order used by whole, to test in subsequent step object to be measured.When So, the switching information of whole test orders can also be disposably obtained, and accordingly obtains the content information of test order.It needs to infuse Meaning, when there are test order parent and test order subclass, since test order subclass inherits test order parent, Therefore include all test orders in test order subclass, test order is being extracted according to the directional information of test order When content information, as long as being extracted from test order subclass.
Based on the various embodiments described above, object to be measured is based on chain table organization, and the data field of chained list includes object to be measured, chained list Pointer field includes the pointer for being directed toward next object to be measured.Specifically, can be using the side for looping through test for object to be measured Formula is tested.For for the test of the traversal of website, the data element in chained list is the address URL, between each data element It is realized and is linked by pointer.Chained list can be constantly filled in traversal test process, can also be complete before traversal test starts Portion's filling is completed.When traversal test starts, first URL link in chained list is obtained, first URL is executed according to test order and is surveyed Examination obtains next link according to pointer after having executed first URL test, continues next URL test, until completing The test of the last one URL.In the case where constantly filling chained list in traversing test process, traversal test is usually by entrance chain Driving is connect, includes other URL on the page pointed by linking inlet ports, extracts the URL on the page, after executing URL duplicate removal, It saves corresponding URL and closes to ensured sustained development test set of URL, that is, URL is added in chained list, to continue to promote the stream of test Turn.Wherein, URL duplicate removal can be realized using Bloom filter, or be realized according to other preset rules.It is of course also possible to Traversal test is fully completed chained list filling before starting, this traversal test is usually to be started with data-driven in traversal test Before, the content of driven file is all imported in chained list to complete chained list, under directly reading in chained list in test process One URL promotes test.Be conducive to space needed for saving test based on chain table organization object to be measured, improve the flexible of test Property and testing efficiency.
As shown in figure 5, Fig. 5 is the terminal for the hardware running environment that the embodiment of the present invention is related to, i.e. test order is ordered The structural schematic diagram of control equipment.
The terminal of that embodiment of the invention can be PC, be also possible to smart phone, tablet computer, E-book reader, MP3 (Moving Picture Experts Group Audio Layer III, dynamic image expert's compression standard audio level 3) Player, MP4 (Moving Picture Experts Group Audio Layer IV, dynamic image expert's compression standard sound Frequency level 3) the packaged type terminal device having a display function such as player, portable computer.
As shown in figure 5, the terminal may include: processor 1001, such as CPU, network interface 1004, user interface 1003, memory 1005, communication bus 1002.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), optional user interface 1003 can also include standard wireline interface and wireless interface.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.
Optionally, terminal can also include camera, RF (Radio Frequency, radio frequency) circuit, sensor, audio Circuit, WiFi module etc..Wherein, sensor such as optical sensor, motion sensor and other sensors.Specifically, light Sensor may include ambient light sensor and proximity sensor, wherein ambient light sensor can according to the light and shade of ambient light come The brightness of display screen is adjusted, proximity sensor can close display screen and/or backlight when mobile terminal is moved in one's ear.As One kind of motion sensor, gravity accelerometer can detect the size of (generally three axis) acceleration in all directions, quiet Size and the direction that can detect that gravity when only, the application that can be used to identify mobile terminal posture are (such as horizontal/vertical screen switching, related Game, magnetometer pose calibrating), Vibration identification correlation function (such as pedometer, tap) etc.;Certainly, mobile terminal can also match The other sensors such as gyroscope, barometer, hygrometer, thermometer, infrared sensor are set, details are not described herein.
It will be understood by those skilled in the art that the restriction of the not structure paired terminal of terminal structure shown in Fig. 5, can wrap It includes than illustrating more or fewer components, perhaps combines certain components or different component layouts.
As shown in figure 5, as may include that operating system, network are logical in a kind of memory 1005 of computer storage medium Believe module, Subscriber Interface Module SIM and the customized program of test order.
In terminal shown in Fig. 5, network interface 1004 is mainly used for connecting background server, carries out with background server Data communication;User interface 1003 is mainly used for connecting client (user terminal), carries out data communication with client;And processor 1001 can be used for calling the customized program of the test order stored in memory 1005, and execute following operation:
Obtain the configuration information of test order;
Object to be measured is obtained, according to object extraction to be measured content to be measured;
Reflection measurement Regularia, to obtain the content information of test order;
According to the configuration information and content information of test order, the content information of pending test order is obtained;
Content to be measured is verified according to the content information of pending test order, and generates check results;
Check results are written in test report, until the whole objects to be measured of traversal.
Further, processor 1001 can be used for calling the customized program of the test order stored in memory 1005, survey Examination Regularia includes test order parent and test order subclass, and test order parent defines common test rule, test order The customized test order of subclass definitions, and test order subclass Inherit Testing rule parent.
Further, processor 1001 can be used for calling the customized program of the test order stored in memory 1005, Reflection measurement Regularia before the operation to obtain the content information of test order, also executes following operation:
Initialization test rule parent, to obtain the content information of all common test rules;
Initialization test rule subclass, to obtain the content information of all customized test orders.
Further, processor 1001 can be used for calling the customized program of the test order stored in memory 1005, Initialization test rule parent also executes following operation before obtaining the operation of the content information of all common test rules:
According to the configuration information of test order, test order parent is supplemented, to obtain updated test order parent; And/or
It is also held before obtaining the operation of the content information of all customized test orders in initialization test rule subclass The following operation of row:
According to the configuration information of test order, test order subclass is supplemented, to obtain updated test order subclass.
Further, processor 1001 can be used for calling the customized program of the test order stored in memory 1005, obtain The operation for taking the configuration information of test order includes:
According to testing requirement, regular configuration file is obtained;
Resolution rules configuration file obtains the configuration information of test order;
Wherein, the configuration information of test order includes the switching information and directional information of test order, and switching information with Testing requirement is corresponding.
Further, processor 1001 can be used for calling the customized program of the test order stored in memory 1005, root According to the configuration information and content information of test order, the operation for obtaining the content information of pending test order includes:
Obtain the switching information of test order;
When the switching information of test order is to open, the directional information of test order is obtained;
According to the directional information of test order, the content information of test order is extracted from test order class, is charged to wait hold The content information of row test order.
Further, processor 1001 can be used for calling the customized program of the test order stored in memory 1005, to It surveys object and is based on chain table organization, the data field of chained list includes object to be measured, and the pointer field of chained list includes being directed toward next object to be measured Pointer.
In addition, the embodiment of the present invention also proposes that a kind of customized device of test order, the customized device of test order include:
Test order configuration module, to obtain the configuration information of test order;
Object acquisition module to be measured, to obtain object to be measured, according to object extraction to be measured content to be measured;
Test order reflecting module, to reflection measurement Regularia, to obtain the content information of test order;
Test order matching module obtains pending test to the configuration information and content information according to test order The content information of rule;
Content authentication module to be measured to verify content to be measured according to the content information of pending test order, and generates Check results;
Test report generation module, check results to be written in test report, until the whole objects to be measured of traversal.
Further, test order class includes test order parent and test order subclass, and the definition of test order parent is public Test order, the customized test order of test order subclass definitions, and test order subclass Inherit Testing rule parent altogether.
Further, the customized device of test order further include:
Test order class initial module, to initialization test rule parent, to obtain in all common test rules Hold information;Initialization test rule subclass, to obtain the content information of all customized test orders.
Further, the customized device of test order further include:
Test order class complementary module supplements test order parent to the configuration information according to test order, and/or According to the configuration information of test order, test order subclass is supplemented, to obtain updated test order subclass.
Further, test order configuration module includes:
Configuration file acquiring unit, to obtain regular configuration file according to testing requirement;
Configuration file resolution unit obtains the configuration information of test order to resolution rules configuration file;
Wherein, the configuration information of test order includes the switching information and directional information of test order, and switching information with Testing requirement is corresponding.
Further, test order matching module includes:
Switching information acquiring unit, to obtain the switching information of test order;
Directional information acquiring unit, to obtain the direction of test order when the switching information of test order is to open Information;
Matching unit extracts the content of test order to the directional information according to test order from test order class Information charges to the content information of pending test order.
Further, object to be measured is based on chain table organization, and the data field of chained list includes object to be measured, the pointer field packet of chained list Include the pointer for being directed toward next object to be measured.
In addition, the embodiment of the present invention also proposes a kind of computer readable storage medium, deposited on computer readable storage medium The customized program of test order is contained, following operation is realized when the customized program of test order is executed by processor:
Obtain the configuration information of test order;
Object to be measured is obtained, according to object extraction to be measured content to be measured;
Reflection measurement Regularia, to obtain the content information of test order;
According to the configuration information and content information of test order, the content information of pending test order is obtained;
Content to be measured is verified according to the content information of pending test order, and generates check results;
Check results are written in test report, until the whole objects to be measured of traversal.
Further, when the customized program of test order is executed by processor, test order class include test order parent and Test order subclass, test order parent defines common test rule, the customized test order of test order subclass definitions, and tests Regular subclass Inherit Testing rule parent.
Further, when the customized program of test order is executed by processor, in reflection measurement Regularia, to obtain test rule Before the operation of content information then, following operation is also executed:
Initialization test rule parent, to obtain the content information of all common test rules;
Initialization test rule subclass, to obtain the content information of all customized test orders.
Further, when the customized program of test order is executed by processor, in initialization test rule parent, to obtain Before the operation for having the content information of common test rule, following operation is also executed:
According to the configuration information of test order, test order parent is supplemented, to obtain updated test order parent; And/or
It is also held before obtaining the operation of the content information of all customized test orders in initialization test rule subclass The following operation of row:
According to the configuration information of test order, test order subclass is supplemented, to obtain updated test order subclass.
Further, when the customized program of test order is executed by processor, the operation of the configuration information of test order is obtained Include:
According to testing requirement, regular configuration file is obtained;
Resolution rules configuration file obtains the configuration information of test order;
Wherein, the configuration information of test order includes the switching information and directional information of test order, and switching information with Testing requirement is corresponding.
Further, when the customized program of test order is executed by processor, according to the configuration information and content of test order Information, the operation for obtaining the content information of pending test order include:
Obtain the switching information of test order;
When the switching information of test order is to open, the directional information of test order is obtained;
According to the directional information of test order, the content information of test order is extracted from test order class, is charged to wait hold The content information of row test order.
Further, when the customized program of test order is executed by processor, object to be measured is based on chain table organization, the number of chained list It include object to be measured according to domain, the pointer field of chained list includes the pointer for being directed toward next object to be measured.
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 test order customization method, which is characterized in that the test order customization method the following steps are included:
Obtain the configuration information of test order;
Object to be measured is obtained, according to the object extraction content to be measured to be measured;
Reflection measurement Regularia, to obtain the content information of test order;
According to the configuration information and content information of the test order, the content information of pending test order is obtained;
The content to be measured is verified according to the content information of the pending test order, and generates check results;
The check results are written in test report, until the whole objects to be measured of traversal.
2. test order customization method as described in claim 1, which is characterized in that the test order class includes test order Parent and test order subclass, the test order parent define common test rule, and the test order subclass definitions are customized Test order, and the test order subclass inherits the test order parent.
3. test order customization method as claimed in claim 2, which is characterized in that in reflection measurement Regularia, surveyed with obtaining Before the step of trying the content information of rule, the test order customization method is further comprising the steps of:
The test order parent is initialized, to obtain the content information of all common test rules;
The test order subclass is initialized, to obtain the content information of all customized test orders.
4. test order customization method as claimed in claim 3, which is characterized in that the test order parent is being initialized, It is further comprising the steps of before the step of obtaining the content information of all common test rules:
According to the configuration information of test order, test order parent is supplemented, to obtain updated test order parent;And/or
Initializing the test order subclass, the step of to obtain the content information of all customized test orders before, also wrap Include following steps:
According to the configuration information of test order, test order subclass is supplemented, to obtain updated test order subclass.
5. test order customization method as described in claim 1, which is characterized in that obtain the step of the configuration information of test order Suddenly include:
According to testing requirement, regular configuration file is obtained;
The regular configuration file is parsed, the configuration information of test order is obtained;
Wherein, the configuration information of the test order includes the switching information and directional information of test order, and the switch is believed It ceases corresponding with the testing requirement.
6. test order customization method as claimed in claim 5, which is characterized in that according to the configuration information of the test order And content information, the step of obtaining the content information of pending test order, include:
Obtain the switching information of test order;
When the switching information of the test order is to open, the directional information of the test order is obtained;
According to the directional information of the test order, the content information of the test order is extracted from the test order class, Charge to the content information of pending test order.
7. such as test order customization method described in any one of claims 1 to 6, which is characterized in that the object base to be measured In chain table organization, the data field of the chained list includes object to be measured, and the pointer field of the chained list includes being directed toward next object to be measured Pointer.
8. a kind of customized equipment of test order, which is characterized in that the customized equipment of test order includes: memory, processor And it is stored in the computer program that can be run on the memory and on the processor, the computer program is by the place Manage the step of realizing the test order customization method as described in any one of claims 1 to 7 when device executes.
9. a kind of customized device of test order, which is characterized in that the customized device of test order includes:
Test order configuration module, to obtain the configuration information of test order;
Object acquisition module to be measured, to obtain object to be measured, according to the object extraction content to be measured to be measured;
Test order reflecting module, to reflection measurement Regularia, to obtain the content information of test order;
Test order matching module obtains pending test to the configuration information and content information according to the test order The content information of rule;
Content authentication module to be measured verifies the content to be measured to the content information according to the pending test order, and Generate check results;
Test report generation module, the check results to be written in test report, until the whole objects to be measured of traversal.
10. a kind of computer readable storage medium, which is characterized in that be stored with test rule on the computer readable storage medium Then customized program is realized as described in any one of claims 1 to 7 when the customized program of test order is executed by processor The step of test order customization method.
CN201810945137.2A 2018-08-17 2018-08-17 Test rule customizing method, device, apparatus and computer readable storage medium Active CN109726111B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810945137.2A CN109726111B (en) 2018-08-17 2018-08-17 Test rule customizing method, device, apparatus and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810945137.2A CN109726111B (en) 2018-08-17 2018-08-17 Test rule customizing method, device, apparatus and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN109726111A true CN109726111A (en) 2019-05-07
CN109726111B CN109726111B (en) 2023-03-28

Family

ID=66294635

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810945137.2A Active CN109726111B (en) 2018-08-17 2018-08-17 Test rule customizing method, device, apparatus and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN109726111B (en)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080186134A1 (en) * 2007-02-02 2008-08-07 Beckman Coulter, Inc. System and method for testing autoverification rules
US20110088018A1 (en) * 2009-10-09 2011-04-14 General Electric Company, A New York Corporation Methods and apparatus for testing user interfaces
WO2014093198A1 (en) * 2012-12-10 2014-06-19 DANIELSSON, Bjorn Rules based data processing system and method
WO2016120989A1 (en) * 2015-01-27 2016-08-04 株式会社日立製作所 Management computer and rule test method
CN107562629A (en) * 2017-09-05 2018-01-09 北京京东金融科技控股有限公司 method and device for test
CN107844400A (en) * 2017-10-16 2018-03-27 阿里巴巴集团控股有限公司 The method of calibration and device of a kind of daily record data
CN108183962A (en) * 2018-01-04 2018-06-19 上海瀚之友信息技术服务有限公司 A kind of simulated testing system

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080186134A1 (en) * 2007-02-02 2008-08-07 Beckman Coulter, Inc. System and method for testing autoverification rules
US20110088018A1 (en) * 2009-10-09 2011-04-14 General Electric Company, A New York Corporation Methods and apparatus for testing user interfaces
WO2014093198A1 (en) * 2012-12-10 2014-06-19 DANIELSSON, Bjorn Rules based data processing system and method
WO2016120989A1 (en) * 2015-01-27 2016-08-04 株式会社日立製作所 Management computer and rule test method
CN107562629A (en) * 2017-09-05 2018-01-09 北京京东金融科技控股有限公司 method and device for test
CN107844400A (en) * 2017-10-16 2018-03-27 阿里巴巴集团控股有限公司 The method of calibration and device of a kind of daily record data
CN108183962A (en) * 2018-01-04 2018-06-19 上海瀚之友信息技术服务有限公司 A kind of simulated testing system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
刘翀: "管理软件的自动化测试系统框架研究" *

Also Published As

Publication number Publication date
CN109726111B (en) 2023-03-28

Similar Documents

Publication Publication Date Title
CN109582579B (en) Application program testing method and device, electronic equipment and storage medium
US11630553B2 (en) Electronic device and method for displaying history of executed application thereof
CN103518393B (en) The system and method for detecting mobile communication equipment content
CN110352446A (en) For obtaining the method and apparatus and its recording medium of image
CN109151301A (en) Electronic device including camera model
CN105824755B (en) A kind of automated testing method, device and mobile terminal
CN107393501A (en) Electronic equipment
CN105893814A (en) Electronic Device And Method Of Registering Fingerprint In Electronic Device
CN108463832A (en) Electronic equipment and process execution method based on hardware diagnostic result
CN106489141B (en) Method and electronic device for classifying content
CN105426035A (en) Method and electronic device for providing information
CN107066473A (en) Web page operation method and the electronic equipment for supporting the web page operation method
CN107888978A (en) KEY codes method for burn-recording, device and computer-readable recording medium
US20160148430A1 (en) Mobile device, operating method for modifying 3d model in ar, and non-transitory computer readable storage medium for storing operating method
CN105874448A (en) Method and apparatus for outputting digital content
US11562517B2 (en) Method and system for populating a digital environment using a semantic map
CN106250076A (en) Devices and methods therefor for the independent multiple regions controlling display
US11951390B2 (en) Method and system for incremental topological update within a data flow graph in gaming
CN106462191A (en) Electronic device and method of content display
CN107688924A (en) Accreditation method, apparatus and computer-readable recording medium
CN109683967A (en) Firmware supports method, apparatus, mobile terminal and readable storage medium storing program for executing
US20220101355A1 (en) Determining lifetime values of users in a messaging system
KR20150117043A (en) Method for sorting a media content and electronic device implementing the same
KR20180111242A (en) Electronic device and method for providing colorable content
CN109726113A (en) Method for generating test case, unit and computer readable storage medium

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