CN109508290A - A kind of automated testing method and electronic equipment based on educational system - Google Patents

A kind of automated testing method and electronic equipment based on educational system Download PDF

Info

Publication number
CN109508290A
CN109508290A CN201811252921.1A CN201811252921A CN109508290A CN 109508290 A CN109508290 A CN 109508290A CN 201811252921 A CN201811252921 A CN 201811252921A CN 109508290 A CN109508290 A CN 109508290A
Authority
CN
China
Prior art keywords
product version
interfaces
interface
test
new
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
CN201811252921.1A
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.)
Shenzhen Dianmao Technology Co Ltd
Original Assignee
Shenzhen Dianmao 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 Shenzhen Dianmao Technology Co Ltd filed Critical Shenzhen Dianmao Technology Co Ltd
Priority to CN201811252921.1A priority Critical patent/CN109508290A/en
Publication of CN109508290A publication Critical patent/CN109508290A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3696Methods or tools to render software testable

Landscapes

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

Abstract

The present invention discloses a kind of automated testing method and electronic equipment based on educational system, wherein new content is increased to formation new product version in old product version comprising steps of when needing to be updated old product version by method;By new content modularization, and by the interface typing automatic test set of interfaces of new content;New product version is tested automatically according to automatic test set of interfaces, exports corresponding test data;Test data is carried out verification with anticipatory data to compare;If verification passes through, process terminates, if verification does not pass through, modifies and debugs.The present invention is by constantly updating automatic test set of interfaces, to carry out test verification in time to new product version, can be multiplexed test interface in this way, testing cost, while modification script convenient for safeguarding is saved, so that test script is more flexible changeable.It during the continuous iteration of version is improved, saves a large amount of time and is absorbed in new module, improve version quality.

Description

A kind of automated testing method and electronic equipment based on educational system
Technical field
The present invention relates to field of computer technology more particularly to a kind of automated testing methods and electricity based on educational system Sub- equipment.
Background technique
Software upgrading refers to update of the software from lowest version to highest version.Since highest version usually repairs the part of lowest version BUG, so experienced software upgrading, it generally all can be more preferable than the performance of original version, the effect optimized, user can also have more Good experience.
Software developer is when writing software, since designer considers that not comprehensive or program function is not perfect, After software publishing, after the modification to program or new function being added, in a manner of being issued in the form of patch.User is these Patch updates, i.e. upgrading is completed.
Software upgrading includes system upgrade and two kinds of application program updating, and system upgrade refers to system conversion at higher-version System (such as Windows 98 is replaced with Windows 2000, Windows 2000 is replaced with Windows XP) or to system Patch is downloaded, attack is protected it from or increases new function;Application program updating is exactly the software of downloading installation latest edition, experience New function.
During the version iteration of application program, it be easy to cause accidental injury to modify old functional module, to influence old Basic function module.
Therefore, the existing technology needs to be improved and developed.
Summary of the invention
In view of above-mentioned deficiencies of the prior art, the purpose of the present invention is to provide a kind of, and the automation based on educational system is surveyed Method for testing and electronic equipment, it is intended to solve existing product version renewal process and be easy that old functional module is caused to accidentally injure modification Problem.
Technical scheme is as follows:
A kind of automated testing method based on educational system, wherein comprising steps of
When needing to be updated old product version, new content is increased into formation new product version in old product version This;
By new content modularization, and by the interface typing automatic test set of interfaces of new content;
New product version is tested automatically according to automatic test set of interfaces, exports corresponding test data;
Test data is carried out verification with anticipatory data to compare;
If verification passes through, process terminates, if verification does not pass through, modifies and debugs.
The automated testing method based on educational system, wherein described to use automatic test set of interfaces pair The step of new product version is tested, exports corresponding test data specifically includes:
Call the interface in automatic test set of interfaces;
Test script is obtained by the interface;
New product version is tested automatically using test script.
The automated testing method based on educational system, wherein the interface include creation, delete, update and Check interface.
The automated testing method based on educational system, wherein obtaining test script includes request URL, request Head and required parameter.
The automated testing method based on educational system, wherein write the interface of new content according to unified format At interface document, it is added into automatic test set of interfaces.
The automated testing method based on educational system, wherein when needing to be updated product version every time, Iteratively product version is updated, and automatic test set of interfaces is updated.
The automated testing method based on educational system, wherein after test verification passes through, cleaning test number According to.
A kind of electronic equipment, wherein include:
Processor is adapted for carrying out each instruction, and
Equipment is stored, is suitable for storing a plurality of instruction, described instruction is suitable for being loaded and being executed by processor:
When needing to be updated old product version, new content is increased into formation new product version in old product version This;
By new content modularization, and by the interface typing automatic test set of interfaces of new content;
New product version is tested automatically according to automatic test set of interfaces, exports corresponding test data;
Test data is carried out verification with anticipatory data to compare;
If verification passes through, process terminates, if verification does not pass through, modifies and debugs.
A kind of non-volatile computer readable storage medium storing program for executing, wherein the non-volatile computer readable storage medium storing program for executing is deposited Computer executable instructions are contained, when which is executed by one or more processors, may make described one A or multiple processors execute the automated testing method based on educational system.
A kind of computer program product, wherein non-volatile computer is readable to be deposited computer program product including being stored in Computer program on storage media, computer program include program instruction, when program instruction is executed by processor, make the place It manages device and executes the automated testing method based on educational system.
The utility model has the advantages that the present invention is by constantly updating automatic test set of interfaces, with to new product version and Shi Jinhang test verification, can be multiplexed test interface in this way, save testing cost, while modification script convenient for safeguarding, so that surveying Training sheet is more flexible changeable.During the continuous iteration of version is improved, saves a large amount of time and be absorbed in new module, mention Highest version quality.
Detailed description of the invention
Fig. 1 is a kind of flow chart of the automated testing method preferred embodiment based on educational system of the present invention.
Fig. 2 is the structural block diagram of a kind of electronic equipment preferred embodiment of the present invention.
Specific embodiment
The present invention provides a kind of automated testing method and electronic equipment based on educational system, to make mesh of the invention , technical solution and effect it is clearer, clear, the present invention is described in more detail below.It should be appreciated that described herein Specific embodiment be only used to explain the present invention, be not intended to limit the present invention.
Referring to Fig. 1, a kind of automated testing method based on educational system, wherein comprising steps of
S1, when needing to be updated old product version, new content is increased in old product version and forms new product Version;
S2, by new content modularization, and by the interface typing automatic test set of interfaces of new content;
S3, new product version is tested according to automatic test set of interfaces automatically, exports corresponding test data;
S4, by test data and anticipatory data carry out verification compare;
If S5, verification pass through, process terminates, if verification does not pass through, modifies and debugs.
The present invention is by constantly updating automatic test set of interfaces, tested in time new product version Verification can be multiplexed test interface in this way, testing cost, while modification script convenient for safeguarding be saved, so that test script is more It is flexible and changeable.It during the continuous iteration of version is improved, saves a large amount of time and is absorbed in new module, improve version matter Amount.
In the step S1, when needing to be updated old product version, new content is increased into old product version Middle formation new product version.
That is, it needs to need to increase to new content in old product version, to be formed when being updated old product version New product version.
In the step S2, by new content modularization, and by the interface typing automatic test set of interfaces of new content.
I.e. in present invention, it is desirable to new content is carried out modularized processing, and the interface of modular new content is entered into Automatic test set of interfaces.
In the step S3, new product version is tested automatically according to automatic test set of interfaces, output phase The test data answered.
New product version is tested automatically using automatic test set of interfaces.
Further, described that new product version is tested using automatic test set of interfaces, export corresponding test The step of data, specifically includes:
Call the interface in automatic test set of interfaces;
Test script is obtained by the interface;
New product version is tested automatically using test script.
The interface in automatic test set of interfaces is first called, the interface includes creating, delete, update and checking etc. to connect Mouthful.Then test script, the contents such as specific acquisition request URL, request header and required parameter can be obtained by these interfaces.Finally New product version is tested automatically using test script.
After i.e. new version comes out, test script is called using interface, each functional module in new product version is carried out certainly Dynamicization test, exports corresponding test data.
In the step S4, test data is subjected to verification with anticipatory data and is compared.
In the step S5, if verification passes through, illustrate that new product version is qualified, process directly terminates, if verification is not Pass through, then specification new product version is unqualified, needs to modify and debug, it is ensured that last new product version is qualified.Into One step clears up test data, after test verification passes through to carry out automatic test next time.
Further, in the present invention, write the interface of new content as interface document according to unified format, in this way can will it is new in The interface of appearance is smoothly added into automatic test set of interfaces.
Further, when needing to be updated product version every time, iteratively product version is updated, with And automatic test set of interfaces is updated.It, then can be to old production when thering is new content to need to be added old product version every time Product version is updated, while being also updated to automatic test set of interfaces, it is ensured that automatic test set of interfaces can expire Sufficient test request.
The multiplexing of intrinsic functions of modules automation interface script can be improved in the present invention, saves testing cost;It is convenient for safeguarding to repair Change script, so that test script is more flexible changeable;For stable intrinsic module, key automatized script verification is executed;? It during the continuous iteration of version is improved, saves a large amount of time and is absorbed in new module, improve version quality;Directly deeply count According in level, data infiltration is carried out to original module, improves edition data Robust Security.
In the present invention, interface testing is exactly that writing and executing for test code is carried out to some interface.Under normal circumstances, The priority for implementing interface testing is: carrying out interface testing to the interface (interface can be called to third party) for being exposed to outside; Internal core function interface can also do interface testing;The interface testing (such as unit testing) of internal non-core functional interface.
Interface testing implement need some conditions: interface testing framework, frame whether customize some functions (such as from Move load java bean, facilitate initialization data, facilitate calibration database data etc.).
The each type of error for each entering ginseng requires to prepare an abnormal use-case.Such as necessary parameters default, parameter type Mistake, parameter area mistake, parameter do not reach minimum more than maximum number of digits, parameter and specify the invalid value of digit, parameter (effective Outside state), the decimal point of parameter be more than specific length, parameter contains illegal word, parameter contains violated word, the inspection of the relevance of parameter Look into (such as place province, city, location is mismatched) etc..
For searching interface, each parameter can be confirmed whether search result is correct separately as search condition, then Result after confirming many condition input again.
For all parameters, require to verify the essential characteristic of parameter, as abnormal use-case.Interface testing generation The main flow of code is as follows:
Step1: test base class (load resource, initialization context) (optional) is write.
Step2: test class is write.
Step3: test method is write in the test class.
Step4: tested method is called in test method.
Step5: whether verifying expected results and the result of return are consistent.
Step6: it executes test and checks test result.
Interface testing code is write for all interface testing use-cases, interface testing code is mainly the difference into ginseng, school The difference of result is tested, the test code in other regions is the same.So the previous test case code of continuous copy, so After modify some parameter, modify some check post.
In certain test scope, makes full use of the automatic metaplasia of tool at test case, guarantee covering for test case Lid rate.The multiplexing of the two kinds of degree protos test suite PROTOS, one is the generation of test case and multiplexings, and one is the generations of test code And multiplexing.
Last iterative development component: first step consideration automatically generates interface testing framework code, the selection of customization Interface automatically generates skeleton code (including being integrated with ready-made interface testing framework);Input test data, and consideration and frame Frame code building carries out integrated fusion;In addition it is exactly the calling for testing the API of environment, runs the test code automatically generated and anti- Result is presented to tester.
The present invention also provides a kind of electronic equipment 10, as shown in Fig. 2, comprising:
Processor 110 is adapted for carrying out each instruction, and
Equipment 120 is stored, is suitable for storing a plurality of instruction, described instruction is suitable for being loaded and being executed by processor 110:
When needing to be updated old product version, new content is increased into formation new product version in old product version This;
By new content modularization, and by the interface typing automatic test set of interfaces of new content;
New product version is tested automatically according to automatic test set of interfaces, exports corresponding test data;
Test data is carried out verification with anticipatory data to compare;
If verification passes through, process terminates, if verification does not pass through, modifies and debugs.
The processor 110 can for general processor, digital signal processor (DSP), specific integrated circuit (ASIC), Field programmable gate array (FPGA), single-chip microcontroller, ARM (Acorn RISC Machine) or other programmable logic device are divided Any combination of vertical door or transistor logic, discrete hardware component or these components.In addition, processor can also be any Conventional processors, microprocessor or state machine.Processor also may be implemented as calculating the combination of equipment, for example, DSP and Wei Chu Manage combination, multi-microprocessor, one or more microprocessors combination DSP core, any other this configuration of device.
It stores equipment 120 and is used as a kind of non-volatile computer readable storage medium storing program for executing, can be used for storing non-volatile software Program, non-volatile computer executable program and module, such as the automation based on educational system in the embodiment of the present invention The corresponding program instruction of test method.Processor is stored in the non-volatile software program stored in equipment, instruction by operation And unit, thereby executing the various function application and data processing of the automated testing method based on educational system, i.e., in fact Existing above method embodiment.
It has been described in detail in the method for particular technique details in front about above-mentioned electronic equipment 10, so it will not be repeated.
The present invention also provides a kind of non-volatile computer readable storage medium storing program for executing, the non-volatile computer readable storage Media storage has computer executable instructions, when which is executed by one or more processors, may make One or more of processors execute the automated testing method based on educational system.
The present invention also provides a kind of computer program product, computer program product includes being stored in non-volatile computer Computer program on readable storage medium storing program for executing, computer program include program instruction, when program instruction is executed by processor, are made The processor executes the automated testing method based on educational system.
It should be understood that the application of the present invention is not limited to the above for those of ordinary skills can With improvement or transformation based on the above description, all these modifications and variations all should belong to the guarantor of appended claims of the present invention Protect range.

Claims (10)

1. a kind of automated testing method based on educational system, which is characterized in that comprising steps of
When needing to be updated old product version, new content is increased into formation new product version in old product version;
By new content modularization, and by the interface typing automatic test set of interfaces of new content;
New product version is tested automatically according to automatic test set of interfaces, exports corresponding test data;
Test data is carried out verification with anticipatory data to compare;
If verification passes through, process terminates, if verification does not pass through, modifies and debugs.
2. the automated testing method according to claim 1 based on educational system, which is characterized in that described using automatic Change the step of test interface set tests to new product version, exports corresponding test data to specifically include:
Call the interface in automatic test set of interfaces;
Test script is obtained by the interface;
New product version is tested automatically using test script.
3. the automated testing method according to claim 1 based on educational system, which is characterized in that the interface includes Create, delete, update and check interface.
4. the automated testing method according to claim 1 based on educational system, which is characterized in that obtain test script Including request URL, request header and required parameter.
5. the automated testing method according to claim 1 based on educational system, which is characterized in that by connecing for new content Mouth is write as interface document according to unified format, is added into automatic test set of interfaces.
6. the automated testing method according to claim 1 based on educational system, which is characterized in that need every time to production When product version is updated, iteratively product version is updated, and automatic test set of interfaces is carried out It updates.
7. the automated testing method according to claim 1 based on educational system, which is characterized in that logical in test verification Later, test data is cleared up.
8. a kind of electronic equipment characterized by comprising
Processor is adapted for carrying out each instruction, and
Equipment is stored, is suitable for storing a plurality of instruction, described instruction is suitable for being loaded and being executed by processor:
When needing to be updated old product version, new content is increased into formation new product version in old product version;
By new content modularization, and by the interface typing automatic test set of interfaces of new content;
New product version is tested automatically according to automatic test set of interfaces, exports corresponding test data;
Test data is carried out verification with anticipatory data to compare;
If verification passes through, process terminates, if verification does not pass through, modifies and debugs.
9. a kind of non-volatile computer readable storage medium storing program for executing, which is characterized in that the non-volatile computer readable storage medium Matter is stored with computer executable instructions, when which is executed by one or more processors, may make institute It states one or more processors perform claim and requires the described in any item automated testing methods based on educational system of 1-7.
10. a kind of computer program product, which is characterized in that computer program product can including being stored in non-volatile computer The computer program on storage medium is read, computer program includes program instruction, when program instruction is executed by processor, makes institute It states processor perform claim and requires the described in any item automated testing methods based on educational system of 1-7.
CN201811252921.1A 2018-10-25 2018-10-25 A kind of automated testing method and electronic equipment based on educational system Pending CN109508290A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811252921.1A CN109508290A (en) 2018-10-25 2018-10-25 A kind of automated testing method and electronic equipment based on educational system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811252921.1A CN109508290A (en) 2018-10-25 2018-10-25 A kind of automated testing method and electronic equipment based on educational system

Publications (1)

Publication Number Publication Date
CN109508290A true CN109508290A (en) 2019-03-22

Family

ID=65745958

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811252921.1A Pending CN109508290A (en) 2018-10-25 2018-10-25 A kind of automated testing method and electronic equipment based on educational system

Country Status (1)

Country Link
CN (1) CN109508290A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110489293A (en) * 2019-08-23 2019-11-22 四川长虹电器股份有限公司 A kind of interface security automation system for testing

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1997909A (en) * 2004-05-22 2007-07-11 株式会社爱德万测试 Method and system for controlling interchangeable components in a modular test system
CN102148719A (en) * 2010-02-09 2011-08-10 奇点新源国际技术开发(北京)有限公司 Integrated automated testing system based on subsystems
CN102789415A (en) * 2011-04-13 2012-11-21 埃森哲环球服务有限公司 Modular script designer for next generation testing system
US20140337223A1 (en) * 2011-08-10 2014-11-13 Monk Akarshala Design Pvt Ltd Modularity in a learning system
CN107480061A (en) * 2017-08-04 2017-12-15 上海爱数信息技术股份有限公司 A kind of Automation regression testing method that change module is built based on Jenkins CI

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1997909A (en) * 2004-05-22 2007-07-11 株式会社爱德万测试 Method and system for controlling interchangeable components in a modular test system
CN102148719A (en) * 2010-02-09 2011-08-10 奇点新源国际技术开发(北京)有限公司 Integrated automated testing system based on subsystems
CN102789415A (en) * 2011-04-13 2012-11-21 埃森哲环球服务有限公司 Modular script designer for next generation testing system
US20140337223A1 (en) * 2011-08-10 2014-11-13 Monk Akarshala Design Pvt Ltd Modularity in a learning system
CN107480061A (en) * 2017-08-04 2017-12-15 上海爱数信息技术股份有限公司 A kind of Automation regression testing method that change module is built based on Jenkins CI

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110489293A (en) * 2019-08-23 2019-11-22 四川长虹电器股份有限公司 A kind of interface security automation system for testing

Similar Documents

Publication Publication Date Title
US11093240B2 (en) Automating identification of code snippets for library suggestion models
US11494181B2 (en) Automating generation of library suggestion engine models
US20200293433A1 (en) Automating Identification of Test Cases for Library Suggestion Models
US11340896B2 (en) Library model addition
KR102341154B1 (en) High-speed application for installation on mobile devices for permitting remote configuration of such mobile devices
US9507680B2 (en) Verification system and method for automated verification of register information for an electronic system
CN113366453A (en) Generating test models from behavior driven development scenarios based on behavior driven development step definitions and similarity analysis using neuro-language programming and machine learning mechanisms
CN114239459B (en) Processing method, device, equipment and medium for FPGA prototype design file
CN109299001A (en) The automated testing method and electronic equipment of a kind of list under programming platform
CN107480050A (en) A kind of method of testing of automatic test renewal bag
CN109508290A (en) A kind of automated testing method and electronic equipment based on educational system
CN101673200B (en) The detection method of user input model and device
CN117435483A (en) Form tool-based simulation verification excitation generation method, device, medium and terminal
CN117667884A (en) Data migration method, device, equipment and storage medium
US20060036422A1 (en) Methods and systems for electronic device modelling
CN109358855A (en) A kind of front end analogue data agile development method and electronic equipment for programming
CN109558311A (en) A kind of the automation interface method of calibration and electronic equipment of educational system
CN112817931A (en) Method and device for generating incremental version file
CN111079160A (en) Method and system for establishing authority management framework
KR100656559B1 (en) Program Automatic Generating Tools
CN111626009A (en) Automatic extraction method for safety verification attribute of register transmission level Verilog design
Tanuska et al. The Proposal of the Essential Strategies of DataWarehouse Testing
CN118567982A (en) FPGA software simulation verification platform and method based on model library
CN116909928A (en) Test case generation method, interface test method, system, equipment and 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
RJ01 Rejection of invention patent application after publication

Application publication date: 20190322

RJ01 Rejection of invention patent application after publication