Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/precompile.jl
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ try
"JULIA_SSL_NO_VERIFY_HOSTS" => nothing,
"JULIA_ALWAYS_VERIFY_HOSTS" => nothing]

withenv(env...) do
@compile_workload begin
@compile_workload begin
withenv(env...) do
HTTP.get(url);
end
end
Expand Down
7 changes: 5 additions & 2 deletions test/httpversion.jl
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,11 @@

# Important that we can parse a string into a `HTTPVersion` without allocations,
# as we do this for every request/response. Similarly if we then want a `VersionNumber`.
@test @allocated(HTTPVersion("1.1")) == 0
@test @allocated(VersionNumber(HTTPVersion("1.1"))) == 0
function test_allocated()
@test @allocated(HTTPVersion("1.1")) == 0
@test @allocated(VersionNumber(HTTPVersion("1.1"))) == 0
end
test_allocated()

# Test comparisons with `VersionNumber`s
req = HTTP.Request("GET", "http://httpbin.org/anything")
Expand Down
Loading