Bug fixes and unit tests for directory class

Added vfsStream to composer.json to enable mocking of filesystem
Full set of unit tests for directory class
Bug fixes and new create() method for directory class