-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Álvaro Bartolomé del Canto
committed
Aug 14, 2019
1 parent
8e83201
commit 75c51ca
Showing
3 changed files
with
51 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
#!/usr/bin/env python3 | ||
# -*- coding: utf-8 -*- | ||
|
||
__author__ = 'Alvaro Bartolome @ alvarob96 on GitHub' | ||
__version__ = '0.1' | ||
|
||
import pytest | ||
|
||
from twipper.credentials import Twipper | ||
|
||
|
||
def test_credentials(): | ||
credentials = Twipper(consumer_key='4mfeYj9SH1PXsff5HgZ5bTOzW', | ||
consumer_secret='aiEfkE5tYCKcKEg42OcHbNgVvA2uikwwpRuBYwl5VmGSAm7N7e', | ||
access_token='254490342-xIGPeyGYLDyD1uFIVgybDsd9ImUPaz467kowIoem', | ||
access_token_secret='JrEuYnm1s44JR46AQDdoJagee3Uw9Ip0jxlp7z3XFcPDg') | ||
|
||
credentials.plan = 'fullarchive' | ||
print(credentials.plan) | ||
credentials.label = 'research' | ||
print(credentials.label) | ||
|
||
credentials.close() | ||
|
||
# api = credentials.get_api() | ||
# auth = credentials.get_oauth() | ||
# | ||
# try: | ||
# tweets = stream_country_tweets(api=api, | ||
# auth=auth, | ||
# country='spain', | ||
# language='es', | ||
# filter_retweets=False, | ||
# tweet_limit=10, | ||
# retry='no_limit') # after cleaning maybe some are empty or invalid | ||
# except: | ||
# credentials.close() | ||
# | ||
# credentials.close() | ||
# | ||
# for tweet in tweets: | ||
# print(tweet) | ||
|
||
|
||
if __name__ == '__main__': | ||
test_credentials() |