Bug 230980 - Migrate _WKDownload tests from TCPServer to HTTPServer
Summary: Migrate _WKDownload tests from TCPServer to HTTPServer
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Alex Christensen
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-09-29 13:44 PDT by Alex Christensen
Modified: 2021-09-29 16:02 PDT (History)
2 users (show)

See Also:


Attachments
Patch (9.57 KB, patch)
2021-09-29 13:46 PDT, Alex Christensen
no flags Details | Formatted Diff | Diff
Patch (9.58 KB, patch)
2021-09-29 14:31 PDT, Alex Christensen
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Christensen 2021-09-29 13:44:51 PDT
Migrate _WKDownload tests from TCPServer to HTTPServer
Comment 1 Alex Christensen 2021-09-29 13:46:48 PDT
Created attachment 439649 [details]
Patch
Comment 2 Alex Christensen 2021-09-29 13:46:51 PDT
<rdar://problem/82100878>
Comment 3 Alex Christensen 2021-09-29 14:31:03 PDT
Created attachment 439660 [details]
Patch
Comment 4 Chris Dumez 2021-09-29 14:31:06 PDT
Comment on attachment 439649 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=439649&action=review

> Tools/TestWebKitAPI/Tests/WebKitCocoa/Download.mm:858
> +void respondSlowly(Connection connection, double kbps)

Why aren't we passing connection by reference here? Seems odd to cause ref counting churn.

> Tools/TestWebKitAPI/Tests/WebKitCocoa/Download.mm:899
> +    HTTPServer server([&](Connection connection) {

Not new to this patch but I think Connection should be passed by reference to the lambda.

> Tools/TestWebKitAPI/Tests/WebKitCocoa/Download.mm:1156
> +    auto websiteDataStore = [WKWebsiteDataStore defaultDataStore];

Nice bug you fixed :)
Comment 5 EWS 2021-09-29 16:02:51 PDT
Committed r283272 (242301@main): <https://commits.webkit.org/242301@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 439660 [details].