Fixed support for filenames which have spaces in them.
Added tests for spaced filenames Issue #3