mirror of
https://github.com/status-im/PyGithub.git
synced 2026-09-01 19:31:10 +00:00
The Github gists api has a since parameter for the various gist searches. This adds that parameter to Github.get_gists(), NamedUser.get_gists() and Authenticator.get_gists(). Tests and replay data added/updated as needed. I added a Time module in the tests directory, containing just a UTCtzinfo class, which I felt I needed for one of the tests (and would probably be useful in other since/until tests). Might not be the best name for the module but it seemed the least invasive thing to do.
23 lines
6.3 KiB
Plaintext
23 lines
6.3 KiB
Plaintext
https
|
|
GET
|
|
api.github.com
|
|
None
|
|
/users/jacquev6/gists
|
|
{'Authorization': 'Basic login_and_password_removed', 'User-Agent': 'PyGithub/Python'}
|
|
None
|
|
200
|
|
[('status', '200 OK'), ('x-ratelimit-remaining', '4967'), ('content-length', '3681'), ('server', 'nginx/1.0.13'), ('connection', 'keep-alive'), ('x-ratelimit-limit', '5000'), ('etag', '"5718165cec484b5936e6e08ff24eb2e5"'), ('date', 'Sat, 26 May 2012 10:09:40 GMT'), ('content-type', 'application/json; charset=utf-8')]
|
|
[{"updated_at":"2012-05-26T10:09:33Z","url":"https://api.github.com/gists/2793179","comments":0,"public":true,"git_pull_url":"git://gist.github.com/2793179.git","git_push_url":"git@gist.github.com:2793179.git","files":{"foobar.txt":{"type":"text/plain","raw_url":"https://gist.github.com/raw/2793179/73a1c7f17aa0ad5d7cbb5a8ca033ce47d3d23197/foobar.txt","size":24,"filename":"foobar.txt","language":"Text"}},"user":{"url":"https://api.github.com/users/jacquev6","avatar_url":"https://secure.gravatar.com/avatar/b68de5ae38616c296fa345d2b9df2225?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"b68de5ae38616c296fa345d2b9df2225","login":"jacquev6","id":327146},"description":"Gist created by PyGithub","created_at":"2012-05-26T09:50:02Z","id":"2793179","html_url":"https://gist.github.com/2793179"},{"updated_at":"2012-04-26T13:20:53Z","url":"https://api.github.com/gists/11cb445f8197e17d303d","comments":0,"public":false,"git_pull_url":"git://gist.github.com/11cb445f8197e17d303d.git","git_push_url":"git@gist.github.com:11cb445f8197e17d303d.git","files":{"FairThreadPoolPool.cpp":{"type":"text/plain","raw_url":"https://gist.github.com/raw/11cb445f8197e17d303d/0f72c6fe50eb011eacb4e39fa613bdfe2f7a0c51/FairThreadPoolPool.cpp","size":7779,"filename":"FairThreadPoolPool.cpp","language":"C++"}},"user":{"url":"https://api.github.com/users/jacquev6","avatar_url":"https://secure.gravatar.com/avatar/b68de5ae38616c296fa345d2b9df2225?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"b68de5ae38616c296fa345d2b9df2225","login":"jacquev6","id":327146},"description":"FairThreadPoolPool.cpp","created_at":"2012-04-26T13:20:53Z","id":"11cb445f8197e17d303d","html_url":"https://gist.github.com/11cb445f8197e17d303d"},{"updated_at":"2012-02-29T16:47:12Z","url":"https://api.github.com/gists/1942384","comments":0,"public":true,"git_pull_url":"git://gist.github.com/1942384.git","git_push_url":"git@gist.github.com:1942384.git","files":{"fail_github.py":{"type":"application/python","raw_url":"https://gist.github.com/raw/1942384/2fb3aa84e0efa50dc0f4c18b5df5b7b9ab27076b/fail_github.py","size":1636,"filename":"fail_github.py","language":"Python"}},"user":{"url":"https://api.github.com/users/jacquev6","avatar_url":"https://secure.gravatar.com/avatar/b68de5ae38616c296fa345d2b9df2225?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"b68de5ae38616c296fa345d2b9df2225","login":"jacquev6","id":327146},"description":"How to error 500 Github API v3, as requested by Rick (GitHub Staff)","created_at":"2012-02-29T16:47:12Z","id":"1942384","html_url":"https://gist.github.com/1942384"},{"updated_at":"2012-02-28T19:44:42Z","url":"https://api.github.com/gists/dcb7de17e8a52b74541d","comments":1,"public":false,"git_pull_url":"git://gist.github.com/dcb7de17e8a52b74541d.git","git_push_url":"git@gist.github.com:dcb7de17e8a52b74541d.git","files":{"cadfael.txt":{"type":"text/plain","raw_url":"https://gist.github.com/raw/dcb7de17e8a52b74541d/48ca696645682d7430d73180814434e0284796b2/cadfael.txt","size":585,"filename":"cadfael.txt","language":"Text"}},"user":{"url":"https://api.github.com/users/jacquev6","avatar_url":"https://secure.gravatar.com/avatar/b68de5ae38616c296fa345d2b9df2225?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"b68de5ae38616c296fa345d2b9df2225","login":"jacquev6","id":327146},"description":"Cadfael: order of episodes in French DVD edition","created_at":"2012-02-28T19:44:42Z","id":"dcb7de17e8a52b74541d","html_url":"https://gist.github.com/dcb7de17e8a52b74541d"}]
|
|
|
|
https
|
|
GET
|
|
api.github.com
|
|
None
|
|
/users/jacquev6/gists?since=2012-03-01T17%3A00%3A00Z
|
|
{'Authorization': 'Basic login_and_password_removed', 'User-Agent': 'PyGithub/Python'}
|
|
None
|
|
200
|
|
[('status', '200 OK'), ('x-ratelimit-remaining', '4967'), ('content-length', '1811'), ('server', 'nginx/1.0.13'), ('connection', 'keep-alive'), ('x-ratelimit-limit', '5000'), ('etag', '"7518615cec183b5396a6e08ef24eb2e9"'), ('date', 'Sat, 26 May 2012 10:10:17 GMT'), ('content-type', 'application/json; charset=utf-8')]
|
|
[{"updated_at":"2012-05-26T10:09:33Z","url":"https://api.github.com/gists/2793179","comments":0,"public":true,"git_pull_url":"git://gist.github.com/2793179.git","git_push_url":"git@gist.github.com:2793179.git","files":{"foobar.txt":{"type":"text/plain","raw_url":"https://gist.github.com/raw/2793179/73a1c7f17aa0ad5d7cbb5a8ca033ce47d3d23197/foobar.txt","size":24,"filename":"foobar.txt","language":"Text"}},"user":{"url":"https://api.github.com/users/jacquev6","avatar_url":"https://secure.gravatar.com/avatar/b68de5ae38616c296fa345d2b9df2225?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"b68de5ae38616c296fa345d2b9df2225","login":"jacquev6","id":327146},"description":"Gist created by PyGithub","created_at":"2012-05-26T09:50:02Z","id":"2793179","html_url":"https://gist.github.com/2793179"},{"updated_at":"2012-04-26T13:20:53Z","url":"https://api.github.com/gists/11cb445f8197e17d303d","comments":0,"public":false,"git_pull_url":"git://gist.github.com/11cb445f8197e17d303d.git","git_push_url":"git@gist.github.com:11cb445f8197e17d303d.git","files":{"FairThreadPoolPool.cpp":{"type":"text/plain","raw_url":"https://gist.github.com/raw/11cb445f8197e17d303d/0f72c6fe50eb011eacb4e39fa613bdfe2f7a0c51/FairThreadPoolPool.cpp","size":7779,"filename":"FairThreadPoolPool.cpp","language":"C++"}},"user":{"url":"https://api.github.com/users/jacquev6","avatar_url":"https://secure.gravatar.com/avatar/b68de5ae38616c296fa345d2b9df2225?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"b68de5ae38616c296fa345d2b9df2225","login":"jacquev6","id":327146},"description":"FairThreadPoolPool.cpp","created_at":"2012-04-26T13:20:53Z","id":"11cb445f8197e17d303d","html_url":"https://gist.github.com/11cb445f8197e17d303d"}]
|
|
|