def test_build_list_of_named_documents_with_overrides(self): expected_list = [{ "first": "Bill", "last": "Jones", "prefs": { "receives_sms": False, "receives_email": True, "v": 4 }, "company_id": self.company_id, "email": "*****@*****.**", "age": 21, "created": "then", "favorite_color": "green", "v": 4 }, { "first": "Bill", "last": "Jones", "prefs": { "receives_sms": False, "receives_email": True, "v": 4 }, "company_id": self.company_id, "email": "*****@*****.**", "age": 22, "created": "then", "favorite_color": "green", "v": 4 }, { "first": "Bill", "last": "Jones", "prefs": { "receives_sms": False, "receives_email": True, "v": 4 }, "company_id": self.company_id, "email": "*****@*****.**", "age": 23, "created": "then", "favorite_color": "green", "v": 4 }] docs = build_list(3, "user", "admin", created="then", favorite_color="green") self.assertEquals(expected_list, docs)
def test_build_list_of_named_documents(self): expected_list = [{ "first": "Bill", "last": "Jones", "prefs": { "receives_sms": False, "receives_email": True, "v": 4 }, "company_id": self.company_id, "email": "*****@*****.**", "age": 21, "created": "now", "v": 4 }, { "first": "Bill", "last": "Jones", "prefs": { "receives_sms": False, "receives_email": True, "v": 4 }, "company_id": self.company_id, "email": "*****@*****.**", "age": 22, "created": "now", "v": 4 }, { "first": "Bill", "last": "Jones", "prefs": { "receives_sms": False, "receives_email": True, "v": 4 }, "company_id": self.company_id, "email": "*****@*****.**", "age": 23, "created": "now", "v": 4 }] docs = build_list(3, "user", "admin") self.assertEquals(expected_list, docs)
def test_build_list(self): expected_list = [{ "first": "John", "last": "Smith", "prefs": { "receives_sms": True, "receives_email": False, "v": 4 }, "company_id": self.company_id, "email": "*****@*****.**", "age": 21, "created": "now" }, { "first": "John", "last": "Smith", "prefs": { "receives_sms": True, "receives_email": False, "v": 4 }, "company_id": self.company_id, "email": "*****@*****.**", "age": 22, "created": "now" }, { "first": "John", "last": "Smith", "prefs": { "receives_sms": True, "receives_email": False, "v": 4 }, "company_id": self.company_id, "email": "*****@*****.**", "age": 23, "created": "now" }] docs = build_list(3, "user") self.assertEquals(expected_list, docs)
def test_build_list(self): expected_list = [{ "first": "John", "last": "Smith", "prefs": { "receives_sms": True, "receives_email": False }, "company_id": self.company_id, "email": "*****@*****.**", "age": 21 }, { "first": "John", "last": "Smith", "prefs": { "receives_sms": True, "receives_email": False }, "company_id": self.company_id, "email": "*****@*****.**", "age": 22 }, { "first": "John", "last": "Smith", "prefs": { "receives_sms": True, "receives_email": False }, "company_id": self.company_id, "email": "*****@*****.**", "age": 23 }] docs = build_list("user", 3) self.assertEquals(expected_list, docs)