# --------- Table with the summary of latest results -------- html += """<h2>Overall Results Summary</h2>""" html += get_html_summary_table(test_names) html += DEFAULT_HTML_FOOTER f = open(os.path.join(basedir, "report.htm"), "w") html = html.replace("\n", os.linesep) # Fix line endings for windows f.write(html) f.close() # -------- Overview of plots ------------ f = open(os.path.join(basedir, "overview_plot.htm"), "w") overview_html = overview_html.replace( "\n", os.linesep) # Fix line endings for windows f.write(overview_html) f.close() print "Report complete!" # ============================================================================================ if __name__ == "__main__": sqlresults.set_database_filename("MyFakeData.db") # Make up some test data if 0: if os.path.exists("MyFakeData.db"): os.remove("MyFakeData.db") sqlresults.generate_fake_data(300) generate_html_report("../Report", 50)
f.write(html) f.close() # -------- Overview of plots ------------ f = open(os.path.join(basedir, "overview_plot.htm"), "w") overview_html = overview_html.replace("\n", os.linesep) # Fix line endings for windows f.write(overview_html) f.close() print "Report complete!" #============================================================================================ if __name__ == "__main__": sqlresults.set_database_filename("MyFakeData.db") # Make up some test data if 0: if os.path.exists("MyFakeData.db"): os.remove("MyFakeData.db") sqlresults.generate_fake_data(300) generate_html_report("../Report", 50) # plot_runtime(name='MyFakeTest', x_field='revision') # plot_runtime(name='MyFakeTest', x_field='date') # plot_success_count() # show()