Commit dc76f38d authored by Jérome Perrin's avatar Jérome Perrin

fix undefined names


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@17242 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 9891c0fa
...@@ -28,7 +28,8 @@ ...@@ -28,7 +28,8 @@
# #
############################################################################## ##############################################################################
import os, sys, cStringIO, zipfile import unittest
import os, cStringIO, zipfile
from xml.dom.minidom import parseString from xml.dom.minidom import parseString
from Testing import ZopeTestCase from Testing import ZopeTestCase
from DateTime import DateTime from DateTime import DateTime
...@@ -40,13 +41,6 @@ from Products.ERP5OOo.Document.OOoDocument import ConversionError ...@@ -40,13 +41,6 @@ from Products.ERP5OOo.Document.OOoDocument import ConversionError
from Products.ERP5.Document.File import _unpackData from Products.ERP5.Document.File import _unpackData
from zLOG import LOG, INFO, ERROR from zLOG import LOG, INFO, ERROR
if __name__ == '__main__':
execfile(os.path.join(sys.path[0], 'framework.py'))
# Needed in order to have a log file inside the current folder
os.environ['EVENT_LOG_FILE'] = os.path.join(os.getcwd(), 'zLOG.log')
os.environ['EVENT_LOG_SEVERITY'] = '-300'
# Define the conversion server host # Define the conversion server host
conversion_server_host = ('127.0.0.1', 8008) conversion_server_host = ('127.0.0.1', 8008)
...@@ -1183,17 +1177,14 @@ class TestIngestion(ERP5TypeTestCase): ...@@ -1183,17 +1177,14 @@ class TestIngestion(ERP5TypeTestCase):
] ]
self.playSequence(step_list, quiet) self.playSequence(step_list, quiet)
if __name__ == '__main__':
framework()
else:
import unittest
def test_suite():
suite = unittest.TestSuite()
suite.addTest(unittest.makeSuite(TestIngestion))
return suite
# Missing tests # Missing tests
""" """
property_dict = context.getPropertyDictFromUserLogin() property_dict = context.getPropertyDictFromUserLogin()
property_dict = context.getPropertyDictFromInput() property_dict = context.getPropertyDictFromInput()
""" """
def test_suite():
suite = unittest.TestSuite()
suite.addTest(unittest.makeSuite(TestIngestion))
return suite
...@@ -45,12 +45,6 @@ from Products.ERP5Type.Cache import clearCache ...@@ -45,12 +45,6 @@ from Products.ERP5Type.Cache import clearCache
from Products.ERP5OOo.Document.OOoDocument import ConversionError from Products.ERP5OOo.Document.OOoDocument import ConversionError
if __name__ == '__main__':
execfile(os.path.join(sys.path[0], 'framework.py'))
# Needed in order to have a log file inside the current folder
os.environ['EVENT_LOG_FILE'] = os.path.join(os.getcwd(), 'zLOG.log')
os.environ['EVENT_LOG_SEVERITY'] = '-300'
ooodoc_coordinates = ('127.0.0.1', 8008) ooodoc_coordinates = ('127.0.0.1', 8008)
...@@ -793,11 +787,8 @@ class TestIngestion(ERP5TypeTestCase): ...@@ -793,11 +787,8 @@ class TestIngestion(ERP5TypeTestCase):
""" """
if __name__ == '__main__': import unittest
framework() def test_suite():
else:
import unittest
def test_suite():
suite = unittest.TestSuite() suite = unittest.TestSuite()
suite.addTest(unittest.makeSuite(TestIngestion)) suite.addTest(unittest.makeSuite(TestIngestion))
return suite return suite
......
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