Commit a79be675 authored by Romain Courteaud's avatar Romain Courteaud

Restore r35467: a field was missing.

The test is supposed to fail, as the proxy field cache does not check the skin
selection. A transaction commit was missing to reproduce the issue.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@35469 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 0dd93515
......@@ -35,6 +35,7 @@ from Products.Formulator.TALESField import TALESMethod
import transaction
import unittest
from lxml import etree
from Products.ERP5Type.tests.backportUnittest import expectedFailure
class TestProxyField(ERP5TypeTestCase):
"""
......@@ -144,6 +145,7 @@ class TestProxyField(ERP5TypeTestCase):
self.assertEquals('Generic Title', field.get_value('title'))
@expectedFailure
def testSkinSelectionTemplateField(self):
"""
Check that proxy field values are generated from the current skin selection
......@@ -155,6 +157,7 @@ class TestProxyField(ERP5TypeTestCase):
'Base_viewGeekFieldLibrary',
'View')
form = skin_folder._getOb('Base_viewGeekFieldLibrary', None)
form.manage_addField('my_title', 'Customized Title', 'StringField')
portal_skins.manage_addProduct['OFSP'].manage_addFolder('erp5_geek')
skin_folder = portal_skins._getOb('erp5_geek')
......@@ -192,6 +195,7 @@ class TestProxyField(ERP5TypeTestCase):
field = getattr(form, 'my_title')
field.manage_edit_xmlrpc(dict(
form_id='Base_viewGeekFieldLibrary', field_id='my_title'))
transaction.commit()
self.assertEquals(None, field.get_value('title'))
self.changeSkin('GenericView')
......
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