CN112905488A - Link testing method and device, computer equipment and storage medium - Google Patents

Link testing method and device, computer equipment and storage medium Download PDF

Info

Publication number
CN112905488A
CN112905488A CN202110343797.5A CN202110343797A CN112905488A CN 112905488 A CN112905488 A CN 112905488A CN 202110343797 A CN202110343797 A CN 202110343797A CN 112905488 A CN112905488 A CN 112905488A
Authority
CN
China
Prior art keywords
link
tested
module
information
modules
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
CN202110343797.5A
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 Saiante Technology Service Co Ltd
Original Assignee
Ping An International Smart City 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 Ping An International Smart City Technology Co Ltd filed Critical Ping An International Smart City Technology Co Ltd
Priority to CN202110343797.5A priority Critical patent/CN112905488A/en
Publication of CN112905488A publication Critical patent/CN112905488A/en
Pending legal-status Critical Current

Links

Images

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/3664Environments for testing or debugging software

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 application discloses a link testing method, a device, computer equipment and a storage medium, comprising the following steps: the method comprises the steps of operating a link to be tested, and inputting data to be tested to the link to be tested, wherein the link to be tested comprises N modules, and N is a positive integer greater than or equal to 2; acquiring a first information set of the N modules, wherein the first information set comprises: when a link to be tested is operated, each module in the N modules generates a set of first information based on data to be tested; comparing the first information set with the second information set to generate a comparison result; and determining whether the link to be tested normally operates based on the comparison result. The data generated by each module in the link to be tested is compared with the normal data, so that whether the link to be tested is abnormal or not is determined, whether each module in the complex link is abnormal or not can be detected in the testing process, the comprehensiveness and accuracy of the link testing are improved, and the abnormal conditions in the subsequent production environment are reduced.

Description

Link testing method and device, computer equipment and storage medium
Technical Field
The embodiment of the invention relates to the field of automatic testing, in particular to a link testing method, a link testing device, computer equipment and a storage medium.
Background
When a functional link is developed, it needs to be tested. Generally, after a test case is designed and reviewed, a tester performs tests step by step according to the procedures described in the test case, and obtains a comparison between an actual result and an expected result, and the automated tests are a process for converting human-driven test behaviors into machine execution.
In the prior art, an automated testing process usually only checks a final return value of a testing link, and judges whether the link is abnormal or not according to the final return value. However, for complex links such as a payment link, it is not enough to detect only the final return value, and the existing automated testing process cannot detect whether the middle module of the complex link is abnormal, so that the test is not comprehensive enough, and further, the abnormal condition occurs in the use process.
Disclosure of Invention
The embodiment of the invention provides a link testing method and device, computer equipment and a storage medium, which can comprehensively test a complex link.
In order to solve the above technical problem, the embodiment of the present invention adopts a technical solution that: provided is a link test method, including:
the method comprises the steps of operating a link to be tested, and inputting data to be tested to the link to be tested, wherein the link to be tested comprises N modules, and N is a positive integer greater than or equal to 2;
acquiring a first information set of the N modules, wherein the first information set comprises: each module in the N modules generates a first information set based on the data to be tested when the link to be tested is operated;
comparing the first information set with a second information set to generate a comparison result, wherein the second information set comprises: under the condition that a link to be tested normally runs, each module in the N modules generates a set of second information;
and determining whether the link to be tested normally operates based on the comparison result.
Optionally, the comparing the first information set with the second information set to generate a comparison result includes:
if the first input value and the second input value of the target module are different, and/or the first output value and the second output value of the target module are different, determining that the link to be tested operates abnormally, otherwise, determining that the link to be tested operates normally;
wherein the target module is any one of the N modules; the second input value and the second output value are the input value and the output value of the target module under the condition that the link to be tested normally runs.
Optionally, after determining whether the link to be tested operates normally based on the comparison result, the method further includes:
and if the comparison result indicates that the link to be tested operates abnormally, determining the target module as an abnormal module.
Optionally, before comparing the first information set with the second information set and generating a comparison result, the method further includes:
storing first information and target information of each of the N modules in an associated manner;
wherein the target information comprises at least one of a name of the module and a network address of the module.
Optionally, the data to be tested is test data indicated by a target case, the target case is any test case in a case set, the case set includes M test cases, one test case corresponds to one second information set, and M is a positive integer greater than or equal to 2.
Optionally, the first information set is obtained according to an input value and an output value of each of the N modules recorded in the target log; and the target log is a log generated when the link to be tested runs based on the data to be tested.
To solve the above technical problem, an embodiment of the present invention further provides a link testing apparatus, including:
the device comprises an input module, a data acquisition module and a data processing module, wherein the input module is used for operating a link to be tested and inputting data to be tested to the link to be tested, the link to be tested comprises N modules, and N is a positive integer greater than or equal to 2;
an obtaining module, configured to obtain a first information set of the N modules, where the first information set includes: each module in the N modules generates a first information set based on the data to be tested when the link to be tested is operated;
a comparison module, configured to compare the first information set obtained by the obtaining module with a second information set, and generate a comparison result, where the second information set includes: under the condition that a link to be tested normally runs, each module in the N modules generates a set of second information;
and the determining module is used for determining whether the link to be tested normally operates based on the comparison result generated by the comparison module.
Optionally, the comparison module is specifically configured to determine that the link to be tested operates abnormally if the first input value and the second input value of the target module are different and/or the first output value and the second output value of the target module are different, and otherwise, determine that the link to be tested operates normally; wherein the target module is any one of the N modules; the second input value and the second output value are the input value and the output value of the target module under the condition that the link to be tested normally runs.
Optionally, the determining module is specifically configured to determine the target module as an abnormal module if the comparison result generated by the comparing module indicates that the to-be-detected link operates abnormally.
Optionally, the link testing apparatus further includes: a storage module; the storage module is used for storing the first information and the target information of each of the N modules in an associated manner; wherein the target information comprises at least one of a name of the module and a network address of the module.
Optionally, the data to be tested is test data indicated by a target case, the target case is any test case in a case set, the case set includes M test cases, one test case corresponds to one second information set, and M is a positive integer greater than or equal to 2.
Optionally, the first information set is obtained according to the input value and the output value of each of the N modules recorded in the target log; and the target log is a log generated when the link to be tested runs based on the data to be tested.
In order to solve the above technical problem, an embodiment of the present invention further provides a computer device, including a memory and a processor, where the memory stores computer-readable instructions, and the computer-readable instructions, when executed by the processor, cause the processor to execute the steps of the above-mentioned link testing method.
In order to solve the above technical problem, an embodiment of the present invention further provides a storage medium storing computer-readable instructions, which, when executed by one or more processors, cause the one or more processors to execute the steps of the above-mentioned link testing method.
The embodiment of the invention has the beneficial effects that: the data to be detected is input into the link to be detected, and the data generated by each module in the N modules when the link to be detected runs is obtained based on the data to be detected. And then, comparing the data with correct data which should be generated by each module in the N modules under the condition that the link to be detected normally runs, and generating a comparison result. And finally, determining whether the link to be tested normally operates based on the comparison result, so that whether each module in the complex link is abnormal or not can be detected in the automatic test process, the comprehensiveness and accuracy of the link test are improved, and the abnormal conditions in the subsequent production environment are reduced.
Drawings
The foregoing and/or additional aspects and advantages of the present application will become apparent and readily appreciated from the following description of the embodiments, taken in conjunction with the accompanying drawings of which:
fig. 1 is a schematic basic flow chart of a link testing method according to an embodiment of the present application;
FIG. 2 is a schematic flow chart illustrating a link testing method according to an embodiment of the present application;
FIG. 3 is a schematic flow chart illustrating a process of determining whether an exception exists in a module according to an embodiment of the present application;
FIG. 4 is a flow diagram of a determine exception module according to one embodiment of the present application;
FIG. 5 is a flowchart illustrating associating storage module information according to an embodiment of the present application;
FIG. 6 is a schematic diagram of a basic structure of a link testing apparatus according to an embodiment of the present application;
fig. 7 is a block diagram of a basic structure of a computer device according to an embodiment of the present application.
Detailed Description
Reference will now be made in detail to embodiments of the present application, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to the same or similar elements or elements having the same or similar function throughout. The embodiments described below with reference to the drawings are exemplary only for the purpose of explaining the present application and are not to be construed as limiting the present application.
As used herein, the singular forms "a", "an", "the" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will be further understood that the terms "comprises" and/or "comprising," when used in this specification, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
The terms first, second and the like in the description and in the claims of the present application are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It will be appreciated that the data so used may be interchanged under appropriate circumstances such that embodiments of the application may be practiced in sequences other than those illustrated or described herein, and that the terms "first," "second," and the like are generally used herein in a generic sense and do not limit the number of terms, e.g., the first term can be one or more than one. In addition, "and/or" in the specification and claims means at least one of connected objects, a character "/" generally means that a preceding and succeeding related objects are in an "or" relationship.
It will be understood by those within the art that, unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. It will be further understood that terms, such as those defined in commonly used dictionaries, should be interpreted as having a meaning that is consistent with their meaning in the context of the prior art and will not be interpreted in an idealized or overly formal sense unless expressly so defined herein.
As used herein, a "terminal" includes both devices that are wireless signal receivers, devices that have only wireless signal receivers without transmit capability, and devices that have receive and transmit hardware, devices that have receive and transmit hardware capable of performing two-way communication over a two-way communication link, as will be understood by those skilled in the art. Such a device may include: a cellular or other communication device having a single line display or a multi-line display or a cellular or other communication device without a multi-line display; PCS (Personal Communications Service), which may combine voice, data processing, facsimile and/or data communication capabilities; a PDA (Personal Digital Assistant), which may include a radio frequency receiver, a pager, internet/intranet access, a web browser, a notepad, a calendar and/or a GPS (Global Positioning System) receiver; a conventional laptop and/or palmtop computer or other device having and/or including a radio frequency receiver. As used herein, a "terminal" may be portable, transportable, installed in a vehicle (aeronautical, maritime, and/or land-based), or situated and/or configured to operate locally and/or in a distributed fashion at any other location(s) on earth and/or in space. The "terminal" used herein may also be a communication terminal, a web-enabled terminal, a music/video playing terminal, such as a PDA, an MID (Mobile Internet Device) and/or a Mobile phone with music/video playing function, and may also be a smart tv, a set-top box, etc.
Referring to fig. 1, fig. 1 is a schematic flow chart illustrating a link testing method in the prior art.
As shown in fig. 1, the link to be tested includes steps 101 to 105, where the conventional link testing method does not test whether data of each module (e.g., module 1 to module 5) in step 103 is abnormal, only detects an output result obtained by the link to be tested in step 104, and if the output result of the link to be tested is not abnormal, the evaluation test result in step 105 indicates that the link to be tested is not abnormal in the current test. However, for a payment link or other complex links, the final output result is correct and does not represent that no abnormality occurs in the whole link. Taking the link to be tested as the payment link as an example, a module in the middle of the payment weighing, which is responsible for returned authentication processing or authority judgment, is abnormal, but the payment result is not affected, and the abnormal module may be attacked or utilized to affect the payment safety of the user.
Based on the existing problems, the present embodiment provides a link testing method, which is used to solve the problem that the existing link testing method cannot perform comprehensive detection on each module in a complex link.
Referring to fig. 2, fig. 2 is a schematic flow chart illustrating a link testing method according to the present embodiment.
As shown in fig. 2, a link testing method includes:
s201, operating a link to be tested, and inputting data to be tested to the link to be tested.
The link to be tested comprises N modules, wherein N is a positive integer greater than or equal to 2.
The link to be tested in this embodiment is a payment link or other complex link. The complex link includes a plurality of functional modules, and for the complex link, not only the final output result of the link needs to be detected, but also the conditions of whether the called module (or interface) is correct, whether the server for routing addresses or the input parameters of the module are correct, and the like need to be checked.
For example, as shown in fig. 1, in step 104, the output result of the link is correct, but the determination result of the module 2 in step 103 is y (yes), at this time, the module 4 should be called, but the module 3 is called incorrectly, but the output result of step 104 is not affected. The existing link test method cannot detect the abnormality and may cause the abnormality in the production environment.
It is understood that the modules in this embodiment may be interfaces (interfaces) capable of implementing specific functions, where the interfaces are borne on a server; or may be a hardware or software program capable of implementing the specified functions. The module may include input parameters and output parameters at run time, or may only have output parameters.
S202, acquiring a first information set of the N modules.
Wherein the first information set includes: and each module in the N modules generates a first information set based on the data to be tested when the link to be tested is operated.
In the embodiment, data generated by each module in the link under the test environment is compared with correct data which should be generated by each module under the condition that the link is normal, and whether the module is abnormal or not is judged according to the comparison result.
In this embodiment, a Test Case (Test Case) is used to Test a link to be tested. The test case is a description of a test task performed on a specific software product, and embodies a test scheme, a method, a technology and a strategy. The contents of the test object, the test environment, the input data, the test steps, the expected results, the test scripts and the like are included, and finally, a document is formed. Simply considered, a test case is a set of test inputs, execution conditions, and expected results tailored for a particular purpose to verify whether a particular software requirement is met.
It should be noted that the test cases are generally used for software automation test, and the test scripts are used for implementing automation of software test. In order to reduce the manual workload, the test process of the link to be tested is automatically tested in the embodiment.
Step 203, comparing the first information set with the second information set to generate a comparison result.
Wherein the second information set includes: and under the condition that the link to be tested normally runs, each module in the N modules generates a set of second information.
In this embodiment, the data to be tested input to the link to be tested is input data in the test case. When the link to be tested is tested by using the test case, data generated by the N modules in the link to be tested or input and output parameters of the N modules can be compared with expected results in the test case, and whether the link to be tested is abnormal or not can be further determined.
The data to be tested in the present embodiment may be test data indicated by a target case (i.e., input data in the test case). The target case is any test case in a case set, the case set comprises M test cases, one test case corresponds to one second information set, and M is a positive integer greater than or equal to 2.
It can be understood that, in general, a plurality of cases are required to test a link to be tested, different test cases may have different expected results due to different input data, and thus, one test case generally corresponds to one second information set.
In some implementations, the first set of information may be derived from input and output values of each of the N modules recorded in the target log. The target log is a log generated when the link to be tested runs based on the data to be tested. That is, the first information may be obtained according to a log file generated by the link to be tested when the link to be tested is tested. Specifically, before comparing the first information set with the second information set, the link testing apparatus further needs to obtain the second information set from the target case.
The second information in this embodiment includes expected results in the test case. Namely, when the link to be tested is tested by using the data to be tested, each module outputs a result in an expected manner under the condition that the link to be tested is normal.
And 204, determining whether the link to be tested normally operates based on the comparison result.
After comparing data generated when each module in the N modules uses the data to be tested to test the link to be tested with data which should be generated when the link to be tested operates correctly, if the N modules are not abnormal, the link to be tested operates normally.
In the above embodiment, the data to be detected is input to the link to be detected, and the data generated by each of the N modules when the link to be detected is operated is obtained based on the data to be detected. And then, comparing the data with the data generated by each module in the N modules under the condition that the link to be tested normally runs, and generating a comparison result. And finally, determining whether the link to be tested normally operates based on the comparison result, so that whether each module in the complex link is abnormal or not can be detected in the automatic test process, the comprehensiveness and accuracy of the link test are improved, and the abnormal conditions in the subsequent production environment are reduced.
In some implementation manners, data generated when each module of the N modules operates the link to be tested may be compared with data that each module should generate when the link to be tested normally operates, so as to obtain a comparison result.
S203 includes:
s2031, if the first input value and the second input value of the target module are different, and/or the first output value and the second output value of the target module are different, determining that the link to be tested is abnormal in operation, otherwise, determining that the link to be tested is normal in operation.
Wherein the target module is any one of the N modules; the second input value and the second output value are the input value and the output value of the target module under the condition that the link to be tested normally runs.
Specifically, in the embodiment of the present application, when testing the link to be tested, the input value and the output value included in the first information corresponding to each module may be respectively compared with the input value and the output value included in the second information corresponding to each module, and a comparison result is generated according to the comparison result.
It should be noted that, the data types of the input values and the output values of the modules in the test link may be basic data types, including: integer type, floating point type, string type, and boolean type, and may also be reference data types, including: classes, interfaces, and arrays. In general, it is necessary to compare whether the first input value and the second input value are the same, and/or whether the first output value and the second output value are the same, and if not, it may be determined that the target module is abnormal in the test process.
In this embodiment, the input value and the output value included in the first information generated by each of the N modules may be respectively compared with the expected input value and the expected output value of the module in the second information corresponding to each module, and when the input value and the output value of each module when operating the link to be tested are respectively the same as the expected input value and the expected output value when the link to be tested normally operates, it is determined that the link to be tested normally operates, otherwise, it is determined that the link to be tested abnormally operates.
In some implementation manners, after the comparison result of each of the N modules is obtained, an abnormal module may be determined according to the comparison result of each module.
After S204, the link testing method further includes:
s205, if the comparison result indicates that the link to be tested runs abnormally, determining the target module as an abnormal module.
Wherein, the exception module is: and the comparison result indicates the modules with abnormal data in the N modules. Specifically, the input value and/or the output value of the abnormal module are/is different from the theoretical input value and/or the theoretical output value indicated by the target use case.
And after each module in the N modules is compared, generating a comparison result. The comparison result can indicate whether the link to be tested is abnormal or not, and can also indicate the module with the abnormality in the link to be tested under the condition that the link to be tested is abnormal.
When the comparison result indicates that the operation of the link to be tested is abnormal, it may be determined that the first input value and the second input value of a certain module are different and/or the first output value and the second output value of the certain module are different in the N modules, and at this time, it may be determined that the certain module is an abnormal module, that is, the target module may be determined as an abnormal module.
It should be noted that, since the input value of the target module may be an output value of a module higher than the target module, when the first input value of the target module is different from the second input value, it may be determined that a second module is an abnormal module, where the second module is a module higher than the target module. Alternatively, it may be determined whether the target module is abnormal only according to the comparison result of the first output value and the second output value of the target module. That is, the target module may be determined to be an abnormal module when the first output value and the second output value of the target module are different, without comparing the first input value and the second input value of the target module.
For example, as shown in fig. 1, if the input value of the module 5 is the same as the theoretical input value of the module 5 indicated by the target use case, but the output value of the module 5 is different from the theoretical output value of the module 5 indicated by the target use case, it may be determined that the module 5 is an abnormal module. If the input value of the module 5 is different from the theoretical input value of the module 5 indicated by the target use case, it may be determined that an abnormal module occurs in the upper module (modules 3 and 4) of the module 5, and then the input and output values of the modules 3 and 4 may be compared according to the above method, so as to determine the abnormal module.
According to the embodiment, the data generated by each module in the link to be tested is detected, so that the specific abnormal position can be determined when the link to be tested is abnormal, the accuracy of the test result is improved, and the test time of manual test is reduced.
In some implementations, in order to determine which module generates the first sub-information specifically, the module name of the module, the server address of the module, and the data generated by the module may be stored in association with each other. Referring to fig. 5, fig. 5 is a schematic flow chart of associating information of the storage module according to the present embodiment.
As shown in fig. 5, before S203, the link testing method further includes:
s2021, storing the first information and the target information of each of the N modules in an associated manner.
Wherein the target information comprises at least one of a name of the module and a network address of the module.
After the first information generated by the module is acquired, the first information and the name of the module and/or the server address of the module can be stored in the database in an associated manner, so that comparison with the second information generated by the module in the test case under the condition that the running link to be tested is normal is facilitated.
In the embodiment, the module name of each module in the link to be tested and/or the server address and the first information generated by each module are stored in the database in an associated manner, so that the module name and/or the server address can be conveniently searched and compared with the second information.
The link testing method provided by the embodiment can be used for detecting each module in the link to be tested, and when the link to be tested is abnormal, the specific module in which the abnormality occurs can be determined according to the detection result, so that the accuracy of the test result is improved. Meanwhile, the link testing method provided by the embodiment makes full use of the log system to acquire data for checking and comparing, so that the testing accuracy is improved, and the workload of the testing process is greatly reduced.
Referring to fig. 6, fig. 6 is a schematic diagram of a basic structure of the link testing apparatus according to the present embodiment.
As shown in fig. 6, a link test apparatus includes: an input module 2100, an acquisition module 2200, a comparison module 2300, and a determination module 2400. The input module 2100 is configured to operate a link to be tested, and input data to be tested to the link to be tested, where the link to be tested includes N modules, and N is a positive integer greater than or equal to 2; an obtaining module 2200, configured to obtain a first information set of the N modules, where the first information set includes: each module in the N modules generates a first information set based on the data to be tested when the link to be tested is operated; a comparing module 2300, configured to compare the first information set obtained by the obtaining module 2200 with a second information set, and generate a comparison result, where the second information set includes: under the condition that a link to be tested normally runs, each module in the N modules generates a set of second information; a determining module 2400, configured to determine whether the link to be tested operates normally based on the comparison result generated by the comparing module 2300.
The link testing device inputs data to be tested to the link to be tested and obtains data generated by each module in the N modules when the link to be tested runs based on the data to be tested. And then, comparing the data with correct data which should be generated by each module in the N modules under the condition that the link to be detected normally runs, and generating a comparison result. And finally, determining whether the link to be tested normally operates based on the comparison result, so that whether each module in the complex link is abnormal or not can be detected in the automatic test process, the comprehensiveness and accuracy of the link test are improved, and the abnormal conditions in the subsequent production environment are reduced.
In some embodiments, the comparing module 2300 is specifically configured to determine that the link to be tested operates abnormally if the first input value and the second input value of the target module are different and/or the first output value and the second output value of the target module are different, or determine that the link to be tested operates normally if the first input value and the second input value of the target module are different; wherein the target module is any one of the N modules; the second input value and the second output value are the input value and the output value of the target module under the condition that the link to be tested normally runs.
In some embodiments, the determining module 2400 is specifically configured to determine the target module as an abnormal module if the comparison result generated by the comparing module 2300 indicates that the link to be tested operates abnormally.
In some implementations, the link test apparatus further includes: a storage module 2500; the storage module 2500 is configured to store the first information and the target information of each of the N modules in an associated manner; wherein the target information comprises at least one of a name of the module and a network address of the module.
In some embodiments, the data to be tested is test data indicated by a target case, the target case is any test case in a case set, the case set includes M test cases, one test case corresponds to one second information set, and M is a positive integer greater than or equal to 2.
In some embodiments, the first set of information is derived from the input and output values of each of the N modules recorded in the target log; and the target log is a log generated when the link to be tested runs based on the data to be tested.
In order to solve the above technical problem, an embodiment of the present invention further provides a computer device. Referring to fig. 7, fig. 7 is a block diagram of a basic structure of a computer device according to the present embodiment.
Fig. 7 is a schematic diagram of the internal structure of the computer device. The computer device includes a processor, a non-volatile storage medium, a memory, and a network interface connected by a system bus. The non-volatile storage medium of the computer device stores an operating system, a database and computer readable instructions, the database can store control information sequences, and the computer readable instructions can enable the processor to realize a link testing method when being executed by the processor. The processor of the computer device is used for providing calculation and control capability and supporting the operation of the whole computer device. The memory of the computer device may have stored therein computer readable instructions that, when executed by the processor, may cause the processor to perform a link testing method. The network interface of the computer device is used for connecting and communicating with the terminal. Those skilled in the art will appreciate that the architecture shown in fig. 7 is merely a block diagram of some of the structures associated with the disclosed aspects and is not intended to limit the computing devices to which the disclosed aspects apply, as particular computing devices may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
In this embodiment, the processor is configured to execute specific functions of the input module 2100, the obtaining module 2200, the comparing module 2300 and the determining module 2400 in fig. 6, and the memory stores program codes and various data required for executing the modules. The network interface is used for data transmission to and from a user terminal or a server. The memory in this embodiment stores program codes and data necessary for executing all the sub-modules in the link testing apparatus, and the server can call the program codes and data of the server to execute the functions of all the sub-modules.
The computer equipment inputs data to be detected to the link to be detected and obtains data generated by each module in the N modules when the link to be detected runs based on the data to be detected. And then, comparing the data with the data generated by each module in the N modules under the condition that the link to be tested normally runs, and generating a comparison result. And finally, determining whether the link to be tested normally operates based on the comparison result, so that whether each module in the complex link is abnormal or not can be detected in the automatic test process, the comprehensiveness and accuracy of the link test are improved, and the abnormal conditions in the subsequent production environment are reduced.
The present invention also provides a storage medium having stored thereon computer-readable instructions which, when executed by one or more processors, cause the one or more processors to perform the steps of any of the above-described embodiments of the link testing method.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by a computer program, which can be stored in a computer-readable storage medium, and can include the processes of the embodiments of the methods described above when the computer program is executed. The storage medium may be a non-volatile storage medium such as a magnetic disk, an optical disk, a Read-Only Memory (ROM), or a Random Access Memory (RAM).
The present invention also provides a storage medium having stored thereon computer-readable instructions which, when executed by one or more processors, cause the one or more processors to perform the steps of any of the above-described embodiments of the link testing method.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by a computer program, which can be stored in a computer-readable storage medium, and can include the processes of the embodiments of the methods described above when the computer program is executed. The storage medium may be a non-volatile storage medium such as a magnetic disk, an optical disk, a Read-Only Memory (ROM), or a Random Access Memory (RAM).
Those of skill in the art will appreciate that the various operations, methods, steps in the processes, acts, or solutions discussed in this application can be interchanged, modified, combined, or eliminated. Further, other steps, measures, or schemes in various operations, methods, or flows that have been discussed in this application can be alternated, altered, rearranged, broken down, combined, or deleted. Further, steps, measures, schemes in the prior art having various operations, methods, procedures disclosed in the present application may also be alternated, modified, rearranged, decomposed, combined, or deleted.
The foregoing is only a partial embodiment of the present application, and it should be noted that, for those skilled in the art, several modifications and decorations can be made without departing from the principle of the present application, and these modifications and decorations should also be regarded as the protection scope of the present application.

Claims (10)

1. A link testing method, comprising:
the method comprises the steps of operating a link to be tested, and inputting data to be tested to the link to be tested, wherein the link to be tested comprises N modules, and N is a positive integer greater than or equal to 2;
acquiring a first information set of the N modules, wherein the first information set comprises: each module in the N modules generates a first information set based on the data to be tested when the link to be tested is operated;
comparing the first information set with a second information set to generate a comparison result, wherein the second information set comprises: under the condition that a link to be tested normally runs, each module in the N modules generates a set of second information;
and determining whether the link to be tested normally operates based on the comparison result.
2. The method of claim 1, wherein comparing the first set of information with the second set of information to generate a comparison result comprises:
if the first input value and the second input value of the target module are different, and/or the first output value and the second output value of the target module are different, determining that the link to be tested operates abnormally, otherwise, determining that the link to be tested operates normally;
wherein the target module is any one of the N modules; the second input value and the second output value are the input value and the output value of the target module under the condition that the link to be tested normally runs.
3. The method according to claim 2, wherein after determining whether the link under test is operating normally based on the comparison result, the method further comprises:
and if the comparison result indicates that the link to be tested operates abnormally, determining the target module as an abnormal module.
4. The method according to claim 2 or 3, wherein before comparing the first set of information with the second set of information to generate a comparison result, the method further comprises:
and storing first information of each of the N modules and target information in an associated manner, wherein the target information comprises at least one of a name of the module and a network address of the module.
5. The method according to any one of claims 1 to 3, wherein the data to be tested is test data indicated by a target case, the target case is any one test case in a case set, the case set includes M test cases, one test case corresponds to one second information set, and M is a positive integer greater than or equal to 2.
6. The method according to any one of claims 1 to 3, wherein the first set of information is derived from the input and output values of each of the N modules recorded in a target log;
and the target log is a log generated when the link to be tested runs based on the data to be tested.
7. A link test apparatus, comprising:
the device comprises an input module, a data acquisition module and a data processing module, wherein the input module is used for operating a link to be tested and inputting data to be tested to the link to be tested, the link to be tested comprises N modules, and N is a positive integer greater than or equal to 2;
an obtaining module, configured to obtain a first information set of the N modules, where the first information set includes: each module in the N modules generates a first information set based on the data to be tested when the link to be tested is operated;
a comparison module, configured to compare the first information set obtained by the obtaining module with a second information set, and generate a comparison result, where the second information set includes: under the condition that a link to be tested normally runs, each module in the N modules generates a set of second information;
and the determining module is used for determining whether the link to be tested normally operates based on the comparison result generated by the comparison module.
8. The apparatus of claim 7,
the comparison module is specifically configured to determine that the link to be tested operates abnormally if the first input value and the second input value of the target module are different and/or the first output value and the second output value of the target module are different, and otherwise, determine that the link to be tested operates normally;
wherein the target module is any one of the N modules; the second input value and the second output value are the input value and the output value of the target module under the condition that the link to be tested normally runs.
9. A computer device comprising a memory and a processor, the memory having stored therein computer-readable instructions that, when executed by the processor, cause the processor to perform the steps of the link testing method according to any one of claims 1 to 6.
10. A storage medium having computer-readable instructions stored thereon which, when executed by one or more processors, cause the one or more processors to perform the steps of the link testing method according to any one of claims 1 to 6.
CN202110343797.5A 2021-03-30 2021-03-30 Link testing method and device, computer equipment and storage medium Pending CN112905488A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110343797.5A CN112905488A (en) 2021-03-30 2021-03-30 Link testing method and device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110343797.5A CN112905488A (en) 2021-03-30 2021-03-30 Link testing method and device, computer equipment and storage medium

Publications (1)

Publication Number Publication Date
CN112905488A true CN112905488A (en) 2021-06-04

Family

ID=76109739

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110343797.5A Pending CN112905488A (en) 2021-03-30 2021-03-30 Link testing method and device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112905488A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113609056A (en) * 2021-06-25 2021-11-05 曙光信息产业(北京)有限公司 Data transmission test method, device, equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108959065A (en) * 2018-05-17 2018-12-07 烽火通信科技股份有限公司 The verification method and system of software interface test parameter
CN110928765A (en) * 2019-10-11 2020-03-27 京东数字科技控股有限公司 Link testing method and device
CN111078551A (en) * 2019-12-13 2020-04-28 浙江诺诺网络科技有限公司 Full link testing method, device and system and computer readable storage medium
CN111625471A (en) * 2020-06-12 2020-09-04 北京灵汐科技有限公司 Execution processing and exception positioning method, device, equipment and medium of test case
WO2020258657A1 (en) * 2019-06-28 2020-12-30 平安科技(深圳)有限公司 Abnormality detection method and apparatus, computer device and storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108959065A (en) * 2018-05-17 2018-12-07 烽火通信科技股份有限公司 The verification method and system of software interface test parameter
WO2020258657A1 (en) * 2019-06-28 2020-12-30 平安科技(深圳)有限公司 Abnormality detection method and apparatus, computer device and storage medium
CN110928765A (en) * 2019-10-11 2020-03-27 京东数字科技控股有限公司 Link testing method and device
CN111078551A (en) * 2019-12-13 2020-04-28 浙江诺诺网络科技有限公司 Full link testing method, device and system and computer readable storage medium
CN111625471A (en) * 2020-06-12 2020-09-04 北京灵汐科技有限公司 Execution processing and exception positioning method, device, equipment and medium of test case

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113609056A (en) * 2021-06-25 2021-11-05 曙光信息产业(北京)有限公司 Data transmission test method, device, equipment and storage medium
CN113609056B (en) * 2021-06-25 2023-08-25 曙光信息产业(北京)有限公司 Data transmission testing method, device, equipment and storage medium

Similar Documents

Publication Publication Date Title
CN109936561B (en) User request detection method and device, computer equipment and storage medium
CN111897724B (en) Automatic testing method and device suitable for cloud platform
CN108919776B (en) Fault assessment method and terminal
CN110134611B (en) Memory leak analysis method, device, terminal and storage medium
CN114201408A (en) Regression testing method, device, computer equipment and storage medium
CN114064208A (en) Method and device for detecting application service state, electronic equipment and storage medium
CN116414948A (en) Abnormal data mining method and software product based on cloud data and artificial intelligence
CN111309584B (en) Data processing method, device, electronic equipment and storage medium
CN112905488A (en) Link testing method and device, computer equipment and storage medium
CN113312258B (en) Interface testing method, device, equipment and storage medium
KR20090030156A (en) The method and apparatus for evaluating performance of test case
CN113486358A (en) Vulnerability detection method and device
CN116578978A (en) Multidimensional hierarchical hardware Trojan horse assessment method for IP soft core
CN110765005A (en) Software reliability evaluation method and device
CN108763053B (en) Method for generating buried point name and terminal equipment
CN113361265B (en) Data quality inspection method, device, electronic equipment and storage medium
US20080115016A1 (en) System and method for analyzing unknown file format to perform software security test
KR101626581B1 (en) Test method for error applition of portable communication terminal
CN114091699A (en) Power communication equipment fault diagnosis method and system
CN114185798A (en) Interface test case detection method and device, computer equipment and storage medium
CN110704218B (en) Data processing method, data processing device, computer equipment and storage medium
CN113300912A (en) Equipment testing method and device and electronic equipment
CN113726779A (en) Rule false alarm test method and device, electronic equipment and computer storage medium
CN113127858A (en) Anomaly detection model training method, anomaly detection method and anomaly detection device
CN108845932B (en) Unit testing method and device of network library, storage medium and terminal

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
TA01 Transfer of patent application right

Effective date of registration: 20211018

Address after: 518000 Room 201, building a, No.1 Qianwan 1st Road, Qianhai Shenzhen Hong Kong cooperation zone, Shenzhen City, Guangdong Province

Applicant after: Shenzhen saiante Technology Service Co.,Ltd.

Address before: 1-34 / F, Qianhai free trade building, 3048 Xinghai Avenue, Mawan, Qianhai Shenzhen Hong Kong cooperation zone, Shenzhen, Guangdong 518000

Applicant before: Ping An International Smart City Technology Co.,Ltd.

TA01 Transfer of patent application right