Change ApplicationFactory to Factory