diff --git a/lib/extension/otaUpdate.js b/lib/extension/otaUpdate.js index 82baaa50..8976f4ca 100644 --- a/lib/extension/otaUpdate.js +++ b/lib/extension/otaUpdate.js @@ -200,7 +200,7 @@ class OTAUpdate extends Extension { const onProgress = (progress, remaining) => { let msg = `Update of '${resolvedEntity.name}' at ${progress.toFixed(2)}%`; if (remaining) { - msg += `, +- ${Math.round(remaining / 60)} minutes remaining`; + msg += `, ≈ ${Math.round(remaining / 60)} minutes remaining`; } logger.info(msg); diff --git a/test/otaUpdate.test.js b/test/otaUpdate.test.js index dcda99f2..8e9fc459 100644 --- a/test/otaUpdate.test.js +++ b/test/otaUpdate.test.js @@ -51,7 +51,7 @@ describe('OTA update', () => { expect(mapped.ota.updateToLatest).toHaveBeenCalledTimes(1); expect(mapped.ota.updateToLatest).toHaveBeenCalledWith(device, logger, expect.any(Function)); expect(logger.info).toHaveBeenCalledWith(`Update of 'bulb' at 0.00%`); - expect(logger.info).toHaveBeenCalledWith(`Update of 'bulb' at 10.00%, +- 60 minutes remaining`); + expect(logger.info).toHaveBeenCalledWith(`Update of 'bulb' at 10.00%, ≈ 60 minutes remaining`); expect(logger.info).toHaveBeenCalledWith(`Finished update of 'bulb', from '{"dateCode":"20190101","softwareBuildID":1}' to '{"dateCode":"20190102","softwareBuildID":2}'`); expect(device.save).toHaveBeenCalledTimes(1); expect(device.dateCode).toBe('20190102'); @@ -310,7 +310,7 @@ describe('OTA update', () => { expect(mapped.ota.updateToLatest).toHaveBeenCalledTimes(1); expect(mapped.ota.updateToLatest).toHaveBeenCalledWith(device, logger, expect.any(Function)); expect(logger.info).toHaveBeenCalledWith(`Update of 'bulb' at 0.00%`); - expect(logger.info).toHaveBeenCalledWith(`Update of 'bulb' at 10.00%, +- 60 minutes remaining`); + expect(logger.info).toHaveBeenCalledWith(`Update of 'bulb' at 10.00%, ≈ 60 minutes remaining`); expect(logger.info).toHaveBeenCalledWith(`Finished update of 'bulb', from '{"dateCode":"20190101","softwareBuildID":1}' to '{"dateCode":"20190102","softwareBuildID":2}'`); expect(logger.error).toHaveBeenCalledTimes(0); expect(device.save).toHaveBeenCalledTimes(1);