in reply to How to re-print multiple lines?

Maybe you can live with the following format:

File: XXX Passed: 30 Failed: 2
Now you only have the last line to write over.

Just make sure that you pad the numbers with spaces so that they are always the same length, this will avoid shifting text.