pino-arborsculpture icon indicating copy to clipboard operation
pino-arborsculpture copied to clipboard

Missing delimiter in default path

Open dirk-ecker opened this issue 4 years ago • 3 comments

const defaultOptions = { path: os.tmpdir() + 'aborsculpt.json', interval: 60000, loggers: []

path gets '/tmpaborsculpt.json' and I think you want '/tmp/aborsculpt.json'

dirk-ecker avatar Jan 27 '21 08:01 dirk-ecker

Would you like to send a Pull Request to address this issue? Remember to add unit tests.

mcollina avatar Jan 27 '21 09:01 mcollina

For this to test I have to get access to the internals of the constructor. This seems not possible without rewriting the tool, or am I wrong. Or do you suggest to check for the existence of the file in the temp directory?

dirk-ecker avatar Jan 27 '21 14:01 dirk-ecker

The tests already look for files in /tmp. I am certain there is a lot of room for improvement in them, but following the current pattern should be sufficient.

jsumners avatar Jan 27 '21 14:01 jsumners