Fix test case on windows

This changes the code to make more use of Qt
to handle filepaths on several platforms. We should
also change the API to only accept QDir, QFileInfo
in the future
fix purge tracks on windows

Again we should change the API here to accept
QDir instead of a QString.