# HG changeset patch # User Christian Kamm # Date 1218558814 -7200 # Node ID 70faa6af1357dac8095cf5c14d9cf41a49edcbb9 # Parent 8bd31c8208da10ea25f21741c58d495fa15e0109 Change web statistics layout, thanks anders! diff -r 8bd31c8208da -r 70faa6af1357 tests/makewebstatistics.d --- a/tests/makewebstatistics.d Tue Aug 12 00:20:04 2008 +0200 +++ b/tests/makewebstatistics.d Tue Aug 12 18:33:34 2008 +0200 @@ -377,73 +377,169 @@ BufferedFile index = new BufferedFile(std.path.join(basedir, "index.html"), FileMode.OutNew); scope(exit) index.close(); index.writefln(` - -

DStress results for x86-32 Linux.

-

- In short, results are defined as follows -

- while the differences between tests are grouped into - -

-

- - - - - - - - - - - - - - - - - - - + + + + DStress results for x86-32 Linux + + + + +

DStress results for x86-32 Linux

+ +

Legend

+
namePASSXFAILFAILXPASSERRORcomparison to ` ~ std.path.getBaseName(reference) ~ `
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ColorDescription
PASSTest passed and was expected to pass
XFAILTest failed and expected to fail
FAILTest failed but was expected to pass
XPASSTest passed but was expected to fail
ERRORThe compiler, linker or the test segfaulted
+Changes from FAIL, XPASS or ERROR to PASS or XFAIL
-Changes from PASS or XFAIL to FAIL, XPASS or ERROR
chgChanged within the good or bad group without crossing over
+ +

Results

+ + + + + + + + + + + + + + + + + + + + + `); for(int i = files.length - 1; i >= 0; --i) { auto file = files[i]; - index.writefln(``); + index.writefln(``); char[] id = std.path.getBaseName(file); char[] statsname = std.path.join(std.path.join(basedir, id), "stats.base"); index.writef(cast(char[])std.file.read(statsname)); + if(i != 0) { + char[] newid = std.path.getBaseName(files[i-1]); + statsname = std.path.join(std.path.join(basedir, newid ~ "-to-" ~ id), "stats.base"); + index.writef(cast(char[])std.file.read(statsname)); + } else { + index.writefln(``); + } + if(i != files.length - 1) { - index.writefln(``); } else { - index.writefln(``); + index.writefln(``); } - if(i == 0) { - continue; - } - - index.writefln(``); - index.writefln(``); + index.writefln(``); } index.writefln(`
Test resultsDiff to previousDiff to ` ~ std.path.getBaseName(reference) ~ `
NamePASSXFAILFAILXPASSERROR+-chg+-chg
`); char[] refid = std.path.getBaseName(reference); statsname = std.path.join(std.path.join(basedir, refid ~ "-to-" ~ id), "stats.base"); index.writef(cast(char[])std.file.read(statsname)); - index.writefln(`
`); - char[] newid = std.path.getBaseName(files[i-1]); - statsname = std.path.join(std.path.join(basedir, newid ~ "-to-" ~ id), "stats.base"); - index.writef(cast(char[])std.file.read(statsname)); - index.writefln(`
`); @@ -505,12 +601,12 @@ BufferedFile stats = new BufferedFile(std.path.join(dirname, "stats.base"), FileMode.OutNew); scope(exit) stats.close(); - stats.writefln(``, id, ``); - stats.writefln(``, log.counts[Result.PASS], ``); - stats.writefln(``, log.counts[Result.XFAIL], ``); - stats.writefln(``, log.counts[Result.FAIL], ``); - stats.writefln(``, log.counts[Result.XPASS], ``); - stats.writefln(``, log.counts[Result.ERROR], ``); + stats.writefln(``, id, ``); + stats.writefln(``, log.counts[Result.PASS], ``); + stats.writefln(``, log.counts[Result.XFAIL], ``); + stats.writefln(``, log.counts[Result.FAIL], ``); + stats.writefln(``, log.counts[Result.XPASS], ``); + stats.writefln(``, log.counts[Result.ERROR], ``); } void generateChangeStatistics(char[] file1, char[] file2, ref Log[char[]] logs) @@ -595,7 +691,7 @@ BufferedFile stats = new BufferedFile(std.path.join(dirname, "stats.base"), FileMode.OutNew); scope(exit) stats.close(); auto dir = oldid ~ "-to-" ~ newid; - stats.writefln(`Improvements: `, nImprovements, `, `); - stats.writefln(`Regressions: `, nRegressions, `, `); - stats.writefln(`Changes: `, nChanges, ``); + stats.writefln(``, nImprovements, ``); + stats.writefln(``, nRegressions, ``); + stats.writefln(``, nChanges, ``); }