How can I get the time difference in hh:mm:ss format between two Date objects in JavaScript? [duplicate]

I have two date object and am trying to get the time difference in hh:mm:ss format. Everything I have seen trying to look it up only shows getting it in seconds like below. Is it possible to get it in the format that I want?

var test = new Date('2023-05-22 03:08:00')
var test1 = new Date('2023-05-22 01:00:00')

var result = (test.getTime() - test1.getTime()) / 1000