The tmp package with promises support and disposers.
93
Error handling and propagation
Promise rejection handling
100%
100%
Cleanup function usage
96%
40%
withFile disposer pattern
0%
96%
Error propagation
66%
60%
Retry and fallback
66%
93%
Temporary directory disposer pattern (withDir)
Uses withDir method
0%
100%
Accesses directory path
0%
100%
File operations in callback
0%
100%
Returns processed results
0%
100%
Error handling preservation
0%
100%
Asynchronous temporary file creation (file)
Uses file() method
100%
100%
Configures postfix option
100%
100%
Cleanup function usage
100%
100%
Error-safe cleanup
100%
100%
File path usage
100%
100%
Atomic file operations with name generation
Uses tmpName
0%
0%
Configures tmpName options
0%
66%
Writes to temp file
100%
100%
Atomic rename
100%
100%
Error handling cleanup
100%
100%
Promise-based approach
100%
50%
Graceful cleanup configuration (setGracefulCleanup)
setGracefulCleanup() invocation
100%
100%
Temporary file creation
100%
100%
Proper async handling
100%
100%
File path usage
100%
100%
Appropriate cleanup strategy
0%
50%
Synchronous name generation (tmpNameSync)
tmpNameSync usage
0%
100%
Prefix option
0%
100%
Postfix option
0%
100%
Template option
0%
100%
Multiple calls
0%
100%
Return values
50%
100%
Nested disposer patterns
Uses withDir
0%
100%
Uses withFile
0%
100%
Proper nesting
0%
100%
File in directory
66%
100%
No manual cleanup
0%
100%
Temporary name generation (tmpName)
Uses tmpName function
0%
100%
Passes directory option
40%
100%
Configures prefix option
66%
100%
Configures postfix option
66%
100%
Handles async operation
100%
100%
Security-sensitive temporary file handling
file() usage
100%
100%
mode option
100%
100%
cleanup function
100%
100%
withFile() usage
0%
100%
withFile callback
0%
100%
withFile mode
0%
100%
Credential writing
100%
100%
Permission and security control (mode)
Uses file() method
100%
100%
Sets mode 0600
100%
100%
Uses dir() method
100%
100%
Sets mode 0700
100%
100%
Returns cleanup function
100%
100%
Writes data correctly
100%
100%
Install with Tessl CLI
npx tessl i tessl/npm-tmp-promiseTable of Contents