I'm confused about how this test could be passing.  The titlebar is never going to contain the literal string "{0}", is it?

All of these tests run in a popup window, and the tests pause until a project is loaded in that window -- see the beforeEach() call at the top of this file.  So there will be a test project loaded at this point, and I'd expect to see its folder name in the string here: "DocumentCommandHandlers-test-files - Brackets".  Is that not what you're seeing?