summaryrefslogtreecommitdiff
path: root/framework/test/opencv.py
AgeCommit message (Collapse)AuthorFilesLines
2022-05-09Make it work with the latest pytest versionCorentin Noël1-1/+1
Fix all deprecation warnings. Remove testing for python 3.6. Signed-off-by: Corentin Noël <corentin.noel@collabora.com> Reviewed-by: Emma Anholt <emma@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/piglit/-/merge_requests/626>
2020-02-13drop python2 supportDylan Baker1-4/+1
This removes all of the python code for handling python 2.x vs 3.x, now only 3.6+ is supported. This also drops all uses of the six module, as its no longer needed. Python 2.x and <= 3.5 are all EOL, it doesn't make sense to continue to support version of python that are at the end of their lives and are being removed from operating systems. Acked-by: Eric Engestrom <eric@engestrom.ch> Part-of: <https://gitlab.freedesktop.org/mesa/piglit/merge_requests/223>
2018-11-08python: add explicit utf-8 encodingEric Engestrom1-0/+1
I went with `# coding=utf-8` as it was the most common format in the existing code: 24 # coding=utf-8 21 ## coding=utf-8 19 # encoding=utf-8 9 ## encoding=utf-8 6 # -*- coding: utf-8 -*- I added it as the first line after the shebang, if any. Suggested-by: Dylan Baker <dylan@pnwbakers.com> Signed-off-by: Eric Engestrom <eric@engestrom.ch> Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
2016-02-10framework/test/{opencv,oclconform}: fix subprocess returning bytesDylan Baker1-1/+2
During the hybridization this little bit was missed, causing the to subprocess to return bytes, while the rest of the code expected unicode. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com> Tested-by: Tom Stellard <thomas.stellard@amd.com>
2016-02-08framework,unittests: use __future__ unicode_literalsDylan Baker1-1/+4
Use unicode_literals from __future__. This makes undecorated strings (those not using and b or u prefix) into unicode instead of bytes in python 2. This means that bytes strings need to have a b prefix now. This also fixes a couple of unittests that broke during the transition. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com> Acked-by: Jose Fonseca <jfonseca@vmware.com>
2016-02-08python: use future print, division, and absolute_importDylan Baker1-1/+1
These are the three python3 like behaviors that piglit should rely on. The only other applicable future import is unicode_literals. Although my plan is to use unicode_literals, that will actually cause behavioral changes in some cases, where these cause minimal changes to the code. Piglit will not be targeting < 3.2, they are old, unsupported, and have fewer features than 2.7. Piglit now has division (using / as floating division, and // as integer division), print as a function (rather than a statement), and absolute import, which changes the way import works when there's a conflict between a local import and a system wide one. Absolute import makes more sense, and copies the behavior of python 3 Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com> Acked-by: Jose Fonseca <jfonseca@vmware.com>
2015-03-05framework: Override run_concurrent for CL test classesDylan Baker1-1/+2
This patch changes where the OpenCL tests get their run_concurrent flag from. After this patch it is computed automatically, leaving no need to set the flag manually unless one wants to force a non default behavior for their platform. v2: - fix some formatting XXX: This assumes Thomas Stellard's "opencv: Automatically run tests concurrently..." patch Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2015-03-05opencv.py: use test_list instead of tests.Dylan Baker1-2/+2
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2014-12-24framework: Cleanup importsDylan Baker1-1/+1
Makes 2 changes, all of which should have absolutely zero effect 1) breaks the imports into three newline separated groups: builtins, installed modules, local modules 2) use print_function and absolute_import in all modules. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2014-12-12opencv.py: use grouptools moduleDylan Baker1-1/+3
Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>
2014-10-14framework: Move tests derived classes into a packageDylan Baker1-0/+81
This moves all of the classes that derive from Test into a package called test. This patch looks very large, but is mostly just moving files around and changing imports to account for this. So why all of this code churn? The big advantage is that through __init__.py magic there is one module to be imported, framework.test. This module contains all of the public classes, functions, and constants, in one place while hiding the rest, but allowing them to be accessed explicitly. Signed-off-by: Dylan Baker <dylanx.c.baker@intel.com>