From: Dylan Baker <baker.dyla...@gmail.com>

In python 2 < 2.6, generators define a next() method. In python 2.6+
(including 2.7) they should define a __next__ method and are called with
the next() function.

In python 2.6 and 2.7 both are supported, but in 3.x only the __next__
method is supported

Signed-off-by: Dylan Baker <dylanx.c.ba...@intel.com>
---
 framework/log.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/framework/log.py b/framework/log.py
index cd6cdc5..213b04f 100644
--- a/framework/log.py
+++ b/framework/log.py
@@ -121,7 +121,7 @@ class QuietLog(BaseLog):
         else:
             self._endcode = '\n'
 
-        self.__counter = self._test_counter.next()
+        self.__counter = next(self._test_counter)
         self._state['running'].append(self.__counter)
 
     def start(self, name):
-- 
2.7.0

_______________________________________________
Piglit mailing list
Piglit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/piglit

Reply via email to