CN111209195A - Method and device for generating test case - Google Patents

Method and device for generating test case Download PDF

Info

Publication number
CN111209195A
CN111209195A CN201911405803.4A CN201911405803A CN111209195A CN 111209195 A CN111209195 A CN 111209195A CN 201911405803 A CN201911405803 A CN 201911405803A CN 111209195 A CN111209195 A CN 111209195A
Authority
CN
China
Prior art keywords
test
function
test case
tested
template
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
CN201911405803.4A
Other languages
Chinese (zh)
Other versions
CN111209195B (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.)
Ruiting Network Technology Shanghai Co ltd
Original Assignee
Ruiting Network Technology Shanghai 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 Ruiting Network Technology Shanghai Co ltd filed Critical Ruiting Network Technology Shanghai Co ltd
Priority to CN201911405803.4A priority Critical patent/CN111209195B/en
Publication of CN111209195A publication Critical patent/CN111209195A/en
Application granted granted Critical
Publication of CN111209195B publication Critical patent/CN111209195B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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/3684Test management for test design, e.g. generating new test cases
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

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 method and a device for generating a test case. The electronic equipment can automatically generate the test cases without manually compiling the test cases by technicians, so that the workload of the technicians is reduced, and the labor cost is reduced. The test case does not need to be manually written, so that the condition of manual writing errors can be avoided, and the test accuracy is prevented from being reduced. For example, when performing a BUG test on a function to be tested, if a technician manually compiles a test case, under the condition that the test function names and the corresponding test function values are more, the condition that a plurality of test function names and the test function values are artificially confused easily occurs, so that a compiling error is caused. The test case is automatically compiled in the whole process without human participation, so that the condition of human error can be avoided as much as possible. The electronic equipment automatically compiles the test cases is usually fast, and the time consumed is short, so that the efficiency of compiling the test cases can be improved, and the test efficiency is improved.

Description

Method and device for generating test case
Technical Field
The present application relates to the field of computer technologies, and in particular, to a method and an apparatus for generating a test case.
Background
After a piece of software is developed, it is sometimes necessary to test the software, for example, to test functions written in a computer language in the software.
Currently, when a function in software needs to be tested, a technician is required to manually write a test case.
However, the inventor finds that the workload of technicians for manually writing test cases is very large, which results in high labor cost, and writing errors easily occur due to manual writing of test cases, so that the test accuracy is reduced.
Disclosure of Invention
In order to solve the above technical problem, the present application shows a method and an apparatus for generating a test case.
In a first aspect, the present application shows a method for generating a test case, where the method includes:
determining a function to be tested among a plurality of functions in a computer program file;
acquiring test parameter data of the function to be tested;
acquiring a target test case generation template for generating a test case for testing the function to be tested from a plurality of test case generation templates;
and generating the test case based on the test parameter data and the target test case generation template.
In an alternative implementation, the determining a function to be tested from among a plurality of functions in a computer program file includes:
displaying function names of a plurality of functions included in the computer program file;
determining a selected function name among the plurality of function names;
and determining the function to be tested according to the selected function name.
In an optional implementation manner, the obtaining test parameter data of the function to be tested includes:
under the condition that a BUG BUG exists in the data processing process of the function to be tested, obtaining a test parameter name from the function to be tested;
acquiring a service log of the function to be tested;
acquiring a test parameter value corresponding to the test parameter name in the service log;
and generating the test parameter data according to the test parameter name and the test parameter value.
In an optional implementation manner, the obtaining, in the service log, a test parameter value corresponding to the test parameter name includes:
determining a data format of data in the service log;
under the condition that the data format is a preset format, analyzing the data in the service log based on a data analysis mode corresponding to the preset format to obtain a test parameter value corresponding to the test parameter name;
or,
and under the condition that the data format is not the preset format, converting the data format of the data in the service log into the preset format, and analyzing the data in the service log after the format is converted based on a data analysis mode corresponding to the preset format to obtain a test parameter value corresponding to the test parameter name.
In an optional implementation manner, the obtaining test parameter data of the function to be tested includes:
under the condition that the function to be tested needs to be subjected to pressure testing, obtaining a test parameter name from the function to be tested;
generating a character string which accords with a regular check rule;
and generating the test parameter data according to the test parameter name and the character string.
In an optional implementation manner, the obtaining, in the multiple test case generation templates, a target test case generation template for generating a test case for testing the function to be tested includes:
displaying template identifications of a plurality of test case generation templates;
determining a selected template identifier from a plurality of template identifiers;
and acquiring the target test case generation template according to the selected template identification.
In an optional implementation manner, before obtaining the target test case generation template according to the selected template identifier, the method further includes:
determining whether the test case generation template corresponding to the selected template identifier is suitable for the function to be tested;
and under the condition of being applicable to the function to be tested, executing the step of obtaining the target test case generation template according to the selected template identification.
In an optional implementation, the method further includes:
and after testing the function to be tested based on the test case, recording the target test case generation template as a test case generation template used when the function in the computer program file is tested last time.
In an optional implementation manner, the recording the target test case generation template as the test case generation template that was used last time when the function in the computer program file is tested includes:
and updating the file identifier of the computer program file and the template identifier of the target test case generation template in the corresponding relation between the file identifier of the computer program file and the template identifier of the test case generation template used when the function in the computer program file is tested for the last time.
In an optional implementation manner, the obtaining, in the multiple test case generation templates, a target test case generation template for generating a test case for testing the function to be tested includes:
and acquiring a recorded test case generation template used when the function in the computer program file is tested at the last time, and taking the test case generation template as the target test case generation template.
In an optional implementation manner, the obtaining a recorded test case generation template that was used last time when a function in the computer program file is tested, and using the test case generation template as the target test case generation template includes:
searching a template identifier corresponding to the file identifier of the computer program file in the corresponding relation between the file identifier of the computer program file and the template identifier of the test case generation template used when the function in the computer program file is tested for the last time;
and searching the target test case generation template according to the searched template identification in the plurality of test case generation templates.
In a second aspect, the present application shows an apparatus for generating test cases, the apparatus comprising:
a determining module for determining a function to be tested among a plurality of functions in a computer program file;
the first acquisition module is used for acquiring test parameter data of the function to be tested;
the second obtaining module is used for obtaining a target test case generation template used for generating a test case for testing the function to be tested from a plurality of test case generation templates;
and the generating module is used for generating the test case based on the test parameter data and the target test case generating template.
In an optional implementation manner, the determining module includes:
the first display submodule is used for displaying the function names of a plurality of functions included in the computer program file;
a first determining submodule for determining a selected function name among the plurality of function names;
and the second determining submodule is used for determining the function to be tested according to the selected function name.
In an optional implementation manner, the first obtaining module includes:
the first obtaining submodule is used for obtaining a test parameter name from the function to be tested under the condition that a BUG BUG exists in the data processing process of the function to be tested;
the second obtaining submodule is used for obtaining the service log of the function to be tested;
a third obtaining submodule, configured to obtain a test parameter value corresponding to the test parameter name from the service log;
and the first generation submodule is used for generating the test parameter data according to the test parameter name and the test parameter value.
In an optional implementation manner, the third obtaining sub-module includes:
the determining unit is used for determining the data format of the data in the service log;
the first analysis unit is used for analyzing the data in the service log based on a data analysis mode corresponding to a preset format under the condition that the data format is the preset format to obtain a test parameter value corresponding to the test parameter name;
or,
the second analysis unit is used for analyzing the data in the service log after the format is converted based on a data analysis mode corresponding to the preset format to obtain a test parameter value corresponding to the test parameter name.
In an optional implementation manner, the first obtaining module includes:
the fourth obtaining submodule is used for obtaining a test parameter name from the function to be tested under the condition that the function to be tested needs to be subjected to pressure test;
the second generation submodule is used for generating a character string which accords with the regular check rule;
and the third generation submodule is used for generating the test parameter data according to the test parameter name and the character string.
In an optional implementation manner, the second obtaining module includes:
the second display submodule is used for displaying the template identifications of the plurality of test case generation templates;
a third determining submodule for determining a selected template identifier among the plurality of template identifiers;
and the fifth obtaining submodule is used for obtaining the target test case generation template according to the selected template identification.
In an optional implementation manner, the second obtaining module further includes:
a fourth determining submodule, configured to determine whether the test case generation template corresponding to the selected template identifier is applicable to the function to be tested;
the fifth obtaining submodule is further configured to obtain the target test case generation template according to the selected template identifier under the condition that the function to be tested is applicable.
In an optional implementation manner, the second obtaining module further includes:
and the recording submodule is used for recording the target test case generation template as the test case generation template used when the function in the computer program file is tested last time after the function to be tested is tested based on the test case.
In an optional implementation manner, the recording sub-module includes:
and the updating unit is used for updating the file identifier of the computer program file and the template identifier of the target test case generation template in the corresponding relation between the file identifier of the computer program file and the template identifier of the test case generation template used when the function in the computer program file is tested last time.
In an optional implementation manner, the second obtaining module includes:
and the sixth obtaining submodule is used for obtaining the recorded test case generation template used when the function in the computer program file is tested at the latest time, and taking the test case generation template as the target test case generation template.
In an optional implementation manner, the sixth obtaining sub-module includes:
the first searching unit is used for searching a template identifier corresponding to the file identifier of the computer program file in the corresponding relation between the file identifier of the computer program file and the template identifier of the test case generation template used when the function in the computer program file is tested for the last time;
and the second searching unit is used for searching the target test case generation template in the plurality of test case generation templates according to the searched template identification.
In a third aspect, the present application shows an electronic device comprising:
a processor;
a memory for storing processor-executable instructions;
wherein the processor is configured to perform the method of generating test cases according to the first aspect.
In a fourth aspect, the present application illustrates a non-transitory computer-readable storage medium, wherein instructions of the storage medium, when executed by a processor of an electronic device, enable the electronic device to perform the method of generating test cases according to the first aspect.
In a fifth aspect, the present application shows a computer program product, wherein instructions of the computer program product, when executed by a processor of an electronic device, enable the electronic device to perform the method for generating test cases according to the first aspect.
The technical scheme provided by the application can comprise the following beneficial effects:
in the present application, a function to be tested is determined among a plurality of functions in a computer program file; acquiring test parameter data of a function to be tested; acquiring a target test case generation template for generating a test case for testing a function to be tested from a plurality of test case generation templates; and generating a test case based on the test parameter data and the target test case generation template.
By the method and the device, the electronic equipment can automatically generate the test cases, technicians do not need to manually compile the test cases, and zero-code automatic compilation of the test cases is realized, so that the workload of the technicians is reduced, and the labor cost is reduced.
Because the test case does not need to be manually written, the situation of manual writing errors can be avoided, and the accuracy of the test is prevented from being reduced. For example, when performing a BUG test on a function to be tested, if a technician manually compiles a test case, under the condition that the test function names and the corresponding test function values are more, the condition that a plurality of test function names and the test function values are artificially confused easily occurs, so that a compiling error is caused. The test case is automatically compiled in the whole process without human participation, so that the condition of human error can be avoided as much as possible.
In addition, time consumed for manually writing the test cases is often more, the test cases are often faster to automatically write by the electronic equipment, and the time consumed is less, so that the efficiency of writing the test cases can be improved, and then the test efficiency is improved.
Through the method and the device, the work of testing the function can be simpler, the time spent on testing the function by technical personnel can be reduced, the enthusiasm of the technical personnel in testing the function in the computer program file can be improved, the technical personnel can have more time and energy spent in developing the computer program file, the possibility of the occurrence of BUG in the computer program file can be reduced, forward circulation is formed, and the development of the computer program file is facilitated.
In one example, a test case generation template selected by a user and a related tool for selecting a function to be tested may be Integrated in an IDE (Integrated Development Environment), and for the user, only the test case generation template selected by the user and the function to be tested may be selected to implement one-key test case generation.
Drawings
FIG. 1 is a flow chart of the steps of a method of generating test cases of the present application;
FIG. 2 is a block diagram of an apparatus for generating test cases according to the present application;
FIG. 3 is a block diagram of an electronic device shown in the present application;
fig. 4 is a block diagram of an electronic device shown in the present application.
Detailed Description
In order to make the aforementioned objects, features and advantages of the present application more comprehensible, the present application is described in further detail with reference to the accompanying drawings and the detailed description.
Referring to fig. 1, a flowchart illustrating steps of a method for generating a test case according to the present application is shown, where the method specifically includes the following steps:
in step S101, a function to be tested is determined among a plurality of functions in a computer program file;
in this application, computer program files include files written in a development environment that include computer code, such as ". class" files and the like. There is typically at least one function in the written computer program file.
Sometimes, it is necessary to test at least one of the functions, for example, when a BUG (BUG) occurs when the function processes data, it is necessary to test the reason why the BUG occurs in the function, and then modify the computer code of the function in the computer program file, so as to eliminate the BUG of the function.
When testing the function, in general, a technician needs to manually write a test case for testing the function, and then test the function based on the test case. However, the workload of a technician for manually writing test cases is very large, which results in high labor cost, and writing errors easily occur due to manual writing of test cases, thereby reducing the accuracy of the test.
Therefore, the workload of technicians is reduced, the labor cost is reduced, and the test accuracy is improved.
The method and the device for testing the function of the electronic device have the advantages that a technician does not need to write a testing user in real time, and the electronic device can automatically generate the test case for testing the function.
When a certain function in the computer program file needs to be tested, the technician may control the electronic device to display function names of a plurality of functions included in the computer program file, the technician may select a function name of a function to be tested from the displayed function names of the plurality of functions, the electronic device may determine the selected function name from the plurality of function names, and then may determine a function to be tested according to the selected function name, for example, in the computer program file, the function corresponding to the selected function name is determined as the function to be tested, and then step S102 is performed.
In step S102, test parameter data of a function to be tested is acquired;
in the application, when a test case for testing a function to be tested is generated, test parameter data is often used, for example, the test parameter data includes a test parameter name and a test parameter value, the test parameter name includes data processed by the function to be tested, and the test parameter value includes a processing result obtained after the data is processed by the function to be tested.
The method includes the steps of obtaining a test parameter name in a function to be tested, obtaining a test parameter value corresponding to the test parameter name in a service log of the function to be tested, and the like.
Specifically, in an embodiment, under the condition that a BUG exists in the data processing process of the function to be tested, the test parameter name can be obtained from the function to be tested, wherein the computer code of the function to be tested in the computer program file includes the test parameter name, so that the test parameter name can be directly obtained from the function to be tested. Secondly, after the function to be tested processes data, a service log of the function to be tested is generated, and the service log often comprises a processing result obtained after the function to be tested processes the data, and the processing result can be used as a test parameter value and the like, so that the service log of the function to be tested can be obtained, and then the test parameter value corresponding to the test parameter name is obtained from the service log; and generating test parameter data according to the test parameter name and the test parameter value, for example, combining the test parameter name and the test parameter value into the test parameter data.
Wherein, in the service log, the data can be stored in any one of a plurality of data formats, and the data format includes: json format and tostring etc.
When the data formats of the data in the service log are different, the electronic device needs to analyze the data in the service day based on different data analysis modes.
In this way, when the test parameter value corresponding to the test parameter name is obtained from the service log, the data format of the data in the service log may be determined, where a specific field in the service log is used to store an identifier, and the identifier is used to identify the data format of the data currently stored in the service log.
Under the condition that the data format of the data in the service log is a preset format, analyzing the data in the service log based on a data analysis mode corresponding to the preset format to obtain a test parameter value corresponding to a test parameter name; under the condition that the data format of the data in the service log is not the preset format, the data format of the data in the service log can be converted into the preset format, and then the data in the service log after the format conversion is analyzed based on the data analysis mode corresponding to the preset format, so that the test parameter value corresponding to the test parameter name is obtained.
The data formats of the application include two formats, a preset format and a non-preset format.
The preset format includes json format, tostring format and the like. In the application, a data analysis mode corresponding to a preset format is loaded in the electronic device in advance, so that under the condition that the data format of the data in the service log is the preset format, the data in the service log can be directly analyzed based on the data analysis mode corresponding to the preset format loaded in the electronic device in advance, and a test parameter value corresponding to the test parameter name is obtained.
In the application, the preset format is a data format commonly used by the service log, and therefore, a data analysis manner corresponding to the commonly used format may be loaded in the electronic device in advance, however, the data analysis manner often occupies a large storage space in the electronic device, and therefore, in order to save the storage space, the data analysis manner corresponding to the infrequently used data format may not be loaded in the electronic device.
However, when the data format of the data in the service log is not the preset format, the data parsing method corresponding to the preset format cannot parse the test parameter value from the service log.
Therefore, in order to obtain the test parameter value, under the condition that the data format of the data in the service log is not the preset format, the data format of the data in the service log may be converted into the preset format, and then the data in the service log after the format conversion is analyzed based on the data analysis mode corresponding to the preset format, so as to obtain the test parameter value corresponding to the test parameter name. Therefore, the test parameter values can be obtained from the service logs in the multiple data formats without occupying excessive storage space, so that the possibility of obtaining the test parameter values corresponding to the test parameter names from the service logs can be improved, or the application supports the participation of the service logs in the multiple data formats.
Through the method and the device, the BUG scene which helps technicians to reproduce the function can be accurately and quickly reproduced, so that the technicians can determine the problem of the function more quickly and accurately, and the BUG can be eliminated more accurately and more quickly.
In another embodiment of the present application, sometimes, the test data is not tested when the processing data of the function to be tested has a BUG, but a pressure test or the like needs to be performed on the function to be tested, in this case, the test parameter name may be obtained from the function to be tested, however, a test parameter value needs to be obtained, but since the function to be tested does not process some data, the test function value cannot be obtained from the service log of the function to be tested, and in this case, the test function value may be generated in real time.
In one embodiment, a technician may manually generate a test function value for the electronic device to generate a test case, but this increases the workload of the technician, so in order to reduce the workload of the technician, in another embodiment of the present application, the electronic device may automatically and randomly generate the test function value, and since the test function value is subjected to a pressure test, etc., this time, what the generated test function value is does not affect the test, and only the test function value needs to be provided.
However, before generating a test case for the function to be tested, the test parameter data often needs to be verified.
For example, data processed by a function to be tested needs to conform to a regular rule, and the function to be tested does not often process data that does not conform to the regular rule, so that in order to enable a pressure test to be performed normally, test parameter data that needs to be used for generating a test case needs to conform to the regular rule, and therefore, whether the test parameter data conforms to the regular rule needs to be verified, and the function to be tested processes the test parameter data only when the test parameter data conforms to the regular rule.
Therefore, in order to enable the pressure test to be normally carried out, a character string which accords with a regular check rule can be generated, and then test parameter data can be generated according to the test parameter name and the character string.
Through the application, the electronic equipment can automatically generate a large number of random test function values so as to test the functions to be tested in batches, thereby realizing pressure test and the like.
In step S103, a target test case generation template for generating a test case for testing a function to be tested is obtained from a plurality of test case generation templates;
in the present application, a plurality of test case generation templates, for example, a general template, a Spring template, and an SCF (Service Communication Framework) template, are loaded in advance in an electronic device. The test case generated based on the SCF template may directly Call an RPC (Remote Procedure Call) service for testing. The test case generated based on the Spring template can test the Spring bean method based on the Spring-test, is usually a test of a service class, and can realize the initialization of the class by relying on injection. The test case generated based on the universal template is a common instantiation class test, and is generally a tool class test and the like.
In an embodiment, a technician may manually select a target test case generation template used for generating a test case for testing a function to be tested from a plurality of test case generation templates, for example, the technician may control an electronic device to display template identifiers of the plurality of test case generation templates, then the technician may select one template identifier from the template identifiers of the plurality of test case generation templates displayed by the electronic device, then the electronic device may determine the selected template identifier from the plurality of template identifiers, and then obtain the target test case generation template according to the template identifier, for example, in the plurality of test case generation templates, the test case generation template corresponding to the template identifier is determined as the target test case generation template.
However, in the test function, objectively, for any function, the function may not be tested by the test case generated based on each test case generation template.
Sometimes, only the test cases generated based on part of the plurality of test case generation templates can test the function.
However, this may be the case since the skilled person is sometimes unaware of this or due to selection errors: the target test case template is not suitable for the function to be tested, so the test case generated based on the selected target test case template cannot test the function to be tested, and after the test case is created, a technician needs to reselect the test case generation template to regenerate the test case by the electronic equipment when finding that the test cannot be performed, and then the test is performed again based on the regenerated test case until the selected test case generation template is suitable for the data to be tested, namely, the test case can be tested on the data to be tested based on the generated test case, but the efficiency of testing the function to be tested is reduced by repeatedly generating the test case for many times.
Therefore, in order to improve the testing efficiency, in another embodiment of the present application, before the target test case generation template is obtained according to the template identifier, it may be determined whether the test case generation template corresponding to the selected template identifier is applicable to the function to be tested, and under the condition that the test case generation template corresponding to the selected template identifier is applicable to the function to be tested, the target test case generation template is obtained according to the template identifier.
The function to be tested comprises an annotation, the annotation comprises an identifier, and the identifier is used for identifying which test case generation templates are used for the function to be tested, so that the electronic device can judge whether the selected template is included in the annotation included in the function to be tested after the selected template is determined in the template identifiers, under the condition that the annotation included in the function to be tested comprises the selected template identifier, the test case generation template corresponding to the selected template identifier is determined to be suitable for the function to be tested, and under the condition that the annotation included in the function to be tested does not comprise the selected template identifier, the test case generation template corresponding to the selected template identifier is determined to be not suitable for the function to be tested.
In step S104, the test case is generated based on the test parameter data and the target test case generation template.
In the application, the test case generation template is used for generating the test case, the test case generation template comprises various generation logics and data filling bits, the test parameter data can be filled in the data filling bits, then the test case generation template is controlled to generate the test case for testing the function to be tested based on the generation logics, and then the test case can be operated, so that the function to be tested can be tested to obtain a test result, and technicians can modify and adjust the function to be tested based on the test result, and the function to be tested can meet the requirements.
That is, the test case generation template in the present application is actually a template, which is a prototype of each test case, and the test case template may include data filling bits of each test step and test parameter data, each test step corresponds to a respective computer test code, and different test parameter data may be filled in each data filling bit, so that the template may be combined with the test steps and the test parameter data to generate different test cases. For example, after the test parameter data is filled in the data filling bits in each test step, the booklet number parameter data may be loaded into the computer test codes corresponding to the test steps, and then the computer test codes corresponding to each test step are logically combined together in sequence, thereby obtaining the test case.
In the present application, a function to be tested is determined among a plurality of functions in a computer program file; acquiring test parameter data of a function to be tested; acquiring a target test case generation template for generating a test case for testing a function to be tested from a plurality of test case generation templates; and generating a test case based on the test parameter data and the target test case generation template.
By the method and the device, the electronic equipment can automatically generate the test cases, technicians do not need to manually compile the test cases, and zero-code automatic compilation of the test cases is realized, so that the workload of the technicians is reduced, and the labor cost is reduced.
Because the test case does not need to be manually written, the situation of manual writing errors can be avoided, and the accuracy of the test is prevented from being reduced. For example, when performing a BUG test on a function to be tested, if a technician manually compiles a test case, under the condition that the test function names and the corresponding test function values are more, the condition that a plurality of test function names and the test function values are artificially confused easily occurs, so that a compiling error is caused. The test case is automatically compiled in the whole process without human participation, so that the condition of human error can be avoided as much as possible.
In addition, time consumed for manually writing the test cases is often more, the test cases are often faster to automatically write by the electronic equipment, and the time consumed is less, so that the efficiency of writing the test cases can be improved, and then the test efficiency is improved.
Through the method and the device, the work of testing the function can be simpler, the time spent on testing the function by technical personnel can be reduced, the enthusiasm of the technical personnel in testing the function in the computer program file can be improved, the technical personnel can have more time and energy spent in developing the computer program file, the possibility of the occurrence of BUG in the computer program file can be reduced, forward circulation is formed, and the development of the computer program file is facilitated.
In one example, a test case generation template selected by a user and a related tool for selecting a function to be tested may be Integrated in an IDE (Integrated Development Environment), and for the user, only the test case generation template selected by the user and the function to be tested may be selected to implement one-key test case generation.
Further, if a technician is required to manually select the test case generation template each time when testing the function to be tested, the manual operation is complicated.
Therefore, in order to reduce the complexity of manual operation, in another embodiment of the present application, after testing the function to be tested based on the test case, the target test case generation template may be recorded as the test case generation template that was used when the function in the computer program file was tested last time.
For example, in the correspondence between the file identifier of the computer program file and the template identifier of the test case generation template used when the function in the computer program file was tested last time, the file identifier of the computer program file and the template identifier of the target test case generation template are updated.
If the corresponding relationship does not have a record including the file identifier of the computer program file, it indicates that the function in the computer program file is tested for the first time, and therefore, the file identifier of the computer program file and the template identifier of the target test case generation template can form a corresponding entry and be stored in the corresponding relationship.
If the corresponding relationship includes a record including the file identifier of the computer program file, it may be determined whether the template identifier corresponding to the file identifier of the computer program file in the corresponding relationship is the template identifier of the target test case generation template, if the template identifier corresponding to the file identifier of the computer program file in the corresponding relationship is the template identifier of the target test case generation template, no update is needed, and if the template identifier corresponding to the file identifier of the computer program file in the corresponding relationship is not the template identifier of the target test case generation template, the template identifier of the target test case generation template may be used in the corresponding relationship to replace the template identifier corresponding to the file identifier of the computer program file.
In the present application, when testing each function in one computer program file, it is often necessary to use a test case generated by the same test case generation template for testing.
In this way, when the next function to be tested is tested, the target test case generation template for generating the test case for testing the function to be tested is obtained from the plurality of test case generation templates, and the recorded test case generation template used in the test of the function in the computer program file at the latest time can be obtained and used as the target test case generation template. For example, in the correspondence between the file identifier of the computer program file and the template identifier of the test case generation template used when the function in the computer program file is tested last time, the template identifier corresponding to the file identifier of the computer program file is searched, and in the plurality of test case generation templates, the target test case generation template is searched according to the template identifier. And the searched target test case generation template is suitable for the function to be tested.
Similarly, when the next test of another function in the computer program file is performed, a target test case generation template for generating a test case for testing another function in the computer program file is acquired from among the plurality of test case generation templates, and the test case generation template that has been recorded and used in the test of the function in the computer program file at the latest time may be acquired and used as the target test case generation template.
For example, in the correspondence between the file identifier of the computer program file and the template identifier of the test case generation template used when the function in the computer program file is tested for the last time, the template identifier corresponding to the file identifier of the computer program file is searched; and searching a target test case generation template in the plurality of test case generation templates according to the template identification. And the searched target test case generation template is suitable for other functions in the computer program file.
It is noted that, for simplicity of explanation, the method embodiments are described as a series of acts or combination of acts, but those skilled in the art will appreciate that the present application is not limited by the order of acts, as some steps may, in accordance with the present application, occur in other orders and concurrently. Further, those skilled in the art will also appreciate that the embodiments described in the specification are exemplary and that no action is necessarily required in this application.
Referring to fig. 2, a block diagram of a structure of an apparatus for generating a test case according to the present application is shown, where the apparatus may specifically include the following modules:
a determining module 11, configured to determine a function to be tested from among a plurality of functions in a computer program file;
a first obtaining module 12, configured to obtain test parameter data of the function to be tested;
a second obtaining module 13, configured to obtain, in the multiple test case generation templates, a target test case generation template for generating a test case for testing the function to be tested;
and the generating module 14 is configured to generate the test case based on the test parameter data and the target test case generation template.
In an optional implementation manner, the determining module includes:
the first display submodule is used for displaying the function names of a plurality of functions included in the computer program file;
a first determining submodule for determining a selected function name among the plurality of function names;
and the second determining submodule is used for determining the function to be tested according to the selected function name.
In an optional implementation manner, the first obtaining module includes:
the first obtaining submodule is used for obtaining a test parameter name from the function to be tested under the condition that a BUG BUG exists in the data processing process of the function to be tested;
the second obtaining submodule is used for obtaining the service log of the function to be tested;
a third obtaining submodule, configured to obtain a test parameter value corresponding to the test parameter name from the service log;
and the first generation submodule is used for generating the test parameter data according to the test parameter name and the test parameter value.
In an optional implementation manner, the third obtaining sub-module includes:
the determining unit is used for determining the data format of the data in the service log;
the first analysis unit is used for analyzing the data in the service log based on a data analysis mode corresponding to a preset format under the condition that the data format is the preset format to obtain a test parameter value corresponding to the test parameter name;
or,
the second analysis unit is used for analyzing the data in the service log after the format is converted based on a data analysis mode corresponding to the preset format to obtain a test parameter value corresponding to the test parameter name.
In an optional implementation manner, the first obtaining module includes:
the fourth obtaining submodule is used for obtaining a test parameter name from the function to be tested under the condition that the function to be tested needs to be subjected to pressure test;
the second generation submodule is used for generating a character string which accords with the regular check rule;
and the third generation submodule is used for generating the test parameter data according to the test parameter name and the character string.
In an optional implementation manner, the second obtaining module includes:
the second display submodule is used for displaying the template identifications of the plurality of test case generation templates;
a third determining submodule for determining a selected template identifier among the plurality of template identifiers;
and the fifth obtaining submodule is used for obtaining the target test case generation template according to the selected template identification.
In an optional implementation manner, the second obtaining module further includes:
a fourth determining submodule, configured to determine whether the test case generation template corresponding to the selected template identifier is applicable to the function to be tested;
the fifth obtaining submodule is further configured to obtain the target test case generation template according to the selected template identifier under the condition that the function to be tested is applicable.
In an optional implementation manner, the second obtaining module further includes:
and the recording submodule is used for recording the target test case generation template as the test case generation template used when the function in the computer program file is tested last time after the function to be tested is tested based on the test case.
In an optional implementation manner, the recording sub-module includes:
and the updating unit is used for updating the file identifier of the computer program file and the template identifier of the target test case generation template in the corresponding relation between the file identifier of the computer program file and the template identifier of the test case generation template used when the function in the computer program file is tested last time.
In an optional implementation manner, the second obtaining module includes:
and the sixth obtaining submodule is used for obtaining the recorded test case generation template used when the function in the computer program file is tested at the latest time, and taking the test case generation template as the target test case generation template.
In an optional implementation manner, the sixth obtaining sub-module includes:
the first searching unit is used for searching a template identifier corresponding to the file identifier of the computer program file in the corresponding relation between the file identifier of the computer program file and the template identifier of the test case generation template used when the function in the computer program file is tested for the last time;
and the second searching unit is used for searching the target test case generation template in the plurality of test case generation templates according to the searched template identification.
In the present application, a function to be tested is determined among a plurality of functions in a computer program file; acquiring test parameter data of a function to be tested; acquiring a target test case generation template for generating a test case for testing a function to be tested from a plurality of test case generation templates; and generating a test case based on the test parameter data and the target test case generation template.
By the method and the device, the electronic equipment can automatically generate the test cases, technicians do not need to manually compile the test cases, and zero-code automatic compilation of the test cases is realized, so that the workload of the technicians is reduced, and the labor cost is reduced.
Because the test case does not need to be manually written, the situation of manual writing errors can be avoided, and the accuracy of the test is prevented from being reduced. For example, when performing a BUG test on a function to be tested, if a technician manually compiles a test case, under the condition that the test function names and the corresponding test function values are more, the condition that a plurality of test function names and the test function values are artificially confused easily occurs, so that a compiling error is caused. The test case is automatically compiled in the whole process without human participation, so that the condition of human error can be avoided as much as possible.
In addition, time consumed for manually writing the test cases is often more, the test cases are often faster to automatically write by the electronic equipment, and the time consumed is less, so that the efficiency of writing the test cases can be improved, and then the test efficiency is improved.
Through the method and the device, the work of testing the function can be simpler, the time spent on testing the function by technical personnel can be reduced, the enthusiasm of the technical personnel in testing the function in the computer program file can be improved, the technical personnel can have more time and energy spent in developing the computer program file, the possibility of the occurrence of BUG in the computer program file can be reduced, forward circulation is formed, and the development of the computer program file is facilitated.
In one example, a test case generation template selected by a user and a related tool for selecting a function to be tested may be Integrated in an IDE (Integrated Development Environment), and for the user, only the test case generation template selected by the user and the function to be tested may be selected to implement one-key test case generation.
For the device embodiment, since it is basically similar to the method embodiment, the description is simple, and for the relevant points, refer to the partial description of the method embodiment.
Fig. 3 is a block diagram of an electronic device 800 shown in the present application. For example, the electronic device 800 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, an exercise device, a personal digital assistant, and the like.
Referring to fig. 3, electronic device 800 may include one or more of the following components: a processing component 802, a memory 804, a power component 806, a multimedia component 808, an audio component 810, an input/output (I/O) interface 812, a sensor component 814, and a communication component 816.
The processing component 802 generally controls overall operation of the electronic device 800, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing components 802 may include one or more processors 820 to execute instructions to perform all or a portion of the steps of the methods described above. Further, the processing component 802 can include one or more modules that facilitate interaction between the processing component 802 and other components. For example, the processing component 802 can include a multimedia module to facilitate interaction between the multimedia component 808 and the processing component 802.
The memory 804 is configured to store various types of data to support operation at the device 800. Examples of such data include instructions for any application or method operating on the electronic device 800, contact data, phonebook data, messages, images, videos, and so forth. The memory 804 may be implemented by any type or combination of volatile or non-volatile memory devices such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks.
The power supply component 806 provides power to the various components of the electronic device 800. The power components 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the electronic device 800.
The multimedia component 808 includes a screen that provides an output interface between the electronic device 800 and a user. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive an input signal from a user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundary of a touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 808 includes a front facing camera and/or a rear facing camera. The front-facing camera and/or the rear-facing camera may receive external multimedia data when the device 800 is in an operating mode, such as a shooting mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
The audio component 810 is configured to output and/or input audio signals. For example, the audio component 810 includes a Microphone (MIC) configured to receive external audio signals when the electronic device 800 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may further be stored in the memory 804 or transmitted via the communication component 816. In some embodiments, audio component 810 also includes a speaker for outputting audio signals.
The I/O interface 812 provides an interface between the processing component 802 and peripheral interface modules, which may be keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to: a home button, a volume button, a start button, and a lock button.
The sensor assembly 814 includes one or more sensors for providing various aspects of state assessment for the electronic device 800. For example, the sensor assembly 814 may detect an open/closed state of the device 800, the relative positioning of components, such as a display and keypad of the electronic device 800, the sensor assembly 814 may also detect a change in the position of the electronic device 800 or a component of the electronic device 800, the presence or absence of user contact with the electronic device 800, orientation or acceleration/deceleration of the electronic device 800, and a change in the temperature of the electronic device 800. Sensor assembly 814 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 814 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 814 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 816 is configured to facilitate wired or wireless communication between the electronic device 800 and other devices. The electronic device 800 may access a wireless network based on a communication standard, such as WiFi, a carrier network (such as 2G, 3G, 4G, or 5G), or a combination thereof. In an exemplary embodiment, the communication component 816 receives broadcast signals or broadcast operation information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 816 further includes a Near Field Communication (NFC) module to facilitate short-range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the electronic device 800 may be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, micro-controllers, microprocessors or other electronic components for performing the above-described methods.
In an exemplary embodiment, a non-transitory computer-readable storage medium comprising instructions, such as the memory 804 comprising instructions, executable by the processor 820 of the electronic device 800 to perform the above-described method is also provided. For example, the non-transitory computer readable storage medium may be a ROM, a Random Access Memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
Fig. 4 is a block diagram of an electronic device 1900 shown in the present application. For example, the electronic device 1900 may be provided as a server.
Referring to fig. 4, electronic device 1900 includes a processing component 1922 further including one or more processors and memory resources, represented by memory 1932, for storing instructions, e.g., applications, executable by processing component 1922. The application programs stored in memory 1932 may include one or more modules that each correspond to a set of instructions. Further, the processing component 1922 is configured to execute instructions to perform the above-described method.
The electronic device 1900 may also include a power component 1926 configured to perform power management of the electronic device 1900, a wired or wireless network interface 1950 configured to connect the electronic device 1900 to a network, and an input/output (I/O) interface 1958. The electronic device 1900 may operate based on an operating system stored in memory 1932, such as Windows Server, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM, or the like.
The embodiments in the present specification are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, apparatus, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, terminal devices (systems), and computer program products according to the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable test case generation terminal device to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable test case generation terminal device, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable test case generation terminal to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable generation test case terminal apparatus to cause a series of operational steps to be performed on the computer or other programmable generation test case terminal apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable generation terminal apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While the preferred embodiments of the present application have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all alterations and modifications as fall within the scope of the application.
Finally, it should also be noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or terminal that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or terminal. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or terminal that comprises the element.
The method and the device for generating the test case provided by the application are introduced in detail, a specific example is applied in the text to explain the principle and the implementation of the application, and the description of the embodiment is only used for helping to understand the method and the core idea of the application; meanwhile, for a person skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

Claims (14)

1. A method for generating test cases, the method comprising:
determining a function to be tested among a plurality of functions in a computer program file;
acquiring test parameter data of the function to be tested;
acquiring a target test case generation template for generating a test case for testing the function to be tested from a plurality of test case generation templates;
and generating the test case based on the test parameter data and the target test case generation template.
2. The method of claim 1, wherein said obtaining test parameter data for said function under test comprises:
under the condition that a BUG BUG exists in the data processing process of the function to be tested, obtaining a test parameter name from the function to be tested;
acquiring a service log of the function to be tested;
acquiring a test parameter value corresponding to the test parameter name in the service log;
and generating the test parameter data according to the test parameter name and the test parameter value.
3. The method of claim 2, wherein obtaining the test parameter value corresponding to the test parameter name in the service log comprises:
determining a data format of data in the service log;
under the condition that the data format is a preset format, analyzing the data in the service log based on a data analysis mode corresponding to the preset format to obtain a test parameter value corresponding to the test parameter name;
or,
and under the condition that the data format is not the preset format, converting the data format of the data in the service log into the preset format, and analyzing the data in the service log after the format is converted based on a data analysis mode corresponding to the preset format to obtain a test parameter value corresponding to the test parameter name.
4. The method according to claim 1, wherein the obtaining a target test case generation template for generating a test case for testing the function to be tested from among the plurality of test case generation templates comprises:
displaying template identifications of a plurality of test case generation templates;
determining a selected template identifier from a plurality of template identifiers;
determining whether the test case generation template corresponding to the selected template identifier is suitable for the function to be tested;
and under the condition of being applicable to the function to be tested, acquiring the target test case generation template according to the selected template identifier.
5. The method of claim 4, further comprising:
and after testing the function to be tested based on the test case, recording the target test case generation template as a test case generation template used when the function in the computer program file is tested last time.
6. The method according to claim 5, wherein the obtaining a target test case generation template for generating a test case for testing the function to be tested from among the plurality of test case generation templates comprises:
and acquiring a recorded test case generation template used when the function in the computer program file is tested at the last time, and taking the test case generation template as the target test case generation template.
7. An apparatus for generating test cases, the apparatus comprising:
a determining module for determining a function to be tested among a plurality of functions in a computer program file;
the first acquisition module is used for acquiring test parameter data of the function to be tested;
the second obtaining module is used for obtaining a target test case generation template used for generating a test case for testing the function to be tested from a plurality of test case generation templates;
and the generating module is used for generating the test case based on the test parameter data and the target test case generating template.
8. The apparatus of claim 7, wherein the first obtaining module comprises:
the first obtaining submodule is used for obtaining a test parameter name from the function to be tested under the condition that a BUG BUG exists in the data processing process of the function to be tested;
the second obtaining submodule is used for obtaining the service log of the function to be tested;
a third obtaining submodule, configured to obtain a test parameter value corresponding to the test parameter name from the service log;
and the first generation submodule is used for generating the test parameter data according to the test parameter name and the test parameter value.
9. The apparatus of claim 8, wherein the third acquisition submodule comprises:
the determining unit is used for determining the data format of the data in the service log;
the first analysis unit is used for analyzing the data in the service log based on a data analysis mode corresponding to a preset format under the condition that the data format is the preset format to obtain a test parameter value corresponding to the test parameter name;
or,
the second analysis unit is used for analyzing the data in the service log after the format is converted based on a data analysis mode corresponding to the preset format to obtain a test parameter value corresponding to the test parameter name.
10. The apparatus of claim 7, wherein the second obtaining module comprises:
the display submodule is used for displaying the template identifications of the test case generation templates;
a first determining submodule for determining a selected template identifier among the plurality of template identifiers;
the second determining submodule is used for determining whether the test case generating template corresponding to the selected template identification is suitable for the function to be tested;
and the fourth obtaining submodule is used for obtaining the target test case generation template according to the selected template identification under the condition that the function to be tested is applicable.
11. The apparatus of claim 10, wherein the second obtaining module further comprises:
and the recording submodule is used for recording the target test case generation template as the test case generation template used when the function in the computer program file is tested last time after the function to be tested is tested based on the test case.
12. The apparatus of claim 11, wherein the second obtaining module comprises:
and the fifth obtaining submodule is used for obtaining the recorded test case generation template used when the function in the computer program file is tested at the latest time, and the test case generation template is used as the target test case generation template.
13. An electronic device, characterized in that the electronic device comprises:
a processor;
a memory for storing processor-executable instructions;
wherein the processor is configured to perform the method of generating test cases of any of claims 1-6.
14. A non-transitory computer readable storage medium, instructions in which, when executed by a processor of an electronic device, enable the electronic device to perform the method of generating test cases of any of claims 1-6.
CN201911405803.4A 2019-12-30 2019-12-30 Method and device for generating test case Active CN111209195B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911405803.4A CN111209195B (en) 2019-12-30 2019-12-30 Method and device for generating test case

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911405803.4A CN111209195B (en) 2019-12-30 2019-12-30 Method and device for generating test case

Publications (2)

Publication Number Publication Date
CN111209195A true CN111209195A (en) 2020-05-29
CN111209195B CN111209195B (en) 2023-08-15

Family

ID=70784157

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911405803.4A Active CN111209195B (en) 2019-12-30 2019-12-30 Method and device for generating test case

Country Status (1)

Country Link
CN (1) CN111209195B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114116466A (en) * 2021-11-12 2022-03-01 苏州浪潮智能科技有限公司 Unit testing method, device and medium based on operation log
CN114328060A (en) * 2022-03-14 2022-04-12 江苏清微智能科技有限公司 Reusable test case framework, construction method and electronic equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101976220A (en) * 2010-09-27 2011-02-16 北京神州泰岳软件股份有限公司 Unit test system
CN106502896A (en) * 2016-10-21 2017-03-15 武汉斗鱼网络科技有限公司 A kind of generation method of function test code and device
WO2018000607A1 (en) * 2016-06-30 2018-01-04 乐视控股(北京)有限公司 Method and electronic apparatus for identifying test case failure causes
CN109002390A (en) * 2018-06-25 2018-12-14 天维讯达(北京)科技有限公司 A kind of test case dynamic state of parameters configuration method and device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101976220A (en) * 2010-09-27 2011-02-16 北京神州泰岳软件股份有限公司 Unit test system
WO2018000607A1 (en) * 2016-06-30 2018-01-04 乐视控股(北京)有限公司 Method and electronic apparatus for identifying test case failure causes
CN106502896A (en) * 2016-10-21 2017-03-15 武汉斗鱼网络科技有限公司 A kind of generation method of function test code and device
CN109002390A (en) * 2018-06-25 2018-12-14 天维讯达(北京)科技有限公司 A kind of test case dynamic state of parameters configuration method and device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
郝晓晓;张卫丰;: "基于XML的SDK自动化测试框架的设计与实现" *

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114116466A (en) * 2021-11-12 2022-03-01 苏州浪潮智能科技有限公司 Unit testing method, device and medium based on operation log
CN114116466B (en) * 2021-11-12 2023-11-07 苏州浪潮智能科技有限公司 Unit test method, device and medium based on operation log
CN114328060A (en) * 2022-03-14 2022-04-12 江苏清微智能科技有限公司 Reusable test case framework, construction method and electronic equipment

Also Published As

Publication number Publication date
CN111209195B (en) 2023-08-15

Similar Documents

Publication Publication Date Title
US10055204B2 (en) Generating communication firmware and a program plug-in based on product information and a program template
CN106569800B (en) Front-end interface generation method and device
CN111273899B (en) Code processing method, device, electronic equipment and storage medium
CN106339384B (en) Storage process conversion method and device
CN104539476A (en) Data package obtaining method and device
CN111221733A (en) Information processing method and device, mobile terminal and storage medium
CN109344051B (en) Data processing method and device, electronic equipment and storage medium
CN112241361A (en) Test case generation method and device and problem scene automatic reproduction method and device
CN111209195B (en) Method and device for generating test case
CN111538502A (en) Installation package processing method and device, electronic equipment and storage medium
CN109684112B (en) Program file operation method, device, terminal and storage medium
CN113420531B (en) Code text conversion method, device and storage medium
CN111061452A (en) Voice control method and device of user interface
CN116069612A (en) Abnormality positioning method and device and electronic equipment
CN112395192A (en) Information processing method and device
CN112416751A (en) Processing method and device for interface automation test and storage medium
CN117033179A (en) Machine instruction debugging method and device, electronic equipment and readable storage medium
CN110851370A (en) Program testing method and device, and storage medium
CN115757135A (en) Test environment deployment method, apparatus, storage medium, and program product
CN113626321B (en) Bridging test method, device, system and storage medium
CN114896165A (en) Testing method and device of conversation robot system, electronic equipment and storage medium
CN106354595B (en) Mobile terminal, hardware component state detection method and device
CN112631695A (en) Data verification method and device, electronic equipment and storage medium
CN112214698A (en) Information processing method and device
CN111597106A (en) Point burying management method and device

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