From 3f305346f3793ec3a2f26346fb5194123a93eb07 Mon Sep 17 00:00:00 2001
From: Fabien Morin <fabien@nexedi.com>
Date: Thu, 18 Feb 2010 14:39:23 +0000
Subject: [PATCH] all proxified listboxes (near all now) were not tested !

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@32790 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 product/ERP5/tests/testXHTML.py | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/product/ERP5/tests/testXHTML.py b/product/ERP5/tests/testXHTML.py
index fa4f8892f8..6ba9719188 100644
--- a/product/ERP5/tests/testXHTML.py
+++ b/product/ERP5/tests/testXHTML.py
@@ -210,7 +210,8 @@ class TestXHTML(ERP5TypeTestCase):
     for form_path, form in skins_tool.ZopeFind(
               skins_tool, obj_metatypes=['ERP5 Form'], search_sub=1):
       for field in self.getFieldList(form, form_path):
-        if field.meta_type =='ListBox':
+        if field.meta_type == 'ListBox' or field.meta_type == 'ProxyField' and\
+            field.getRecursiveTemplateField().meta_type == 'ListBox':
           selection_name = field.get_value("selection_name")
           if selection_name in ("",None):
             error_list.append(form_path)
@@ -223,7 +224,8 @@ class TestXHTML(ERP5TypeTestCase):
     for form_path, form in skins_tool.ZopeFind(
               skins_tool, obj_metatypes=['ERP5 Form'], search_sub=1):
       for field in self.getFieldList(form, form_path):
-        if field.meta_type == 'ListBox':
+        if field.meta_type == 'ListBox' or field.meta_type == 'ProxyField' and\
+            field.getRecursiveTemplateField().meta_type == 'ListBox':
           list_method = field.get_value("list_method")
           if list_method:
             if isinstance(list_method, str):
-- 
2.30.9