Set default of threads command to 1 page and 40 threads (#80)

* Set default of threads command to 1 page and 40 threads

* Echo posts in a pager
This commit is contained in:
Dave Gallant
2020-08-16 15:07:48 -04:00
committed by GitHub
parent cfd7e01e43
commit b30a3c5b66
5 changed files with 52 additions and 51 deletions

View File

@@ -19,11 +19,10 @@ def test_extract_post_id():
def test_parse_threads(threads_api_response):
limit = 10
threads = parse_threads(threads_api_response, limit)
assert len(threads) == limit
threads = parse_threads(threads_api_response.get("topics"))
assert len(threads) == 10
def test_parse_threads_empty():
assert parse_threads(None, 10) == []
assert parse_threads(None) == []