summaryrefslogtreecommitdiff
path: root/piglit-summary-html.py
diff options
context:
space:
mode:
authorDylan Baker <baker.dylan.c@gmail.com>2013-05-03 16:02:02 -0700
committerDylan Baker <baker.dylan.c@gmail.com>2013-05-31 14:11:21 -0700
commitfc25db9771b88a17c8f615d57bf47bd013efc4ca (patch)
tree7a6e64d942747dffac592179f4fa348d68c90b40 /piglit-summary-html.py
parent80f597632541ef2c178d2367602ca0e055526496 (diff)
HTML summary: Provides means to exclude generating test result files
This provides a switch and method for excluding the generation of the test result HTML files (those that live under <testrun name>/). This allows the user to trade some verbosity in the results for a significant increase in generation speed. A run of quick.tests with all options enabled takes ~5.5 seconds, with just pass and skip disabled it only takes ~2.5 seconds. This only becomes more significant as more testsruns are added the HTML page. V3: - Remove some bad comments - adds 'skip' to exclude list V4: - Renames --exclude-generation to --exclude-details Signed-off-by: Dylan Baker <baker.dylan.c@gmail.com> Reviewed-By: Aaron Watry <awatry@gmail.com> Reviewed-By: Kenneth Graunke <kenneth@whitecape.org>
Diffstat (limited to 'piglit-summary-html.py')
-rwxr-xr-xpiglit-summary-html.py17
1 files changed, 16 insertions, 1 deletions
diff --git a/piglit-summary-html.py b/piglit-summary-html.py
index 5ee10ec7d..65e6653a8 100755
--- a/piglit-summary-html.py
+++ b/piglit-summary-html.py
@@ -52,6 +52,17 @@ def main():
help = "Load a newline seperated list of results. "
"These results will be prepended to any "
"Results specified on the command line")
+ parser.add_argument("-e", "--exclude-details",
+ default = [],
+ action = "append",
+ choices = ['skip', 'pass', 'warn', 'crash' 'fail',
+ 'all'],
+ help = "Optionally exclude the generation of HTML"
+ "pages for individual test pages with the"
+ "status(es) given as arguments. This speeds"
+ "up HTML generation, but reduces the info"
+ "in the HTML pages. May be used multiple"
+ "times")
parser.add_argument("summaryDir",
metavar = "<Summary Directory>",
help = "Directory to put HTML files in")
@@ -65,6 +76,10 @@ def main():
if not args.list and not args.resultsFiles:
raise parser.error("Missing required option -l or <resultsFiles>")
+ # If exclude-results has all, then change it to be all
+ if 'all' in args.exclude_details:
+ args.exclude_details=['skip', 'pass', 'warn', 'crash', 'fail']
+
# if overwrite is requested delete the output directory
if path.exists(args.summaryDir) and args.overwrite:
shutil.rmtree(args.summaryDir)
@@ -78,7 +93,7 @@ def main():
# Create the HTML output
output = summary.NewSummary(args.resultsFiles)
- output.generateHTML(args.summaryDir)
+ output.generateHTML(args.summaryDir, args.exclude_details)
if __name__ == "__main__":