Add more testing for the factory and config