aboutsummaryrefslogtreecommitdiff
path: root/test (follow)
AgeCommit message (Collapse)AuthorFilesLines
2023-08-06Fixes #4001 (#4034)Gravatar Jarred Sumner 1-0/+82
* Avoid a utf8 conversion in isDetached * Fixes #4001 * hit the long url codepath --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-08-06Fixes #4029 and fixes #4022 (#4032)Gravatar Jarred Sumner 1-22/+22
* Fixes #4029 and Fixes #4022 Fixes #4029 Fixes #4022 * Add test for all the fetches --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-08-06Bind require.resolve() (#4030)Gravatar Jarred Sumner 1-3/+5
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-08-06Running missing scripts exits with non-0 (#4026)Gravatar Yash Sharma 1-0/+12
Co-authored-by: Yash Sharma <yashsharma@Yashs-MacBook-Air.local>
2023-08-06[install] handle `bun add` of existing `peerDependencies` correctly (#4028)Gravatar Alex Lam S.L 2-6/+90
2023-08-06Fixes #3129 (#4018)Gravatar Jarred Sumner 1-6/+7
* Fixes #3129 * add CloseEvent --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-08-06Code coverage for `bun test` (#3975)Gravatar Jarred Sumner 2-6/+9
* WIP code coverage initial commit * almost works * one approach * Code Coverage * Update WebKit * it works but is not yet accurate * skip double ascii check * wrapper * it works but i'm not sure what to do about blocks * hide blocks for now * Update ZigSourceProvider.cpp * Create coverage.md * Update nav.ts --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-08-06feat: impl `dns.getServers` (#3982)Gravatar Ai Hoshino 1-0/+33
* feat: impl `dns.getServers` Close: #3981 * check return value of `ares_inet_ntop`
2023-08-04fix macro string escaping (#3967)Gravatar Dylan Conway 2-1/+74
* handle macro escaping * remove printer * use `js_lexer.decodeEscapeSequences`
2023-08-04Fixes #3991Gravatar Jarred Sumner 1-0/+36
Fixes #3991
2023-08-04[install] handle `workspace:*` correctly (#3994)Gravatar Alex Lam S.L 1-0/+102
- parse as path so it works on unversioned workspaces - fix missed storage of workspace version fixes #3985
2023-08-04FFI typo (#3973)Gravatar dave caruso 1-1/+6
* FFI typo * add tests * it was a newline
2023-08-04Buffer.copy should ignore out-of-range sourceEnd (#3971)Gravatar Yifei Wang 1-16/+32
2023-08-04[install] store resolved workspace path in lockfile (#3974)Gravatar Alex Lam S.L 2-24/+140
- resolve cwd consistently - speed up package diff - update `test/bun.lockb` fixes #3685 fixes #3958
2023-08-03Fix thread safety issue in async fs functions file paths (#3964)Gravatar Jarred Sumner 1-0/+33
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-08-03Make the test betterGravatar Jarred Sumner 1-1/+2
2023-08-03Test for Module.wrap()Gravatar Jarred Sumner 1-1/+7
2023-08-03allow bundling builtins for browser (#3959)Gravatar Dylan Conway 1-0/+36
* Update resolver.zig * bundle resolve error for non-existent builtins * tests
2023-08-03Fix edge case in `path.relative`. (#3952)Gravatar Ai Hoshino 1-0/+8
Close: #3924
2023-08-03Bunch of fixes (#3516)Gravatar Ashcon Partovi 6-2541/+2547
* Fix #3497 * Fix #3497 * Run prettier * Fix package.json * remove this too * yeah * Fix missing tests * Use native for utf-8-validate * Add module ID names to builtins * Defer evaluation of ESM & CJS modules until link time * Use builtin name for exports in plugins * Add module IDs to builtins * Update JSC build with new flag * WebKit upgrade fixes * Update WebKit * prettier * Upgrade WebKit * bump * Update once again * Add visitAdditionalChildren, remove .fill() usage * Update process.test.js * Update fs.test.ts --------- Co-authored-by: dave caruso <me@paperdave.net> Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-08-03[install] fix stale `bun.lockb` on workspaces (#3945)Gravatar Alex Lam S.L 1-0/+33
- handle workspaces under `--production` correctly - fix `Makefile`
2023-08-03Fix the string encoding in `path.extname`. (#3949)Gravatar Ai Hoshino 1-0/+5
Close: #3948
2023-08-02Fix http write (#3939)Gravatar dave caruso 1-0/+55
* Fix encoding problem when uploading a binary file. Close: #3116 * use BufferList * Finish rebase --------- Co-authored-by: Hanaasagi <ambiguous404@gmail.com>
2023-08-02Implement `node:worker_threads` (#3923)Gravatar Jarred Sumner 4-22/+115
* Start to implement `worker_threads` * more * more!! * more * Update bundle_v2.zig * delete outdated tests * `receiveMessageOnPort` * props test and export default * fix merge * not implemented tests * individual imports * `receiveMessageOnPort` tests --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> Co-authored-by: Dylan Conway <dylan.conway567@gmail.com>
2023-08-02Implement `node:diagnostics_channel` (#3934)Gravatar Ashcon Partovi 2-0/+372
* Add types for `node:async_hooks` * Implement \`node:diagnostics_channel\`
2023-08-02Rewrite built-in modules to use CommonJS over ESM (#3814)Gravatar dave caruso 7-2583/+2539
* stfdsafsd sadffdsa stuff finish commonjs stuff asdf not done but work not done but work not done yet but this is how far i am remove files lol update built files uncomment everything in events lol export default stuff * afdsafsd * its not perfect but almost done * okay * cool * remove temp file * finish rebase * revert settings.json * a * ch-ch-ch-ch-changes * okay * remove this check in release for now * sxdcfghnjm, * lkjhgf * fmt * filename can be null * Update NodeModuleModule.h * weee * fmt --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-08-02Fixes #3931 (#3933)Gravatar Jarred Sumner 2-1/+15
Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-08-01close `BroadcastChannel` in testsGravatar Dylan Conway 2-1/+49
2023-08-01Fix some flaky tests (#3919)Gravatar Ciro Spaciari 2-23/+91
* fix some flask tests * fix condition on prisma test * oops
2023-08-01Fix expanding on .env files (#3918)Gravatar Ciro Spaciari 1-1/+67
* fix expanding * refactor locks * bound checks * fix comment * one more test * oops
2023-08-01add `BroadcastChannel` (#3922)Gravatar Dylan Conway 3-14/+166
* copy and format * update `SerializedScriptValue.cpp` * use `expect().fail()` in message channel tests * rename `BroadcastChannelIdentifier.h` * copy registries * progress and tests * cleanup * worker and broadcast channel test * `BroadcastChannel` ref and unref * `MessagePort` ref, unref, and hasRef * remove `SecurityContext.cpp/h` * add types
2023-08-01Update worker.test.tsGravatar Dylan Conway 1-1/+1
2023-08-01Implement Worker.prototype.threadIdGravatar Jarred Sumner 1-0/+1
2023-07-31throw error if node module does not exist (#3913)Gravatar Vlad Sirenko 1-0/+7
2023-07-31Add a test for TransformStreamGravatar Jarred Sumner 1-4/+43
2023-07-30Fix memory leak in response.clone(), further reduce memory usage of Request ↵Gravatar Jarred Sumner 4-9/+42
& Response (#3902) * Atomize respsone.url & response.statusText * Fix warning * Atomize Request & Response URLs when possible * Fix memory leak in response.clone() bun/bench/snippets on  jarred/atomize ❯ mem bun --smol request-response-clone.mjs cpu: Apple M1 Max runtime: bun 0.7.2 (arm64-darwin) benchmark time (avg) (min … max) p75 p99 p995 -------------------------------------------------------- ----------------------------- req.clone().url 77.3 ns/iter (40.35 ns … 222.64 ns) 91.53 ns 128.11 ns 172.78 ns resp.clone().url 162.43 ns/iter (116 ns … 337.77 ns) 177.4 ns 232.38 ns 262.65 ns Peak memory usage: 60 MB bun/bench/snippets on  jarred/atomize ❯ mem bun-0.7.1 --smol request-response-clone.mjs cpu: Apple M1 Max runtime: bun 0.7.1 (arm64-darwin) benchmark time (avg) (min … max) p75 p99 p995 -------------------------------------------------------- ----------------------------- req.clone().url 115.85 ns/iter (80.35 ns … 247.39 ns) 128.19 ns 181.93 ns 207.23 ns resp.clone().url 252.32 ns/iter (202.6 ns … 351.07 ns) 266.56 ns 325.88 ns 334.73 ns Peak memory usage: 1179 MB * Update tests * Update js_ast.zig * Update test --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-07-30skip flay testGravatar Jarred Sumner 1-1/+1
2023-07-30Support `bun .` to run the entry point (#3891)Gravatar Jarred Sumner 1-4/+68
* Support `bun .` * Fix tests --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-07-30Fix issue with file loader (#3889)Gravatar Jarred Sumner 4-3/+12
* Fix issue with file loader * Update jest-extended.test.js --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-07-30Fix coredump when reading an empty file(`node:stream:createReadStream`) (#3882)Gravatar Ai Hoshino 1-0/+26
* Fix coredump when reading an empty file. Close: #3607 * It seems that the fd is closed when `auto_close` is true.
2023-07-30Improv. (#3885)Gravatar Tiramify (A.K. Daniel) 2-24/+22
2023-07-28Stat largefile test (#3870)Gravatar Jarred Sumner 1-0/+22
* Add test for stat on a large file * Update fs.test.ts --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>
2023-07-28Mark broken test as todoGravatar Jarred Sumner 2-1/+5
2023-07-28fix types and add message channel/port gc testGravatar Dylan Conway 1-3/+15
2023-07-28`MessageChannel` and `MessagePort` (#3860)Gravatar Dylan Conway 4-1/+270
* copy and format * copy * copy * cleanup * some tests * spellcheck * add types * don't lock getting contextId * array buffer test
2023-07-28mark tests as todoGravatar Jarred Sumner 2-81/+75
2023-07-28add fork to child_process (#3851)Gravatar Vlad Sirenko 5-3/+284
* add fork to child_process * fix export * add test to child_process method `fork` * fmt fork * remove only from test
2023-07-28feat(bun/test): Impl. expect().pass() & expect().fail() (#3843)Gravatar Tiramify (A.K. Daniel) 1-5/+10
* Impl. pass & fail * fix * fix 2 * smol
2023-07-28fix the chunk boundary (`node:stream:createReadStream`) (#3853)Gravatar Ai Hoshino 1-0/+82
* fix the slice boundary. Close: #3668 * Add more boundary test case. * fix end is 0.
2023-07-28Support file: URLs in `fetch` (#3858)Gravatar Jarred Sumner 2-0/+11
* Support file: URLs in `fetch` * Update url.zig --------- Co-authored-by: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com>