diff options
author | 2023-08-28 04:39:16 -0700 | |
---|---|---|
committer | 2023-08-28 04:39:16 -0700 | |
commit | e2a17344dc543c9c652cfe2b14cd2709dd6cfd22 (patch) | |
tree | fe93965d39886494aee12dca71bdcf2a991d806f /src/bun.js/test | |
parent | efe987e8d12e824dde840b56cbb704feabe26ed1 (diff) | |
download | bun-e2a17344dc543c9c652cfe2b14cd2709dd6cfd22.tar.gz bun-e2a17344dc543c9c652cfe2b14cd2709dd6cfd22.tar.zst bun-e2a17344dc543c9c652cfe2b14cd2709dd6cfd22.zip |
just kernel32 things (#4354)
* just kernel32 things
* more
* Update linux_c.zig
* Update windows_c.zig
* Add workaround
Workaround https://github.com/ziglang/zig/issues/16980
* Rename http.zig to bun_dev_http_server.zig
* Rename usages
* more
* more
* more
* thanks tigerbeetle
* Rename `JSC.Node.Syscall` -> `bun.sys`
* more
* woops
* more!
* hmm
* it says there are only 37 errors, but that's not true
* populate argv
* it says 32 errors!
* 24 errors
* fix regular build
* 12 left!
* Still 12 left!
* more
* 2 errors left...
* 1 more error
* Add link to Tigerbeetle
* Fix the remainign error
* Fix test timeout
* Update syscall.zig
---------
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
Diffstat (limited to 'src/bun.js/test')
-rw-r--r-- | src/bun.js/test/jest.zig | 3 | ||||
-rw-r--r-- | src/bun.js/test/snapshot.zig | 8 |
2 files changed, 5 insertions, 6 deletions
diff --git a/src/bun.js/test/jest.zig b/src/bun.js/test/jest.zig index 77cd79d21..e52c9f0e2 100644 --- a/src/bun.js/test/jest.zig +++ b/src/bun.js/test/jest.zig @@ -3,8 +3,7 @@ const bun = @import("root").bun; const js_parser = bun.js_parser; const js_ast = bun.JSAst; const Api = @import("../../api/schema.zig").Api; -const RequestContext = @import("../../http.zig").RequestContext; -const MimeType = @import("../../http.zig").MimeType; +const MimeType = @import("../../bun_dev_http_server.zig").MimeType; const ZigURL = @import("../../url.zig").URL; const HTTPClient = @import("root").bun.HTTP; const NetworkThread = HTTPClient.NetworkThread; diff --git a/src/bun.js/test/snapshot.zig b/src/bun.js/test/snapshot.zig index 12c7b3c36..072194b11 100644 --- a/src/bun.js/test/snapshot.zig +++ b/src/bun.js/test/snapshot.zig @@ -227,11 +227,11 @@ pub const Snapshots = struct { if (this.snapshot_dir_path == null or !strings.eqlLong(dir_path, this.snapshot_dir_path.?, true)) { remain[0] = 0; const snapshot_dir_path = snapshot_file_path_buf[0 .. snapshot_file_path_buf.len - remain.len :0]; - switch (JSC.Node.Syscall.mkdir(snapshot_dir_path, 0o777)) { + switch (bun.sys.mkdir(snapshot_dir_path, 0o777)) { .result => this.snapshot_dir_path = dir_path, .err => |err| { switch (err.getErrno()) { - std.os.E.EXIST => this.snapshot_dir_path = dir_path, + .EXIST => this.snapshot_dir_path = dir_path, else => return JSC.Maybe(void){ .err = err, }, @@ -249,7 +249,7 @@ pub const Snapshots = struct { var flags: JSC.Node.Mode = std.os.O.CREAT | std.os.O.RDWR; if (this.update_snapshots) flags |= std.os.O.TRUNC; - const fd = switch (JSC.Node.Syscall.open(snapshot_file_path, flags, 0o644)) { + const fd = switch (bun.sys.open(snapshot_file_path, flags, 0o644)) { .result => |_fd| _fd, .err => |err| return JSC.Maybe(void){ .err = err, @@ -258,7 +258,7 @@ pub const Snapshots = struct { var file: File = .{ .id = file_id, - .file = .{ .handle = fd }, + .file = .{ .handle = bun.fdcast(fd) }, }; if (this.update_snapshots) { |