This repository was archived by the owner on Aug 7, 2024. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ language: python
22sudo : false
33python :
44 - " 2.7"
5- - " 3.5"
65
76before_install :
87 - pip install codecov
Original file line number Diff line number Diff line change 1- .PHONY : docs test
21
32help :
43 @echo " env create a development environment using virtualenv"
54 @echo " deps install dependencies"
65 @echo " clean remove unwanted stuff"
76 @echo " lint check style with flake8"
7+ @echo " coverage run tests with code coverage"
88 @echo " test run tests"
99
1010env :
@@ -27,8 +27,15 @@ clean:
2727lint :
2828 flake8 twitter > violations.flake8.txt
2929
30+ coverage :
31+ nosetests --with-coverage --cover-package=twitter
32+
3033test :
31- python test.py
34+ nosetests
35+
36+ build : clean
37+ python setup.py sdist
38+ python setup.py bdist_wheel
3239
3340upload : clean
3441 python setup.py sdist upload
Original file line number Diff line number Diff line change @@ -4,9 +4,21 @@ A Python wrapper around the Twitter API.
44
55By the `Python-Twitter Developers <python-twitter@googlegroups.com >`_
66
7- .. image :: https://pypip.in/wheel/python-twitter/badge.png
8- :target: https://pypi.python.org/pypi/python-twitter/
9- :alt: Wheel Status
7+ .. image :: https://img.shields.io/pypi/v/python-twitter.svg
8+ :target: https://pypi.python.org/pypi/parsedatetime/
9+ :alt: Downloads
10+
11+ .. image :: https://travis-ci.org/bear/python-twitter.svg?branch=master
12+ :target: https://travis-ci.org/bear/python-twitter
13+ :alt: Travis CI
14+
15+ .. image :: http://codecov.io/github/bear/python-twitter/coverage.svg?branch=master
16+ :target: http://codecov.io/github/bear/python-twitter
17+ :alt: Codecov
18+
19+ .. image :: https://requires.io/github/bear/python-twitter/requirements.svg?branch=master
20+ :target: https://requires.io/github/bear/python-twitter/requirements/?branch=master
21+ :alt: Requirements Status
1022
1123============
1224Introduction
@@ -24,10 +36,6 @@ You can install python-twitter using::
2436
2537 $ pip install python-twitter
2638
27- Testing::
28-
29- $ python test.py
30-
3139================
3240Getting the code
3341================
@@ -47,14 +55,18 @@ Activate the virtual environment created:
4755
4856 $ source env/bin/activate
4957
50- Run tests:
58+ =============
59+ Running Tests
60+ =============
61+ Note that tests require ```pip install nose` `` and optionally ```pip install coverage` ``:
5162
52- $ make test
63+ To run the unit tests:
5364
54- To see other options available, run:
65+ $ make test
5566
56- $ make help
67+ to also run code coverage:
5768
69+ $ make coverage
5870
5971=============
6072Documentation
Original file line number Diff line number Diff line change 1+ [run]
2+ source = twitter
Original file line number Diff line number Diff line change 2424
2525
2626def get_access_token (consumer_key , consumer_secret ):
27- oauth_client = OAuth1Session (consumer_key , client_secret = consumer_secret )
27+ oauth_client = OAuth1Session (consumer_key , client_secret = consumer_secret , callback_uri = 'oob' )
2828
2929 print 'Requesting temp token from Twitter'
3030
You can’t perform that action at this time.
0 commit comments