CN112988585B - PaaS platform testing method, paaS platform testing device, paaS platform testing equipment and PaaS platform testing medium - Google Patents
PaaS platform testing method, paaS platform testing device, paaS platform testing equipment and PaaS platform testing medium Download PDFInfo
- Publication number
- CN112988585B CN112988585B CN202110308756.2A CN202110308756A CN112988585B CN 112988585 B CN112988585 B CN 112988585B CN 202110308756 A CN202110308756 A CN 202110308756A CN 112988585 B CN112988585 B CN 112988585B
- Authority
- CN
- China
- Prior art keywords
- paas
- result
- paas platform
- test
- page
- 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.)
- Active
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Prevention of errors by analysis, debugging or testing of software
- G06F11/3668—Testing of software
- G06F11/3672—Test management
- G06F11/3684—Test management for test design, e.g. generating new test cases
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Prevention of errors by analysis, debugging or testing of software
- G06F11/3668—Testing of software
- G06F11/3672—Test management
- G06F11/3688—Test management for test execution, e.g. scheduling of test suites
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)
- Test And Diagnosis Of Digital Computers (AREA)
Abstract
The application discloses a PaaS platform test method, a PaaS platform test device, paaS platform test equipment and PaaS platform test media, wherein the PaaS platform test method comprises the following steps: performing element positioning on a control console UI page of a PaaS platform by using a PaaS control terminal test case, executing a keyword drive corresponding to a positioned first target element, and determining a test result of the control console UI page based on a first execution result of the keyword drive; the PaaS control end test case is a test case which is pre-packaged with a keyword driver corresponding to the first target element; and calling a target interface encapsulated in the application demo by using the PaaS access test case, calling a function corresponding to the target interface in the PaaS platform by using the target interface to obtain a function calling result, and determining an access test result of the PaaS platform corresponding to the target interface based on the function calling result. Therefore, the labor cost of PaaS platform test can be reduced, and the test efficiency is improved.
Description
Technical Field
The application relates to the technical field of testing, in particular to a PaaS platform testing method, a PaaS platform testing device, paaS platform testing equipment and PaaS platform testing media.
Background
The PaaS (Platform AS A SERVICE, platform serving) Platform is suitable for micro-service architecture application of high concurrency scene, and consists of a whole set of tools and services, and comprises distributed message middleware, a distributed micro-service framework, distributed cache, distributed service management and monitoring, distributed task scheduling, a unified configuration center and the like. The current testing method for the PaaS platform mainly adopts a manual black box testing technology, which comprises equivalence classes, boundary values, causal graphs and the like, so that on one hand, the manual black box testing has higher labor cost and on the other hand, the testing efficiency is lower. In summary, in the process of implementing the invention, the inventor finds that at least the problems of higher labor cost and lower test efficiency of the PaaS platform test exist in the prior art.
Disclosure of Invention
Accordingly, the application aims to provide a PaaS platform testing method, a PaaS platform testing device, paaS platform testing equipment and PaaS platform testing media, which can reduce the labor cost of PaaS platform testing and improve the testing efficiency. The specific scheme is as follows:
in a first aspect, the application discloses a PaaS platform testing method, which comprises the following steps:
performing element positioning on a control console UI page of a PaaS platform by using a PaaS control terminal test case, executing a keyword drive corresponding to a positioned first target element, and determining a test result of the control console UI page based on a first execution result of the keyword drive; the PaaS control end test case is a test case which is pre-packaged with a keyword driver corresponding to the first target element;
And calling a target interface encapsulated in the application demo by using the PaaS access test case, calling a function corresponding to the target interface in the PaaS platform by using the target interface to obtain a function calling result, and determining an access test result of the PaaS platform corresponding to the target interface based on the function calling result.
Optionally, the performing element positioning on the control console UI page of the PaaS platform by using the PaaS management and control terminal test case, and executing the keyword driving corresponding to the positioned first target element, includes:
And performing element positioning on a control console UI page of the PaaS platform by using the PaaS control terminal test case and based on PageObject model, and executing the keyword driving corresponding to the positioned first target element.
Optionally, the determining the test result of the console UI page based on the first execution result of the keyword driver includes:
adding the first execution result driven by the keyword to a preset database, and comparing a first expected result with the first execution result in the preset database to obtain a test result of the control console UI page;
And/or displaying the first execution result driven by the keyword in the console UI page, and comparing the first expected result with the first execution result displayed in the console UI page to obtain a test result of the console UI page.
Optionally, the calling, by using the target interface, a function corresponding to the target interface in the PaaS platform includes:
Determining a target protocol template from the PaaS access test case based on a communication protocol required by the target interface to call a function corresponding to the target interface in the PaaS platform; the PaaS access test case is pre-packaged with an HTTP protocol template or a socket protocol template;
and calling a function corresponding to the target interface in the PaaS platform by using the target interface based on the target protocol template.
Optionally, the determining, based on the function call result, a PaaS platform access test result corresponding to the target interface includes:
Adding the function calling result to a preset database, and comparing a second expected result with the function calling result in the preset database to obtain a PaaS platform access test result corresponding to the target interface;
And/or displaying the function calling result in the control console UI page, and comparing the second expected result with the function calling result displayed in the control console UI page to obtain a PaaS platform access test result corresponding to the target interface.
Optionally, the determining, based on the function call result, a PaaS platform access test result corresponding to the target interface includes:
performing element positioning on the control console UI page by using the PaaS access test case, and executing keyword driving corresponding to the positioned second target element;
and determining a PaaS platform access test result corresponding to the target interface based on the function calling result and a second execution result driven by the keyword corresponding to the second target element.
Optionally, the method further comprises:
And acquiring a test case priority, and calling the PaaS control terminal test case and the PaaS access test case based on the test case priority.
In a second aspect, the application discloses a PaaS platform testing device, comprising:
The PaaS platform UI page test module is used for carrying out element positioning on a control console UI page of the PaaS platform by utilizing a PaaS management and control end test case, executing keyword driving corresponding to a positioned first target element, and determining a test result of the control console UI page based on a first execution result of the keyword driving; the PaaS control end test case is a test case which is pre-packaged with a keyword driver corresponding to the first target element;
The PaaS platform access test module is used for calling a target interface encapsulated in the application demo by using the PaaS access test case, calling a function corresponding to the target interface in the PaaS platform by using the target interface to obtain a function calling result, and determining the PaaS platform access test result corresponding to the target interface based on the function calling result.
In a third aspect, the present application discloses an electronic device, comprising:
A memory for storing a computer program;
And the processor is used for executing the computer program to realize the PaaS platform testing method.
In a fourth aspect, the present application discloses a computer readable storage medium for storing a computer program, which when executed by a processor implements the PaaS platform test method described above.
Therefore, the PaaS control terminal test case is utilized to perform element positioning on the control console UI page of the PaaS platform, the keyword driving corresponding to the positioned first target element is executed, and the test result of the control console UI page is determined based on the first execution result of the keyword driving; the PaaS control end test case is a test case which is pre-packaged with a keyword driver corresponding to the first target element; and calling a target interface encapsulated in the application demo by using the PaaS access test case, calling a function corresponding to the target interface in the PaaS platform by using the target interface to obtain a function calling result, and determining an access test result of the PaaS platform corresponding to the target interface based on the function calling result. Therefore, the PaaS control end test case is driven by the packaging keywords, the control console UI page of the PaaS platform is tested, the target interface is packaged in the application demo, the PaaS access test case is utilized to carry out the PaaS platform access test result, the manual coding is avoided to carry out the test, the automatic test of the PaaS platform is realized, the test labor cost of the PaaS platform can be reduced, and the test efficiency is improved.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings that are required to be used in the embodiments or the description of the prior art will be briefly described below, and it is obvious that the drawings in the following description are only embodiments of the present application, and that other drawings can be obtained according to the provided drawings without inventive effort for a person skilled in the art.
FIG. 1 is a schematic diagram of a system framework to which the PaaS platform test scheme disclosed herein is applicable;
fig. 2 is a schematic diagram of a PaaS platform test service layered structure disclosed in the present application;
FIG. 3 is a flow chart of a PaaS platform test method disclosed by the application;
FIG. 4 is a flowchart of a specific PaaS platform test method disclosed in the present application;
Fig. 5 is a schematic structural diagram of a PaaS platform testing device disclosed in the present application;
Fig. 6 is a block diagram of an electronic device according to the present disclosure.
Detailed Description
The following description of the embodiments of the present application will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present application, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
The current testing method for PaaS platform is mainly manual black box testing technology, including equivalence class, boundary value, causal graph, etc., thus, on one hand, the manual black box test requires high labor cost, and on the other hand, the test efficiency is low. In summary, in the process of implementing the application, the inventor finds that at least the problems of higher labor cost and lower test efficiency of the PaaS platform test exist in the prior art. Therefore, the PaaS platform testing scheme provided by the application can reduce the labor cost of the PaaS platform testing and improve the testing efficiency.
In the PaaS platform test scheme of the application, the adopted system framework can be specifically shown in fig. 1, and can specifically comprise a plurality of web ends and a plurality of clients, wherein a distributed test mode of the web-clients is adopted, the clients communicate with each other through Netty (a java open source framework for providing asynchronous and event-driven network application program frameworks and tools for rapidly developing high-performance and high-reliability network servers and Client programs), the test plans are distributed to different web ends and clients through load balancing, the web ends are used for configuring test tasks based on the acquired test plans, the test plans comprise a thread number for executing the test cases and an execution Client, the Client is used for executing the test cases corresponding to the test tasks, the thread number for executing the test cases can also be specified, and the test cases are executed in a command line mode. And, the web side can trigger test tasks at regular time so that the client side executes the test cases.
The method specifically executed by the client comprises the following steps: performing element positioning on a control console UI page of a PaaS platform by using a PaaS control terminal test case, executing a keyword drive corresponding to a positioned first target element, and determining a test result of the control console UI page based on a first execution result of the keyword drive; the PaaS control end test case is a test case which is pre-packaged with a keyword driver corresponding to the first target element; and calling a target interface encapsulated in the application demo by using the PaaS access test case, calling a function corresponding to the target interface in the PaaS platform by using the target interface to obtain a function calling result, and determining an access test result of the PaaS platform corresponding to the target interface based on the function calling result.
In addition, the Web end can inquire the test progress of the test task, the client records the test process logs through log4j and the database, and the logs recorded in the 2 modes can be checked in real time through the Web end to locate the problem. And the web end can analyze the test result based on the test log and display the analysis result through multiple charts.
In addition, basic information management display and test case management can be carried out through the web end, online debugging of test cases is supported, the test cases are directly debugged through the test case management interface, and the complexity caused by using a development tool for debugging is avoided. In the application, the Web end can support single-step debugging and task scheduling. Typically, the test tasks are performed at regular time by the cron expression after the debugging is passed. After the execution of the test plan is completed, a test report is automatically generated and sent to a designated tester through mail, and all use case execution details in the test plan can be checked. And the web side can check all test cases and test task execution conditions through a dashboard, and data statistics is carried out according to project dimensions.
In addition, when the PaaS platform is tested, the shell can be remotely executed through the web end to restart the tomcat, and the projects in the Jenkins are constructed.
Further, the PaaS platform test service can be constructed based on the PaaS platform test scheme of the application, and deployed on the web side and the client side, as shown in fig. 2, fig. 2 is a schematic diagram of a layered structure of the PaaS platform test service based on the application. The uppermost layer of the PaaS platform test service is an application layer, a Jenkins continuous integration tool is adopted for management, an API interface is packaged for calling, and a crontab+shell script is adopted for timing monitoring; the case layer manages the test case through java codes and testng, carries out logic verification and abnormal scene verification and sensitive word judgment on the test case parameters, and realizes multi-interface call; the configuration layer is used for managing configuration files, hots and personalized requirements; the public function is used for extracting common public modules, such as date acquisition, attribute acquisition, crawling function, data reading, database operation, email short message WeChat monitoring and the like; the data management layer is mainly used for dynamically acquiring the online log, constructing basic use case data and constructing special scene data; the bottom layer is the running environment, supporting mainly the mainstream operating system Linux, windows and the container Docker.
Aiming at the deployment of the PaaS platform test service on the Web end, a Springboot framework is adopted, a Mysql library is used for a database, the project is constructed and compiled through MAVEN INSTALL, and a jar package is started. And (3) deploying the client, automatically constructing and generating a target directory, and starting the service through the bat or shell script. After deployment, the PaaS platform test service can be subjected to system-level management through the Web terminal, and basic data of a system level, including basic data of users, roles, departments, projects, clients, parameters, logs and the like, is mainly maintained.
Referring to fig. 3, the embodiment of the application discloses a PaaS platform testing method, which comprises the following steps:
Step S11: performing element positioning on a control console UI page of a PaaS platform by using a PaaS control terminal test case, executing a keyword drive corresponding to a positioned first target element, and determining a test result of the control console UI page based on a first execution result of the keyword drive; the PaaS control end test case is a test case which is pre-packaged with a keyword driver corresponding to the first target element.
The console UI page may include a web-side console UI page and a mobile-side console UI page, among others. That is, the embodiment of the application can realize the UI page automation test of the web end and the mobile end of the PaaS platform.
And, the keyword driver corresponding to the web terminal console UI page can be packaged by WebDriver3.0, and the keyword driver corresponding to the mobile terminal console UI page can be packaged by Appium. And written in Java and Python.
In a specific embodiment, the PaaS management and control end test case can be utilized to perform element positioning on a console UI page of the PaaS platform based on PageObject model, and keyword driving corresponding to the positioned first target element is executed.
Thus, unified management of each console UI page can be achieved through the PageObject model.
The embodiment can perform element positioning on the control console UI page of the PaaS platform based on the keywords in the keyword driving.
In a specific embodiment, the first execution result driven by the keyword may be added to a preset database, and a first expected result is compared with the first execution result in the preset database to obtain a test result of the console UI page. And if the first expected result corresponding to any keyword driver is consistent with the first execution result in the preset database, the target element corresponding to the keyword driver passes the test, otherwise, the target element does not pass the test.
In another specific embodiment, the first execution result of the keyword driver may be displayed in the console UI page, and the first expected result may be compared with the first execution result displayed in the console UI page, so as to obtain a test result of the console UI page. And if the first expected result is consistent with the first execution result displayed on the UI page of the control console, the test is passed, otherwise, the test is not passed.
Specifically, the first expected result can be used for assertion, comparing the first expected result with the first execution result in the preset database, and comparing the first expected result with the first execution result displayed on the console UI page.
Of course, in a specific embodiment, the first expected result may be compared with the first execution result in the preset database, and the first expected result is compared with the first execution result displayed on the console UI page, and if the comparison results of the two ways are consistent, the test is passed, so as to implement double verification on the execution result.
Step S12: and calling a target interface encapsulated in the application demo by using the PaaS access test case, calling a function corresponding to the target interface in the PaaS platform by using the target interface to obtain a function calling result, and determining an access test result of the PaaS platform corresponding to the target interface based on the function calling result.
In a specific embodiment, a target protocol template may be determined from the PaaS access test case based on a communication protocol required by the target interface to invoke a function corresponding to the target interface in the PaaS platform; the PaaS access test case is pre-packaged with an HTTP protocol template or a socket protocol template; and calling a function corresponding to the target interface in the PaaS platform by using the target interface based on the target protocol template.
It should be noted that, in an actual application scenario, a service application needs to access the PaaS platform through some interfaces, in this embodiment, an application demo is written, and a target interface is encapsulated in the application demo, so that the PaaS platform is accessed through the target interface, and an access test of the PaaS platform is implemented.
In addition, because communication protocols required by different target interfaces for calling functions corresponding to the target interfaces in the PaaS platform may be different, the embodiment of the application can package an HTTP protocol template or a socket protocol template in the PaaS access test case in advance, and realize the calling of the target interfaces to the corresponding functions in the PaaS platform.
In a specific embodiment, the function calling result may be added to a preset database, and a second desired result is compared with the function calling result in the preset database, so as to obtain a PaaS platform access test result corresponding to the target interface;
In another specific embodiment, the function call result may be displayed in the console UI page, and the second desired result may be compared with the function call result displayed in the console UI page, so as to obtain a PaaS platform access test result corresponding to the target interface.
Specifically, the second expected result can be used for assertion, comparing the second expected result with the function call result in the preset database, and comparing the second expected result with the function call result displayed on the console UI page.
In a specific embodiment, the function call result may be displayed in the console UI page, element positioning may be performed on the console UI page, an element value corresponding to the positioned third target element may be obtained, the function call result displayed in the console UI page may be obtained, and the second desired result may be compared with the function call result displayed in the console UI page, so as to obtain a PaaS platform access test result corresponding to the target interface. That is, the element value of the third target element, that is, the function call result, may be obtained through element positioning. Specifically, element positioning can be performed on the console UI page through keyword driving.
Therefore, the embodiment of the application utilizes the PaaS control end test case to locate the elements of the control console UI page of the PaaS platform, executes the keyword drive corresponding to the located first target element, and determines the test result of the control console UI page based on the first execution result of the keyword drive; the PaaS control end test case is a test case which is pre-packaged with a keyword driver corresponding to the first target element; and calling a target interface encapsulated in the application demo by using the PaaS access test case, calling a function corresponding to the target interface in the PaaS platform by using the target interface to obtain a function calling result, and determining an access test result of the PaaS platform corresponding to the target interface based on the function calling result. Therefore, the PaaS control end test case is driven by the packaging keywords, the control console UI page of the PaaS platform is tested, the target interface is packaged in the application demo, the PaaS access test case is utilized to carry out the PaaS platform access test result, the manual coding is avoided to carry out the test, the automatic test of the PaaS platform is realized, the test labor cost of the PaaS platform can be reduced, and the test efficiency is improved.
Referring to fig. 4, the embodiment of the application discloses a specific PaaS platform testing method, which comprises the following steps:
Step S21: performing element positioning on a control console UI page of a PaaS platform by using a PaaS control terminal test case, executing a keyword drive corresponding to a positioned first target element, and determining a test result of the control console UI page based on a first execution result of the keyword drive; the PaaS control end test case is a test case which is pre-packaged with a keyword driver corresponding to the first target element.
The specific process of the step S21 may refer to the corresponding content disclosed in the foregoing embodiment, and will not be described herein.
Step S22: and calling a target interface encapsulated in the application demo by using the PaaS access test case, calling a function corresponding to the target interface in the PaaS platform by using the target interface to obtain a function calling result, positioning an element on the control console UI page, and executing a keyword drive corresponding to a positioned second target element.
Step S23: and determining a PaaS platform access test result corresponding to the target interface based on the function calling result and a second execution result driven by the keyword corresponding to the second target element.
It should be noted that, in the PaaS platform access test of some interfaces, not only the target interface encapsulated in the application demo needs to be called, and the function corresponding to the target interface in the PaaS platform is called by using the target interface, but also element positioning is required to be performed on the console UI page, and the keyword driving corresponding to the positioned second target element is performed. The PaaS access test case may encapsulate the key driver corresponding to the second target element.
In a specific embodiment, the function calling result may be added to a preset database, a second desired result is compared with the function calling result in the preset database, and/or the function calling result is displayed in the console UI page, and the second desired result is compared with the function calling result displayed in the console UI page, so as to obtain a comparison result corresponding to the function calling result. And adding a second execution result driven by the keyword to a preset database, comparing a third expected result with the second execution result in the preset database, and/or displaying the second execution result driven by the keyword in the console UI page, and comparing the third expected result with the second execution result displayed in the console UI page to obtain a comparison result corresponding to the second execution result. And finally, determining a test result based on the comparison result corresponding to the function calling result and the comparison result corresponding to the second execution result, namely, the function calling result is consistent with the second expected result, and the second execution result is consistent with the third expected result, namely, the test is passed, or else, the test is not passed.
In addition, in a specific embodiment, a test case priority may be obtained, and the PaaS management and control end test case and the PaaS access test case may be called based on the test case priority. Specifically, test case priorities may be determined in the test plan.
Therefore, the embodiment meets the richer PaaS access test requirement.
The following describes a specific procedure of PaaS platform test of the present solution.
A tester writes a test plan at a tester terminal, distributes the test plan to different web terminals through load balancing, configures a test task at the web terminals based on the acquired test plan, designates an execution client, acquires a corresponding test task execution instruction from the client, performs element positioning on a control console UI page of a PaaS platform by using a PaaS management and control terminal test case under the control of the task execution instruction, executes keyword driving corresponding to a positioned first target element, and determines a test result of the control console UI page based on a first execution result of the keyword driving; the PaaS control end test case is a test case which is pre-packaged with a keyword driver corresponding to the first target element; and calling a target interface encapsulated in the application demo by using the PaaS access test case, calling a function corresponding to the target interface in the PaaS platform by using the target interface to obtain a function calling result, and determining an access test result of the PaaS platform corresponding to the target interface based on the function calling result. After the test plan is executed, a test report is finally generated and sent to corresponding testers.
Referring to fig. 5, the embodiment of the application discloses a PaaS platform testing device, which comprises:
The PaaS platform UI page test module 11 is used for carrying out element positioning on a control console UI page of the PaaS platform by utilizing a PaaS management and control end test case, executing a keyword drive corresponding to a positioned first target element, and determining a test result of the control console UI page based on a first execution result of the keyword drive; the PaaS control end test case is a test case which is pre-packaged with a keyword driver corresponding to the first target element;
The PaaS platform access test module 12 is configured to invoke a target interface encapsulated in an application demo by using a PaaS access test case, invoke a function corresponding to the target interface in the PaaS platform by using the target interface to obtain a function call result, and then determine a PaaS platform access test result corresponding to the target interface based on the function call result.
Therefore, the embodiment of the application utilizes the PaaS control end test case to locate the elements of the control console UI page of the PaaS platform, executes the keyword drive corresponding to the located first target element, and determines the test result of the control console UI page based on the first execution result of the keyword drive; the PaaS control end test case is a test case which is pre-packaged with a keyword driver corresponding to the first target element; and calling a target interface encapsulated in the application demo by using the PaaS access test case, calling a function corresponding to the target interface in the PaaS platform by using the target interface to obtain a function calling result, and determining an access test result of the PaaS platform corresponding to the target interface based on the function calling result. Therefore, the PaaS control end test case is driven by the packaging keywords, the control console UI page of the PaaS platform is tested, the target interface is packaged in the application demo, the PaaS access test case is utilized to carry out the PaaS platform access test result, the manual coding is avoided to carry out the test, the automatic test of the PaaS platform is realized, the test labor cost of the PaaS platform can be reduced, and the test efficiency is improved.
In a specific embodiment, the PaaS platform UI page test module 11 is specifically configured to use a PaaS management and control end test case to perform element positioning on a console UI page of the PaaS platform based on a PageObject model, and execute a keyword driver corresponding to the positioned first target element.
The PaaS platform UI page test module 11 is specifically configured to add a first execution result driven by the keyword to a preset database by using a PaaS management and control end test case, and compare a first expected result with the first execution result in the preset database to obtain a test result of the console UI page; and/or displaying the first execution result driven by the keyword in the console UI page, and comparing the first expected result with the first execution result displayed in the console UI page to obtain a test result of the console UI page.
The PaaS platform accesses the test module 12, in particular to a test case of a control end by using PaaS, determining a target protocol template from the PaaS access test case based on a communication protocol required by the target interface to call a function corresponding to the target interface in the PaaS platform; the PaaS access test case is pre-packaged with an HTTP protocol template or a socket protocol template; and calling a function corresponding to the target interface in the PaaS platform by using the target interface based on the target protocol template.
The PaaS platform access test module 12 is specifically configured to add the function call result to a preset database by using a PaaS management and control end test case, and compare a second expected result with the function call result in the preset database to obtain a PaaS platform access test result corresponding to the target interface; and/or displaying the function calling result in the control console UI page, and comparing the second expected result with the function calling result displayed in the control console UI page to obtain a PaaS platform access test result corresponding to the target interface.
The PaaS platform access test module 12 is specifically configured to perform element positioning on the console UI page by using the PaaS access test case, and execute keyword driving corresponding to the positioned second target element; and determining a PaaS platform access test result corresponding to the target interface based on the function calling result and a second execution result driven by the keyword corresponding to the second target element.
In addition, the PaaS platform testing device is also used for acquiring the priority of the test case, and calling the PaaS control terminal test case and the PaaS access test case based on the priority of the test case.
Further, the embodiment of the application also provides electronic equipment. Fig. 6 is a block diagram of an electronic device 20, according to an exemplary embodiment, and the contents of the diagram should not be construed as limiting the scope of use of the present application in any way.
Fig. 6 is a schematic structural diagram of an electronic device 20 according to an embodiment of the present application. The electronic device 20 may specifically include: at least one processor 21, at least one memory 22, a power supply 23, a communication interface 24, an input output interface 25, and a communication bus 26. The memory 22 is configured to store a computer program, where the computer program is loaded and executed by the processor 21 to implement relevant steps in the PaaS platform testing method disclosed in any of the foregoing embodiments.
In this embodiment, the power supply 23 is configured to provide an operating voltage for each hardware device on the electronic device 20; the communication interface 24 can create a data transmission channel between the electronic device 20 and an external device, and the communication protocol to be followed is any communication protocol applicable to the technical solution of the present application, which is not specifically limited herein; the input/output interface 25 is used for acquiring external input data or outputting external output data, and the specific interface type thereof may be selected according to the specific application requirement, which is not limited herein.
The memory 22 may be a carrier for storing resources, such as a read-only memory, a random access memory, a magnetic disk, or an optical disk, and the resources stored thereon may include an operating system 221, a computer program 222, data 223, and the like, and the storage may be temporary storage or permanent storage.
The operating system 221 is used for managing and controlling various hardware devices on the electronic device 20 and the computer program 222 to implement the operation and processing of the data 223 in the memory 22 by the processor 21, which may be Windows Server, netware, unix, linux, etc. The computer program 222 may further comprise a computer program capable of performing other specific tasks in addition to the computer program capable of performing the PaaS platform testing method performed by the electronic device 20 as disclosed in any of the previous embodiments. Data 223 may include PaaS platform test related data collected by electronic device 20.
Further, the embodiment of the application also discloses a storage medium, wherein the storage medium stores a computer program, and when the computer program is loaded and executed by a processor, the steps of the PaaS platform testing method disclosed in any embodiment are realized.
In this specification, each embodiment is described in a progressive manner, and each embodiment is mainly described in a different point from other embodiments, so that the same or similar parts between the embodiments are referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant points refer to the description of the method section.
Finally, it is further noted that relational terms such as first and second, and the like are 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. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus 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 apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The method, the device, the equipment and the medium for testing the PaaS platform provided by the application are described in detail, and specific examples are applied to the description of the principle and the implementation mode of the application, and the description of the examples is only used for helping to understand the method and the core idea of the application; meanwhile, as those skilled in the art will have variations in the specific embodiments and application scope in accordance with the ideas of the present application, the present description should not be construed as limiting the present application in view of the above.
Claims (10)
1. A PaaS platform testing method, comprising:
performing element positioning on a control console UI page of a PaaS platform by using a PaaS control terminal test case, executing a keyword drive corresponding to a positioned first target element, and determining a test result of the control console UI page based on a first execution result of the keyword drive; the PaaS control end test case is a test case which is pre-packaged with a keyword driver corresponding to the first target element;
And calling a target interface encapsulated in the application demo by using the PaaS access test case, calling a function corresponding to the target interface in the PaaS platform by using the target interface to obtain a function calling result, and determining an access test result of the PaaS platform corresponding to the target interface based on the function calling result.
2. The PaaS platform test method of claim 1, wherein the performing element positioning on the console UI page of the PaaS platform by using the PaaS management and control end test case, and executing the keyword driving corresponding to the positioned first target element, includes:
And performing element positioning on a control console UI page of the PaaS platform by using the PaaS control terminal test case and based on PageObject model, and executing the keyword driving corresponding to the positioned first target element.
3. The PaaS platform testing method of claim 1, wherein the determining the test result of the console UI page based on the first execution result of the keyword driver comprises:
adding the first execution result driven by the keyword to a preset database, and comparing a first expected result with the first execution result in the preset database to obtain a test result of the control console UI page;
And/or displaying the first execution result driven by the keyword in the console UI page, and comparing the first expected result with the first execution result displayed in the console UI page to obtain a test result of the console UI page.
4. The PaaS platform testing method of claim 1, wherein the calling the function corresponding to the target interface in the PaaS platform by using the target interface comprises:
Determining a target protocol template from the PaaS access test case based on a communication protocol required by the target interface to call a function corresponding to the target interface in the PaaS platform; the PaaS access test case is pre-packaged with an HTTP protocol template or a socket protocol template;
and calling a function corresponding to the target interface in the PaaS platform by using the target interface based on the target protocol template.
5. The PaaS platform test method of claim 1, wherein the determining the PaaS platform access test result corresponding to the target interface based on the function call result comprises:
Adding the function calling result to a preset database, and comparing a second expected result with the function calling result in the preset database to obtain a PaaS platform access test result corresponding to the target interface;
And/or displaying the function calling result in the control console UI page, and comparing the second expected result with the function calling result displayed in the control console UI page to obtain a PaaS platform access test result corresponding to the target interface.
6. The PaaS platform test method of claim 1, wherein the determining the PaaS platform access test result corresponding to the target interface based on the function call result comprises:
performing element positioning on the control console UI page by using the PaaS access test case, and executing keyword driving corresponding to the positioned second target element;
and determining a PaaS platform access test result corresponding to the target interface based on the function calling result and a second execution result driven by the keyword corresponding to the second target element.
7. The PaaS platform testing method of any one of claims 1-6, further comprising:
And acquiring a test case priority, and calling the PaaS control terminal test case and the PaaS access test case based on the test case priority.
8. A PaaS platform testing device, comprising:
The PaaS platform UI page test module is used for carrying out element positioning on a control console UI page of the PaaS platform by utilizing a PaaS management and control end test case, executing keyword driving corresponding to a positioned first target element, and determining a test result of the control console UI page based on a first execution result of the keyword driving; the PaaS control end test case is a test case which is pre-packaged with a keyword driver corresponding to the first target element;
The PaaS platform access test module is used for calling a target interface encapsulated in the application demo by using the PaaS access test case, calling a function corresponding to the target interface in the PaaS platform by using the target interface to obtain a function calling result, and determining the PaaS platform access test result corresponding to the target interface based on the function calling result.
9. An electronic device, comprising:
A memory for storing a computer program;
a processor for executing the computer program to implement the PaaS platform test method as claimed in any one of claims 1 to 7.
10. A computer readable storage medium for storing a computer program which when executed by a processor implements the PaaS platform testing method according to any one of claims 1 to 7.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202110308756.2A CN112988585B (en) | 2021-03-23 | 2021-03-23 | PaaS platform testing method, paaS platform testing device, paaS platform testing equipment and PaaS platform testing medium |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202110308756.2A CN112988585B (en) | 2021-03-23 | 2021-03-23 | PaaS platform testing method, paaS platform testing device, paaS platform testing equipment and PaaS platform testing medium |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| CN112988585A CN112988585A (en) | 2021-06-18 |
| CN112988585B true CN112988585B (en) | 2024-05-17 |
Family
ID=76333160
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202110308756.2A Active CN112988585B (en) | 2021-03-23 | 2021-03-23 | PaaS platform testing method, paaS platform testing device, paaS platform testing equipment and PaaS platform testing medium |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN112988585B (en) |
Families Citing this family (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN114490384B (en) * | 2022-01-26 | 2025-04-25 | 浙江绿城未来数智科技有限公司 | An automated testing system and method for APP shell platform |
Citations (10)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN109189688A (en) * | 2018-09-11 | 2019-01-11 | 北京奇艺世纪科技有限公司 | A kind of generation method, generating means and the electronic equipment of test case script |
| CN109471793A (en) * | 2018-09-29 | 2019-03-15 | 天津大学 | A deep learning-based web page automated testing defect location method |
| CN109783346A (en) * | 2018-12-05 | 2019-05-21 | 深圳怡化电脑股份有限公司 | Keyword-driven automatic testing method and device and terminal equipment |
| CN109857663A (en) * | 2019-01-26 | 2019-06-07 | 北京工业大学 | An automated testing platform combining keyword-driven and image similarity |
| CN110399299A (en) * | 2019-07-17 | 2019-11-01 | 深圳证券交易所 | The execution method of automated test frame and test case |
| CN110851356A (en) * | 2019-10-30 | 2020-02-28 | 河海大学 | A web application automation testing framework based on Selenium and its construction method and system |
| CN110941546A (en) * | 2019-10-12 | 2020-03-31 | 平安健康保险股份有限公司 | Automatic test method, device, equipment and storage medium for WEB page case |
| CN111124919A (en) * | 2019-12-24 | 2020-05-08 | 浙江诺诺网络科技有限公司 | User interface testing method, device, equipment and storage medium |
| CN111338970A (en) * | 2020-03-25 | 2020-06-26 | 广州棒谷科技股份有限公司 | WEB-side keyword-driven UI (user interface) automatic testing method |
| CN112035348A (en) * | 2020-08-26 | 2020-12-04 | 广东博智林机器人有限公司 | Automatic test platform and automatic test method thereof |
Family Cites Families (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2012040178A1 (en) * | 2010-09-24 | 2012-03-29 | Waters Technologies Corporation | Techniques for automated software testing |
| US9424167B2 (en) * | 2014-05-21 | 2016-08-23 | Cgi Technologies And Solutions Inc. | Automated testing of an application system |
-
2021
- 2021-03-23 CN CN202110308756.2A patent/CN112988585B/en active Active
Patent Citations (10)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN109189688A (en) * | 2018-09-11 | 2019-01-11 | 北京奇艺世纪科技有限公司 | A kind of generation method, generating means and the electronic equipment of test case script |
| CN109471793A (en) * | 2018-09-29 | 2019-03-15 | 天津大学 | A deep learning-based web page automated testing defect location method |
| CN109783346A (en) * | 2018-12-05 | 2019-05-21 | 深圳怡化电脑股份有限公司 | Keyword-driven automatic testing method and device and terminal equipment |
| CN109857663A (en) * | 2019-01-26 | 2019-06-07 | 北京工业大学 | An automated testing platform combining keyword-driven and image similarity |
| CN110399299A (en) * | 2019-07-17 | 2019-11-01 | 深圳证券交易所 | The execution method of automated test frame and test case |
| CN110941546A (en) * | 2019-10-12 | 2020-03-31 | 平安健康保险股份有限公司 | Automatic test method, device, equipment and storage medium for WEB page case |
| CN110851356A (en) * | 2019-10-30 | 2020-02-28 | 河海大学 | A web application automation testing framework based on Selenium and its construction method and system |
| CN111124919A (en) * | 2019-12-24 | 2020-05-08 | 浙江诺诺网络科技有限公司 | User interface testing method, device, equipment and storage medium |
| CN111338970A (en) * | 2020-03-25 | 2020-06-26 | 广州棒谷科技股份有限公司 | WEB-side keyword-driven UI (user interface) automatic testing method |
| CN112035348A (en) * | 2020-08-26 | 2020-12-04 | 广东博智林机器人有限公司 | Automatic test platform and automatic test method thereof |
Also Published As
| Publication number | Publication date |
|---|---|
| CN112988585A (en) | 2021-06-18 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN109302522B (en) | Test method, test device, computer system, and computer medium | |
| CN112765023B (en) | Test case generation method and device | |
| US8898643B2 (en) | Application trace replay and simulation systems and methods | |
| US8918762B2 (en) | Generating test plans and test cases from service-oriented architecture and process models | |
| CN106383786A (en) | Interface pressure performance testing method and device and electronic equipment | |
| CN111124919A (en) | User interface testing method, device, equipment and storage medium | |
| CN110750458A (en) | Big data platform testing method and device, readable storage medium and electronic equipment | |
| CN107832207A (en) | Interface performance test method, apparatus, storage medium and computer equipment | |
| CN111290951B (en) | Test method, terminal, server, system and storage medium | |
| CN105740138A (en) | Test method, test device and test system of application | |
| CN112596750B (en) | Application testing method and device, electronic equipment and computer readable storage medium | |
| CN117215910A (en) | Interface test frame generation method, test method, electronic device and storage medium | |
| CN113986714B (en) | A container-based automated continuous testing method and device | |
| CN108427639A (en) | Automated testing method, application server and computer readable storage medium | |
| CN117370203B (en) | Automatic test method, system, electronic equipment and storage medium | |
| CN112988585B (en) | PaaS platform testing method, paaS platform testing device, paaS platform testing equipment and PaaS platform testing medium | |
| CN114461470B (en) | Memory power consumption testing method, system, equipment and storage medium | |
| CN116010280A (en) | A kind of automatic test method, device, equipment and medium based on natural language | |
| CN111309625A (en) | Regression testing method and device based on real transaction data | |
| CN103019927B (en) | A kind of performance test methods and system | |
| CN118524025A (en) | Double-ended communication simulation method, device, storage medium, and program product | |
| CN116881161A (en) | Software testing method, system, device and electronic equipment | |
| CN117950988A (en) | Interface test method, device and equipment of application program and storage medium | |
| CN115470152A (en) | Test code generation method, test code generation device, and storage medium | |
| CN113342633B (en) | Performance test 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 | ||
| CB02 | Change of applicant information | ||
| CB02 | Change of applicant information |
Address after: 601, 6 / F, building 2, No. 18, Kechuang 11th Street, Daxing District, Beijing, 100176 Applicant after: Jingdong Technology Information Technology Co.,Ltd. Address before: 601, 6th floor, building 2, yard 18, Kechuang 11th Street, Beijing Economic and Technological Development Zone, Daxing District, Beijing Applicant before: Jingdong Shuke Haiyi Information Technology Co.,Ltd. |
|
| GR01 | Patent grant | ||
| GR01 | Patent grant |