diff options
author | Sylvain Pineau <sylvain.pineau@canonical.com> | 2015-04-07 17:47:25 +0200 |
---|---|---|
committer | Sylvain Pineau <sylvain.pineau@canonical.com> | 2015-04-07 17:47:25 +0200 |
commit | 25dd3cbd15b1d352f3b5d4d483cb02c4df2ea148 (patch) | |
tree | eb02818388ea4eeaf19c5e1a43abf7630e08b494 | |
parent | 9f8dc8d1c2cb9cc6ee2991bc48ec232bfefa9fef (diff) |
providers:checkbox: Remove the old GLOBS benchmark
Rationale: - python2.x only - last SVN version 0.2 in 2007 - unused in all known test plans
-rwxr-xr-x | bin/glob_test | 121 | ||||
-rw-r--r-- | jobs/benchmarks.txt.in | 9 |
2 files changed, 0 insertions, 130 deletions
diff --git a/bin/glob_test b/bin/glob_test deleted file mode 100755 index df13e0f..0000000 --- a/bin/glob_test +++ /dev/null @@ -1,121 +0,0 @@ -#!/usr/bin/python -from Globs import benchmarks, hwd -import argparse -import locale -import logging -import sys -import os - -#Magic to override the _ function from gettext, since -#it's overkill for our needs here. -def underscore(string, *args, **kwargs): - return(string) - -__builtins__._ = underscore - -class Application: - - def __init__(self, share_dir='', bench_dir='', width=800, height=600, - time=5, repetitions=1, fullscreen=False, min_fps=60, - ignore_problems=False): - self.opts= {} - self.opts['width'] = width - self.opts['height'] = height - self.opts['time'] = time - self.opts['repetitions'] = repetitions - self.opts['fullscreen'] = fullscreen - self.min_fps = min_fps - self.ignore_problems = ignore_problems - - self.share_dir = share_dir - self.bench_dir = bench_dir - - - def run(self): - test_pass = True - - self.hwd = hwd.HWDetect() - self.bm = benchmarks.Benchmarks(os.path.join(self.bench_dir, - 'benchmarks')) - ver_str = self.hwd.get_gl_info()['version'] - hwd_ext = self.hwd.get_gl_info()['extensions'] - bench_list = [name for name in self.bm.get_names() if name != 'Fake'] - for benchmark_name in bench_list : - runnable = True - if self.bm.check_ver(benchmark_name, ver_str) == False: - logging.warning("%s requires OpenGL version %s, I have %s", - benchmark_name, - self.bm.get_info(benchmark_name)['glversion'], - ver_str) - runnable = False - test_pass = False - - ext_list = self.bm.check_ext(benchmark_name, hwd_ext) - if ext_list.__class__ == list: # Returned a list of missing exts - missing_ext = '' - for ext in ext_list: - missing_ext += ext - if ext_list.index(ext) != len(ext_list) - 1: - missing_ext += ', ' - logging.warning("Missing extensions: %s",missing_ext) - runnable = False - test_pass = False - if runnable: - fps = self.bm.run(benchmark_name, self.opts) - if fps is None: - #oops, test failed to produce usable result! - print("Test failed to produce FPS measurement.") - print("Possible causes: OpenGL version too low/high") - if self.ignore_problems: - print("Ignoring this as requested") - else: - print("Considering this a FAIL test") - test_pass = False - else: - print("{} {} fps".format(benchmark_name, fps)) - if ( self.min_fps > fps): - print("(Failed to meet minimum {} FPS)".format( - self.min_fps)) - test_pass = False - return test_pass - - - - -share_dir = '/usr/share/globs' -locale_dir = '/usr/share/locale' -bench_dir = '/usr/lib/globs' - -parser = argparse.ArgumentParser("Executes gl benchmarks non-interactively") -parser.add_argument("--width", action='store', - default=800, type=int) -parser.add_argument("--height", action='store', - default=600, type=int) -parser.add_argument("--repetitions", action='store', - default=1, type=int) -parser.add_argument("--time", action='store', - default=10, type=int) -parser.add_argument("--ignore-problems", action='store_true', - default=False, help=("If a test fails to " - "produce a FPS rating, ignore it for global test " - "outcome purposes")) -parser.add_argument("--fullscreen", action='store_true', - default=False) -parser.add_argument("--min-fps", action='store', - default=60.0, type=float, help=("If any of the benchmarks" - "obtains less than this FPS, the test will be considered" - "failed")) - -args = parser.parse_args() - -app = Application(share_dir, bench_dir, args.width, args.height, - args.time, args.repetitions, args.fullscreen, args.min_fps, - args.ignore_problems) - -if app.run(): - print("PASS") - sys.exit(0) -else: - print("FAIL") - sys.exit(1) - diff --git a/jobs/benchmarks.txt.in b/jobs/benchmarks.txt.in index 3550261..d4abcbe 100644 --- a/jobs/benchmarks.txt.in +++ b/jobs/benchmarks.txt.in @@ -96,15 +96,6 @@ estimated_duration: 306.000 _description: Run GLmark2 benchmark plugin: shell -id: benchmarks/graphics/globs -requires: - package.name == 'globs' - cpuinfo.platform in ("i386", "x86_64") -command: glob_test --min-fps=26 --ignore-problems -estimated_duration: 53.500 -_description: Run globs benchmark - -plugin: shell id: benchmarks/graphics/unigine-sanctuary requires: package.name == 'phoronix-test-suite' command: pts_run unigine-sanctuary |