GithubHelp home page GithubHelp logo

johndlloyd / honeydew Goto Github PK

View Code? Open in Web Editor NEW

This project forked from amplify-education/honeydew

0.0 2.0 0.0 1001 KB

Honeydew is a Ruby driver for UIAutomator which enables automated testing of Android devices

License: MIT License

honeydew's Introduction

Honeydew

NOTE: Honeydew is currently in alpha and is not quite ready for use.

Honeydew is a Ruby driver for UIAutomator which enables automated testing of Android devices.

Installation

Install the honeydew gem:

$ gem install honeydew

Or if you're using Bundler, add honeydew to your Gemfile:

gem 'honeydew'

You'll need to have the Android SDK installed, ANDROID_HOME set correctly as well as Maven.

Using Honeydew

In typical operation, Honeydew connects to the first Android device connected to your system which has debugging enabled. You can send commands to this device like so:

    Honeydew.current_device.launch_home
    Honeydew.

If you want to interact with multiple Android devices at the same time, you can create separate device instances by specifying their serial IDS. You can get the serial IDs of all android devices connected to your system with the ``adb devices -l``` command, e.g:

$ adb devices -l
List of devices attached

Once you have the serial ID of a device you wish to control, create a device object for it:

    nexus = Honeydew::Device.new ''

Then you can begin issuing commands:

    nexus.click_text 'Android Air-Hockey'
    if nexus.has_text? 'New Game'
      nexus.click_button 'New Game'
    ...

Using Honeydew with RSpec

Honeydew comes with a DSL that can be used in RSpec as well as matchers for use with RSpec.

Using Honeydew with Cucumber

If you're using Cucumber, Honeydew comes with a DSL that can ease the creation of device related steps. Firstly require the honeydew cucumber files:

    require 'honeydew/cucumber'

This adds the Honeydew DSL to World so you can interact with the device in your steps like so:

    using_device :teacher_tablet
    teacher_tablet.launch_settings

Controlling Android Devices

Honeydew provides a number of methods for interacting with an Android device.

Thanks

Honeydew is sponsored by Amplify and was created by Selvakumar Natesan and Christopher Rex of ThoughtWorks.

Additional thanks to Shyam Vala, Premanand Chandrasekaran and John Barker for multi device support, testing and a little bit of polish.

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

honeydew's People

Contributors

j16r avatar selvakn avatar mkurutin avatar shyamvala avatar prabhap avatar christopher-rex avatar

Watchers

James Cloos avatar John D. Lloyd avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.