From: Sebastien D. <sde...@us...> - 2004-11-29 14:04:09
|
Update of /cvsroot/tslogparser/tslogparser In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17897 Modified Files: detailed.php index.php report.php run-browse.php Added Files: footer.inc.php header.inc.php Log Message: (*) Added 2 files: header.inc.php and footer.inc.php (*) Changes in all other files to use the 2 new files (*) Defaulting run browser to hide PASS and SKIP tests Index: run-browse.php =================================================================== RCS file: /cvsroot/tslogparser/tslogparser/run-browse.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** run-browse.php 22 Nov 2004 17:08:12 -0000 1.2 --- run-browse.php 29 Nov 2004 14:04:01 -0000 1.3 *************** *** 24,40 **** */ - ?> - <html> - <head> - <title>Open POSIX TestSuite - Results browser</title> - </head> - <body> - <h1 align="center">Open POSIX TestSuite - Results browser</h1> - <hr align=center width="30%"> - - <h3>Available results in database</h3> - - <?php - /* We need to find all runs inside the database */ $root=""; --- 24,27 ---- *************** *** 43,46 **** --- 30,37 ---- db_init(); + $_PAGE["title"]="Open POSIX TestSuite - Results browser"; + + require($root."header.inc.php"); + /* *************** *** 91,94 **** --- 82,88 ---- /* Ok, now we'll display the result on the html page */ ?> + + <h3>Available results in database</h3> + <table border="1"> <tr> *************** *** 138,141 **** --- 132,141 ---- echo " <form method='POST' action='report.php'>\n"; echo " <input type='hidden' name='opts_rel' value=\"".$data["id"]."\">\n"; + + /* default to masking PASS and SKIP status */ + echo " <input type='hidden' name='build_PASS' value='hidden'>\n"; + echo " <input type='hidden' name='link_SKIP' value='hidden'>\n"; + echo " <input type='hidden' name='execution_PASS' value='hidden'>\n"; + foreach ($data["runs"] as $run_id => $run_data) { *************** *** 175,181 **** ?> </table> - </body> - </html> <?php db_fini(); ?> --- 175,180 ---- ?> </table> <?php db_fini(); + require($root."footer.inc.php"); ?> Index: detailed.php =================================================================== RCS file: /cvsroot/tslogparser/tslogparser/detailed.php,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** detailed.php 22 Nov 2004 10:34:39 -0000 1.1.1.1 --- detailed.php 29 Nov 2004 14:04:01 -0000 1.2 *************** *** 30,52 **** */ - ?> - <html> - <head> - <title> - Open POSIX TestSuite Testcase Detail - </title> - </head> - <body> - <h1 align=center>Open POSIX TestSuite Testcase Detail</h1> - <hr align=center width="30%"> - <?php if (!isset($_GET["run_id"]) || (!isset($_GET["testcase_id"]))) die("<p><b>Wrong parameter format.</b></p>\n</body></html>\n"); - $root=""; - require($root."database.inc.php"); - require($root."functions.inc.php"); db_init(); --- 30,45 ---- */ + $root=""; + require($root."database.inc.php"); + require($root."functions.inc.php"); + + $_PAGE["title"]="Open POSIX TestSuite Testcase Detail"; + + require($root."header.inc.php"); if (!isset($_GET["run_id"]) || (!isset($_GET["testcase_id"]))) die("<p><b>Wrong parameter format.</b></p>\n</body></html>\n"); db_init(); *************** *** 112,119 **** </tr> </table> - </body> - </html> <?php db_fini(); ?> --- 105,111 ---- </tr> </table> <?php db_fini(); + require($root."footer.inc.php"); ?> --- NEW FILE: footer.inc.php --- <?php if (!isset($_PAGE["title"])) die("Incorrect page inclusion.\n"); ?> <hr width="100%"> <p> <font size='-2' color='grey'> Generated with <a href="http://tslogparser.sourceforge.net">TsLogParser</a>. </font> </p> </body> </html> --- NEW FILE: header.inc.php --- <?php /* * Copyright (c) 2004, Bull S.A.. All rights reserved. * Created by: Sebastien Decugis * This program is free software; you can redistribute it and/or modify it * under the terms of version 2 of the GNU General Public License as * published by the Free Software Foundation. * * This program is distributed in the hope that it would be useful, but * WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * * You should have received a copy of the GNU General Public License along * with this program; if not, write the Free Software Foundation, Inc., 59 * Temple Place - Suite 330, Boston MA 02111-1307, USA. */ if (!isset($_PAGE["title"])) die("Incorrect page inclusion.\n"); ?> <!DOCTYPE html PUBLIC "-//w3c//dtd html 4.0 transitional//en"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <title>TsLogParser Project</title> </head> <body> <h1 align="center"><?php echo $_PAGE["title"]; ?></h1> <hr width='30%'> <p>Back to <a href="run-browse.php">browser</a>.</p> Index: index.php =================================================================== RCS file: /cvsroot/tslogparser/tslogparser/index.php,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** index.php 22 Nov 2004 10:34:39 -0000 1.1.1.1 --- index.php 29 Nov 2004 14:04:01 -0000 1.2 *************** *** 1,3 **** --- 1,20 ---- <?php + /* + * Copyright (c) 2004, Bull S.A.. All rights reserved. + * Created by: Sebastien Decugis + + * This program is free software; you can redistribute it and/or modify it + * under the terms of version 2 of the GNU General Public License as + * published by the Free Software Foundation. + * + * This program is distributed in the hope that it would be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write the Free Software Foundation, Inc., 59 + * Temple Place - Suite 330, Boston MA 02111-1307, USA. + */ + /* Redirect to the browser page */ header("Location: http://" . $_SERVER['HTTP_HOST'] Index: report.php =================================================================== RCS file: /cvsroot/tslogparser/tslogparser/report.php,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** report.php 22 Nov 2004 15:55:59 -0000 1.2 --- report.php 29 Nov 2004 14:04:01 -0000 1.3 *************** *** 42,59 **** //echo "</pre>\n"; ! ?> ! <html> ! <head> ! <title> ! Open POSIX TestSuite Reporting Tool ! </title> ! </head> ! <body> ! <h1 align=center>Open POSIX TestSuite Reporting Tool</h1> ! <hr align=center width="30%"> ! <p>Go back to the <a href="run-browse.php">Results browser</a>.</p> ! <?php if (!isset($_POST["opts_rel"])) die("<p>No valid parameter found. Please use <a href='run-browse.php'>this page</a>.</p>\n</body></html>\n"); --- 42,54 ---- //echo "</pre>\n"; ! $root=""; ! require($root."database.inc.php"); ! require($root."functions.inc.php"); ! $_PAGE["title"]="Open POSIX TestSuite Reporting Tool"; ! require($root."header.inc.php"); ! ! /* Verify that the page was not opened directly */ if (!isset($_POST["opts_rel"])) die("<p>No valid parameter found. Please use <a href='run-browse.php'>this page</a>.</p>\n</body></html>\n"); *************** *** 91,94 **** --- 86,94 ---- unset($_POST["noasserts"]); } + if (isset($_POST["nodetails"])) + { + unset($_POST["details"]); + unset($_POST["nodetails"]); + } if (isset($_POST["filter"]) && ($_POST["filter"]=="Show")) { *************** *** 156,162 **** /* Whatever the mode is, we need to query the database with the same informations */ - $root=""; - require($root."database.inc.php"); - require($root."functions.inc.php"); db_init(); --- 156,159 ---- *************** *** 211,215 **** while ($row = db_getline($res)) { ! if (!isset($_POST[str_replace (' ','_',$row["res_status"])])) { $data[$row["rou_name"]][$row["assert_id"]][$row["descr_info"]][$row["descr_id"]][$row["run_name"]]=array( --- 208,212 ---- while ($row = db_getline($res)) { ! if ($mode != "BROWSE" || !isset($_POST[str_replace (' ','_',$row["res_status"])])) { $data[$row["rou_name"]][$row["assert_id"]][$row["descr_info"]][$row["descr_id"]][$row["run_name"]]=array( *************** *** 445,452 **** unset($data); unset($runs); ?> ! <p> </p> ! <hr width='30%'> ! <font size='-2' color='grey'>Generated with <a href="http://sourceforge.net/projects/tslogparser/">TsLogParser</a></font> ! </body> ! </html> --- 442,448 ---- unset($data); unset($runs); + + + require($root."footer.inc.php"); ?> ! |