[fix] test_shopping_cart.py
diff --git a/erpnext/shopping_cart/cart.py b/erpnext/shopping_cart/cart.py
index 963514e..a51f6f3 100644
--- a/erpnext/shopping_cart/cart.py
+++ b/erpnext/shopping_cart/cart.py
@@ -368,7 +368,8 @@
 		return debtors_account_name
 
 
-def get_address_docs(doctype=None, txt=None, filters=None, limit_start=0, limit_page_length=20, party=None):
+def get_address_docs(doctype=None, txt=None, filters=None, limit_start=0, limit_page_length=20,
+	party=None):
 	if not party:
 		party = get_party()
 
@@ -380,8 +381,8 @@
 
 	out = []
 
-	for address_name in address_names:
-		address = frappe.get_doc('Address', address_name)
+	for a in address_names:
+		address = frappe.get_doc('Address', a.parent)
 		address.display = get_address_display(address.as_dict())
 		out.append(address)
 
diff --git a/erpnext/shopping_cart/test_shopping_cart.py b/erpnext/shopping_cart/test_shopping_cart.py
index 314e1a4..f221a8a 100644
--- a/erpnext/shopping_cart/test_shopping_cart.py
+++ b/erpnext/shopping_cart/test_shopping_cart.py
@@ -14,6 +14,7 @@
 	"""
 	def setUp(self):
 		frappe.set_user("Administrator")
+		create_test_contact_and_address()
 		self.enable_shopping_cart()
 
 	def tearDown(self):
@@ -185,7 +186,6 @@
 		frappe.set_user("test_cart_user@example.com")
 
 	def login_as_customer(self):
-		create_test_contact_and_address()
 		self.create_user_if_not_exists("test_contact_customer@example.com",
 			"_Test Contact For _Test Customer")
 		frappe.set_user("test_contact_customer@example.com")