add factory test