CN108536587A - A kind of automated testing method and system based on Appium - Google Patents

A kind of automated testing method and system based on Appium Download PDF

Info

Publication number
CN108536587A
CN108536587A CN201810235960.4A CN201810235960A CN108536587A CN 108536587 A CN108536587 A CN 108536587A CN 201810235960 A CN201810235960 A CN 201810235960A CN 108536587 A CN108536587 A CN 108536587A
Authority
CN
China
Prior art keywords
configuration information
code
test
test object
versatility
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
CN201810235960.4A
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.)
Qingke Xiaomei robot technology (Chengdu) Co.,Ltd.
Original Assignee
Light Guest Intelligent Technology (jiangsu) 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 Light Guest Intelligent Technology (jiangsu) Co Ltd filed Critical Light Guest Intelligent Technology (jiangsu) Co Ltd
Priority to CN201810235960.4A priority Critical patent/CN108536587A/en
Publication of CN108536587A publication Critical patent/CN108536587A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites

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)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention discloses a kind of automated testing method and system based on Appium, the method includes:Obtain environment configuration information and code configuration information;According to the environment configuration information, corresponding installation kit is obtained;By the installation kit, corresponding test object is installed;According to the code configuration information, the test object is tested, test result is obtained;The test result is sent to predetermined reception target.Technical scheme of the present invention can promote the accuracy of test result while reducing the human cost of Appium tests.

Description

A kind of automated testing method and system based on Appium
Technical field
The present invention relates to software testing technology fields, and in particular to a kind of automated testing method based on Appium and is System.
Background technology
Under the conditions of the prior art, test frame is applied in such a mobile terminals only Appium, this applies test frame The inspection and analysis of manually progress test configurations, test execution and test result are needed, the human cost of consumption is very high, and goes out Error rate is also very high, be easy to cause test result inaccuracy.
Therefore, the accuracy that test result how is promoted while reducing testing cost, becomes urgently to be resolved hurrily at present Technical problem.
Invention content
The purpose of the present invention is to provide a kind of automated testing method and system based on Appium, it is existing to solve The problem that testing cost is high, accuracy is low.
To achieve the above object, the first aspect of the present invention provides a kind of automated testing method based on Appium, The method includes:Obtain environment configuration information and code configuration information;According to the environment configuration information, corresponding peace is obtained Dress packet;By the installation kit, corresponding test object is installed;According to the code configuration information, to the test object into Row test, obtains test result;The test result is sent to predetermined reception target.
In the above-mentioned technical solutions, optionally, the environment configuration information includes:It is set using the user of the test object Standby model, the system model using the test object and the predetermined reception target.
In the above-mentioned technical solutions, optionally, according to the environment configuration information, the step of obtaining corresponding installation kit, It specifically includes:Obtain the user equipment model using the test object and/or the system model institute using the test object The installation kit needed.
In the above-mentioned technical solutions, optionally, the code configuration information include real-time edition code, versatility code and The operation order of the real-time edition code and versatility code.
In the above-mentioned technical solutions, optionally, the code configuration information includes versatility code and the versatility code Predetermined running sequence.
In the above-mentioned technical solutions, optionally, the acquisition environment configuration information and code configuration information the step of it Before, further include:Multigroup versatility code is set;A variety of predetermined running sequences are set with for multigroup versatility code.
In the above-mentioned technical solutions, optionally, the predetermined reception target includes E-mail address, cell-phone number, terminal, service It is one or more in device and memory;The predetermined quantity for receiving target is one or more.
The second aspect of the present invention provides a kind of automatization test system based on Appium, the system comprises:Letter Configuration module is ceased, environment configuration information and code configuration information are obtained;Installation kit acquisition module is believed according to the environment configurations Breath, obtains corresponding installation kit;Program installation module installs corresponding test object by the installation kit;Test module, According to the code configuration information, the test object is tested, test result is obtained;Test result sending module, will The test result is sent to predetermined reception target.
In the above-mentioned technical solutions, optionally, the environment configuration information includes:It is set using the user of the test object Standby model, the system model using the test object and the predetermined reception target.
In the above-mentioned technical solutions, optionally, the installation kit acquisition module is used for:It obtains using the test object Installation kit needed for the system model of user equipment model and/or the use test object.
In the above-mentioned technical solutions, optionally, the code configuration information include real-time edition code, versatility code and The operation order of the real-time edition code and versatility code.
In the above-mentioned technical solutions, optionally, the code configuration information includes versatility code and the versatility code Predetermined running sequence.
In the above-mentioned technical solutions, optionally, further include:Setup module obtains environment in described information configuration module and matches Confidence ceases and multigroup versatility code before code configuration information, is arranged, and a variety of predetermined for multigroup versatility code setting Operation order.
In the above-mentioned technical solutions, optionally, the predetermined reception target includes E-mail address, cell-phone number, terminal, service It is one or more in device and memory;The predetermined quantity for receiving target is one or more.
The invention has the advantages that:
To can originally need the process that manually test using Appium test frames, be improved to based on Appium from Dynamicization test process so that system can obtain environment configuration information and code configuration information, and be obtained based on environment configuration information Corresponding installation kit is taken and installed, realizes the installation of test object, and test is executed based on code configuration information, it will be final Obtained test result is automatically sent to predeterminated target.In this way, can be tested with one-key start, test target can directly receive Test result is realized the automation tested based on Appium, saves cost of labor.Simultaneously as using automatic test Process is tested the probability made a fault and is greatly reduced, improves the accuracy of test result, and test result is directly transmitted To predeterminated target, the step of manual analysis obtains test result can be also saved, manpower is further saved.
To sum up, technical scheme of the present invention can promote test result while reducing the human cost of Appium tests Accuracy.
Description of the drawings
Fig. 1 shows the flow chart of the automated testing method based on Appium of one embodiment of the present of invention.
Fig. 2 shows the block diagrams of the automatization test system based on Appium of one embodiment of the present of invention.
Specific implementation mode
The following examples are used to illustrate the present invention, but are not intended to limit the scope of the present invention..
Embodiment 1
Fig. 1 shows the flow chart of the automated testing method based on Appium of one embodiment of the present of invention.
Appium is an automatic test Open-Source Tools, supports the native applications in iOS platforms and Android platform, So-called native applications refer to the application that those are write with iOSSDK or AndroidSDK, that is to say, that Appium be one across The tool of platform allows tester in different platforms (such as iOS and Android), using different development language (such as AVA, The language such as ython and Ruby), automatic test script is write using same set of API, considerably increases iOS and Android in this way Test the durability of code.As shown in Figure 1, the automated testing method based on Appium includes:
Step 102, environment configuration information and code configuration information are obtained.The acquisition process can be obtained in database The environment configuration information of configuration and configured code configuration information can also be to receive developer to input or select in real time Environment configuration information and code configuration information.
Wherein, the environment configuration information includes but not limited to:Using the user equipment model of the test object, use The system model of the test object and the predetermined reception target.Configuration comprehensive system configuration information is conducive to further match Close smoothly completing for test.The detailed content of code configuration information is specifically described in following embodiment 2 and 3.
Step 104, according to the environment configuration information, corresponding installation kit is obtained.
Specifically, it can obtain using the user equipment model of the test object and/or using the test object Installation kit needed for system model.Since different user equipment models and/or different system models have different configurations, The installation kit of its installation test object is also different, therefore system can obtain the user equipment type using the test object automatically Number and/or using the test object system model, obtain the installation kit for meeting actual demand accordingly, installation test pair As test object includes but not limited to application program.Thus, it is ensured that test object meets actual test demand, it is ensured that survey The validity and accuracy of examination.
Step 106, by the installation kit, corresponding test object is installed.
Step 108, according to the code configuration information, the test object is tested, test result is obtained.
Step 110, test result is sent to predetermined reception target.
In the above-mentioned technical solutions, optionally, the predetermined reception target includes E-mail address, cell-phone number, terminal, service It is one or more in device and memory;The predetermined quantity for receiving target is one or more.
To can originally need the process that manually test using Appium test frames, be improved to based on Appium from Dynamicization test process so that system can obtain environment configuration information and code configuration information, and be obtained based on environment configuration information Corresponding installation kit is taken and installed, realizes the installation of test object, and test is executed based on code configuration information, it will be final Obtained test result is automatically sent to predeterminated target.In this way, can be tested with one-key start, test target can directly receive Test result is realized the automation tested based on Appium, saves cost of labor.Simultaneously as using automatic test Process is tested the probability made a fault and is greatly reduced, improves the accuracy of test result, and test result is directly transmitted To predeterminated target, the step of manual analysis obtains test result can be also saved, manpower is further saved.
To sum up, technical scheme of the present invention can promote test result while reducing the human cost of Appium tests Accuracy.
Embodiment 2
In a kind of realization method of the present invention, the code configuration information includes versatility code and the versatility code Predetermined running sequence.
Some test contents are a variety of test all-purposes, therefore predeterminable multigroup versatility code in system, to correspond to these surveys Content is tried, in this way, whenever needing test, it is only necessary to call existing versatility code to test these test contents, nothing These corresponding codes of test content need to be edited every time.Based on this, it can reduce by 70% size of code so that most code It may be reused, improve and further improve testing efficiency.
Meanwhile for multigroup versatility code, needs to be executed in a certain order, can be only achieved test purpose, i.e., It needs to obtain and executes the obtained result of versatility code in a certain order.And hence it is also possible to which the predetermined of versatility code is arranged Operation order, to adapt to actual test demand.
Therefore, before the acquisition environment configuration information and code configuration information the step of, it is also necessary to be arranged multigroup logical With code, and for multigroup versatility code, a variety of predetermined runnings sequences are set.
Embodiment 3
Similarly with embodiment 2, in another realization method of the present invention, the code configuration information includes real-time edition The operation order of code, versatility code and the real-time edition code and versatility code.
Real-time edition code why is needed, is due to having tested difference every time, the code needed is not fully identical, It can not be provided completely by versatility code, therefore to ensure test accuracy, still need to provide real-time edition code to system.
Embodiment 4
Fig. 2 shows the block diagrams of the automatization test system based on Appium of one embodiment of the present of invention.
As shown in Fig. 2, the automatization test system 200 based on Appium of one embodiment of the present of invention includes:Information Configuration module 202 obtains environment configuration information and code configuration information;Installation kit acquisition module 204, according to the environment configurations Information obtains corresponding installation kit;Program installation module 206 installs corresponding test object by the installation kit;Test Module 208 tests the test object, obtains test result according to the code configuration information;Test result is sent The test result is sent to predetermined reception target by module 210.
Automatization test system 200 based on Appium uses the technical solution as described in any one of embodiment 1 to 3, With above-mentioned whole technique effects, details are not described herein, also, also has following technical characteristic:
In the above-mentioned technical solutions, optionally, the environment configuration information includes:It is set using the user of the test object Standby model, the system model using the test object and the predetermined reception target.
In the above-mentioned technical solutions, optionally, the installation kit acquisition module 204 is used for:It obtains using the test pair Installation kit needed for the user equipment model of elephant and/or the system model of the use test object.
In the above-mentioned technical solutions, optionally, the code configuration information include real-time edition code, versatility code and The operation order of the real-time edition code and versatility code.
In the above-mentioned technical solutions, optionally, the code configuration information includes versatility code and the versatility code Predetermined running sequence.
In the above-mentioned technical solutions, optionally, further include:Setup module obtains environment in described information configuration module 202 Before configuration information and code configuration information, multigroup versatility code is set, and a variety of pre- for multigroup versatility code setting Determine operation order.
In the above-mentioned technical solutions, optionally, the predetermined reception target includes E-mail address, cell-phone number, terminal, service It is one or more in device and memory;The predetermined quantity for receiving target is one or more.
Although above having used general explanation and specific embodiment, the present invention is described in detail, at this On the basis of invention, it can be made some modifications or improvements, this will be apparent to those skilled in the art.Therefore, These modifications or improvements without departing from theon the basis of the spirit of the present invention belong to the scope of protection of present invention.

Claims (8)

1. a kind of automated testing method based on Appium, which is characterized in that the method includes:
Obtain environment configuration information and code configuration information;
According to the environment configuration information, corresponding installation kit is obtained;
By the installation kit, corresponding test object is installed;
According to the code configuration information, the test object is tested, test result is obtained;
The test result is sent to predetermined reception target.
2. according to the method described in claim 1, it is characterized in that,
The environment configuration information includes:It is using the user equipment model of the test object, using the test object Model of uniting and the predetermined reception target.
3. according to the method described in claim 2, it is characterized in that, according to the environment configuration information, corresponding installation is obtained The step of packet, specifically includes:
Obtain the peace needed for the user equipment model using the test object and/or the system model using the test object Dress packet.
4. according to the method described in claim 1, it is characterized in that,
The code configuration information includes real-time edition code, versatility code and the real-time edition code and versatility code Operation order.
5. according to the method described in claim 1, it is characterized in that,
The code configuration information includes the predetermined running sequence of versatility code and the versatility code.
6. according to the method described in claim 5, it is characterized in that, in the acquisition environment configuration information and code configuration information The step of before, further include:
Multigroup versatility code is set;With
For multigroup versatility code, a variety of predetermined running sequences are set.
7. method according to any one of claim 1 to 6, which is characterized in that
The predetermined reception target includes one or more in E-mail address, cell-phone number, terminal, server and memory;
The predetermined quantity for receiving target is one or more.
8. a kind of automatization test system based on Appium, which is characterized in that the system comprises:
Information collocation module obtains environment configuration information and code configuration information;
Installation kit acquisition module obtains corresponding installation kit according to the environment configuration information;
Program installation module installs corresponding test object by the installation kit;
Test module tests the test object, obtains test result according to the code configuration information;
The test result is sent to predetermined reception target by test result sending module.
CN201810235960.4A 2018-03-21 2018-03-21 A kind of automated testing method and system based on Appium Pending CN108536587A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810235960.4A CN108536587A (en) 2018-03-21 2018-03-21 A kind of automated testing method and system based on Appium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810235960.4A CN108536587A (en) 2018-03-21 2018-03-21 A kind of automated testing method and system based on Appium

Publications (1)

Publication Number Publication Date
CN108536587A true CN108536587A (en) 2018-09-14

Family

ID=63485046

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810235960.4A Pending CN108536587A (en) 2018-03-21 2018-03-21 A kind of automated testing method and system based on Appium

Country Status (1)

Country Link
CN (1) CN108536587A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111352668A (en) * 2020-02-27 2020-06-30 珠海格力智能装备有限公司 Device testing method and device based on plug-in and testing system based on plug-in
CN111563050A (en) * 2020-07-14 2020-08-21 智者四海(北京)技术有限公司 Automated testing method for mobile equipment

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104035873A (en) * 2014-06-30 2014-09-10 青岛海信电器股份有限公司 Method and device for generating testing codes
CN105740153A (en) * 2016-02-29 2016-07-06 网易(杭州)网络有限公司 Cloud testing method and device
CN106250307A (en) * 2016-07-20 2016-12-21 福建省农村信用社联合社 A kind of bank's mobile phone application automated testing method and system
CN106547688A (en) * 2016-10-19 2017-03-29 厦门市美亚柏科信息股份有限公司 Product automation method of testing and its system based on Windows
CN106776344A (en) * 2017-01-16 2017-05-31 上海聚宝网络科技股份有限公司 A kind of automated testing method of the intelligent express delivery cabinet based on APPIUM
CN107357727A (en) * 2017-07-04 2017-11-17 广州君海网络科技有限公司 APP testing results method, apparatus, readable storage medium storing program for executing and computer equipment
CN107741904A (en) * 2017-09-14 2018-02-27 平安科技(深圳)有限公司 Test machine method of automatic configuration, device, equipment and storage medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104035873A (en) * 2014-06-30 2014-09-10 青岛海信电器股份有限公司 Method and device for generating testing codes
CN105740153A (en) * 2016-02-29 2016-07-06 网易(杭州)网络有限公司 Cloud testing method and device
CN106250307A (en) * 2016-07-20 2016-12-21 福建省农村信用社联合社 A kind of bank's mobile phone application automated testing method and system
CN106547688A (en) * 2016-10-19 2017-03-29 厦门市美亚柏科信息股份有限公司 Product automation method of testing and its system based on Windows
CN106776344A (en) * 2017-01-16 2017-05-31 上海聚宝网络科技股份有限公司 A kind of automated testing method of the intelligent express delivery cabinet based on APPIUM
CN107357727A (en) * 2017-07-04 2017-11-17 广州君海网络科技有限公司 APP testing results method, apparatus, readable storage medium storing program for executing and computer equipment
CN107741904A (en) * 2017-09-14 2018-02-27 平安科技(深圳)有限公司 Test machine method of automatic configuration, device, equipment and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111352668A (en) * 2020-02-27 2020-06-30 珠海格力智能装备有限公司 Device testing method and device based on plug-in and testing system based on plug-in
CN111563050A (en) * 2020-07-14 2020-08-21 智者四海(北京)技术有限公司 Automated testing method for mobile equipment

Similar Documents

Publication Publication Date Title
WO2018120965A1 (en) Automatic test method and device, and computer-readable storage medium
CN104717337A (en) Method for testing mobile application in batch and equipment used in method
CN103823758A (en) Browser testing method and device
CN110704323B (en) Automatic data testing method and device based on rail transit line data
CN108132876B (en) Embedded software object code unit testing method based on injection mode
CN112395202B (en) Interface automation test method and device, computer equipment and storage medium
CN103077114A (en) Automatic testing method based on communication protocol of temperature measuring device
CN111782556A (en) Automatic test method and device
CN110990289B (en) Method and device for automatically submitting bug, electronic equipment and storage medium
CN108536587A (en) A kind of automated testing method and system based on Appium
CN116627848B (en) Automatic test method and system for application program
CN112685311A (en) Test script automatic generation method and device, computer equipment and storage medium
CN110688173B (en) Positioning method and device of components in cross-platform interface framework and electronic equipment
CN116431522A (en) Automatic test method and system for low-code object storage gateway
CN111078526A (en) Test case generation method and device and storage medium
CN109739760B (en) Code debugging test method and device and storage medium
CN111427582A (en) Management method, device and equipment of RT L code and computer readable storage medium
CN114661615B (en) FPGA software testing method and device
CN113986263A (en) Code automation test method, device, electronic equipment and storage medium
CN113886262A (en) Software automation test method and device, computer equipment and storage medium
CN111722997B (en) Abnormality detection method for automated test and computer-readable storage medium
CN112835789A (en) Realization technology for automatic test of automatic test framework
CN111752823A (en) Method, device and equipment for testing vehicle-mounted power supply application software
CN111124904A (en) Regression testing method and device for application software
CN110618932A (en) Input box testing method based on Web automatic test and readable 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
TA01 Transfer of patent application right
TA01 Transfer of patent application right

Effective date of registration: 20200812

Address after: 610000 9, 3 building 200, Tianfu five street, hi tech Zone, Chengdu, Sichuan.

Applicant after: Qingke Xiaomei robot technology (Chengdu) Co.,Ltd.

Address before: E2-318 sensor network China International Innovation Park No. 200 214135 Jiangsu province Wuxi City Linghu new Wu Road

Applicant before: SLIGHTECH INTELLIGENT SCIENCE & TECHNOLOGY (JIANGSU) Co.,Ltd.

RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20180914