Node.js core uses error-first callbacks: (err, result) => void.
Implement promisify(fn) that wraps such a function to return a Promise.
promisify(fn)(...args) should:
result if the callback is called with (null, result).error if the callback is called with (err).solve drives your implementation through a series of test cases
and returns whether each resolved or rejected.
Sample tests