CN108268374A - software version test method, device, terminal device and storage medium - Google Patents

software version test method, device, terminal device and storage medium Download PDF

Info

Publication number
CN108268374A
CN108268374A CN201711070064.9A CN201711070064A CN108268374A CN 108268374 A CN108268374 A CN 108268374A CN 201711070064 A CN201711070064 A CN 201711070064A CN 108268374 A CN108268374 A CN 108268374A
Authority
CN
China
Prior art keywords
content
tested
code
version
database
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
CN201711070064.9A
Other languages
Chinese (zh)
Other versions
CN108268374B (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 Technology Shenzhen Co Ltd
Original Assignee
Ping An Technology Shenzhen 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 Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN201711070064.9A priority Critical patent/CN108268374B/en
Priority to PCT/CN2018/081532 priority patent/WO2019085386A1/en
Publication of CN108268374A publication Critical patent/CN108268374A/en
Application granted granted Critical
Publication of CN108268374B publication Critical patent/CN108268374B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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

Abstract

The invention discloses a kind of software version test method, device, terminal device and storage mediums.The software version test method, including:It runs code and compares platform, the code compares platform and is connected with database;The software version test method further includes the following steps for being compared platform by the code and being performed:The release content to be tested stored in the database is obtained, the release content to be tested is associated with revision ID to be tested;Based on the revision ID to be tested, the baseline version content homologous with the revision ID to be tested stored in the database is obtained, the baseline version content is associated with baseline version ID;The release content to be tested and the baseline version content into line code are compared, obtain comparison result.When the software version test method carries out software version test, software version testing efficiency and optimization software version test effect can be improved.

Description

Software version test method, device, terminal device and storage medium
Technical field
The present invention relates to software test field more particularly to a kind of software version test method, device, terminal device and deposit Storage media.
Background technology
The update iteration speed of software is very fast at present, and software updates the change that can all have software version each time.With The raising of software version change frequency, it is also higher and higher to the test request of software version.Current software version change compares It is more and scattered, it is difficult to directly read the release content in test environment, and lack the comparison to release content, can not meet to frequency The testing requirement that numerous newer software version is intuitively compared, cause software version testing efficiency low and test effect compared with Difference.
Invention content
The embodiment of the present invention provides a kind of software version test method, to solve software version testing efficiency lowly and test The problem of effect is poor.
In a first aspect, the embodiment of the present invention provides a kind of software version test method, including:
Obtain the release content to be tested stored in the database, the release content to be tested and revision ID to be tested It is associated;
Based on the revision ID to be tested, the base homologous with the revision ID to be tested stored in the database is obtained Line release content, the baseline version content are associated with baseline version ID;
The release content to be tested and the baseline version content into line code are compared, obtain comparison result.
Second aspect, the embodiment of the present invention provide a kind of software version test device, including:
Release content acquisition module to be tested, for obtaining the release content to be tested stored in the database;
Baseline version content obtaining module for being based on the revision ID to be tested, obtains what is stored in the database The homologous baseline version content with the revision ID to be tested;
Comparison result acquisition module, for the release content to be tested and the baseline version content into line code ratio It is right, obtain comparison result.
The third aspect, the embodiment of the present invention provide a kind of terminal device, including memory, processor and are stored in described In memory and the computer program that can run on the processor, the processor are realized when performing the computer program The step of software version test method.
Fourth aspect, the embodiment of the present invention provide a kind of computer readable storage medium, the computer-readable storage medium Matter is stored with computer program, and the computer program realizes the step of the software version test method when being executed by processor Suddenly.
In software version test method, device, terminal device and storage medium that the embodiment of the present invention is provided, transport first Line code compares platform, compares platform by running code, can realize the system of release content and baseline version content to be tested One management, is conducive to directly read release content and the baseline version content to be tested in platform test environment data base and carries out Code compares, and greatly improves the efficiency for carrying out version test.Then it compares platform in code and obtains release content to be tested, it is to be measured Examination release content is associated with revision ID to be tested, and the content of quick obtaining version to be tested is capable of by code comparison platform, Improve the efficiency for obtaining beta version content.Revision ID to be tested is then based on, comparing platform in code obtains in baseline version Hold, baseline version content is associated with baseline version ID, and comparing platform by code can be according to version to be tested and baseline version The content of contact quick obtaining baseline version between this, improves the efficiency for obtaining baseline version content.It is finally based on code ratio It to platform, treats beta version content and baseline version content is compared, obtain comparison result, platform is compared by code, Can to release content and the baseline version content to be tested that is obtained in platform platform display interface directly into line code ratio It is right, it realizes and the function that release content and baseline version content code to be tested compares is carried out on code comparison platform.
Description of the drawings
In order to illustrate the technical solution of the embodiments of the present invention more clearly, below by institute in the description to the embodiment of the present invention Attached drawing to be used is needed to be briefly described, it should be apparent that, the accompanying drawings in the following description is only some implementations of the present invention Example, for those of ordinary skill in the art, without having to pay creative labor, can also be according to these attached drawings Obtain other attached drawings.
Fig. 1 is a flow chart of software version test method in the embodiment of the present invention 1.
Fig. 2 is a particular flow sheet of step S10 in Fig. 1.
Fig. 3 is a particular flow sheet of step S20 in Fig. 1.
Fig. 4 is a particular flow sheet of step S30 in Fig. 1.
Fig. 5 is a particular flow sheet of step S40 in Fig. 1.
Fig. 6 is another particular flow sheet of step S40 in Fig. 1.
Fig. 7 is a functional block diagram of software version test device in the embodiment of the present invention 2.
Fig. 8 is a schematic diagram of terminal device in the embodiment of the present invention 4.
Specific embodiment
Below in conjunction with the attached drawing in the embodiment of the present invention, the technical solution in the embodiment of the present invention is carried out clear, complete Site preparation describes, it is clear that described embodiment is part of the embodiment of the present invention, instead of all the embodiments.Based on this hair Embodiment in bright, the every other implementation that those of ordinary skill in the art are obtained without creative efforts Example, shall fall within the protection scope of the present invention.
Embodiment 1
Fig. 1 shows a flow chart of software version test method in the present embodiment.The software version test method can be applied It, can be to release content for carrying out software version test in the terminal device of the financial institutions such as bank, insurance and security configuration Directly read line code comparison of going forward side by side, enable to software version testing efficiency high and test effect and is good.Wherein, the terminal Equipment is the equipment that human-computer interaction can be carried out with user, the including but not limited to equipment such as computer, smart mobile phone and tablet.Such as Fig. 1 Shown, which includes the following steps:
S10:It runs code and compares platform, code compares platform and is connected with database.
Wherein, code comparison platform refers to that collection directly reads release content and is into line code comparison function to release content The system platform of one.In the present embodiment, platform is compared in terminal device operation code, which compares platform by showing boundary Face obtains instruction input by user (such as version selection instruction, first, second code compare instruction etc.), and execute instruction will simultaneously perform It is presented on display interface to result visualization.When user can simplify the test of script software version by code comparison platform Cumbersome step does not spend and individually obtains different release contents, and in addition different release contents is compared.The code Platform is compared, is connected with database, the release content of each version is stored in database.For the ease of managing each version Release content establishes corresponding software release data sheet in the database, by searching for what is recorded in the software release data sheet The storage address of each release content directly invokes storage corresponding release content in the database.And it is compared on platform in code It realizes the function that code compares, optimizes the efficiency of software version test and the effect of code comparison.
In a specific embodiment, as shown in Fig. 2, in step S10, code compares platform and is connected with database, has Body includes the following steps:
S11:Code compares platform and obtains database configuration parameters input by user.
Wherein, database configuration parameters refer to that establishing code compares platform and the call parameter of database connection relation, should The IP address of database configuration parameters including database, No. Sid of database, the user name of log database, database step on The port numbers of password and database are recorded, above-mentioned database configuration parameters are all the configuration parameters that must be filled out, and lack any one and all will The connection that code compares platform and database can not be established.Sid (Security Identifiers, i.e. secure identifier) is mark Know unique number of user, group and computer account, the present embodiment middle finger is for the unique identification database to be connected Number.In the present embodiment, code compares platform when foundation is connect with database, and platform will show newly-built linkage interface, and User is waited for input corresponding database configuration parameters in this creates linkage interface, so that code compares platform and obtains the data Parameter is configured in library.
Particularly, when user runs code for the first time compares platform, which will show newly-built linkage interface, until obtaining Otherwise database configuration parameters input by user can not compare in the code and carry out other operations on platform.When user is non-for the first time When running code comparison platform, platform will be automatically loaded the database of the last connection, and attended operation is repeated without user; If when user needs to change the database of connection, " connection of newdata library " button can be clicked on platform, with to code Platform input database change directive is compared, so that after code comparison platform receives the database change directive, display is newly-built Linkage interface re-establishes the connection with required database.
S12:According to database configuration parameters, code is made to compare platform and is connected with database.
In the present embodiment, code compares platform according to acquisition database configuration parameters input by user (including database IP address, No. Sid of database, the user name of log database, the port numbers of the login password of database and database), sentence Whether the database configuration parameters of disconnected input are correct.If correct, the connection between code comparison platform and database is established, and The configuration that platform is compared into code compares interface;The configuration compares interface and refers to for the display interface of configuration version content. If incorrect, newly-built linkage interface is shown again, so that user re-enters database configuration parameters.Specifically, judge number Whether correctly refer to judge whether all database configuration parameters correspond to same database according to library configuration parameter, that is, judge all numbers Its database to be connected can be uniquely directed toward according to library configuration parameter.
Further, code compares platform and obtains database configuration parameters input by user every time, is judging its input When database configuration parameters are incorrect, the current number of the incorrect database configuration parameters of same day input need to be counted, judging should Whether current number is more than preset times (such as 5 times);If current number is more than preset times, refuse code compare platform with Database connects, and is connected to avoid the disabled user by fishing test or other modes realization with database, is protected so as to play Protect the purpose of the data safety in database;If current number is not above preset times, display is newly-built again connects boundary Face, so that user re-enters database configuration parameters.
S20:The release content to be tested stored in database is obtained, release content to be tested is related to revision ID to be tested Connection.
Wherein, release content to be tested refers to the release content tested, which, which refers to, treats The code that beta version includes.The release content to be tested includes but not limited to installation kit configuration file, can be and software version The relevant All Files of this test, illustrate by taking release content to be tested as an example below, not with specific file (as installed Packet configuration file) it illustrates.Version to be tested code compare platform on can show it is multiple, every time into line code compare Release content to be tested be user's release content to be tested for choosing and confirming.Revision ID to be tested refers to for unique identification The mark of release content to be tested.
In the present embodiment, code compares platform according to version acquisition instruction to be tested input by user is obtained, this is to be tested Version acquisition instruction includes revision ID to be tested.Code comparison platform has created soft according to revision ID to be tested from database Part edition data table finds the associated storage address of release content to be tested corresponding with the revision ID to be tested, then root Release content to be tested is obtained, and compare the release content to be tested of acquisition on platform with information in code according to the storage address The form of item is shown in configuration and compares on interface.Version command to be tested can have a plurality of, and every comprising unique corresponding to be measured Try revision ID, i.e., release content to be tested can have it is multiple, and show information bar arrange from top to bottom in order.Believing It ceases on item, has multiple buttons that can carry out clicking operation, each button has its corresponding function (including checking, choosing, obtaining Homologous baseline version, deletion etc.).Wherein, the release content to be tested can be checked when button is checked in click;When click is chosen During button, the state that the corresponding release content to be tested of the information bar can be shown in information bar is to have chosen state, this is chosen For function for determining the release content to be tested compared into line code, a release content to be tested is chosen in each code comparison, Until release content to be tested is all surveyed.Release content to be tested is obtained by comparing platform in code, generation can be utilized The relationship that is connected with database of code comparison platform, compares to directly read on platform and stores in the database to be tested in code Release content greatly improves the efficiency of software version test.
In a specific embodiment, as shown in figure 3, in step S20, obtain in the version to be tested stored in database Hold, release content to be tested is associated with revision ID to be tested, specifically comprises the following steps:
S21:Obtain revision ID to be tested input by user.
In the present embodiment, compared in the configuration of code comparison platform and " obtaining a version to be tested " button be equipped on interface, User, which clicks on, can pop up a revision ID input frame to be tested, and wait for user's input correctly revision ID to be tested, So as to which code be made to compare the version acquisition instruction to be tested that platform obtains carrying revision ID to be tested.Specifically, version to be tested ID can be named with timestamp;Wherein, timestamp (timestamp) refers to that one can represent a data in some spy Time identifier that is already existing, complete before fixing time, can verify that;The time identifier is typically a character string, is used In the time for uniquely identifying certain a moment.After code, which compares platform, obtains correctly revision ID to be tested, it will be configured The information bar that the version to be tested is shown on interface is compared, user can input corresponding operation according to the button in the information bar Instruction.Code, which compares platform, can obtain multiple revision IDs to be tested input by user, and is compared in configuration and show phase on interface Multiple information bars are answered, each information bar represents corresponding each release content to be tested.
S22:The storage address of release content to be tested is searched according to revision ID to be tested, is obtained based on storage address to be measured Try release content.
In the present embodiment, code compare platform according to the revision ID to be tested of acquisition with it is each in software release data sheet Revision ID is matched, when matching the revision ID identical with revision ID to be tested input by user in software release data sheet When, it will release content to be tested is obtained, and with information bar according to the storage address of the revision ID corresponding software version to be tested Form be shown in configuration compare interface on.
S30:Based on revision ID to be tested, obtain in the baseline version homologous with revision ID to be tested stored in database Hold, baseline version content is associated with baseline version ID.
Wherein, baseline version can be understood as one " snapshot " of each software version in the specific period.It provides one Official standard, the change of subsequent software version could change this standard based on this standard only after mandate.It establishes After one initial baseline, the change carried out every time to it later will all be recorded as a difference, until building up next baseline version This.Therefore, baseline version can equally have multiple.Baseline version content refers to the code that baseline version includes.Baseline version ID Refer to for the mark of unique identification baseline version content.During software version is tested, release content and base to be tested Line release content is to compare essential two kinds of comparisons object into line code.In general, release content to be tested refers to out The release content that hair personnel modify to function in the baseline version content basis after a certain baseline version.Especially Ground, version to be tested are an opposite concepts, and baseline version content can also be used as release content to be tested, i.e. initial input Revision ID to be tested be specifically a certain baseline version ID.It is to be appreciated that in a baseline version when being compared into line code Hold the comparison between another baseline version content.
In the present embodiment, based on revision ID to be tested, by revision ID to be tested and the incidence relation of baseline version ID, obtain Take the baseline version content homologous with revision ID to be tested stored in database.Wherein, homologous is data source according to configuration Determining, data source refers to database used in database application or database server.Pass through version to be tested ID obtains homologous baseline version content, improves the efficiency that baseline version is obtained in software version test process.
In a specific embodiment, as shown in figure 4, in step S30, based on revision ID to be tested, obtain in database The baseline version content homologous with revision ID to be tested of storage, baseline version content is associated with baseline version ID, specific to wrap Include following steps:
S31:Based on revision ID to be tested, obtain and the homologous baseline version list of revision ID to be tested.
In the present embodiment, code compares platform and obtains the homologous baseline version acquisition that user inputs on configuration comparison interface Instruction.Specifically, i.e. information bar of the user according to release content to be tested, clicks homologous baseline version in information bar Button is obtained, code compares the homologous baseline version acquisition instruction that platform obtains button representative.It is obtained when code compares platform After the homologous baseline version acquisition instruction, it will searched in the database according to revision ID to be tested and obtain homologous baseline version This ID, and final be shown in the form of a list is configured on comparison interface, i.e., is compared in configuration and show homologous baseline on interface Version list.
S32:Based on baseline version list, baseline version selection instruction input by user, baseline version selection instruction are obtained Including baseline version ID.
In the present embodiment, configuration compares and shows the baseline version list for including multiple and different baseline version ID on interface, It is that family can be used to compare platform input baseline version selection instruction to code that user, which clicks configuration and compares any baseline version in interface, The baseline version selection instruction carries the corresponding baseline version ID of baseline version that user clicks.Code compares platform should in acquisition After baseline version selection instruction, obtained and the baseline version ID phases entrained by baseline version selection instruction in baseline version list Corresponding baseline version content.It is clicked on configuration comparison interface in baseline version list it is to be appreciated that the process is user One of baseline version operation, to obtain baseline version content.
S33:Based on baseline version ID, the baseline version content stored in database is obtained.
In the present embodiment, code compares platform according in the baseline version ID of acquisition and the baseline version tables of data created Each revision ID matched, when matching the version identical with baseline version ID input by user in baseline version tables of data During this ID, it will the storage address that baseline version is corresponded to according to the revision ID obtains baseline version content, and with the shape of information bar Formula is shown in configuration and compares on interface.It is similar to release content to be tested, the operation of multiple functions is equipped with equally in information bar Button (including checking, choosing, into subbase line release content interface, deletion etc.).
S40:It treats beta version content and baseline version content to compare into line code, obtains comparison result.
In the present embodiment, code compares and shows multiple and different release contents to be tested on the configuration comparison interface of platform With the information bar of baseline version content, according to the release content and baseline version to be tested in the user's click information table got Content and input choose instruction, determine release content and the baseline version content to be tested compared into line code, and in platform On treat beta version content and baseline version content is compared, obtain comparison result.Platform is compared by the code, it can be with The each release content to be tested compared into line code and baseline version properties collection will be needed on a platform, it is straight to realize The function of reading and code comparison is connect, can easily obtain the release content needed for being compared into line code, and scheme in visualization It realizes that the unrestricted choice of release content and baseline version content to be tested compares on shape interface, improves and carry out software version test Flexibility, greatly improve software version test efficiency.
In a specific embodiment, in step S40, platform is compared based on code, treats beta version content and baseline Release content is compared, and obtains comparison result, specifically comprises the following steps:
S411:It obtains full code input by user and compares instruction, comparing instruction according to full code treats beta version content Character string comparison is carried out with baseline version content, obtains comparison result;Comparison result is highlighted in release content to be tested At the difference of code and the code in baseline version content.
In the present embodiment, the release content and baseline version to be tested compared into line code is chosen in configuration compares interface After content, comparing interface in configuration originally will be shown as in the code comparison button that can not click state (such as grey is shown) State is clicked with what configuration compared interface same color depth, when the release content chosen is release content to be tested and baseline During release content, which compares the corresponding instruction of button and compares instruction for full code.After user, which clicks code, compares button, Code comparison platform will obtain full code comparison and instruct, in the instruction and the release content and baseline version to be tested specifically chosen Hold associated.Code compares platform and performs full code comparison instruction, which compares instruction will be at configuration comparison interface Code in release content and the baseline version content to be tested chosen is compared, if the release content and base to be tested chosen Line release content does not meet the principle of code comparison, then can not be compared into line code, and configuration, which compares interface, will feed back and show Error message reminds user to carry out correctly choosing operation.Such as when user has chosen multiple and different versions to be tested simultaneously Code is clicked after content and compares button, configuration comparison interface, which will be shown, " please select a version to be tested!" prompting box, User is reminded to cancel the extra release content to be tested chosen.Platform is compared by code and treats beta version content and baseline version This content is compared into line code, concrete mode alignments to carry out character string comparison, to the code in beta version content and The enterprising line character string in the corresponding position of code in baseline version content compares, and obtains comparison result.
By carrying out character string comparison, code compares will be by beta version content and baseline version on the display interface of platform Code in this content shows that for the content of beta version in the left side of display interface, the content of baseline version is showing boundary The right side in face.(i.e. different part) will highlight at the difference that wherein character string compares, this is highlighted can be with It is highlighted for color or code overstriking is shown etc. highlights mode, user to be facilitated to check comparison result.
In a specific embodiment, as shown in figure 5, in step S40, platform is compared based on code, treats beta version Content and baseline version content are compared, and obtain comparison result, can also specifically include the following steps:
S421:Subbase line release content acquisition instruction input by user is obtained, subbase line release content acquisition instruction includes Subbase line revision ID.
Wherein, subbase line release content refers to the baseline version content with part standalone feature in baseline version content Functional component can be specifically the sub- content in entire baseline version content with part standalone feature.In the present embodiment, Code compares platform and obtains subbase line release content acquisition instruction input by user, and specially user is according to subbase line release content Shown information bar, clicks to enter subbase line release content interface button in information bar, and code compares platform and enters subbase Line release content interface;Then, code compares platform and obtains subbase line release content acquisition instruction input by user, specially hooks Subbase line release content needed for the subbase line release content interface is selected, each subbase line release content includes corresponding one Subbase line revision ID.
S422:Corresponding subbase line release content is obtained based on subbase line revision ID.
In the present embodiment, after code compares platform acquisition subbase line release content acquisition instruction, it will according to subbase line version This ID searches the subbase line revision ID in the software release data sheet created, and passes through this subbase line revision ID is corresponding and deposit It stores up address and obtains subbase line release content.
S423:It obtains first code input by user and compares instruction, comparing instruction according to first code treats beta version Content and subbase line release content carry out character string comparison, obtain comparison result, and comparison result is highlighted in version to be tested At the difference of the code of code and subbase line release content in appearance.
In the present embodiment, after subbase line release content is obtained, code compares platform and obtains the first generation input by user Code compares instruction, and after specially user's click code compares button, code, which compares platform, will obtain first code comparison instruction, should Instruction is associated with release content and subbase the line release content to be tested specifically chosen, i.e., the comparison object that ought be compared is During release content and baseline version content to be tested, which compares the corresponding instruction of button and compares instruction for first code.Generation Code comparison platform will perform the instruction after configuration compares interface acquisition first code comparison instruction, which will be in configuration ratio Code in release content and subbase the line release content to be tested chosen to interface is compared, the comparison result and ratio of acquisition To result to highlight effect similar to step S411, do not repeat one by one herein.The present embodiment is using version to be tested The comparison of content and subbase line release content, user can carry out specific part content (i.e. subbase line release content) as needed It is compared with release content to be tested, by using the comparison of specific part content (i.e. subbase line release content), improves soft Part testing efficiency.
In a specific embodiment, as shown in fig. 6, in step S40, platform is compared based on code, treats beta version Content and baseline version content are compared, and obtain comparison result, can also specifically include the following steps:
S431:Obtain subbase line release content acquisition instruction input by user and module contents acquisition instruction to be measured, subbase Line release content acquisition instruction includes subbase line revision ID, and module contents instruction to be measured includes module I D to be measured.
Wherein, module contents to be measured refers to the release content to be tested in release content to be tested with part standalone feature Functional component, can be specifically the sub- content in entire release content to be tested with part standalone feature.This implementation In example, code compares platform and obtains subbase line release content acquisition instruction input by user and module contents acquisition instruction to be measured, Specially information bar of the user according to subbase line release content, clicks to enter subbase line release content circle in information bar Face button, code compare platform and enter subbase line release content interface, obtain subbase line release content acquisition input by user and refer to It enables, specially chooses subbase line release content needed for the interface, each subbase line release content includes a corresponding son Baseline version ID.Information bar of the user according to release content to be tested, clicks to enter in information bar in module to be measured Hold interface button, code compares platform and enters module contents interface to be measured, obtains module contents acquisition to be measured input by user and refers to It enables, specially chooses module contents to be measured needed for the interface, each module contents to be measured includes a corresponding mould to be measured Block ID.
S432:Corresponding subbase line release content is obtained based on subbase line revision ID.
It is identical with step S422, it does not repeat one by one herein.
S433:Corresponding module contents to be measured is obtained based on module I D to be measured.
In the present embodiment, after code compares platform acquisition module contents acquisition instruction to be measured, it will according to module I D to be measured The module I D to be measured is searched in the software release data sheet created, and passes through the corresponding storage address of the module I D to be measured and obtains Take module contents to be measured.
S434:It obtains second code input by user and compares instruction, instructed according to second code to sub- baseline version content Character string comparison is carried out with module contents to be measured, obtains comparison result, comparison result highlights the generation in module contents to be measured At the difference of code in code and subbase line release content.
Similar to step S423, the instruction difference lies in acquisition is second code instruction, and what is be compared is module to be measured Content and subbase line release content, by using the ratio of specific part content (i.e. subbase line release content) and module contents to be measured It is right, testing efficiency can be further improved.
In the software version test method that the present embodiment is provided, code is run first and compares platform, by running code Platform is compared, can realize the unified management of release content and baseline version content to be tested, is conducive to directly read platform survey Examination environment data base in release content and baseline version content to be tested go forward side by side line code comparison, improve software version test Efficiency.Then the release content to be tested stored in database is obtained, release content to be tested is associated with revision ID to be tested, The connection established between platform and database is compared by code, the version to be tested of storage in the database can be directly read Content improves the efficiency for obtaining beta version content.Be then based on revision ID to be tested, obtain stored in database with it is to be measured The homologous baseline version content of revision ID is tried, baseline version content is associated with baseline version ID, and platform energy is compared by code Enough contacts according between version to be tested and baseline version obtain baseline version content, improve the effect for obtaining baseline version content Rate.Finally treat beta version content and baseline version content into line code compare, obtain comparison result, and by comparison result into Row highlights, and platform is compared by code, can be straight to release content and the baseline version content to be tested obtained in platform Tap into line code comparison, and show comparison result on display interface, realize code compare carried out on platform it is to be measured The function that release content and baseline version content code compare is tried, is conducive to user and directly easily obtains comparison from code platform As a result so that the effect of software version test is more preferable, more efficient.
It should be understood that the size of the serial number of each step is not meant to the priority of execution sequence, each process in above-described embodiment Execution sequence should determine that the implementation process without coping with the embodiment of the present invention forms any limit with its function and internal logic It is fixed.
Embodiment 2
Fig. 7 shows the principle frame with the one-to-one software version test device of software version test method in embodiment 1 Figure.As shown in fig. 7, the software version test device includes, code compares platform operation module 10, release content to be tested obtains Module 20, baseline version content obtaining module 30 and comparison result acquisition module 40.Wherein, code compares platform operation module 10th, the realization of release content acquisition module 20 to be tested, baseline version content obtaining module 30 and comparison result acquisition module 40 Function step corresponding with software version test method in embodiment corresponds, and is repeated to avoid, and the present embodiment is not detailed one by one It states.
Code compares platform operation module 10, and platform is compared for running code.
Release content acquisition module 20 to be tested, for obtaining the release content to be tested stored in database.
Baseline version content obtaining module 30, for being based on revision ID to be tested, obtain stored in database with it is to be measured Try the homologous baseline version content of revision ID.
Comparison result acquisition module 40 is compared into line code for treating beta version content and baseline version content, is obtained Take comparison result.
Preferably, code compares platform operation module 10 and is connected including database configuration parameters acquiring unit 11 with database Unit 12.
Database configuration parameters acquiring unit 11 compares platform for code and obtains database configuration ginseng input by user Number.
Database connection unit 12, for according to database configuration parameters, code being made to compare platform and is connected with database.
Wherein, the IP address of database configuration parameters including database, No. Sid of database, the user of log database The port numbers of name, the login password of database and database.
Preferably, release content acquisition module 20 to be tested includes revision ID acquiring unit 21 to be tested and version to be tested Contents acquiring unit 22.
Revision ID acquiring unit 21 to be tested, for obtaining revision ID to be tested input by user.
Release content acquiring unit 22 to be tested, for searching the storage of release content to be tested according to revision ID to be tested Address obtains release content to be tested based on storage address.
Preferably, baseline version content obtaining module 30, including baseline version list acquiring unit 31, version selection instruction Acquiring unit 32 and baseline version contents acquiring unit 33.
Baseline version list acquiring unit 31 for being based on revision ID to be tested, obtains homologous with revision ID to be tested Baseline version list.
Version selection instruction acquiring unit 32 for being based on baseline version list, obtains baseline version choosing input by user Instruction is selected, baseline version selection instruction includes baseline version ID.
Baseline version contents acquiring unit 33 for being based on baseline version ID, obtains the baseline version stored in database Content.
Preferably, comparison result acquisition module 40 includes full code comparison result acquiring unit 411.
Full code comparison result acquiring unit 411 compares instruction, according to full code for obtaining full code input by user It compares instruction and treats beta version content and the progress character string comparison of baseline version content, obtain comparison result;Comparison result is dashed forward At the difference for going out to show the code in release content to be tested and the code in baseline version content.
Preferably, comparison result acquisition module 40 further includes subbase line revision ID acquiring unit 421, the first sub- baseline version Contents acquiring unit 422 and first code comparison result acquiring unit 423.
Subbase line revision ID acquiring unit 421, for obtaining subbase line release content acquisition instruction input by user, subbase Line release content acquisition instruction includes subbase line revision ID.
First subbase line release content acquiring unit 422 obtains corresponding subbase line version for being based on subbase line revision ID This content.
First code comparison result acquiring unit 423 compares instruction for obtaining first code input by user, according to the One code compares instruction and treats beta version content and the progress character string comparison of subbase line release content, obtains comparison result;Than At the difference that the code of the code and subbase line release content in release content to be tested is highlighted to result.
Preferably, comparison result acquisition module 40 further includes subbase line revision ID and module I D acquiring units 431 to be measured, the Two subbase line release content acquiring units 432, module contents acquiring unit 433 to be measured and second code comparison result acquiring unit 434。
Subbase line revision ID and module I D acquiring units 431 to be measured, for obtaining subbase line release content input by user Acquisition instruction and module contents acquisition instruction to be measured, subbase line release content acquisition instruction include subbase line revision ID, mould to be measured Block content instruction includes module I D to be measured.
Second subbase line release content acquiring unit 432 obtains corresponding subbase line version for being based on subbase line revision ID This content.
Module contents acquiring unit 433 to be measured obtains corresponding module contents to be measured for being based on module I D to be measured.
Second code comparison result acquiring unit 434 compares instruction for obtaining second code input by user, according to the Two codes compare instruction and carry out character string comparison to sub- baseline version content and module contents to be measured, obtain comparison result;It compares As a result at the difference for highlighting the code in module contents to be measured and the code in subbase line release content.
In the software version test device that the present embodiment is provided, code compares platform operation module 10, for running generation Code comparison platform, can realize the unified management of release content and baseline version content to be tested, be conducive to directly read platform Release content and baseline version content to be tested in test environment database go forward side by side line code comparison, improve software version test Efficiency.Release content acquisition module 20 to be tested for obtaining the release content to be tested stored in database, passes through code The connection established between platform and database is compared, the release content to be tested of storage in the database can be directly read, carried Height obtains the efficiency of beta version content.Baseline version content obtaining module 30 for being based on revision ID to be tested, obtains data The baseline version content homologous with revision ID to be tested stored in library, comparing platform by code can be according to version to be tested Contact between baseline version obtains baseline version content, improves the efficiency for obtaining baseline version content.Comparison result obtains Module 40 compares into line code for treating beta version content and baseline version content, comparison result is obtained, by comparison result It is highlighted, release content and the baseline version content to be tested obtained in platform can directly be compared into line code, And show comparison result on display interface, it realizes and carries out release content and baseline to be tested on code comparison platform The function that release content code compares, is conducive to user and directly easily obtains comparison result from code platform so that software version The effect of this test is more preferable, more efficient.
Embodiment 3
The present embodiment provides a computer readable storage medium, computer journey is stored on the computer readable storage medium Sequence is realized software version test method in embodiment 1, is repeated to avoid, here not when the computer program is executed by processor It repeats again.Alternatively, realized when the computer program is executed by processor in embodiment 2 each module in software version test device/ The function of unit is repeated to avoid, and which is not described herein again.
Embodiment 4
Fig. 8 is the schematic diagram of terminal device in the present embodiment.As shown in figure 8, terminal device 80 includes processor 81, storage Device 82 and it is stored in the computer program 83 that can be run in memory 82 and on processor 81.Processor 81 performs computer Each step of software version test method in embodiment 1, such as step S10, S20, S30 shown in FIG. 1 are realized during program 83 And S40.Alternatively, processor 81 realizes each module/unit of software version test device in embodiment 2 when performing computer program 83 Function, code as shown in Figure 7 compares platform operation module 10, release content acquisition module 20 to be tested, baseline version content The function of acquisition module 30 and comparison result acquisition module 40.
Illustratively, computer program 83 can be divided into one or more module/units, one or more mould Block/unit is stored in memory 82, and is performed by processor 81, to complete the present invention.One or more module/units can To be the series of computation machine program instruction section that can complete specific function, the instruction segment is for describing computer program 83 at end Implementation procedure in end equipment 80.For example, the code that computer program 80 can be divided into embodiment 2 compares platform operation mould Block 10, release content acquisition module 20 to be tested, baseline version content obtaining module 30 and comparison result acquisition module 40, each mould The concrete function of block as described in Example 2, is repeated to avoid, is not repeated one by one herein.
Terminal device 80 can be the computing devices such as desktop PC, notebook, palm PC and cloud server.Eventually End equipment may include, but be not limited only to, processor 81, memory 82.It will be understood by those skilled in the art that Fig. 8 is only eventually The example of end equipment 80 does not form the restriction to terminal device 80, can include than illustrate more or fewer components or Combine certain components or different components, for example, terminal device can also include input-output equipment, network access equipment, Bus etc..
Alleged processor 81 can be central processing unit (Central Processing Unit, CPU), can also be Other general processors, digital signal processor (Digital Signal Processor, DSP), application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field- Programmable Gate Array, FPGA) either other programmable logic device, discrete gate or transistor logic, Discrete hardware components etc..General processor can be microprocessor or the processor can also be any conventional processor Deng.
Memory 82 can be the internal storage unit of terminal device 80, such as the hard disk or memory of terminal device 80.It deposits Reservoir 82 can also be the plug-in type hard disk being equipped on the External memory equipment of terminal device 80, such as terminal device 80, intelligence Storage card (Smart Media Card, SMC), secure digital (Secure Digital, SD) card, flash card (Flash Card) Deng.Further, memory 82 can also both include the internal storage unit of terminal device 80 or including External memory equipment.It deposits Reservoir 82 is used to store computer program and other programs and data needed for terminal device.Memory 82 can be also used for temporarily When store the data that has exported or will export.
It is apparent to those skilled in the art that for convenience of description and succinctly, only with above-mentioned each work( Can unit, module division progress for example, in practical application, can be as needed and by above-mentioned function distribution by different Functional unit, module are completed, i.e., the internal structure of described device are divided into different functional units or module, more than completion The all or part of function of description.
In addition, each functional unit in each embodiment of the present invention can be integrated in a processing unit, it can also That each unit is individually physically present, can also two or more units integrate in a unit.Above-mentioned integrated list The form that hardware had both may be used in member is realized, can also be realized in the form of SFU software functional unit.
If the integrated module/unit realized in the form of SFU software functional unit and be independent product sale or In use, it can be stored in a computer read/write memory medium.Based on such understanding, the present invention realizes above-mentioned implementation All or part of flow in example method, can also instruct relevant hardware to complete, the meter by computer program Calculation machine program can be stored in a computer readable storage medium, the computer program when being executed by processor, it can be achieved that on The step of stating each embodiment of the method.Wherein, the computer program includes computer program code, the computer program generation Code can be source code form, object identification code form, executable file or certain intermediate forms etc..The computer-readable medium It can include:Any entity of the computer program code or device, recording medium, USB flash disk, mobile hard disk, magnetic can be carried Dish, CD, computer storage, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electric carrier signal, telecommunication signal and software distribution medium etc..It is it should be noted that described The content that computer-readable medium includes can carry out appropriate increasing according to legislation in jurisdiction and the requirement of patent practice Subtract, such as in certain jurisdictions, according to legislation and patent practice, computer-readable medium do not include be electric carrier signal and Telecommunication signal.
Embodiment described above is merely illustrative of the technical solution of the present invention, rather than its limitations;Although with reference to aforementioned reality Example is applied the present invention is described in detail, it will be understood by those of ordinary skill in the art that:It still can be to aforementioned each Technical solution recorded in embodiment modifies or carries out equivalent replacement to which part technical characteristic;And these are changed Or replace, the spirit and scope for various embodiments of the present invention technical solution that it does not separate the essence of the corresponding technical solution should all It is included within protection scope of the present invention.

Claims (10)

1. a kind of software version test method, which is characterized in that including:It runs code and compares platform, the code compares platform It is connected with database;
The software version test method further includes the following steps for being compared platform by the code and being performed:
The release content to be tested stored in the database is obtained, the release content to be tested is related to revision ID to be tested Connection;
Based on the revision ID to be tested, the baseline version homologous with the revision ID to be tested stored in the database is obtained This content;
The release content to be tested and the baseline version content into line code are compared, obtain comparison result.
2. software version test method according to claim 1, which is characterized in that the code compares platform and database It is connected, including:
The code compares platform and obtains database configuration parameters input by user;
According to the database configuration parameters, the code is made to compare platform and is connected with the database;
The IP address of database configuration parameters including database, No. Sid of database, the user name of log database, number According to the login password in library and the port numbers of database.
3. software version test method according to claim 1, which is characterized in that described obtain stores in the database Release content to be tested, including:
Obtain revision ID to be tested input by user;
The storage address of release content to be tested is searched according to the revision ID to be tested, based on described in storage address acquisition Release content to be tested.
4. software version test method according to claim 1, which is characterized in that described to be based on the version to be tested ID obtains the baseline version content homologous with the release content to be tested stored in the database, including:
Based on the revision ID to be tested, obtain and the homologous baseline version list of the revision ID to be tested;
Based on the baseline version list, baseline version selection instruction input by user, the baseline version selection instruction are obtained Including baseline version ID;
Based on the baseline version ID, the baseline version content stored in the database is obtained.
5. software version test method according to claim 1, which is characterized in that described to the release content to be tested It is compared with the baseline version content into line code, obtains comparison result, including:
Obtain full code input by user and compare instruction, according to the full code compare instruction to the release content to be tested and The baseline version content carries out character string comparison, obtains comparison result;The comparison result highlights the test run to be measured At the difference of code in this content and the code in the baseline version content.
6. software version test method according to claim 1, which is characterized in that described to the release content to be tested It is compared with the baseline version content into line code, obtains comparison result, further include:
Subbase line release content acquisition instruction input by user is obtained, the subbase line release content acquisition instruction includes subbase line Revision ID;
Corresponding subbase line release content is obtained based on the subbase line revision ID;
It obtains first code input by user and compares instruction, instruction is compared in the version to be tested according to the first code Hold and the subbase line release content carries out character string comparison, obtain comparison result;The comparison result highlights described treat At the difference of the code of code and the subbase line release content in beta version content.
7. software version test method according to claim 1, which is characterized in that described to the release content to be tested It is compared with the baseline version content into line code, obtains comparison result, further include:
Obtain subbase line release content acquisition instruction input by user and module contents acquisition instruction to be measured, the sub- baseline version Content obtaining instruction includes subbase line revision ID, and the module contents instruction to be measured includes module I D to be measured;
Corresponding subbase line release content is obtained based on the subbase line revision ID;
Corresponding module contents to be measured is obtained based on the module I D to be measured;
It obtains second code input by user and compares instruction, instruction is compared in the sub- baseline version according to the second code Hold and the module contents to be measured carries out character string comparison, obtain comparison result;The comparison result highlights described to be measured At the difference of code in module contents and the code in the subbase line release content.
8. a kind of software version test device, which is characterized in that including:
Code compares platform operation module, and platform is compared for running code;
Release content acquisition module to be tested, for obtaining the release content to be tested stored in the database;
Baseline version content obtaining module, for being based on the revision ID to be tested, obtain stored in the database with institute State the homologous baseline version content of revision ID to be tested;
Comparison result acquisition module, for being compared to the release content to be tested and the baseline version content into line code, Obtain comparison result.
9. a kind of terminal device, including memory, processor and it is stored in the memory and can be on the processor The computer program of operation, which is characterized in that the processor realizes such as claim 1 to 7 when performing the computer program The step of any one software version test method.
10. a kind of computer readable storage medium, the computer-readable recording medium storage has computer program, and feature exists In realizing the software version test method as described in any one of claim 1 to 7 when the computer program is executed by processor Step.
CN201711070064.9A 2017-11-03 2017-11-03 Software version test method, device, terminal device and storage medium Active CN108268374B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201711070064.9A CN108268374B (en) 2017-11-03 2017-11-03 Software version test method, device, terminal device and storage medium
PCT/CN2018/081532 WO2019085386A1 (en) 2017-11-03 2018-04-02 Software version test method and apparatus, terminal device, and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711070064.9A CN108268374B (en) 2017-11-03 2017-11-03 Software version test method, device, terminal device and storage medium

Publications (2)

Publication Number Publication Date
CN108268374A true CN108268374A (en) 2018-07-10
CN108268374B CN108268374B (en) 2019-03-05

Family

ID=62770952

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711070064.9A Active CN108268374B (en) 2017-11-03 2017-11-03 Software version test method, device, terminal device and storage medium

Country Status (2)

Country Link
CN (1) CN108268374B (en)
WO (1) WO2019085386A1 (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109829083A (en) * 2019-01-25 2019-05-31 深圳市金泰克半导体有限公司 SPD data automatic verification method, device, computer equipment and storage medium
CN110389903A (en) * 2019-07-19 2019-10-29 中国工商银行股份有限公司 Test environment dispositions method and device, electronic equipment and readable storage medium storing program for executing
CN113138933A (en) * 2021-05-13 2021-07-20 网易(杭州)网络有限公司 Data table testing method, electronic device and storage medium
CN115118616A (en) * 2022-04-29 2022-09-27 腾讯科技(深圳)有限公司 Display result testing method and device, computer equipment and storage medium

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113448862B (en) * 2021-07-12 2022-08-02 上海哔哩哔哩科技有限公司 Software version testing method and device and computer equipment

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102495790A (en) * 2011-10-20 2012-06-13 镇江睿泰信息科技有限公司 Version change difference identifier and version change identification method
CN102722436A (en) * 2012-05-29 2012-10-10 百度在线网络技术(北京)有限公司 Statistical method and device for incremental coverage information
CN102929600A (en) * 2012-06-13 2013-02-13 许继集团有限公司 ELF (executable and linkable format)-based monitoring system version recognition method
US8881109B1 (en) * 2009-01-22 2014-11-04 Intuit Inc. Runtime documentation of software testing
US8978013B1 (en) * 2013-10-09 2015-03-10 Electronic Arts Inc. Autonomous media version testing
US9547579B1 (en) * 2014-12-30 2017-01-17 Ca, Inc. Method and apparatus for automatically detecting defects
CN106445812A (en) * 2016-08-31 2017-02-22 上海携程商务有限公司 Regression test system and regression test method
CN106528399A (en) * 2015-09-15 2017-03-22 腾讯科技(深圳)有限公司 Test case determination method and apparatus
CN106528428A (en) * 2016-11-24 2017-03-22 中山大学 Method for constructing software variability prediction model

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105302710B (en) * 2014-07-03 2019-06-07 腾讯科技(深圳)有限公司 The method and apparatus that a kind of determination needs the test case of regression test

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8881109B1 (en) * 2009-01-22 2014-11-04 Intuit Inc. Runtime documentation of software testing
CN102495790A (en) * 2011-10-20 2012-06-13 镇江睿泰信息科技有限公司 Version change difference identifier and version change identification method
CN102722436A (en) * 2012-05-29 2012-10-10 百度在线网络技术(北京)有限公司 Statistical method and device for incremental coverage information
CN102929600A (en) * 2012-06-13 2013-02-13 许继集团有限公司 ELF (executable and linkable format)-based monitoring system version recognition method
US8978013B1 (en) * 2013-10-09 2015-03-10 Electronic Arts Inc. Autonomous media version testing
US9547579B1 (en) * 2014-12-30 2017-01-17 Ca, Inc. Method and apparatus for automatically detecting defects
CN106528399A (en) * 2015-09-15 2017-03-22 腾讯科技(深圳)有限公司 Test case determination method and apparatus
CN106445812A (en) * 2016-08-31 2017-02-22 上海携程商务有限公司 Regression test system and regression test method
CN106528428A (en) * 2016-11-24 2017-03-22 中山大学 Method for constructing software variability prediction model

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109829083A (en) * 2019-01-25 2019-05-31 深圳市金泰克半导体有限公司 SPD data automatic verification method, device, computer equipment and storage medium
CN110389903A (en) * 2019-07-19 2019-10-29 中国工商银行股份有限公司 Test environment dispositions method and device, electronic equipment and readable storage medium storing program for executing
CN110389903B (en) * 2019-07-19 2023-08-22 中国工商银行股份有限公司 Test environment deployment method and device, electronic equipment and readable storage medium
CN113138933A (en) * 2021-05-13 2021-07-20 网易(杭州)网络有限公司 Data table testing method, electronic device and storage medium
CN115118616A (en) * 2022-04-29 2022-09-27 腾讯科技(深圳)有限公司 Display result testing method and device, computer equipment and storage medium
CN115118616B (en) * 2022-04-29 2024-04-23 腾讯科技(深圳)有限公司 Display result testing method, device, computer equipment and storage medium

Also Published As

Publication number Publication date
WO2019085386A1 (en) 2019-05-09
CN108268374B (en) 2019-03-05

Similar Documents

Publication Publication Date Title
CN108268374B (en) Software version test method, device, terminal device and storage medium
CN108268253B (en) Interface code generation method and terminal equipment
US20210117210A1 (en) Methods and Systems for Integrated Development Environment Editor Support with a Single Code Base
US8151244B2 (en) Merging graphical programs based on an ancestor graphical program
CN107408043A (en) System and method for the intelligence tool in sequence streamline
CN109643270A (en) Multi-layer testing external member generates
CN108255714A (en) Interface document builds test method and terminal device
CN108293081A (en) Pass through the program playback deep linking of user interface event to mobile application state
CN111552627A (en) User interface testing method and device, storage medium and computer equipment
CN107766040A (en) A kind of method, apparatus and computer-readable recording medium for generating interface document
CN106559438A (en) A kind of program method for uploading and device based on objective network platform
CN110221968A (en) Method for testing software and Related product
US20140331212A1 (en) Computer implemented system and method for indexing and annotating use cases and generating test scenarios therefrom
CN108563445A (en) Application code detection method and server
CN110287002A (en) A kind of ether mill virtual machine defect inspection method and system
CN111414374B (en) Block chain transaction concurrent processing method, device and equipment
CN107704546A (en) Page configuration method and server
CN110378561A (en) Order tracking management method, device and storage medium
CN111176980B (en) Data analysis method, device and system for separating debugging environment and running environment
CN107679222A (en) Image processing method, mobile terminal and computer-readable recording medium
CN110874365A (en) Information query method and related equipment thereof
Sinha et al. Mince: Mining change history of android project
CN110879701A (en) Workflow visualization configuration method, server, system and medium
CN113641628B (en) Data quality detection method, device, equipment and storage medium
CN109522201A (en) A kind of method and apparatus of application program stability test

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