Fixing factory bugs found while adding tests
Adding tests for DmFileman factories