[Piglit] [PATCH 1/5] framework/backends/abstract.py: use next() instead of generator.next()
Dylan Baker
baker.dylan.c at gmail.com
Thu Jul 2 16:46:44 PDT 2015
Python2.7 supports both the legacy next method, and the future looking
next() function. We'd rather be future looking so use the next function.
Signed-off-by: Dylan Baker <dylanx.c.baker at intel.com>
---
framework/backends/abstract.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/framework/backends/abstract.py b/framework/backends/abstract.py
index 47186f2..9da2ef8 100644
--- a/framework/backends/abstract.py
+++ b/framework/backends/abstract.py
@@ -188,7 +188,7 @@ class FileBackend(Backend):
shutil.move(tfile, file_)
file_ = os.path.join(self._dest, 'tests', '{}.{}'.format(
- self.__counter.next(), self._file_extension))
+ next(self.__counter), self._file_extension))
with open(file_, 'w') as f:
self._write(f, name, self.__INCOMPLETE)
--
2.4.5
More information about the Piglit
mailing list