From 64ec9e20987072692227d8817d9fd99d497fea5e Mon Sep 17 00:00:00 2001 From: Lorenz Diener Date: Wed, 18 Apr 2018 22:00:35 +0200 Subject: Update the tests --- tests/cassettes/test_follow_request_authorize.yaml | 32 +++++++++++----------- 1 file changed, 16 insertions(+), 16 deletions(-) (limited to 'tests/cassettes/test_follow_request_authorize.yaml') diff --git a/tests/cassettes/test_follow_request_authorize.yaml b/tests/cassettes/test_follow_request_authorize.yaml index 0cb8487..fb91e01 100644 --- a/tests/cassettes/test_follow_request_authorize.yaml +++ b/tests/cassettes/test_follow_request_authorize.yaml @@ -7,23 +7,23 @@ interactions: Authorization: [Bearer __MASTODON_PY_TEST_ACCESS_TOKEN_2] Connection: [keep-alive] Content-Length: ['0'] - User-Agent: [python-requests/2.18.4] + User-Agent: [python-requests/2.9.1] method: POST uri: http://localhost:3000/api/v1/accounts/1234567890123456/follow response: - body: {string: '{"id":"1234567890123456","following":false,"followed_by":false,"blocking":false,"muting":false,"requested":true,"domain_blocking":false}'} + body: {string: '{"id":"1234567890123456","following":false,"showing_reblogs":true,"followed_by":false,"blocking":false,"muting":false,"muting_notifications":false,"requested":true,"domain_blocking":false}'} headers: Cache-Control: ['max-age=0, private, must-revalidate'] Content-Type: [application/json; charset=utf-8] - ETag: [W/"39b04ee179b7c6820c81f24224090155"] + ETag: [W/"c64083bd2e9e2c9da5d97d3e2aaf65cb"] Transfer-Encoding: [chunked] Vary: ['Accept-Encoding, Origin'] X-Content-Type-Options: [nosniff] X-Frame-Options: [SAMEORIGIN] - X-Request-Id: [ff6e83a7-8f9e-4e71-91fe-ab3d12a7b379] - X-Runtime: ['0.073482'] + X-Request-Id: [581837a1-60ed-47a4-8532-002a37bc220d] + X-Runtime: ['0.123469'] X-XSS-Protection: [1; mode=block] - content-length: ['136'] + content-length: ['188'] status: {code: 200, message: OK} - request: body: null @@ -33,7 +33,7 @@ interactions: Authorization: [Bearer __MASTODON_PY_TEST_ACCESS_TOKEN] Connection: [keep-alive] Content-Length: ['0'] - User-Agent: [python-requests/2.18.4] + User-Agent: [python-requests/2.9.1] method: POST uri: http://localhost:3000/api/v1/follow_requests/1/authorize response: @@ -41,13 +41,13 @@ interactions: headers: Cache-Control: ['max-age=0, private, must-revalidate'] Content-Type: [application/json; charset=utf-8] - ETag: [W/"25cc8a12b4a7526df56e78049197b9fc"] + ETag: [W/"22373afedef13443fef6492eb2a68e66"] Transfer-Encoding: [chunked] Vary: ['Accept-Encoding, Origin'] X-Content-Type-Options: [nosniff] X-Frame-Options: [SAMEORIGIN] - X-Request-Id: [e7e70867-7816-42f7-bdfa-994f6bd2dbbc] - X-Runtime: ['0.040458'] + X-Request-Id: [9cd9cb5a-e5ed-4f9d-b99f-94915e040005] + X-Runtime: ['0.096094'] X-XSS-Protection: [1; mode=block] content-length: ['2'] status: {code: 200, message: OK} @@ -59,22 +59,22 @@ interactions: Authorization: [Bearer __MASTODON_PY_TEST_ACCESS_TOKEN_2] Connection: [keep-alive] Content-Length: ['0'] - User-Agent: [python-requests/2.18.4] + User-Agent: [python-requests/2.9.1] method: POST uri: http://localhost:3000/api/v1/accounts/1234567890123456/unfollow response: - body: {string: '{"id":"1234567890123456","following":false,"followed_by":false,"blocking":false,"muting":false,"requested":false,"domain_blocking":false}'} + body: {string: '{"id":"1234567890123456","following":false,"showing_reblogs":false,"followed_by":false,"blocking":false,"muting":false,"muting_notifications":false,"requested":false,"domain_blocking":false}'} headers: Cache-Control: ['max-age=0, private, must-revalidate'] Content-Type: [application/json; charset=utf-8] - ETag: [W/"fc9790ae7d4aa4b12007bc0900ea9c72"] + ETag: [W/"d59e6faa8506a5a44211ad29fa1c8fe1"] Transfer-Encoding: [chunked] Vary: ['Accept-Encoding, Origin'] X-Content-Type-Options: [nosniff] X-Frame-Options: [SAMEORIGIN] - X-Request-Id: [a651ddce-80d0-484b-a2f2-6c5fb6377d06] - X-Runtime: ['0.040597'] + X-Request-Id: [1ef6642f-f8fd-43c3-9105-460bacafbd7c] + X-Runtime: ['0.141057'] X-XSS-Protection: [1; mode=block] - content-length: ['137'] + content-length: ['190'] status: {code: 200, message: OK} version: 1 -- cgit v1.2.3 From bc7b9defe8b72b6ab14ade6828a98f4d6e82b1de Mon Sep 17 00:00:00 2001 From: Lorenz Diener Date: Wed, 18 Apr 2018 22:07:03 +0200 Subject: Attempt 2 at fixing the tests for travis --- tests/cassettes/test_follow_request_authorize.yaml | 78 ++++++++++++++++++++++ 1 file changed, 78 insertions(+) (limited to 'tests/cassettes/test_follow_request_authorize.yaml') diff --git a/tests/cassettes/test_follow_request_authorize.yaml b/tests/cassettes/test_follow_request_authorize.yaml index fb91e01..4ea4878 100644 --- a/tests/cassettes/test_follow_request_authorize.yaml +++ b/tests/cassettes/test_follow_request_authorize.yaml @@ -77,4 +77,82 @@ interactions: X-XSS-Protection: [1; mode=block] content-length: ['190'] status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Authorization: [Bearer __MASTODON_PY_TEST_ACCESS_TOKEN_2] + Connection: [keep-alive] + Content-Length: ['0'] + User-Agent: [python-requests/2.9.1] + method: POST + uri: http://localhost:3000/api/v1/accounts/1234567890123456/follow + response: + body: {string: '{"id":"1234567890123456","following":false,"showing_reblogs":true,"followed_by":false,"blocking":false,"muting":false,"muting_notifications":false,"requested":true,"domain_blocking":false}'} + headers: + Cache-Control: ['max-age=0, private, must-revalidate'] + Content-Type: [application/json; charset=utf-8] + ETag: [W/"b3e7ef6e1d5df03bfa98e425f5bb9547"] + Transfer-Encoding: [chunked] + Vary: ['Accept-Encoding, Origin'] + X-Content-Type-Options: [nosniff] + X-Frame-Options: [SAMEORIGIN] + X-Request-Id: [dc39c0ac-158c-4151-a885-301303a1d314] + X-Runtime: ['0.099701'] + X-XSS-Protection: [1; mode=block] + content-length: ['188'] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Authorization: [Bearer __MASTODON_PY_TEST_ACCESS_TOKEN] + Connection: [keep-alive] + Content-Length: ['0'] + User-Agent: [python-requests/2.9.1] + method: POST + uri: http://localhost:3000/api/v1/follow_requests/1/authorize + response: + body: {string: '{}'} + headers: + Cache-Control: ['max-age=0, private, must-revalidate'] + Content-Type: [application/json; charset=utf-8] + ETag: [W/"ebde216f2328956515154640c4a2b85b"] + Transfer-Encoding: [chunked] + Vary: ['Accept-Encoding, Origin'] + X-Content-Type-Options: [nosniff] + X-Frame-Options: [SAMEORIGIN] + X-Request-Id: [235afc2e-87d1-4444-9450-192807cdef1f] + X-Runtime: ['0.101137'] + X-XSS-Protection: [1; mode=block] + content-length: ['2'] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: ['*/*'] + Accept-Encoding: ['gzip, deflate'] + Authorization: [Bearer __MASTODON_PY_TEST_ACCESS_TOKEN_2] + Connection: [keep-alive] + Content-Length: ['0'] + User-Agent: [python-requests/2.9.1] + method: POST + uri: http://localhost:3000/api/v1/accounts/1234567890123456/unfollow + response: + body: {string: '{"id":"1234567890123456","following":false,"showing_reblogs":false,"followed_by":false,"blocking":false,"muting":false,"muting_notifications":false,"requested":false,"domain_blocking":false}'} + headers: + Cache-Control: ['max-age=0, private, must-revalidate'] + Content-Type: [application/json; charset=utf-8] + ETag: [W/"b0cecb650347058310c6a0a326568bdb"] + Transfer-Encoding: [chunked] + Vary: ['Accept-Encoding, Origin'] + X-Content-Type-Options: [nosniff] + X-Frame-Options: [SAMEORIGIN] + X-Request-Id: [3047c295-964e-4d3e-a325-8372bd08ec5d] + X-Runtime: ['0.110171'] + X-XSS-Protection: [1; mode=block] + content-length: ['190'] + status: {code: 200, message: OK} version: 1 -- cgit v1.2.3 From a15d28d9d60128fd5551f05eccd8999b46f70f5e Mon Sep 17 00:00:00 2001 From: Lorenz Diener Date: Sun, 6 May 2018 01:37:13 +0200 Subject: Testing updates, can now test streaming API --- tests/cassettes/test_follow_request_authorize.yaml | 96 ++-------------------- 1 file changed, 9 insertions(+), 87 deletions(-) (limited to 'tests/cassettes/test_follow_request_authorize.yaml') diff --git a/tests/cassettes/test_follow_request_authorize.yaml b/tests/cassettes/test_follow_request_authorize.yaml index 4ea4878..3009793 100644 --- a/tests/cassettes/test_follow_request_authorize.yaml +++ b/tests/cassettes/test_follow_request_authorize.yaml @@ -15,13 +15,13 @@ interactions: headers: Cache-Control: ['max-age=0, private, must-revalidate'] Content-Type: [application/json; charset=utf-8] - ETag: [W/"c64083bd2e9e2c9da5d97d3e2aaf65cb"] + ETag: [W/"6bb005ea6a91d756d0ba9108c1185bce"] Transfer-Encoding: [chunked] Vary: ['Accept-Encoding, Origin'] X-Content-Type-Options: [nosniff] X-Frame-Options: [SAMEORIGIN] - X-Request-Id: [581837a1-60ed-47a4-8532-002a37bc220d] - X-Runtime: ['0.123469'] + X-Request-Id: [e77d21a6-ad74-4741-9cae-2f15454ac124] + X-Runtime: ['0.084303'] X-XSS-Protection: [1; mode=block] content-length: ['188'] status: {code: 200, message: OK} @@ -41,13 +41,13 @@ interactions: headers: Cache-Control: ['max-age=0, private, must-revalidate'] Content-Type: [application/json; charset=utf-8] - ETag: [W/"22373afedef13443fef6492eb2a68e66"] + ETag: [W/"0701583423fc411927a998269cc998b6"] Transfer-Encoding: [chunked] Vary: ['Accept-Encoding, Origin'] X-Content-Type-Options: [nosniff] X-Frame-Options: [SAMEORIGIN] - X-Request-Id: [9cd9cb5a-e5ed-4f9d-b99f-94915e040005] - X-Runtime: ['0.096094'] + X-Request-Id: [02ff5c49-4e6d-4d62-bb0e-8acc2cbd499f] + X-Runtime: ['0.083789'] X-XSS-Protection: [1; mode=block] content-length: ['2'] status: {code: 200, message: OK} @@ -67,91 +67,13 @@ interactions: headers: Cache-Control: ['max-age=0, private, must-revalidate'] Content-Type: [application/json; charset=utf-8] - ETag: [W/"d59e6faa8506a5a44211ad29fa1c8fe1"] + ETag: [W/"dc184f6640b1ece83b3ef3c72c76d808"] Transfer-Encoding: [chunked] Vary: ['Accept-Encoding, Origin'] X-Content-Type-Options: [nosniff] X-Frame-Options: [SAMEORIGIN] - X-Request-Id: [1ef6642f-f8fd-43c3-9105-460bacafbd7c] - X-Runtime: ['0.141057'] - X-XSS-Protection: [1; mode=block] - content-length: ['190'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Authorization: [Bearer __MASTODON_PY_TEST_ACCESS_TOKEN_2] - Connection: [keep-alive] - Content-Length: ['0'] - User-Agent: [python-requests/2.9.1] - method: POST - uri: http://localhost:3000/api/v1/accounts/1234567890123456/follow - response: - body: {string: '{"id":"1234567890123456","following":false,"showing_reblogs":true,"followed_by":false,"blocking":false,"muting":false,"muting_notifications":false,"requested":true,"domain_blocking":false}'} - headers: - Cache-Control: ['max-age=0, private, must-revalidate'] - Content-Type: [application/json; charset=utf-8] - ETag: [W/"b3e7ef6e1d5df03bfa98e425f5bb9547"] - Transfer-Encoding: [chunked] - Vary: ['Accept-Encoding, Origin'] - X-Content-Type-Options: [nosniff] - X-Frame-Options: [SAMEORIGIN] - X-Request-Id: [dc39c0ac-158c-4151-a885-301303a1d314] - X-Runtime: ['0.099701'] - X-XSS-Protection: [1; mode=block] - content-length: ['188'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Authorization: [Bearer __MASTODON_PY_TEST_ACCESS_TOKEN] - Connection: [keep-alive] - Content-Length: ['0'] - User-Agent: [python-requests/2.9.1] - method: POST - uri: http://localhost:3000/api/v1/follow_requests/1/authorize - response: - body: {string: '{}'} - headers: - Cache-Control: ['max-age=0, private, must-revalidate'] - Content-Type: [application/json; charset=utf-8] - ETag: [W/"ebde216f2328956515154640c4a2b85b"] - Transfer-Encoding: [chunked] - Vary: ['Accept-Encoding, Origin'] - X-Content-Type-Options: [nosniff] - X-Frame-Options: [SAMEORIGIN] - X-Request-Id: [235afc2e-87d1-4444-9450-192807cdef1f] - X-Runtime: ['0.101137'] - X-XSS-Protection: [1; mode=block] - content-length: ['2'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Authorization: [Bearer __MASTODON_PY_TEST_ACCESS_TOKEN_2] - Connection: [keep-alive] - Content-Length: ['0'] - User-Agent: [python-requests/2.9.1] - method: POST - uri: http://localhost:3000/api/v1/accounts/1234567890123456/unfollow - response: - body: {string: '{"id":"1234567890123456","following":false,"showing_reblogs":false,"followed_by":false,"blocking":false,"muting":false,"muting_notifications":false,"requested":false,"domain_blocking":false}'} - headers: - Cache-Control: ['max-age=0, private, must-revalidate'] - Content-Type: [application/json; charset=utf-8] - ETag: [W/"b0cecb650347058310c6a0a326568bdb"] - Transfer-Encoding: [chunked] - Vary: ['Accept-Encoding, Origin'] - X-Content-Type-Options: [nosniff] - X-Frame-Options: [SAMEORIGIN] - X-Request-Id: [3047c295-964e-4d3e-a325-8372bd08ec5d] - X-Runtime: ['0.110171'] + X-Request-Id: [85b47933-58e1-42ed-aa9a-b435d9d83a2b] + X-Runtime: ['0.076345'] X-XSS-Protection: [1; mode=block] content-length: ['190'] status: {code: 200, message: OK} -- cgit v1.2.3 From bb92f76e61063bbe59868659fb42824d3649c7b2 Mon Sep 17 00:00:00 2001 From: Lorenz Diener Date: Sun, 6 May 2018 03:02:19 +0200 Subject: Refresh casettes and add some new ones --- tests/cassettes/test_follow_request_authorize.yaml | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'tests/cassettes/test_follow_request_authorize.yaml') diff --git a/tests/cassettes/test_follow_request_authorize.yaml b/tests/cassettes/test_follow_request_authorize.yaml index 3009793..2f14bef 100644 --- a/tests/cassettes/test_follow_request_authorize.yaml +++ b/tests/cassettes/test_follow_request_authorize.yaml @@ -15,13 +15,13 @@ interactions: headers: Cache-Control: ['max-age=0, private, must-revalidate'] Content-Type: [application/json; charset=utf-8] - ETag: [W/"6bb005ea6a91d756d0ba9108c1185bce"] + ETag: [W/"081762809bc21ca493670420dc736fa1"] Transfer-Encoding: [chunked] Vary: ['Accept-Encoding, Origin'] X-Content-Type-Options: [nosniff] X-Frame-Options: [SAMEORIGIN] - X-Request-Id: [e77d21a6-ad74-4741-9cae-2f15454ac124] - X-Runtime: ['0.084303'] + X-Request-Id: [2559832e-48fb-4782-a78e-73edd7cf1cfa] + X-Runtime: ['0.113395'] X-XSS-Protection: [1; mode=block] content-length: ['188'] status: {code: 200, message: OK} @@ -41,13 +41,13 @@ interactions: headers: Cache-Control: ['max-age=0, private, must-revalidate'] Content-Type: [application/json; charset=utf-8] - ETag: [W/"0701583423fc411927a998269cc998b6"] + ETag: [W/"7450e41af88d5294b91dd2d498b116ae"] Transfer-Encoding: [chunked] Vary: ['Accept-Encoding, Origin'] X-Content-Type-Options: [nosniff] X-Frame-Options: [SAMEORIGIN] - X-Request-Id: [02ff5c49-4e6d-4d62-bb0e-8acc2cbd499f] - X-Runtime: ['0.083789'] + X-Request-Id: [e420580c-7bc9-499c-8363-143e76184b5f] + X-Runtime: ['0.056386'] X-XSS-Protection: [1; mode=block] content-length: ['2'] status: {code: 200, message: OK} @@ -67,13 +67,13 @@ interactions: headers: Cache-Control: ['max-age=0, private, must-revalidate'] Content-Type: [application/json; charset=utf-8] - ETag: [W/"dc184f6640b1ece83b3ef3c72c76d808"] + ETag: [W/"d52662a06ac8e4bd34c2c2b4e2e46f99"] Transfer-Encoding: [chunked] Vary: ['Accept-Encoding, Origin'] X-Content-Type-Options: [nosniff] X-Frame-Options: [SAMEORIGIN] - X-Request-Id: [85b47933-58e1-42ed-aa9a-b435d9d83a2b] - X-Runtime: ['0.076345'] + X-Request-Id: [066d1c43-5304-41fe-af40-041dfb36253d] + X-Runtime: ['0.077256'] X-XSS-Protection: [1; mode=block] content-length: ['190'] status: {code: 200, message: OK} -- cgit v1.2.3