Skip to content

Fix variable used in updateProgress in URLSessionTask#5482

Open
valerianb wants to merge 1 commit into
swiftlang:mainfrom
valerianb:fix-update-progress-url-session-task
Open

Fix variable used in updateProgress in URLSessionTask#5482
valerianb wants to merge 1 commit into
swiftlang:mainfrom
valerianb:fix-update-progress-url-session-task

Conversation

@valerianb

Copy link
Copy Markdown
Contributor

The wrong variable was used to populate toBeReceived

@valerianb valerianb requested a review from a team as a code owner May 21, 2026 08:38
@parkera parkera requested a review from xbhatnag May 21, 2026 17:45
@parkera

parkera commented May 21, 2026

Copy link
Copy Markdown
Contributor

Can we add a unit test to this one too? Thanks!

@xbhatnag

Copy link
Copy Markdown
Contributor

I agree with @parkera , this should be possible to unit-test. I imagine it would require crafting a request with Content-Length header in response such that URLSessionTask.progress.totalUnitCount gets set correctly.

@valerianb

Copy link
Copy Markdown
Contributor Author

I was on leave, I will try to give it a go soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants