ios--(monkey) test--ui Automonkey

Source: Internet
Author: User

Read Catalogue

    • Installation
    • Additional configuration
UI Automonkey

The UI Automonkey is a very simple iOS stress test tool. It allows you to send swipe, drag, rotate, and even lock screen and unlock commands to your iOS device. Original GitHub Address: Https://github.com/jonathanpenn/ui-auto-monkey

Installation

If your Mac computer already has Xcode installed, the environment is OK, and Xcode has its own UI automation and instruments. Follow the steps below to use UIAutomonkey.js this JS script for monkey testing.

    • First, use Xcode to open your iOS project and choose Profile from the Product menu (or direct shortcut command+i) so you can build your iOS project and launch the tool template selector.
    • Next, select UI Automation in the selector. Once we have created an Automation template, we can test the app's performance.
    • In the Scripts panel, click "Editor Log", select "Script" in the drop-down list, click the "Add" button and select "Create" in the drop-down list to create a new JS script.
    • UIAutoMonkey.jsPaste the contents of this file into the new JS script (or you can import it directly) UIAutoMonkey.js .
    • At this point, we can directly click the Play button to execute the script, the monkey test begins.
Go back to the top of the extra configuration

UIAutoMonkey.jsThe script begins with the following code:

config: { numberOfEvents: 1000, delayBetweenEvents: 0.05, // In seconds //各事件的几率. // 数字越大,几率越大. eventWeights: { tap: 30, drag: 1, flick: 1, orientation: 1, clickVolumeUp: 1, clickVolumeDown: 1, lock: 1, pinchClose: 10, pinchOpen: 10, shake: 1 }, // Probability that touch events will have these different properties touchProbability: { multipleTaps: 0.05, multipleTouches: 0.05, longPress: 0.05 } },

numberOfEventThe meaning is clear and represents the number of random events that need to be generated.

delayBetweenEventsRepresents a delay time between two events. This value is generally required for adjustment. If the value is 0, the script sends events to the device as quickly as possible.

eventWeightsThis value represents the chance of triggering each event. If the tab event has a value of 100 and orientation the event has a value of 1, then the tab chance of event firing is orientation 100 times times.

touchProbabilityControls the different kinds of tab events. By default, tab is the Click event. Adjust these parameters to set the frequency at which the double-click, long-event occurs. These values are bounded between 0 and 1.


This article link address: IOS Monkey Test UI Automonkey

ios--(monkey) test--ui Automonkey

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.