For firmware development I’ve done automated testing with the hardware on a fixture connected to JTAG, uart, and DAQ. It worked pretty well but every once in a while I’d have to press a button or something that the fixture couldn’t.
Testing firmware is not the same as testing hardware.