Skip to content

Commit cfcbc0d

Browse files
committed
test: verify MediaUploader retry logic
1 parent ab7d912 commit cfcbc0d

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

test/x/media_uploader_test.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,8 @@ def test_retry
8888
stub_request(:post, "#{BASE_URL}/#{TEST_MEDIA_ID}/finalize").to_return(status: 201, headers: JSON_HEADERS, body: JSON_BODY)
8989

9090
assert MediaUploader.chunked_upload(client: @client, file_path:, media_category: MediaUploader::TWEET_VIDEO)
91+
assert_requested(:post, "#{BASE_URL}/#{TEST_MEDIA_ID}/append", times: 2)
92+
assert_requested(:post, "#{BASE_URL}/#{TEST_MEDIA_ID}/finalize", times: 1)
9193
end
9294

9395
def test_validate

0 commit comments

Comments
 (0)