Commit e3cba458 authored by Lucas Carvalho's avatar Lucas Carvalho

Added new test for WebSite_getProductList

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@28810 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 43684d40
......@@ -994,6 +994,25 @@ class TestCommerce(ERP5TypeTestCase):
shipping.setBasePrice(10.0)
def test_23_getProductListFromWebSite(self, quiet=0, run=run_all_test):
"""
Test the WebSite_getProductList script.
"""
if not run:
return
if not quiet:
message = '\nTest the script WebSite_getProductList.'
ZopeTestCase._print(message)
LOG('Testing... ', 0, message)
portal = self.getPortal()
web_site = self.setupWebSite()
transaction.commit()
self.tic()
self.assertEquals(5, len(web_site.WebSite_getProductList()))
self.assertEquals(13, len(web_site.WebSite_getProductList(limit=1000)))
import unittest
def test_suite():
suite = unittest.TestSuite()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment