Fix unit tests

This commit is contained in:
Franck Chastagnol
2020-06-07 23:21:07 -07:00
parent 4c0a06fc36
commit 2498bf5560
2 changed files with 6 additions and 6 deletions

View File

@@ -70,9 +70,9 @@ def _get_origin_shop_products(receipt_log, listing_id, ipfs_client, shop_ipfs_ha
result.description = product.get('description', '')
result.price = product.get('price', '')
result.currency = product.get('currency', 'fiat-USD')
result.option1 = ''
result.option2 = ''
result.option3 = ''
result.option1 = None
result.option2 = None
result.option3 = None
result.image = product.get('image', '')
results.append(result)

View File

@@ -1,3 +1,3 @@
{"block_number": 10014847, "log_index": 31, "listing_id": "1-001-2065", "product_id": "1-001-2065-victory-soap", "ipfs_path": "Qmcs4ixnxihovGs4oQxdj9KGR9P1T6Gxb1QB111GZAzdvp/victory-soap/victory-soap", "external_id": "", "parent_external_id": "", "title": "Victory Soap", "description": "In World War II, “Victory Gardens” were a grassroots effort supporting food needs at home while canned goods went to support the troops on the front lines.", "price": 1200, "option2": "", "option3": "", "image": "soapy-fight-covid.png"}
{"block_number": 10014847, "log_index": 31, "listing_id": "1-001-2065", "product_id": "1-001-2065-0", "ipfs_path": "Qmcs4ixnxihovGs4oQxdj9KGR9P1T6Gxb1QB111GZAzdvp/victory-soap/victory-soap", "external_id": "", "parent_external_id": "", "title": "3 pack", "description": "In World War II, “Victory Gardens” were a grassroots effort supporting food needs at home while canned goods went to support the troops on the front lines.", "price": 3000, "option2": null, "option3": null, "image": "soapy-fight-covid.png"}
{"block_number": 10014847, "log_index": 31, "listing_id": "1-001-2065", "product_id": "1-001-2065-1", "ipfs_path": "Qmcs4ixnxihovGs4oQxdj9KGR9P1T6Gxb1QB111GZAzdvp/victory-soap/victory-soap", "external_id": "", "parent_external_id": "", "title": "1 bar", "description": "In World War II, “Victory Gardens” were a grassroots effort supporting food needs at home while canned goods went to support the troops on the front lines.", "price": 1200, "option2": null, "option3": null, "image": "soapy-fight-covid.png"}
{"block_number": 10014847, "log_index": 31, "listing_id": "1-001-2065", "product_id": "1-001-2065-victory-soap", "ipfs_path": "Qmcs4ixnxihovGs4oQxdj9KGR9P1T6Gxb1QB111GZAzdvp/victory-soap/victory-soap", "external_id": "", "parent_external_id": "", "title": "Victory Soap", "description": "In World War II, “Victory Gardens” were a grassroots effort supporting food needs at home while canned goods went to support the troops on the front lines.", "price": 1200, "currency": "fiat-USD", "option1": null, "option2": null, "option3": null, "image": "soapy-fight-covid.png"}
{"block_number": 10014847, "log_index": 31, "listing_id": "1-001-2065", "product_id": "1-001-2065-0", "ipfs_path": "Qmcs4ixnxihovGs4oQxdj9KGR9P1T6Gxb1QB111GZAzdvp/victory-soap/victory-soap", "external_id": "", "parent_external_id": "", "title": "3 pack", "description": "In World War II, “Victory Gardens” were a grassroots effort supporting food needs at home while canned goods went to support the troops on the front lines.", "price": 3000, "currency": "fiat-USD", "option1": "3 pack", "option2": null, "option3": null, "image": "soapy-fight-covid.png"}
{"block_number": 10014847, "log_index": 31, "listing_id": "1-001-2065", "product_id": "1-001-2065-1", "ipfs_path": "Qmcs4ixnxihovGs4oQxdj9KGR9P1T6Gxb1QB111GZAzdvp/victory-soap/victory-soap", "external_id": "", "parent_external_id": "", "title": "1 bar", "description": "In World War II, “Victory Gardens” were a grassroots effort supporting food needs at home while canned goods went to support the troops on the front lines.", "price": 1200, "currency": "fiat-USD", "option1": "1 bar", "option2": null, "option3": null, "image": "soapy-fight-covid.png"}