CN113836026A - Upgrade test method and device, electronic equipment and storage medium - Google Patents

Upgrade test method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN113836026A
CN113836026A CN202111143162.7A CN202111143162A CN113836026A CN 113836026 A CN113836026 A CN 113836026A CN 202111143162 A CN202111143162 A CN 202111143162A CN 113836026 A CN113836026 A CN 113836026A
Authority
CN
China
Prior art keywords
test
upgrade
product
upgrading
path
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
CN202111143162.7A
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 TCL New Technology Co Ltd
Original Assignee
Shenzhen TCL New Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen TCL New Technology Co Ltd filed Critical Shenzhen TCL New Technology Co Ltd
Priority to CN202111143162.7A priority Critical patent/CN113836026A/en
Publication of CN113836026A publication Critical patent/CN113836026A/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
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates

Landscapes

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

Abstract

The embodiment of the application discloses an upgrade test method, an upgrade test device, electronic equipment and a storage medium; the method and the device can receive the upgrading test triggering instruction of the product; identifying an upgrading path of the product according to an upgrading trigger instruction; determining a target test scene of a product under an upgrading path; and testing the product under the upgrading path based on the target test scene, and generating an upgrading test report of the product. By the upgrade testing method provided by the embodiment of the application, the product can be tested under different upgrade paths in different test scenes, and the robustness of the upgrade test on the product is improved.

Description

Upgrade test method and device, electronic equipment and storage medium
Technical Field
The present application relates to the field of communications technologies, and in particular, to an upgrade test method and apparatus, an electronic device, and a storage medium.
Background
With the development of information technology and the rapid development and popularization of internet technology, electronic products are prosperous. The electronic product not only promotes the prosperous development of the information technology field, but also brings convenience to the daily learning and life of people, and becomes an indispensable part of the daily learning and life of people.
In the prior art, testing electronic products is also an important step in research and development, and many problems in use of products can be avoided by continuously testing the products. For example, by performing upgrade test on the product, the problem of the product during upgrade can be found, so that the product is optimized. In the practice of the prior art, the inventor of the present application finds that the upgrade test of the product has a problem of low robustness.
Disclosure of Invention
The embodiment of the application provides an upgrade test method, an upgrade test device, electronic equipment and a storage medium, and robustness of upgrade test on products can be improved.
The embodiment of the application provides an upgrade test method, which comprises the following steps:
receiving an upgrading test trigger instruction of a product;
identifying an upgrading path of the product according to the upgrading triggering instruction;
determining a target test scene of the product under the upgrading path;
and testing the product under the upgrading path based on the target test scene, and generating an upgrading test report of the product.
Correspondingly, the embodiment of the present application further provides an upgrade testing apparatus, including:
the receiving unit is used for receiving an upgrading test triggering instruction of a product;
the identification unit is used for identifying the upgrading path of the product according to the upgrading trigger instruction;
the determining unit is used for determining a target test scene of the product under the test path;
and the test processing unit is used for carrying out test processing on the product under the upgrading path based on the target test scene and generating an upgrading test report of the product.
In one embodiment, the test processing unit includes:
the first acquisition subunit is used for acquiring the test logic and the test logic points of the test scene;
the detection subunit is used for detecting the upgrading process of the product in the upgrading path based on the test logic point;
and the execution subunit is used for executing the test logic on the product under the test logic point when the test logic point is detected.
In one embodiment, the execution subunit includes:
the sending module is used for sending a network abnormity triggering instruction to the network control platform when the test logic point is detected;
the receiving module is used for receiving a network abnormity triggering success instruction returned by the network control platform;
and the first upgrading processing module is used for upgrading the product based on the network abnormity triggering success instruction.
In one embodiment, the execution subunit includes:
the first acquisition module is used for acquiring the upgrade file of the product;
the compression exception handling module is used for carrying out compression exception handling on the upgrade file to obtain an exception compression file;
and the second upgrading processing module is used for upgrading the product based on the abnormal compression file when the test logic point is detected.
In one embodiment, the execution subunit includes:
the second acquisition module is used for acquiring the upgrade file of the product;
the file exception handling module is used for carrying out file exception handling on the upgrade file to obtain an exception upgrade file;
and the third upgrading processing module is used for upgrading the product based on the abnormal upgrading file when the test logic point is detected.
In an embodiment, the test processing unit further includes:
the monitoring subunit is used for monitoring the testing process to obtain upgrading testing information when the product is tested and processed under the upgrading path;
and the generation subunit is used for generating the upgrade test report based on the upgrade test information.
In one embodiment, the monitoring subunit includes:
the stage identifier distinguishing processing module is used for distinguishing the stage identifier of the upgrading path and generating the stage identification information according to the distinguishing result;
the version identification processing module is used for carrying out version identification processing on the product to obtain the version information;
and the function verification processing module is used for performing function verification processing on the product to obtain the function verification information.
In one embodiment, the identification unit includes:
the second obtaining subunit is configured to obtain an upgrade path list according to the upgrade trigger instruction, where the upgrade path list includes at least one preset upgrade path;
the analysis subunit is used for analyzing the upgrade trigger instruction to obtain upgrade setting information and product attribute information;
and the determining subunit is configured to determine, based on the upgrade setting information and the product attribute information, an upgrade path of the product in the at least one preset upgrade path.
In one embodiment, the identification unit further comprises:
the test detection subunit is used for carrying out test detection on the upgrade path list to obtain a test detection result;
the updating subunit is used for updating the upgrading path when the test detection result does not meet the preset detection condition, so as to obtain an updated upgrading path;
and the test processing subunit is used for carrying out test processing on the product under the updated upgrade path based on the target test scene.
In one embodiment, the determining unit includes:
the judging subunit is used for judging whether to test the product under the upgrading path based on each test scene;
and the screening subunit is used for screening out the target test scene from at least one untested test scene when at least one untested test scene exists.
Correspondingly, the embodiment of the application also provides an electronic device, which comprises a memory and a processor; the memory stores a computer program, and the processor is configured to run the computer program in the memory to execute the upgrade test method provided in any one of the embodiments of the present application.
Correspondingly, an embodiment of the present application further provides a storage medium, where the storage medium stores a computer program, and the computer program, when executed by a processor, implements the upgrade test method provided in any embodiment of the present application.
The method and the device can receive the upgrading test triggering instruction of the product; identifying an upgrading path of the product according to the upgrading triggering instruction; determining a target test scene of the product under the upgrading path; and testing the product under the upgrading path based on the target test scene, and generating an upgrading test report of the product, thereby improving the robustness of upgrading test on the product.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a schematic view of a scenario of an upgrade testing method provided in an embodiment of the present application;
FIG. 2 is a schematic flowchart of an upgrade testing method provided in an embodiment of the present application;
FIG. 3 is a schematic flowchart of an upgrade testing method provided in an embodiment of the present application;
FIG. 4 is a schematic diagram of another scenario of an upgrade testing method provided in an embodiment of the present application;
FIG. 5 is a schematic flowchart of an upgrade testing method provided in an embodiment of the present application;
FIG. 6 is a schematic structural diagram of an upgrade testing apparatus provided in an embodiment of the present application;
fig. 7 is a schematic structural diagram of an electronic device provided in an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, however, the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments of the present application. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The embodiment of the application provides an upgrade test method, which can be executed by an upgrade test device, and the upgrade test device can be integrated in an electronic device. The electronic device may include at least one of a terminal and a server. Namely, the upgrade test method may be executed by the terminal or the server.
Wherein, this terminal can include personal computer, panel computer, smart television, smart mobile phone, intelligent house, wearable electronic equipment, VR/AR equipment, on-vehicle computer etc..
The server may be an interworking server or a background server among a plurality of heterogeneous systems, an independent physical server, a server cluster or a distributed system formed by a plurality of physical servers, a cloud server providing basic cloud computing services such as cloud service, a cloud database, cloud computing, a cloud function, cloud storage, network service, cloud communication, middleware service, domain name service, security service, big data, an artificial intelligence platform and the like, and the like.
In an embodiment, as shown in fig. 1, the upgrade testing apparatus may be integrated on an electronic device such as a terminal or a server, so as to implement the upgrade testing method provided in the embodiment of the present application. Specifically, the electronic device may receive an upgrade test trigger instruction of a product; identifying an upgrading path of the product according to an upgrading trigger instruction; determining a target test scene of a product under a test path; and testing the product under the upgrading path based on the target test scene, and generating an upgrading test report of the product.
The following are detailed below, and it should be noted that the order of description of the following examples is not intended to limit the preferred order of the examples.
The upgrade test method provided by the embodiment of the present application will be described from the perspective of integrating the upgrade test apparatus in the server.
As shown in fig. 2, an upgrade testing method is provided, and the specific process includes:
101. and receiving an upgrading test triggering instruction of the product.
Wherein the article of manufacture may comprise a collection of computer data and instructions organized in a particular order. For example, the product may be an application or a software package on a smart home, and so on.
The application program comprises a computer program for completing one or more specific functions, which is operated in an interaction mode, can interact with a use object of the application program and is provided with a visual display interface.
For example, the application programs may include application software on various terminals. For example, the Application program may include various mobile phone software (APP), tablet Application software, Application software on a notebook Computer, Application software on a Personal Computer (PC), and the like.
For example, the application programs may include browsers, video playback software, game software, and so forth.
As another example, an application may also include an applet. Among them, the applet (Mini Program) is an application that can be used without downloading and installing. In order to provide more diversified business services to users, developers can develop corresponding applets for applications (such as instant messaging applications, shopping applications, mail applications, and the like) of the terminal, the applets can be embedded into the applications of the terminal as sub-applications, and the corresponding business services can be provided for the users by running the sub-applications (i.e., the corresponding applets) in the applications.
The smart home (home automation) integrates facilities related to home life by using a home as a platform and utilizing a comprehensive wiring technology, a network communication technology, a security technology, an automatic control technology and an audio and video technology, so that a high-efficiency management system of home facilities and home schedule affairs is constructed, home safety, convenience, comfort and artistry are improved, and an environment-friendly and energy-saving living environment is realized.
For example, the software package of the smart home may include a home system formed by smart homes such as a smart television, a smart air conditioner, or a smart refrigerator, and the software package may control functions and modes of the smart home.
In one embodiment, a developer may continuously optimize the functions of a product or develop new functions for the product, and at this time, the product needs to be upgraded, so that the functions of the product are optimized or the product has new functions.
In one embodiment, to test the upgrade process of the product, the upgrade process of the product may be simulated at the server. For example, a developer may perform upgrade trigger simulation on a product, and at this time, the server may receive an upgrade test trigger instruction.
Wherein, there are many ways to trigger the upgrade of the product. For example, when the product is an application, the user may trigger an upgrade control on the application, thereby triggering an upgrade on the product. As another example, a forced upgrade trigger may be performed on a product by a server. For another example, when the product is a software package of a smart home, since the smart home performs upgrade detection at intervals, the product may implement upgrade triggering at intervals.
In an embodiment, when the product is subjected to upgrade testing, the upgrade trigger simulation of the product can be realized through a plurality of automatic testing means, so that the server receives an upgrade test trigger instruction.
For example, when the product is an application, the user can be simulated through the appium framework to trigger an upgrade control on the application. The apium is an open-source cross-platform automatic testing tool, supports a plurality of different operating systems, and can be used for testing native and lightweight application programs.
Also for example, a forced upgrade trigger may be performed on the product by the selenium analog server. Among them, Selenium is a tool for Web application testing, and the Selenium test runs directly in the browser, just like a real user is operating.
102. And identifying an upgrading path of the product according to the upgrading triggering instruction.
In one embodiment, it is possible for a developer to optimize a product multiple times in a short time. After each optimization, the product has a new upgrade version and an upgrade path corresponding to the upgrade version. When the user selects one of the upgrading versions, the product is upgraded according to the upgrading path corresponding to the upgrading version.
For example, a developer performs 3 sub-optimization on a product in a short time to obtain an upgraded version 1, an upgraded version 2 and an upgraded version 3, and each upgraded version has its corresponding upgrade path, and the corresponding upgrade paths are different. And when the user selects one of the upgrading versions, the product is upgraded according to the upgrading path corresponding to the upgrading version.
Wherein the upgrade path includes an upgrade mode of the product.
In one embodiment, the upgrade path is diverse. For example, as shown in FIG. 4, an upgrade path may include a sequential upgrade path, a helicopter channel path, a cross single version upgrade path, a cross multiple version upgrade path, and a rollback re-upgrade path, among others.
The sequential upgrading path comprises an upgrading mode for sequentially upgrading from the current version to the latest version. For example, if the current version is version 1 and the latest version is version 5, the upgrade path is sequentially upgraded from version 1 to version 2, then from version 2 to version 3, then from version 3 to version 4, and then from version 4 to version 5, so as to achieve the upgrade from the current version to the latest version.
Wherein the cut-through upgrade path comprises an upgrade mode for directly upgrading from the current version to the latest version. For example, if the current version is version 1 and the latest version is version 5, the pass-through upgrade path will upgrade directly from version 1 to version 5.
The upgrade mode comprises an upgrade mode of sequentially upgrading from the current version to the latest version across the single version. For example, if the current version is version 1 and the latest version is version 5, the upgrade will be from version 1 to version 3 across a single version upgrade path and then to version 5.
The upgrading mode comprises upgrading from the current version to multiple versions. For example, the current version is version 1 and the latest version is version 7, and the upgrade from version 1 to version 4 and then from version 4 to version 7 is performed across multiple versions.
The rollback re-upgrading path comprises an upgrading mode of reverting to the current version and upgrading to the latest version after upgrading from the current version to the latest version. For example, if the current version is version 1 and the latest version is version 5, the rollback re-upgrade path will be upgraded from version 1 to version 5, and then the rollback will be performed to version 1 and then the rollback will be performed to version 5.
In an embodiment, since the upgrade path has a variety of types, the upgrade testing apparatus may identify the upgrade path of the product according to the upgrade trigger instruction, so that the target test scenario of the product may be determined under the upgrade path.
In one embodiment, there are a number of ways to identify an upgrade path to a product.
For example, an upgrade path for a product may be determined in conjunction with a current version of the product and a target version to which an upgrade is desired. For example, if the current version of the product is version 1 and the target version is version 2, it may be determined that the upgrade path of the product is a through upgrade path or a sequential upgrade path.
For another example, the upgrade path of the product may be determined in combination with factors such as the memory of the product and/or the network speed of the upgrade. For example, when the memory of the product is large, the upgrade path of the product may be determined to be a sequential upgrade path or an upgrade across a single version. When the memory of the product is less, the upgrade path of the product can be determined to be a through upgrade path or a multi-version upgrade path. For another example, when the upgrade net speed of the product is fast, a pass-through upgrade path may be adopted. And when the upgrading network speed of the product is slow, a rollback re-upgrading path or an upgrading path across a single version can be adopted, and the like.
103. And determining a target test scene of the product under the upgrading path.
In an embodiment, in order to improve robustness of an upgrade test, a plurality of test scenarios are provided in the embodiment of the present application, and the upgrade test is performed on a product based on the plurality of scenarios.
Wherein the test scenario includes an environment set by a developer in order to test the function or performance of the product. For example, the test scenarios may include a network exception test scenario, a compression exception test scenario, and a file exception test scenario, among others.
The network anomaly test scenario may include a scenario in which an anomaly occurs in the network during the upgrade process. For example, network anomaly scenarios may include a network outage, a signal loss, a weak network, and so on.
In an embodiment, in the process of upgrading a product, the original product file is often replaced and updated to the upgrade file in the upgrade package, so that the upgrading process is realized. The product file and the upgrade file can be the basis for the product to run related services and processes. For example, the product file and the upgrade file may be an Application Package (APK), or the like.
In one embodiment, there are generally multiple upgrade files in the upgrade package, and there is an interdependent relationship between these upgrade files. If a certain file in the upgrade package is missing, a certain service or a certain progress of the product will be in a problem and cannot be operated. Therefore, when a product is upgraded, a file list, file contents, dependency relationships between files, core files, and the like are often checked.
The file exception test scenario may include a scenario in which an exception occurs in the upgrade file during the upgrade process. For example, a file exception test scenario may include missing upgrade files in an upgrade package, an exception exists for dependencies between upgrade files, the contents of a file are tampered with, a file manifest is missing, and so on.
In an embodiment, the upgrade package is often compressed, so that the upgrade package needs to be compressed before the original product file can be updated and replaced with the upgrade file.
The compression abnormity test scene comprises a scene in which an abnormity occurs when the upgrade package is compressed. For example, a compression exception test scenario may include an incomplete upgrade package, a compression format not supported or compression encrypted, and so on.
In one embodiment, different upgrade paths need to be tested in all test scenarios in order for the upgrade test to be robust and reliable.
The target test scenario may include a scenario in which a product is currently tested in an upgrade path. For example, when a product is tested under an upgrade path based on a compression exception test scenario, the compression exception test scenario may be a target test scenario. For another example, when a product is tested under an upgrade path based on a file exception test scenario, the file exception test scenario may be a target test scenario.
In an embodiment, the upgrade testing apparatus may determine whether to perform a test process on the product under the upgrade path based on each test scenario when determining the target test scenario of the product. And when at least one untested test scene exists, screening out a target test scene from the at least one untested test scene. Specifically, the step of "determining a target test scenario of a product under a test path" may include:
judging whether to test the product under the upgrading path based on each test scene;
and when at least one untested test scene exists, screening out a target test scene from the at least one untested test scene.
In one embodiment, there are various ways to determine whether to perform the test processing on the product in the upgrade path based on each test scenario. For example, when a product is tested and processed under an upgrade path based on a certain test scenario, a tested identifier may be added to the test scenario, so that whether the product is tested and processed under the upgrade path based on each test scenario may be determined according to the identifier. For another example, it can be said that the test scenarios are all stored in the test library, and each time a test scenario is tested, the test scenario is removed from the test library. Therefore, whether the product is subjected to test processing under the upgrade path based on each test scenario can be known by judging the number of the test scenarios of the test library.
In one embodiment, when there is at least one untested test scenario, a target test scenario may be screened from the at least one untested test scenario.
For example, when the test scenarios are stored in the test library, the target test scenarios may be screened out according to the storage order of the test scenarios in the test library. For example, the test scenarios include a network exception test scenario, a compression exception test scenario, and a file exception test scenario. The storage sequence of the test scenes in the test library is a network exception test scene, a compression exception test scene and a file exception test scene respectively. Therefore, when the target test scenario is screened, the network anomaly test scenario can be determined as the target test scenario.
For another example, the target test scenario may be randomly selected from a plurality of test scenarios.
104. And testing the product under the upgrading path based on the target test scene, and generating an upgrading test report of the product.
In an embodiment, after the target test scenario is determined, the product may be tested in the upgrade path based on the target test scenario, and an upgrade test report of the product may be generated.
For example, when the target test scenario is a compression exception test scenario, the product may be subjected to test processing under the upgrade path based on the compression exception test scenario.
For another example, when the target test scenario is a network anomaly test scenario, the product may be tested and processed under the upgrade path based on the network anomaly test scenario.
For another example, when the target test scenario is a file exception test scenario, the product may be subjected to test processing under the upgrade path based on the file exception test scenario.
In an embodiment, an upgrade test report for a product may be generated after a test process is performed on the product under an upgrade path based on a target test scenario. And an upgrade test report of the product can be generated after the product is tested and processed under the upgrade path based on all the test scenes.
The embodiment of the application provides an upgrade test method, which can receive an upgrade test trigger instruction of a product; identifying an upgrading path of the product according to an upgrading trigger instruction; determining a target test scene of a product under an upgrading path; and testing the product under the upgrading path based on the target test scene, and generating an upgrading test report of the product. By the upgrade testing method provided by the embodiment of the application, the product can be tested under different upgrade paths in different test scenes, and the robustness of the upgrade test on the product is improved.
The method described in the above examples is further illustrated in detail below by way of example.
The method of the embodiment of the present application will be described by taking an example in which an upgrade test method is integrated on a server. Specifically, as shown in fig. 3, a flow of the upgrade testing method provided in the embodiment of the present application may include:
201. and the server receives an upgrading test triggering instruction of the product.
For example, the server may perform an upgrade trigger simulation on the product. For example, forced upgrade triggers can be made to the product by the selenium analog server. At this time, the server receives an upgrade test trigger command for the product.
202. And the server identifies the upgrading path of the product according to the upgrading triggering instruction.
In one embodiment, since the upgrade path has a variety, a plurality of upgrade paths may be stored in the upgrade path manifest. The upgrade path list is a data structure with a storage function. For example, the upgrade path manifest may be an array, a stack, or the like.
In an embodiment, in order to improve the robustness of the product upgrade test, the product may be subjected to the upgrade test under different upgrade paths. Therefore, the upgrade path to be tested can be firstly stored in the upgrade path list, and the product can be upgraded and tested based on the upgrade path in the upgrade path list. Specifically, the step of identifying the upgrade path of the product according to the upgrade trigger instruction includes:
acquiring an upgrading path list according to an upgrading trigger instruction, wherein the upgrading path list comprises at least one preset upgrading path;
analyzing the upgrading trigger instruction to obtain upgrading setting information and product attribute information;
and determining an upgrade path of the product in at least one preset upgrade path based on the upgrade setting information and the product attribute information.
The preset upgrading path comprises a path which needs to carry out upgrading test on the product under the upgrading path.
In one embodiment, to better test a product, the environment of the product during upgrade is simulated during testing of the product during upgrade. For example, upgrade setting information and product attribute information, etc.
The upgrade setting information comprises the setting of the product in the upgrade process of the user when the user upgrades the product. For example, when there are multiple updated versions of a product, a user may select one of the versions to upgrade the product, and the upgrade setting information may include the version selected by the user for upgrading. For another example, when upgrading a product, the user may select where the upgrade file is stored in the device, and the upgrade setting information may include where the user selects to store the upgrade file.
The product attribute information may include information related to the product itself, among other things. For example, product attribute information may include how much traffic is needed to update the product, how much storage space is needed to update the product, what rights are needed to upgrade the product, and so forth.
In an embodiment, the upgrade trigger instruction may be parsed, so as to obtain upgrade setting information and product attribute information. For example, the upgrade trigger instruction may be traversed to obtain upgrade setting information and product attribute information.
In an embodiment, after obtaining the upgrade path list, the upgrade setting information, and the product attribute information, an upgrade path of the product may be determined in at least one preset upgrade path based on the upgrade setting information and the product attribute information.
For example, one of the preset upgrade paths may be determined as the upgrade path based on the upgrade setting information. Then, whether it is reasonable to upgrade the product in the upgrade path may be determined based on the product attribute information. When reasonable, the upgrade path may be determined to be an upgrade path for the product. When not reasonable, an appropriate upgrade path may be selected based on the product attribute information.
In an embodiment, after an upgrade path of a product is identified, a target test scenario of the product may be determined under the upgrade path, and a test process may be performed on the product under the upgrade path based on the target test scenario, and an upgrade test report of the product may be generated.
In an embodiment, since the robustness of the product upgrade test is improved, the product can be upgraded and tested under different upgrade paths respectively. Therefore, based on the method for identifying the upgrade path of the product, after the step of performing test processing on the product under the upgrade path based on the target test scenario, the method further includes:
testing and detecting the upgrade path list to obtain a test and detection result;
when the test detection result does not accord with the preset detection condition, updating the upgrade path to obtain an updated upgrade path;
and testing the product under the updated upgrade path based on the target test scene.
The detecting the upgrade path list may include whether to perform an upgrade test on the product based on detecting an upgrade path suitable for the product in the upgrade path list.
In an embodiment, after the product attribute information of the product is obtained, an upgrade path suitable for the product may be selected according to the product attribute information. Then, after the product is subjected to upgrade testing based on one of the upgrade paths, a tested identifier can be added to the upgrade path. Therefore, when the upgrade path list is tested and detected, whether the upgrade paths all have tested identifications can be detected.
When the test detection result does not meet the preset detection condition, the upgrading path list is provided with the upgrading path without the tested mark, and the upgrading path is possibly not tested. At this time, one upgrade path may be arbitrarily selected from the untested upgrade paths as an updated upgrade path. Then, the product can be tested under the updated upgrade path based on the target test scenario.
In an embodiment, the product may also be upgrade tested based on all upgrade paths on the upgrade path list. For example, when the upgrade path list includes 7 upgrade paths, the product may be upgrade tested based on the 7 upgrade paths, respectively, so as to improve robustness of the upgrade test performed on the product.
203. And the server determines a target test scene of the product under the upgrading path.
In an embodiment, after the server determines the upgrade path of the product, the server may further determine a target test product under the upgrade path, so that the server may perform upgrade test processing on the product under the upgrade path based on the target test scenario, and generate an upgrade test report.
In an embodiment, since the product is subjected to the upgrade test processing based on each test scenario, when the target test scenario is determined, it is determined whether the product is subjected to the test processing under the upgrade path based on each test scenario. When at least one untested test scenario exists, the server may screen out a target test scenario from the at least one untested test scenario. Specifically, the step of determining the target test scene of the product by the server under the upgrade path includes:
judging whether to test the product under the upgrading path based on each test scene;
and when at least one untested test scene exists, screening out a target test scene from the at least one untested test scene.
In an embodiment, whether the server performs the test processing on the product in the upgrade path based on each test scenario may be determined in various ways.
For example, suppose the server stores each test scenario in an array. When the server performs a test process on the product based on a test scenario, the test scenario may be removed from the data. Therefore, whether the product is subjected to test processing under the upgrade path based on each test scenario can be judged by judging the number of the test scenarios in the data. For example, when the number of test scenarios in the data is not zero, it indicates that the product has not been subjected to the test processing under the upgrade path based on each test scenario. For another example, when the number of test scenarios in the data is zero, it is described that the test processing has been performed on the product under the upgrade path on a per test scenario basis.
For another example, when a product is subjected to a test process based on a test scenario, a tested identifier may be added to the test scenario. Therefore, the server can judge whether to perform test processing on the product under the upgrade path based on each test scenario through the tested identifier. For example, when there is a test scenario without a tested identifier, it indicates that the product has not been subjected to test processing under the upgrade path based on each test scenario. For another example, when all test scenarios have the tested identifier, it is stated that the product is subjected to the test processing under the upgrade path based on each test scenario.
In one embodiment, when at least one untested test scenario exists, the server screens out a target test scenario from the at least one untested test scenario. For example, the server may randomly screen out a target test scenario from at least one untested test scenario. For another example, when the test scenario is stored in a data structure such as an array or a stack, the server may filter out the target test scenario according to a storage order of the test scenario in the array or the stack.
204. And the server tests and processes the product under the upgrading path based on the target test scene and generates an upgrading test report of the product.
In an embodiment, after the server determines the target test scenario, the server may perform a test process on the product under the upgrade path based on the target test scenario, and generate an upgrade test report of the product.
In an embodiment, different test scenarios may have different test logics and test time points, and therefore, when the server performs test processing on a product in an upgrade path based on a target test scenario, the server may obtain the test logics and test logic points of the test scenarios, and perform test processing on the product based on the test logics and the test logic points. Specifically, the step of performing test processing on the product under the upgrade path based on the target test scenario includes:
acquiring a test logic and a test logic point of a test scene;
detecting the upgrading process of the product in the upgrading path based on the test logic point;
when a test logic point is detected, the test logic is executed on the product under the test logic point.
The test logic point comprises a stage of upgrading and testing the product in the product upgrading process.
In one embodiment, the upgrade process for a product may be divided into more than one stage. For example, as shown in fig. 4, the upgrade process of the product may be divided into a detection phase, a download phase, a verification phase, and so on.
In the detection stage, the equipment integrated with the product can detect the upgrade package of the server and information in the upgrade package, and match information such as model, hash, validity check and the like, so that the upgrade package is suitable for the equipment, the hash value of the upgrade package is effective, and the upgrade package is a package issued by a trusted official channel and the like.
In the downloading stage, when the equipment confirms that the upgrade package is suitable, the downloading logic is triggered, the upgrade package is pulled from the cloud, and network fluctuation may be received in the pulling process, so that various downloading robustness mechanisms such as breakpoint continuous transmission, grouping downloading splicing, timeout reconnection and the like can be performed.
In the verification stage, when the device successfully downloads the upgrade package, the upgrade package is verified, for example, the size of the package, the content of the package, the integrity of the number of package files and the like are verified, so that the upgrade package is ensured to be consistent with official release, and the loss, damage and the like of part of files caused by the downloading process are avoided.
In addition, there are many other stages in the upgrade process, such as a compression stage (transmitting a compression key through a secure channel, splicing and compressing an upgrade package), a backup stage (backing up a key file so that an error in the upgrade process can be restored), a replacement stage (replacing an existing file in the upgrade package with a file in the system to update the file), and the like.
In one embodiment, each stage may correspond to a test logic point. For example, the detection phase may be testing logical point 1. Also for example, the download phase may be test logic point 2. As another example, the verification phase may be test logic Point 3. As another example, the compression phase may be test logic point 4. As another example, the backup phase may be testing logical point 5, and so on.
The test logic may include logic to be followed when upgrading and testing the product based on the test scenario. For example, the test logic may include steps that the server needs to perform when performing an upgrade test on a product basis. Through the test logic, the server can know how to test the product under the test scene, so that the automatic test of the product is realized.
In an embodiment, when a product is subjected to test processing under an upgrade path based on a target test scenario, a server may obtain a test logic and a test logic point of the test scenario. And detecting the upgrading process of the product in the upgrading path based on the test logic point.
In one embodiment, a phase identifier is generated for each phase that a product enters during an upgrade. For example, when a product is in a testing phase, a testing phase identifier is generated. As another example, when a product is in the download phase, a download phase identifier may be generated, and so on. When so, the server may check for the phase identifier. Wherein, when the server detects that the phase identifier matches the test logical point, the server may begin executing the test phase at the test logical point.
In an embodiment, when the test scenario is a network anomaly test scenario, the step "execute the test logic under the test logic point on the product when the test logic point is detected" may include:
when the test logic point is detected, sending a network abnormity triggering instruction to the network control platform;
receiving a network abnormity triggering success instruction returned by the network control platform;
and triggering a success command based on network exception, and upgrading the product.
In one embodiment, the test scenario may include a network outage, signal loss, weak network, and the like due to network anomalies. Wherein, the network disconnection, the signal loss, the weak network and the like are controlled by the network control platform. Therefore, when the test logical point is detected, the server can send a network exception triggering instruction to the network control platform. Then, the network control platform performs network exception handling based on the network exception triggering instruction.
Wherein the network control platform may be a router, etc.
For example, for a network anomaly test scenario of network disconnection, the server can be connected with a router background through an automatic script, connection of a WAN port is cancelled, and the router is caused to have no network, so that the scenario that a product is disconnected during upgrading is simulated.
For another example, for a network anomaly test scenario in which the signal disappears, the server may connect to the router background through an automated script to turn off the WiFi hotspot signal, and the product cannot find the hotspot.
For another example, for a network anomaly test scenario such as a weak network, the server may perform operations such as limiting the network speed and setting the packet loss rate in the background of the router.
After the network control platform performs network exception handling, the server may receive a network exception triggering success instruction returned by the network control platform, and perform upgrade processing on the product based on the network exception triggering success instruction.
In an embodiment, the product upgrade package is generally transmitted to the device in a compressed package form, the compressed package can ensure the integrity of the upgrade package, and meanwhile, the size of the upgrade package can be controlled, so that the bandwidth and time required by network transmission are reduced, and if the compressed package has problems, the intelligent device fails to compress, and then robust processing is performed by trying different compression formats or performing various operations such as repairing a file header of the compressed package.
Therefore, when the target test scenario is a compression anomaly test scenario, the step "execute the test logic on the product under the test logic point when the test logic point is detected" includes:
obtaining an upgrade file of a product;
performing compression exception processing on the upgrade file to obtain an exception compression file;
and when the test logic point is detected, upgrading the product based on the abnormal compression file.
In an embodiment, the compression exception test scenario may include various forms of compression problems such as an incorrect header format compression packet, an incomplete compression packet, a non-supported compression format, and compression encryption. Therefore, the upgrade file of the product can be obtained, and the compression exception processing is carried out on the upgrade file to obtain the exception compression file. For example, the server may package the upgrade file into upgrade packages of multiple compression formats (zip/rar/7z, etc.), set a random password/error password/null password at the time of compression, delete a part of bytes of the compressed package file after the compressed package is generated so that the compressed package is incomplete, generate a split compressed package through split compression, and so on.
In an embodiment, after obtaining the abnormal compression file, when the test logic point is detected, the server may perform an upgrade process on the product based on the abnormal compression file.
In an embodiment, when a product is upgraded, the original files are replaced and updated by the files in the upgrade package, and relevant services and processes are run by using the new versions of the files. However, a plurality of files are generally placed in the upgrade package, the plurality of files have mutual dependency relationship, and if a certain file in the upgrade package is missing, a certain service/process is dependent on a problem and cannot operate. Therefore, when a product is upgraded, a file list, file contents, dependency relationship check, core file check and the like are often checked, so that the influence caused by a scenario that a certain robustness test is performed on the product based on the scenario that a file is missing is required to avoid.
Specifically, when the test scenario is a file exception test scenario, the step "execute the test logic under the test logic point for the product when the test logic point is detected" includes:
obtaining an upgrade file of a product;
performing file exception processing on the upgrade file to obtain an exception upgrade file;
and when the test logic point is detected, upgrading the product based on the abnormal upgrading file.
In an embodiment, the server may obtain an upgrade file of a product, and then perform file exception handling on the upgrade file to obtain an exception upgrade file.
For example, the server may pack a part of the files less than before generating the compressed package, or the contents of the packed files are missing, the contents of the files are tampered, and the like.
Next, when the test logical point is detected, the server may perform an upgrade process on the product based on the abnormal upgrade file.
In an embodiment, after the server performs a test process on the product based on the target test scenario, an upgrade test report of the product may be generated. Specifically, the step of generating an upgrade test report of the product includes:
when the product is tested and processed under the upgrading path, monitoring the testing process to obtain upgrading testing information;
and generating an upgrade test report based on the upgrade test information.
The upgrade test information may include various test results fed back by the product during the upgrade test of the product. For example, the upgrade test information may include phase identification information, version information, function verification information, and memory information, among others.
Wherein the stage identification information may include the stage that the product undergoes during the upgrade process. For example, the stage identification information may include which stages the product has passed through during the upgrade process, and so on. Whether the product is successfully upgraded or not can be judged through the stage identification information, and if the product is not successfully upgraded, the upgrading is failed in which stage, and the like.
The version information comprises the version of the product before the upgrade test and the version of the product after the upgrade test. For example, the version of the product before the upgrade test is a, and the version of the product after the upgrade test is B, which is the same as the effect of the normal upgrade, indicating that the product upgrade is successful.
The function verification information comprises a result of verifying the functions of the product in the upgrading process.
In one embodiment, the upgrade of the product is successful and not only is the version number changed, but the most essential is some function change of the product. Therefore, the server checks whether the upgraded function can be normally used or not through some preset automatic test cases, and can also be used as one of judgment bases for successful upgrade.
In one embodiment, there are multiple ways to detect the testing process, and thus obtain the upgraded testing information. For example, a performance monitoring tool such as perfdog may be used to detect a product, thereby obtaining upgrade test information. For another example, the memory information of the product can be checked by using a free command to obtain the upgrade test information of the product. For another example, a log of the product may be obtained using an adb command or the like. Generally, the log of the product records the version, the resource and other conditions of the product, so that the upgrade test information can be obtained by acquiring the log of the product. For another example, the product log may also be viewed through kibana, so as to obtain the upgrade test information of the product.
In an embodiment, when the upgrade test information includes stage identification information, version information, and function verification information, the step "monitoring the test process to obtain the upgrade test information when performing test processing on the product under the upgrade path" includes:
stage identifier discrimination processing is carried out on the upgrading path, and stage identification information is generated according to a discrimination result;
performing version identification processing on the product to obtain version information;
and performing function verification processing on the product to obtain function verification information.
In an embodiment, in a normal upgrade scenario, the server may obtain phase identifiers of the phases, which indicate that the upgrade process has undergone the phases and processing results of the phases.
For example, the phase designators may include step-uncompress: begin and step-uncompress: success, and so on. Step-uncompress, begin, may indicate that the product entered the decompression phase. step-uncompress: success can indicate that the product entered the stage of successful decompression.
After the target test scenario carries out upgrade test on the product, whether the product has step-uncompress, begin, and step-uncompress, success stage identifiers can be judged.
By determining whether a stage identifier exists in this manner, if the robustness of upgrading a product is not sufficiently robust, the absence of a particular identifier may result. For example, absence of step-uncompress, begin, indicates that the decompression phase was not entered, or absence of step-uncompress, success, indicates that decompression was not successful.
In one embodiment, the version information may be obtained by looking up a log of the product and identifying the version in the log of the product. For example, by looking at a log of products, it is known that the products have changed from version A to version B.
In an embodiment, there may be multiple ways to perform function verification processing on a product to obtain function verification information. For example, the server may trigger a product function based on the automated testing framework, thereby determining whether the product function can be executed normally and obtaining function verification information.
In an embodiment, after obtaining the upgrade test information, an upgrade test report may be generated based on the upgrade test information. For example, after the server obtains the stage identification information, the version information, and the function verification information, the stage identification information, the version information, and the function verification information may be analyzed, and a test report may be generated according to a result of the analysis.
In an embodiment, to more clearly illustrate the method provided in the embodiment of the present application, the upgrade test method provided in the embodiment of the present application may be further shown in fig. 5:
301. and acquiring an upgrade path list.
For example, there are 5 upgrade paths on the upgrade path manifest. Then, one of the 5 upgrade paths can be randomly selected to perform upgrade testing on the product.
302. And judging whether the upgrade path completes the robustness test.
And judging whether the product completes the upgrade test (equivalent to a robustness test) under the selected upgrade path. If the product under the upgrade path has finished the upgrade test, then any one upgrade path can be selected from the rest upgrade paths to perform the upgrade test on the product. If the product has not yet executed the upgrade test in the upgrade path, step 303 is executed.
303. The steps/stages to be tested are obtained.
For example, an upgrade stage (equivalent to a test logic point) and a test step of a product may be obtained. Then, based on the test logic point, the upgrade process of the product in the upgrade path is detected. When a test logic point is detected, test logic may be executed on the product under the test logic point.
304. And judging whether all robustness scenes are tested or not.
When the product is subjected to the upgrade test based on the test scenario (equivalent to the robustness scenario), it may be determined whether the product is subjected to the upgrade test based on all the test scenarios.
If all the test scenes are tested, the next stage can be performed. For example, when all test scenarios are tested and the product is in the verification phase, the product may enter the backup phase from the verification phase, and so on.
If the test scenes are not tested, the untested test scenes can be obtained.
305. A robust scene is acquired.
306. And inserting a robustness scene in the normal upgrading process.
In the process of upgrading test, a test scene can be inserted, so that the product can be upgraded and tested based on the test scene. For example, as shown in FIG. 4, a test scenario may be obtained from a scenario library and inserted in an upgrade test.
307. And cross-comparing the normal upgrading result with the test result in the robustness scene.
For example, as shown in fig. 4, the test results under the normal upgrade condition and the test scenario may be compared through different dimensions such as version verification and resource consumption.
308. And generating a robustness test report.
The method and the device can receive the upgrading test triggering instruction of the product; identifying an upgrading path of the product according to an upgrading trigger instruction; determining a target test scene of a product under an upgrading path; and testing the product under the upgrading path based on the target test scene, and generating an upgrading test report of the product. By the upgrade testing method provided by the embodiment of the application, the product can be tested under different upgrade paths in different test scenes, and the robustness of the upgrade test on the product is improved.
In order to better implement the upgrade testing method provided by the embodiment of the present application, in an embodiment, an upgrade testing apparatus is further provided, and the upgrade testing apparatus may be integrated in an electronic device. The meanings of the terms are the same as those in the above upgrading test method, and specific implementation details can refer to the description in the method embodiment.
In an embodiment, an upgrade test apparatus is provided, which may be specifically integrated in an electronic device, as shown in fig. 6, and includes: the receiving unit 401, the identifying unit 402, the determining unit 403 and the test processing unit 404 are specifically as follows:
a receiving unit 401, configured to receive an upgrade test trigger instruction of a product;
an identifying unit 402, configured to identify an upgrade path of the product according to the upgrade trigger instruction;
a determining unit 403, configured to determine a target test scenario of the product under the test path;
a test processing unit 404, configured to perform test processing on the product in the upgrade path based on the target test scenario, and generate an upgrade test report of the product.
In one embodiment, the test processing unit 404 includes:
the first acquisition subunit is used for acquiring the test logic and the test logic points of the test scene;
the detection subunit is used for detecting the upgrading process of the product in the upgrading path based on the test logic point;
and the execution subunit is used for executing the test logic on the product under the test logic point when the test logic point is detected.
In one embodiment, the execution subunit includes:
the sending module is used for sending a network abnormity triggering instruction to the network control platform when the test logic point is detected;
the receiving module is used for receiving a network abnormity triggering success instruction returned by the network control platform;
and the first upgrading processing module is used for upgrading the product based on the network abnormity triggering success instruction.
In one embodiment, the execution subunit includes:
the first acquisition module is used for acquiring the upgrade file of the product;
the compression exception handling module is used for carrying out compression exception handling on the upgrade file to obtain an exception compression file;
and the second upgrading processing module is used for upgrading the product based on the abnormal compression file when the test logic point is detected.
In one embodiment, the execution subunit includes:
the second acquisition module is used for acquiring the upgrade file of the product;
the file exception handling module is used for carrying out file exception handling on the upgrade file to obtain an exception upgrade file;
and the third upgrading processing module is used for upgrading the product based on the abnormal upgrading file when the test logic point is detected.
In an embodiment, the test processing unit 404 further includes:
the monitoring subunit is used for monitoring the testing process to obtain upgrading testing information when the product is tested and processed under the upgrading path;
and the generation subunit is used for generating the upgrade test report based on the upgrade test information.
In one embodiment, the monitoring subunit includes:
the stage identifier distinguishing processing module is used for distinguishing the stage identifier of the upgrading path and generating the stage identification information according to the distinguishing result;
the version identification processing module is used for carrying out version identification processing on the product to obtain the version information;
and the function verification processing module is used for performing function verification processing on the product to obtain the function verification information.
In an embodiment, the identifying unit 402 includes:
the second obtaining subunit is configured to obtain an upgrade path list according to the upgrade trigger instruction, where the upgrade path list includes at least one preset upgrade path;
the analysis subunit is used for analyzing the upgrade trigger instruction to obtain upgrade setting information and product attribute information;
and the determining subunit is configured to determine, based on the upgrade setting information and the product attribute information, an upgrade path of the product in the at least one preset upgrade path.
In an embodiment, the identifying unit 402 further comprises:
the test detection subunit is used for carrying out test detection on the upgrade path list to obtain a test detection result;
the updating subunit is used for updating the upgrading path when the test detection result does not meet the preset detection condition, so as to obtain an updated upgrading path;
and the test processing subunit is used for carrying out test processing on the product under the updated upgrade path based on the target test scene.
In an embodiment, the determining unit 403 includes:
the judging subunit is used for judging whether to test the product under the upgrading path based on each test scene;
and the screening subunit is used for screening out the target test scene from at least one untested test scene when at least one untested test scene exists.
In a specific implementation, the above units may be implemented as independent entities, or may be combined arbitrarily to be implemented as the same or several entities, and the specific implementation of the above units may refer to the foregoing method embodiments, which are not described herein again.
The upgrading test device can improve the robustness of upgrading test on products.
The embodiment of the application also provides an electronic device, which can comprise a terminal or a server; for example, the electronic device may be a server, such as an upgrade test server. As shown in fig. 7, it shows a schematic structural diagram of a terminal according to an embodiment of the present application, specifically:
the electronic device may include components such as a processor 501 of one or more processing cores, memory 502 of one or more computer-readable storage media, a power supply 503, and an input unit 504. Those skilled in the art will appreciate that the electronic device configuration shown in fig. 7 does not constitute a limitation of the electronic device and may include more or fewer components than shown, or some components may be combined, or a different arrangement of components. Wherein:
the processor 501 is a control center of the electronic device, connects various parts of the whole electronic device by using various interfaces and lines, and performs various functions of the electronic device and processes data by running or executing software programs and/or modules stored in the memory 502 and calling data stored in the memory 502, thereby performing overall monitoring of the electronic device. Optionally, processor 501 may include one or more processing cores; preferably, the processor 501 may integrate an application processor and a modem processor, wherein the application processor mainly handles operating systems, user pages, application programs, and the like, and the modem processor mainly handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 501.
The memory 502 may be used to store software programs and modules, and the processor 501 executes various functional applications and data processing by operating the software programs and modules stored in the memory 502. The memory 502 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application program required by at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may store data created according to use of the computer device, and the like. Further, the memory 502 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. Accordingly, the memory 502 may also include a memory controller to provide the processor 501 with access to the memory 502.
The electronic device further comprises a power supply 503 for supplying power to each component, and preferably, the power supply 503 may be logically connected to the processor 501 through a power management system, so that functions of managing charging, discharging, power consumption, and the like are realized through the power management system. The power supply 503 may also include any component of one or more dc or ac power sources, recharging systems, power failure detection circuitry, power converters or inverters, power status indicators, and the like.
The electronic device may also include an input unit 504, where the input unit 504 may be used to receive input numeric or character information and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function control.
Although not shown, the electronic device may further include a display unit and the like, which are not described in detail herein. Specifically, in this embodiment, the processor 501 in the electronic device loads the executable file corresponding to the process of one or more application programs into the memory 502 according to the following instructions, and the processor 501 runs the application program stored in the memory 502, so as to implement various functions as follows:
receiving an upgrading test trigger instruction of a product;
identifying an upgrading path of the product according to the upgrading triggering instruction;
determining a target test scene of the product under the upgrading path;
and testing the product under the upgrading path based on the target test scene, and generating an upgrading test report of the product.
The above operations can be implemented in the foregoing embodiments, and are not described in detail herein.
According to an aspect of the application, there is provided a computer program application or computer program comprising computer instructions stored in a computer readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions to cause the computer device to perform the method provided in the various alternative implementations of the above embodiments.
It will be understood by those skilled in the art that all or part of the steps of the methods of the above embodiments may be performed by a computer program, which may be stored in a computer-readable storage medium and loaded and executed by a processor, or by related hardware controlled by the computer program.
To this end, embodiments of the present application further provide a storage medium, in which a computer program is stored, where the computer program can be loaded by a processor to execute the steps in any one of the upgrade test methods provided in the embodiments of the present application. For example, the computer program may perform the steps of:
receiving an upgrading test trigger instruction of a product;
identifying an upgrading path of the product according to the upgrading triggering instruction;
determining a target test scene of the product under the upgrading path;
and testing the product under the upgrading path based on the target test scene, and generating an upgrading test report of the product.
The above operations can be implemented in the foregoing embodiments, and are not described in detail herein.
Since the computer program stored in the storage medium can execute the steps in any of the upgrade test methods provided in the embodiments of the present application, the beneficial effects that can be achieved by any of the upgrade test methods provided in the embodiments of the present application can be achieved, which are detailed in the foregoing embodiments and will not be described herein again.
The upgrade test method, apparatus, electronic device and storage medium provided in the embodiments of the present application are described in detail above, and a specific example is applied in the present application to explain the principle and implementation manner of the present application, and the description of the above embodiments is only used to help understanding the method and core ideas of the present application; meanwhile, for those 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 (13)

1. An upgrade test method, comprising:
receiving an upgrading test trigger instruction of a product;
identifying an upgrading path of the product according to the upgrading triggering instruction;
determining a target test scene of the product under the upgrading path;
and testing the product under the upgrading path based on the target test scene, and generating an upgrading test report of the product.
2. The method of claim 1, wherein the performing a test process on the product under the upgrade path based on the target test scenario comprises:
acquiring a test logic and a test logic point of the test scene;
detecting the upgrading process of the product in the upgrading path based on the test logic point;
when the test logic point is detected, executing the test logic under the test logic point on the product.
3. The method of claim 2, wherein the target test scenario comprises a network anomaly test scenario; when the test logic point is detected, executing the test logic on the product under the test logic point, including:
when the test logic point is detected, sending a network abnormity triggering instruction to a network control platform;
receiving a network abnormity triggering success instruction returned by the network control platform;
and upgrading the product based on the network abnormity trigger success instruction.
4. The method of claim 2, wherein the target test scenario comprises a compression anomaly test scenario; when the test logic point is detected, executing the test logic on the product under the test logic point, including:
obtaining an upgrade file of the product;
performing compression exception processing on the upgrade file to obtain an exception compression file;
and when the test logic point is detected, upgrading the product based on the abnormal compression file.
5. The method of claim 2, wherein the target test scenario comprises a file exception test scenario; when the test logic point is detected, executing the test logic on the product under the test logic point, including:
obtaining an upgrade file of the product;
performing file exception processing on the upgrade file to obtain an exception upgrade file;
and when the test logic point is detected, upgrading the product based on the abnormal upgrading file.
6. The method of claim 1, wherein the generating an upgrade test report for the product comprises:
when the product is tested and processed under the upgrading path, monitoring the testing process to obtain upgrading testing information;
and generating the upgrade test report based on the upgrade test information.
7. The method of claim 6, wherein the upgrade test information includes phase identification information, version information, and function verification information; when the product is tested and processed under the upgrading path, the testing process is monitored to obtain upgrading testing information, and the method comprises the following steps:
stage identifier distinguishing processing is carried out on the upgrading path, and the stage identification information is generated according to a distinguishing result;
carrying out version identification processing on the product to obtain the version information;
and performing function verification processing on the product to obtain the function verification information.
8. The method of claim 1, wherein identifying an upgrade path for the product based on the upgrade trigger instructions comprises:
acquiring an upgrade path list according to the upgrade trigger instruction, wherein the upgrade path list comprises at least one preset upgrade path;
analyzing the upgrading trigger instruction to obtain upgrading setting information and product attribute information;
determining an upgrade path of the product in the at least one preset upgrade path based on the upgrade setting information and the product attribute information.
9. The method of claim 8, wherein after the testing the product under the upgrade path based on the target test scenario, further comprising:
testing and detecting the upgrade path list to obtain a test and detection result;
when the test detection result does not accord with the preset detection condition, updating the upgrade path to obtain an updated upgrade path;
and testing the product under the updated upgrade path based on the target test scene.
10. The method of claim 1, wherein said determining a target test scenario for the product under the test path comprises:
judging whether the product is subjected to test processing under the upgrading path based on each test scene;
when at least one untested test scene exists, screening the target test scene from the at least one untested test scene.
11. An upgrade test apparatus, comprising:
the receiving unit is used for receiving an upgrading test triggering instruction of a product;
the identification unit is used for identifying the upgrading path of the product according to the upgrading trigger instruction;
the determining unit is used for determining a target test scene of the product under the test path;
and the test processing unit is used for carrying out test processing on the product under the upgrading path based on the target test scene and generating an upgrading test report of the product.
12. An electronic device comprising a memory and a processor; the memory stores a computer program, and the processor is configured to execute the computer program in the memory to perform the upgrade test method according to any one of claims 1 to 10.
13. A storage medium storing a plurality of computer programs adapted to be loaded by a processor to perform the upgrade test method according to any one of claims 1 to 10.
CN202111143162.7A 2021-09-28 2021-09-28 Upgrade test method and device, electronic equipment and storage medium Pending CN113836026A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111143162.7A CN113836026A (en) 2021-09-28 2021-09-28 Upgrade test method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111143162.7A CN113836026A (en) 2021-09-28 2021-09-28 Upgrade test method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN113836026A true CN113836026A (en) 2021-12-24

Family

ID=78966915

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111143162.7A Pending CN113836026A (en) 2021-09-28 2021-09-28 Upgrade test method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113836026A (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101625658A (en) * 2009-08-04 2010-01-13 卓望信息技术(北京)有限公司西城分公司 Method for testing software system performance
CN107590064A (en) * 2016-07-08 2018-01-16 北京奇虎科技有限公司 A kind of application upgrade method of testing, device and system
CN110119348A (en) * 2018-02-06 2019-08-13 福建天泉教育科技有限公司 A kind of method and terminal of software upgrading test
CN112291621A (en) * 2020-10-29 2021-01-29 深圳创维-Rgb电子有限公司 System upgrading automation test method, device and test equipment
CN112286779A (en) * 2019-07-23 2021-01-29 腾讯科技(深圳)有限公司 Test task processing method and device, storage medium and computer equipment

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101625658A (en) * 2009-08-04 2010-01-13 卓望信息技术(北京)有限公司西城分公司 Method for testing software system performance
CN107590064A (en) * 2016-07-08 2018-01-16 北京奇虎科技有限公司 A kind of application upgrade method of testing, device and system
CN110119348A (en) * 2018-02-06 2019-08-13 福建天泉教育科技有限公司 A kind of method and terminal of software upgrading test
CN112286779A (en) * 2019-07-23 2021-01-29 腾讯科技(深圳)有限公司 Test task processing method and device, storage medium and computer equipment
CN112291621A (en) * 2020-10-29 2021-01-29 深圳创维-Rgb电子有限公司 System upgrading automation test method, device and test equipment

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
范勇等: "软件测试技术 第2版", 30 November 2009, 西安电子科学大学出版社, pages: 198 - 199 *

Similar Documents

Publication Publication Date Title
US7165191B1 (en) Automated verification of user interface tests on low-end emulators and devices
CN102736978B (en) A kind of method and device detecting the installment state of application program
CN112988485B (en) Simulation test method and device for electric power Internet of things equipment
CN105512044B (en) Update method and system for the library of object of keyword driving test
CN105653329A (en) Application management method, apparatus and system
CN110013672B (en) Method, device, apparatus and computer-readable storage medium for automated testing of machine-run games
CN104598380A (en) Method and system for automatic testing based on control
CN107302476B (en) Automatic testing method and system for testing asynchronous interactive system
CN112241360A (en) Test case generation method, device, equipment and storage medium
CN112860645A (en) Processing method and device for offline compressed file, computer equipment and medium
CN111651352B (en) Warehouse code merging method and device
CN107632901A (en) A kind of self-repair method and device of application program operation exception
CN106407054B (en) BMC automatic test system and method
CN112732587A (en) Method and device for acquiring automatic test log, electronic equipment and storage medium
KR20180060569A (en) Apparatus and method for test and evaluation of security patch for distribution automation system
CN115658496A (en) Extensible Web automatic test method, system, equipment and storage medium
CN115576600A (en) Code change-based difference processing method and device, terminal and storage medium
CN110045969B (en) Application program installation method, server, system, device and storage medium
CN111324365A (en) Method and equipment for upgrading super-converged system
CN114172978A (en) Multi-protocol equipment access method and related device
CN107203471B (en) Joint debugging method, service platform and computer storage medium
CN113595832A (en) Network data acquisition system and method
CN111538542B (en) System configuration method and related device
CN115129574A (en) Code testing method and device
CN110362416A (en) Page assembly loading method and device, electronic equipment, storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination