Additional unit-tests for #789

* tests whether files are created when the parent directory does not exists
* removes duplicate test case