summaryrefslogtreecommitdiff
path: root/cli/tests/unit/files_test.ts
AgeCommit message (Collapse)Author
2024-02-10chore: move cli/tests/ -> tests/ (#22369)Matt Mastracci
This looks like a massive PR, but it's only a move from cli/tests -> tests, and updates of relative paths for files. This is the first step towards aggregate all of the integration test files under tests/, which will lead to a set of integration tests that can run without the CLI binary being built. While we could leave these tests under `cli`, it would require us to keep a more complex directory structure for the various test runners. In addition, we have a lot of complexity to ignore various test files in the `cli` project itself (cargo publish exclusion rules, autotests = false, etc). And finally, the `tests/` folder will eventually house the `test_ffi`, `test_napi` and other testing code, reducing the size of the root repo directory. For easier review, the extremely large and noisy "move" is in the first commit (with no changes -- just a move), while the remainder of the changes to actual files is in the second commit.
2024-02-07chore(cli): Use @test_util for relative path for unit tests (#22327)Matt Mastracci
This removes the majority of `../../../../../../test_util` relative imports from the codebase, allowing us to move this code more easily in the future.
2024-02-05feat(unstable): `Deno.FsFile.lock[Sync]()` and `Deno.FsFile.unlock[Sync]()` ↵Asher Gomez
(#22235) Closes #22178.
2024-01-25fix(fs): instanceof check for Deno.FsFile (#22121)Bartek Iwańczuk
Regression caused by https://github.com/denoland/deno/pull/22072. I added a relevant test so we don't regress again. Fixes https://github.com/denoland/deno/issues/22115
2024-01-24revert: Remove deprecations of file sync APIs (#22085)Bartek Iwańczuk
- `Deno.FsFile.dataSync` -> `Deno.FsFile.syncData` - `Deno.FsFile.dataSyncSync` -> `Deno.FsFile.syncDataSync` Also marks these APIs as unstable
2024-01-24feat: `FsFile.sync()` and `FsFile.syncSync()` (#22017)Asher Gomez
This change: 1. Implements `Deno.FsFile.sync()` and `Deno.FsFile.syncSync()`. 2. Deprecates `Deno.fsync()` and `Deno.fsyncSync()` for removal in Deno v2, in favour of the above corresponding methods. Related #21995 --------- Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2024-01-24feat: `Deno.FsFile.dataSync()` and `Deno.FsFile.dataSyncSync()` (#22019)Asher Gomez
This change: 1. Implements `Deno.FsFile.dataSync()` and `Deno.FsFile.dataSyncSync()`. 2. Deprecates `Deno.fdatasync()` and `Deno.fdatasyncSync()` for removal in Deno v2, in favour of the above corresponding methods. 3. Replaces use of `Deno.fdatasync()` and `Deno.fdatasyncSync()` with the above instance methods. Related #21995
2024-01-22chore: use `FsFile[Symbol.dispose]()` (#22007)Asher Gomez
This change takes advantage of explicit resources management for `FsFile` instances and tweaks documentation to encourage the use of it. --------- Signed-off-by: Asher Gomez <ashersaupingomez@gmail.com>
2024-01-01chore: update copyright to 2024 (#21753)David Sherret
2023-11-01feat: disposable Deno resources (#20845)Luca Casonato
This commit implements Symbol.dispose and Symbol.asyncDispose for the relevant resources. Closes #20839 --------- Signed-off-by: Bartek Iwańczuk <biwanczuk@gmail.com> Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2023-03-21feat: TypeScript 5.0.2 (except decorators) (#18294)David Sherret
This upgrades TypeScript to 5.0.2, but does not have ES decorator support because swc does not support that yet.
2023-01-19feat(runtime): add bigint to seek typings (#17314)Leo Kettmeir
2023-01-15chore: update std submodule and its imports (#17408)Asher Gomez
2023-01-02chore: update copyright year to 2023 (#17247)David Sherret
Yearly tradition of creating extra noise in git.
2022-10-17chore: upgrade internal deno_std to 0.160 (#16333)David Sherret
2022-09-19refactor: move out test files from root testdata directory into sub ↵David Sherret
directories (#15949)
2022-07-13chore: remove flaky writeSyncWhileAsyncFails test (#15194)David Sherret
2022-07-13fix(cli): synchronize async stdio/file reads and writes (#15092)David Sherret
Fixes a regression where async writes and reads could get out of order.
2022-05-01fix(runtime): lossy utf8 readTextFile (#14456)Aaron O'Mullan
2022-02-15feat(runtime): web streams in fs & net APIs (#13615)Luca Casonato
This commit adds `readable` and `writable` properties to `Deno.File` and `Deno.Conn`. This makes it very simple to use files and network sockets with fetch or the native HTTP server.
2022-01-20chore: update copyright year (#13434)Yoshiya Hinosawa
2021-11-23refactor: remove "unitTest" wrapper from cli/tests/unit (#12750)Bartek Iwańczuk
2021-10-11feat(runtime): improve error messages of runtime fs (#11984)Feng Yu
This commit annotates errors returned from FS Deno APIs to include paths that were passed to the API calls. Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2021-09-23test(cli): align unit test permissions with runtime test permissions (#12189)Casper Beyer
2021-09-22chore: replace calls to assertThrowsAsync with assertRejects (#12176)Casper Beyer
2021-08-11chore: move test files to testdata directory (#11601)David Sherret
2021-08-05refactor(cli/tests): remove unnecessary void return types (#11577)Leo K
2021-07-12chore(runtime): deprecate `Deno.copy` (#11369)Luca Casonato
2021-04-09chore: upgrade dependencies (#10094)Bartek Iwańczuk
This commit upgrades: - swc_ecmascript - swc_bundler - deno_doc - deno_lint - dprint-plugin-typescript
2021-01-17chore: Enforce ban-untagged-todo lint rule (#9135)Bartek Iwańczuk
2021-01-11chore: update copyright to 2021 (#9092)Yusuke Tanaka
2020-11-03build: migrate to dlint (#8176)Bartek Iwańczuk
This commit migrates repository from using "eslint" to "dlint" for linting JavaScript code.
2020-09-27feat(fmt): Sort named import and export specifiers (#7711)David Sherret
2020-07-22test(cli/unit): remove rogue console.log statement (#6846)Casper Beyer
2020-07-14Use dprint for internal formatting (#6682)David Sherret
2020-06-25refactor(cli/tests/unit) to use assertThrows (#6459)Casper Beyer
2020-06-11feat: URL support in Deno filesystem methods (#5990)River
2020-06-05Rename abbreviated assertions in std/testing (#6118)Casper Beyer
2020-06-02fix: Better use of @ts-expect-error (#6038)Kitson Kelly
2020-05-26Use ts-expect-error instead of ts-ignore. (#5869)Kitson Kelly
2020-05-20move js unit tests to cli/tests (#5678)Ryan Dahl