-
Notifications
You must be signed in to change notification settings - Fork 662
feat(fs/unstable): add remove and removeSync api.
#6438
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #6438 +/- ##
==========================================
- Coverage 95.93% 95.85% -0.08%
==========================================
Files 568 569 +1
Lines 42586 42637 +51
Branches 6397 6400 +3
==========================================
+ Hits 40853 40869 +16
- Misses 1694 1729 +35
Partials 39 39 ☔ View full report in Codecov by Sentry. |
fs/unstable_remove_test.ts
Outdated
| await remove(tempDir); | ||
| const existedCheckAgain = await stat(tempDir); | ||
| assert(existedCheckAgain.isDirectory === false); | ||
| } catch { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needs to be finally. Currently this catches the error thrown from await stat(tempDir) and swallows it (The last assertion doesn't seem working).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated.
Thank you~
fs/unstable_remove_test.ts
Outdated
| await remove(tempDir); | ||
| const fsStat = await stat(tempDir); | ||
| assert(fsStat.isDirectory === false); | ||
| } catch { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto. This needs to be finally
| } catch { | |
| } finally { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated.
…no_std into feat/fs-unstable-remove-api * 'feat/fs-unstable-remove-api' of github.com:eryue0220/deno_std: test(fs/unstable): remove windows specific paths and fix ci (denoland#6448) BREAKING(tar/unstable): fix handling of mode, uid, and gid (denoland#6440)
…no_std into feat/fs-unstable-remove-api * 'feat/fs-unstable-remove-api' of github.com:eryue0220/deno_std: feat(fs/unstable): add umask (denoland#6454) feat(fs/unstable): add utime and utimeSync (denoland#6446)
|
It seems could not use |
kt3k
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Thanks!
The error was thrown from |
This pr is part of #6255, which aims to add
removeandremoveSyncapi.