refine the engine loader order so that production mode and test mode works well