Fixed tests to run with new RepositoryFactory.
Fixed wrong class instantiation.
Added --purge-with-truncate command line option(issue #26).
Merge pull request #32 from lenardpalko/master

Fixed tests to run with new RepositoryFactory.