mirror of
https://github.com/ziglang/zig.git
synced 2026-01-20 14:25:16 +00:00
wasi: don't try to test http
wasi does not support networking
This commit is contained in:
parent
483b63d301
commit
d7ac8c8e65
@ -1,5 +1,3 @@
|
||||
const std = @import("std.zig");
|
||||
|
||||
pub const Client = @import("http/Client.zig");
|
||||
pub const Server = @import("http/Server.zig");
|
||||
pub const protocol = @import("http/protocol.zig");
|
||||
@ -308,6 +306,9 @@ pub const Header = struct {
|
||||
value: []const u8,
|
||||
};
|
||||
|
||||
const builtin = @import("builtin");
|
||||
const std = @import("std.zig");
|
||||
|
||||
test {
|
||||
_ = Client;
|
||||
_ = Method;
|
||||
@ -315,5 +316,7 @@ test {
|
||||
_ = Status;
|
||||
_ = HeadParser;
|
||||
_ = ChunkParser;
|
||||
_ = @import("http/test.zig");
|
||||
if (builtin.os.tag != .wasi) {
|
||||
_ = @import("http/test.zig");
|
||||
}
|
||||
}
|
||||
|
||||
@ -914,6 +914,7 @@ const TestServer = struct {
|
||||
|
||||
fn destroy(self: *@This()) void {
|
||||
self.server_thread.join();
|
||||
self.net_server.deinit();
|
||||
std.testing.allocator.destroy(self);
|
||||
}
|
||||
|
||||
@ -924,7 +925,6 @@ const TestServer = struct {
|
||||
|
||||
fn createTestServer(S: type) !*TestServer {
|
||||
if (builtin.single_threaded) return error.SkipZigTest;
|
||||
if (builtin.os.tag == .wasi) return error.SkipZigTest;
|
||||
if (builtin.zig_backend == .stage2_llvm and native_endian == .big) {
|
||||
// https://github.com/ziglang/zig/issues/13782
|
||||
return error.SkipZigTest;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user