Use factory instance instead of mock since factory is now final