Coder Social home page Coder Social logo

msoftware / webviewtester Goto Github PK

View Code? Open in Web Editor NEW

This project forked from azimolabs/webviewtester

0.0 2.0 0.0 63 KB

Android tool to automate interaction with web pages displayed in Android WebViews. Could be especially helpful in testing UI with Espresso.

HTML 1.75% Java 98.25%

webviewtester's Introduction

WebViewTester

Android Arsenal

Android tool to automate interaction with web pages displayed in Android WebViews. Could be especially helpful in testing UI with Espresso.

So far it provides methods to:

- get value
- set value
- set checked state
- click on element
- pick one of items from <select>
- get inner HTML

All mentioned methods find element either by its id, name or className. When there are more elements returned by name or className selector, we can use additional index parameter.

Methods allow to use callbacks which will be executed after method ends.

Works on Android KitKat and above. WebView has to have JavaScript support enabled.

Download

Library dependency

dependencies {
  compile 'com.azimolabs.webviewtester:webviewtester:0.1'
}

Java code

If you don't want to add another dependency to your project, just copy WebViewTester.java class to your source directory.

Examples of usage are shown in sample application.

License

Copyright (C) 2016 Azimo

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

webviewtester's People

Contributors

frogermcs avatar mbozetka avatar

Watchers

Michael jentsch avatar  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.