Commit 423f24ad authored by Jérome Perrin's avatar Jérome Perrin

performance_test,simplified_invoicing: don't depend on pystone

this is removed from python3, it was not so useful here either
parent b6d67c58
...@@ -25,11 +25,7 @@ ...@@ -25,11 +25,7 @@
# #
############################################################################## ##############################################################################
from __future__ import print_function
from test import pystone
from time import time from time import time
from six.moves import range
pystone.clock = time
from erp5.component.test.testPerformance import TestPerformanceMixin from erp5.component.test.testPerformance import TestPerformanceMixin
from Products.ERP5Type.Core.Workflow import ValidationFailed from Products.ERP5Type.Core.Workflow import ValidationFailed
from Testing import ZopeTestCase from Testing import ZopeTestCase
...@@ -73,8 +69,6 @@ class TestWorkflowPerformance(TestPerformanceMixin): ...@@ -73,8 +69,6 @@ class TestWorkflowPerformance(TestPerformanceMixin):
foo.getSimulationState() foo.getSimulationState()
end = time() end = time()
print("\n%s pystones/second" % pystone.pystones()[1])
message = "\n%s took %.4gs (%s foo(s))" % (self._testMethodName, message = "\n%s took %.4gs (%s foo(s))" % (self._testMethodName,
end - start, foo_count) end - start, foo_count)
print(message) print(message)
......
...@@ -28,10 +28,7 @@ ...@@ -28,10 +28,7 @@
from __future__ import print_function from __future__ import print_function
import subprocess import subprocess
import unittest import unittest
from test import pystone
from time import time from time import time
from six.moves import range
pystone.clock = time
from Products.ERP5Type.tests.runUnitTest import ERP5TypeTestLoader from Products.ERP5Type.tests.runUnitTest import ERP5TypeTestLoader
from erp5.component.test.testTradeModelLine import TestTradeModelLineSale from erp5.component.test.testTradeModelLine import TestTradeModelLineSale
...@@ -59,7 +56,6 @@ class TestSimulationPerformance(TestTradeModelLineSale): ...@@ -59,7 +56,6 @@ class TestSimulationPerformance(TestTradeModelLineSale):
self.test_01_OrderWithSimpleTaxedAndDiscountedLines() self.test_01_OrderWithSimpleTaxedAndDiscountedLines()
self.__class__._order = self['order'].getRelativeUrl() self.__class__._order = self['order'].getRelativeUrl()
self.runAlarms() self.runAlarms()
print("\n%s pystones/second" % pystone.pystones()[1])
def perf_01_invoiceSimpleOrder(self, order_count=1): def perf_01_invoiceSimpleOrder(self, order_count=1):
start = time() start = time()
......
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