Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rafpyprog/mobilenium
Mobilenium allows you to use Selenium and have access to status codes and HTTP headers, without the need for manual labor.
https://github.com/rafpyprog/mobilenium
browsermob-proxy python selenium webdriver
Last synced: 5 days ago
JSON representation
Mobilenium allows you to use Selenium and have access to status codes and HTTP headers, without the need for manual labor.
- Host: GitHub
- URL: https://github.com/rafpyprog/mobilenium
- Owner: rafpyprog
- License: apache-2.0
- Created: 2017-03-15T16:33:50.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-07-16T04:17:54.000Z (over 5 years ago)
- Last Synced: 2024-11-11T05:54:22.992Z (5 days ago)
- Topics: browsermob-proxy, python, selenium, webdriver
- Language: Python
- Homepage:
- Size: 18.8 MB
- Stars: 21
- Watchers: 5
- Forks: 4
- Open Issues: 4
-
Metadata Files:
- Readme: README.rst
Awesome Lists containing this project
README
Mobilenium: Selenium with steroids
==================================.. image:: https://img.shields.io/pypi/v/mobilenium.svg
:target: https://pypi.python.org/pypi/mobilenium.. image:: https://img.shields.io/pypi/l/mobilenium.svg
:target: https://pypi.mobileniumpython.org/pypi/mobilenium.. image:: https://img.shields.io/pypi/pyversions/mobilenium.svg
:target: https://pypi.python.org/pypi/mobilenium.. image:: https://api.travis-ci.org/rafpyprog/Mobilenium.svg
:target: https://pypi.python.org/pypi/mobilenium.. image:: https://img.shields.io/codecov/c/github/rafpyprog/mobilenium.svg
:target: https://pypi.python.org/pypi/mobilenium.. image:: https://img.shields.io/pypi/dm/mobilenium.svg
:target: https://pypi.org/project/mobilenium/Mobilenium uses `BrowserMob Proxy `_ to give superpowers to Selenium.
Usage
------------.. code-block:: python
>>> from mobilenium import mobidriver
>>>
>>> browsermob_path = 'path/to/browsermob-proxy'
>>> mob = mobidriver.Firefox(browsermob_binary=browsermob_path)
>>> mob.get('http://python-requests.org')
301
>>> mob.response['redirectURL']
'http://docs.python-requests.org'
>>> mob.headers['Content-Type']
'application/json; charset=utf8'
>>> mob.title
'Requests: HTTP for Humans \u2014 Requests 2.13.0 documentation'
>>> mob.find_elements_by_tag_name('strong')[1].text
'Behold, the power of Requests'Mobilenium allows you to use Selenium and manipulate HTTP requests and responses, capture HTTP content, and export performance data, without the need for manual labor. It is powered by BrowserMob Proxy.
Installation
------------* pip install mobilenium
Dependencies
------------
Mobilenium depends on the BrowserMob Proxy. Download the latest BrowserMob Proxy binary from `page `_.Contribute
------------
Contributions are welcome! Not familiar with the codebase yet? No problem! There are many ways to contribute to open source projects: reporting bugs, helping with the documentation, spreading the word and of course, adding new features and patches.