Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 95733 Details for
Bug 201844
Time Frame Historical Report view does not have tabs and is missing info
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
Patch
Defect_201844_patch.txt (text/plain), 35.38 KB, created by
Paul Slauenwhite
on 2008-04-11 14:40:42 EDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Paul Slauenwhite
Created:
2008-04-11 14:40:42 EDT
Size:
35.38 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.tptp.test.report.birt.doc.user >Index: tasks/treporttest.xhtml >=================================================================== >RCS file: /cvsroot/tptp/test/org.eclipse.tptp.test.report.birt.doc.user/tasks/treporttest.xhtml,v >retrieving revision 1.12 >diff -u -r1.12 treporttest.xhtml >--- tasks/treporttest.xhtml 28 Feb 2008 17:04:24 -0000 1.12 >+++ tasks/treporttest.xhtml 11 Apr 2008 18:40:20 -0000 >@@ -26,13 +26,15 @@ > <h1>Generating BIRT test reports</h1> > > <p> >-Test execution histories can be exported to HTML reports that use the >-Business Intelligence and Reporting Tools reporting system. These reports present the >-data in tables and charts so that end users can easily find trends and analyze the data effectively. >+Once execution histories have been generated from executing test suites, you can >+generate a BIRT test report to summarize the test execution results. The >+Business Intelligence and Reporting Tools (BIRT) test reports aggregate and summarize >+numerous test executions over a period of time. The BIRT test reports present test >+executions in tables and charts so users can easily locate trends and effectually analyze. > </p> > > <p> >-The following is a list of existing BIRT reports: >+The following BIRT test report types are provided: > </p> > > <table border="1" width="596" cellspacing="2" cellpadding="2" style="border-collapse:collapse"> >@@ -40,39 +42,32 @@ > <tr> > <th>Report</th> > <th>Description</th> >+ </tr> >+ <tr> >+ <td>HTML Tabular Test Report (BIRT)</td> >+ <td>Tabular report with only the most recent execution results for each selected test within a specified period of time.</td> > </tr> >- > <tr> >- <td> >- HTML Tabular Test Report (BIRT) >- </td> >- <td> >- A tabular report with the most recent execution results for each selected >- tests within a specified period of time. >- </td> >+ <td>HTML Test Pass Report (BIRT)<sup>1</sup></td> >+ <td>Report with only the most recent execution results for each selected test within a specified period of time.</td> > </tr> > <tr> >- <td>HTML Test Pass Report (BIRT)</td> >- <td valign="top">A test pass report with the most recent execution results for each selected tests within a specified period of time. A pie chart shows the number of failed, inconclusive, passed and error tests. </td> >+ <td>XML Test Report</td> >+ <td>Report with all of the execution results for each selected test within a specified period of time in an XML format.</td> > </tr> > </tbody> > </table> > >-<p> >-<b>Note:</b> to view the charts in some of the reports you need to install >-Adobe's Scalable Vector Graphics (SVG) browser plug-in. You can get this free >-viewer from the Adobe web site at >-<a href="http://www.adobe.com/svg/viewer/install/main.html">http://www.adobe.com/svg/viewer/install/main.html </a>. >-</p> >+[1] Adobe's <a href="http://www.adobe.com/svg/viewer/install/main.html">Scalable Vector Graphics (SVG)</a> browser plug-in is required. > >-<h3><a id="link5"></a>Reporting on the data in the view</h3> >-<p>Generate the report: </p> >+<p>Generate the BIRT test report:</p> > <ol> >- <li>Right-click on a test in the Test Navigator and select <strong>Report... </strong> from the pop-up menu.</li> >- <li>The <strong>New Report</strong> dialog launches.</li> >- <li>Select the <strong>Time Frame Historic </strong> option then click on <strong>Next </strong>.</li> >- <li>Provide the parent folder and a name for the report, then click on <strong>Next </strong> and provide the report time frame Start and End dates and times.</li> >- <li>Click on <strong>Finish </strong> to generate the report.</li> >+ <li>Right-click on a test suite in the Test Navigator and select <strong>Report... </strong> from the context menu.</li> >+ <li>The <strong>New Report</strong> dialog opens.</li> >+ <li>Select one of the BIRT test report types and click on <strong>Next </strong>.</li> >+ <li>Provide the parent folder and a name for the BIRT test report, then click on <strong>Next</strong>.</li> >+ <li>Optionally, provide the report window (start and end data and time) for the BIRT test report.</li> >+ <li>Click <strong>Finish </strong> to generate the BIRT test report.</li> > </ol> > </body> > </html> >#P org.eclipse.hyades.test.doc.user >Index: tasks/tcreatetestreports.htm >=================================================================== >RCS file: /cvsroot/tptp/test/org.eclipse.hyades.test.doc.user/tasks/tcreatetestreports.htm,v >retrieving revision 1.2 >diff -u -r1.2 tcreatetestreports.htm >--- tasks/tcreatetestreports.htm 3 May 2007 14:33:14 -0000 1.2 >+++ tasks/tcreatetestreports.htm 11 Apr 2008 18:40:21 -0000 >@@ -2,7 +2,7 @@ > <html lang="en-us" xml:lang="en-us"> > <!-- > /********************************************************************** >- * Copyright (c) 2007 IBM Corporation. >+ * Copyright (c) 2007, 2008 IBM Corporation. > * All rights reserved. This content > * is made available under the terms of the Eclipse Public License v1.0 > * which accompanies this distribution, and is available at >@@ -21,105 +21,59 @@ > </head> > <body> > >-<h2>Generating test reports</h2> >+<h1>Generating test reports</h1> >+ > <p> >-After you have run your tests and generated execution histories, you can generate a report >-on those test results to summarize the data. >+Once execution histories have been generated from executing test suites, you can >+generate a test report to summarize the test execution results. The test reports >+aggregate and summarize numerous test executions over a period of time. The test >+reports present test executions in tables and charts so users can easily locate >+trends and effectually analyze. > </p> > >-Generate the report: >-<ol> >- <li> >- Right-click on a test in the Test Navigator and >- select <b>Report...</b> from the pop-up menu. >- </li> >- <li> >- The <b>New Report</b> dialog launches. >- </li> >- <li> >- Select the <b>Time Frame Historic</b> option then click on >- <b>Next</b>. >- </li> >- <li> >- Provide the parent folder and a name for the report, then >- click on <b>Next</b> and provide the report time frame Start and End dates and times. >- </li> >- <li> >- Click on <b>Finish</b> to generate the report. >- </li> >-</ol> >- >-<h2>Time Frame Historic report</h2> >-<p>There are 4 tabs in the report: Overview, By Test, By Log, and Details.</p> >- >-<h3>Overview Tab</h3> >- >-<p>The Overview report is a 3D pie chart showing the overall >-breakdown across all test runs during the specified period. In this example >-two-thirds (66.67%) of the tests failed and one-third (33.33%) were in error.</p> >- >-<p><img src="../images/junitanalysis009.png" alt="Pie chart showing 66.67% of the tests failed and 33.33% of the tests were in error."/></p> >- >- >-<h3>By Test Tab</h3> >- >-<p>The By Test report shows the overall relative proportions >-of the categories Pass, Inconclusive, Fail, and Error. </p> >- >-<p><img src="../images/junitanalysis011.png" alt="Part of a bar chart showing that a portion of the test failed and a portion of the test was in error."/></p> >- >-<h3>By Test Log Tab</h3> >- >-<p>The By Test Log report shows, for each test log, the overall relative proportions of the >-categories Pass, Inconclusive, Fail, and Error. </p> >- >-<p><img src="../images/junitanalysis013.png" alt="Part of a bar chart summarizing two tests. Both tests have part fail and part error."/></p> >- >-<h3>Details Tab</h3> >- >-<p>The <b>Details</b> report is in 2 sections: <b>Summary</b> >-and <b>Results by Test</b>. >+<p> >+The following test report types are provided: > </p> > >-<p><img src="../images/junitanalysis015.png" alt=""/></p> >- >- >-<h3>Summary</h3> >- >-<p>The Summary lists the following: >- <ul> >- <li>name of the tests that ran</li> >- <li>verdict across all of those tests</li> >- <li>creation date of the report</li> >- <li>start time of the execution histories</li> >- <li>end time of the execution histories</li> >- <li>number of pass results</li> >- <li>number of fail results</li> >- <li>number of inconclusive results</li> >- <li>number of error results</li> >- </ul> >-This section summarizes the outcomes for test runs taking place >-during the specified period. In this example, out of a total of 6 tests, there were 4 failed tests and 2 tests in >-error. </p> >- >-<h3>Results by Test</h3> >- >-<p>The Results by Test section is a table with eight columns: >- <ul> >- <li>Test Log (the name of the test)</li> >- <li>Date (the day and time of the execution history)</li> >- <li>Pass (the number of tests that passed)</li> >- <li>Inconclusive (the number of tests that were inconclusive)</li> >- <li>Fail (the number of tests that failed)</li> >- <li>Error (the number of tests that had an error)</li> >- <li>Attempted (the number of tests attempted)</li> >- <li>Failure Rate (the percentage of tests that failed)</li> >- </ul> >- This section tabulates the the test outcomes for each test log.</p> >- >+<table border="1" width="596" cellspacing="2" cellpadding="2" style="border-collapse:collapse"> >+ <tbody> >+ <tr> >+ <th>Report</th> >+ <th>Description</th> >+ </tr> >+ <tr> >+ <td>Test Pass Report<sup>1</sup></td> >+ <td>Report with only the most recent execution results for each selected test within a specified period of time.</td> >+ </tr> >+ <tr> >+ <td>Time Frame Historic<sup>1</sup></td> >+ <td>Report with all of the execution results for each selected test within a specified period of time.</td> >+ </tr> >+ <tr> >+ <td>Test Pass Report<sup>1</sup></td> >+ <td>Report with only the most recent execution results for each selected test within a specified period of time.</td> >+ </tr> >+ </tbody> >+</table> > >+[1] Adobe's <a href="http://www.adobe.com/svg/viewer/install/main.html">Scalable Vector Graphics (SVG)</a> browser plug-in is required. > >+<p>Configure the fonts used when generating the test report:</p> >+<ol> >+ <li>Open the <b>Window > Preferences</b> dialog.</li> >+ <li>Select the report <b>Test > Test Report > Font</b> preference page.</li> >+ <li>Configure the fonts used when generating the test report.</li> >+ <li>Select <b>OK</b>.</li> >+</ol> > >+<p>Generate the test report:</p> >+<ol> >+ <li>Right-click on a test suite in the Test Navigator and select <strong>Report... </strong> from the context menu.</li> >+ <li>The <strong>New Report</strong> dialog opens.</li> >+ <li>Select one of the test report types and click on <strong>Next </strong>.</li> >+ <li>Provide the parent folder and a name for the test report, then click on <strong>Next</strong>.</li> >+ <li>Optionally, provide the report window (start and end data and time) for the test report.</li> >+ <li>Click <strong>Finish </strong> to generate the test report.</li> >+</ol> > </body> >- > </html> >Index: tasks/tcreateperformancetestreports.htm >=================================================================== >RCS file: /cvsroot/tptp/test/org.eclipse.hyades.test.doc.user/tasks/tcreateperformancetestreports.htm,v >retrieving revision 1.2 >diff -u -r1.2 tcreateperformancetestreports.htm >--- tasks/tcreateperformancetestreports.htm 3 May 2007 14:33:14 -0000 1.2 >+++ tasks/tcreateperformancetestreports.htm 11 Apr 2008 18:40:21 -0000 >@@ -35,43 +35,55 @@ > <title>Generating performance test reports</title> > </head> > <body> >-<a name="analzingtestresults"><!-- --></a> > >-<h1 class="topictitle1">Generating performance test reports</h1> >+<h1>Generating performance test reports</h1> > >-<p>At the conclusion of a performance test run you see an execution history, which you can create two types of graphical performance test reports; Page Response Time and Page Hit Rate. The Page Response Time report is a bar graph showing the seconds required to process each page in the test and >-the average response time for all pages.</p> >- >-<img src="../images/prt_no_values.gif" alt="Sample Page Response Time report that shows a bar for each of five pages. The bar shows the number of seconds for each page."/> >+<p> >+Once execution histories have been generated from executing performance test suites, you can >+generate a performance test report to summarize the test execution results. The performance test reports >+aggregate and summarize numerous test executions over a period of time. The performance test >+reports present test executions in charts so users can easily locate trends and effectually analyze. >+</p> > >-<p>The Page Hit Rate report is a bar graph showing the hits per second to each page and the total hit rate for all pages. The exact numbers displayed >-at the top of the bars (available on the Page Response Time as well) do not appear unless you click one of the bars.</p> >+<p> >+The following performance test report types are provided: >+</p> > >-<img src="../images/phr_values.gif" alt="sample Page Hit Rate report showing the hits per second for five pages and the total hit rate for all pages."/> >+<table border="1" width="596" cellspacing="2" cellpadding="2" style="border-collapse:collapse"> >+ <tbody> >+ <tr> >+ <th>Report</th> >+ <th>Description</th> >+ </tr> >+ <tr> >+ <td>HTTP Page Response Time<sup>1</sup></td> >+ <td>Report with the response time for each HTTP page in the the most recent execution results for each selected test.</td> >+ </tr> >+ <tr> >+ <td>HTTP Page Hit Rate<sup>1</sup></td> >+ <td>Create a report with the hits per second for each HTTP page in the the most recent execution results for each selected test.</td> >+ </tr> >+ </tbody> >+</table> > >-<p>In order to view the Page Response Time and the Page Hit Rate reports, you need to install Adobe's Scalable Vector Graphics (SVG) browser plug-in. >-You can get this free viewer from the Adobe web site at <a href="http://www.adobe.com/svg/viewer/install/main.html">http://www.adobe.com/svg/viewer/install/main.html</a>.</p> >+[1] Adobe's <a href="http://www.adobe.com/svg/viewer/install/main.html">Scalable Vector Graphics (SVG)</a> browser plug-in is required. > >-<p>To generate reports from a performance test's results: >+<p>Configure the fonts used when generating the performance test report:</p> > <ol> >- <li>In the <b>Test Navigator</b>, right-click the performance test and select <b>Report</b>. Page one of the <b>New Report</b> wizard opens.</li> >- <li>Click the type of report you want to create. If you want to see the report immediately, without having to browse to it, leave the <b>Open Report >- Automatically</b> box checked. When you click <b>Next</b>, the second page of the New Report wizard opens.</li> >- <li>From the list of projects in the middle pane, click the one that you want to put the report file in: the project's name appears in the <b>Enter >- or select the parent folder</b> box.</li> >- <li>In the <b>File name</b> box, enter the name of the report file.</li> >- <li>Click <b>Finish</b>.</li> >+ <li>Open the <b>Window > Preferences</b> dialog.</li> >+ <li>Select the report <b>Test > Test Report > Font</b> preference page.</li> >+ <li>Configure the fonts used when generating the performance test report.</li> >+ <li>Select <b>OK</b>.</li> > </ol> >-</p> >-<p>If you left the <b>Open Report Automatically</b> box checked in step 1 (assuming you have the SVG viewer installed), the report opens in your >-browser.</p> > >- >-<div> >-<p><b class="parentlink">Parent topic:</b> <a href="../concepts/ctestwithhyades.htm" >- title="The Eclipse test and performance tools platform (TPTP) supports automated performance testing of HTTP applications.">Performance Testing with >-TPTP</a><br /> >-</p> >-</div> >+<p>Generate the performance test report:</p> >+<ol> >+ <li>Right-click on a performance test suite in the Test Navigator and select <strong>Report... </strong> from the context menu.</li> >+ <li>The <strong>New Report</strong> dialog opens.</li> >+ <li>Select one of the performance test report types and click on <strong>Next </strong>.</li> >+ <li>Provide the parent folder and a name for the performance test report, then click on <strong>Next</strong>.</li> >+ <li>Optionally, provide the report window (start and end data and time) for the performance test report.</li> >+ <li>Click <strong>Finish </strong> to generate the performance test report.</li> >+</ol> > </body> > </html> >#P org.eclipse.tptp.test.samples >Index: src/org/eclipse/hyades/test/tools/ui/common/internal/report/ReportStylesPreferencePage.java >=================================================================== >RCS file: /cvsroot/tptp/test/org.eclipse.tptp.test.samples/src/org/eclipse/hyades/test/tools/ui/common/internal/report/ReportStylesPreferencePage.java,v >retrieving revision 1.6 >diff -u -r1.6 ReportStylesPreferencePage.java >--- src/org/eclipse/hyades/test/tools/ui/common/internal/report/ReportStylesPreferencePage.java 21 Jan 2008 16:53:55 -0000 1.6 >+++ src/org/eclipse/hyades/test/tools/ui/common/internal/report/ReportStylesPreferencePage.java 11 Apr 2008 18:40:22 -0000 >@@ -12,6 +12,7 @@ > package org.eclipse.hyades.test.tools.ui.common.internal.report; > > import org.eclipse.hyades.test.tools.ui.common.internal.report.jscrib.StylesInitializer; >+import org.eclipse.hyades.ui.internal.util.GridDataUtil; > import org.eclipse.jface.dialogs.Dialog; > import org.eclipse.jface.preference.PreferencePage; > import org.eclipse.swt.SWT; >@@ -19,18 +20,27 @@ > import org.eclipse.swt.layout.GridLayout; > import org.eclipse.swt.widgets.Composite; > import org.eclipse.swt.widgets.Control; >+import org.eclipse.swt.widgets.Group; > import org.eclipse.tptp.platform.report.core.internal.DStyleRegistry; > import org.eclipse.tptp.platform.report.signals.internal.Signal; > import org.eclipse.tptp.platform.report.ui.swt.widgets.internal.StylesFieldEditor; > import org.eclipse.tptp.test.samples.SamplesPlugin; >+import org.eclipse.tptp.test.samples.internal.resources.SamplesPluginResourceBundle; > import org.eclipse.ui.IWorkbench; > import org.eclipse.ui.IWorkbenchPreferencePage; >-import org.eclipse.ui.PlatformUI; >- >- > > /** >- * @see PreferencePage >+ * >+ */ >+/** >+ * ReportStylesPreferencePage.java >+ * <p/> >+ * >+ * >+ * @author Paul E. Slauenwhite >+ * @version April 11, 2008 >+ * @since June 6, 2005 >+ * @see PreferencePage > */ > public class ReportStylesPreferencePage extends PreferencePage implements IWorkbenchPreferencePage { > >@@ -38,37 +48,17 @@ > > public static final String ID = "ReportView.Preferences"; > >- private class LocalStylesFieldEditor extends StylesFieldEditor >- { >- public LocalStylesFieldEditor(String name, String labelText, >- Composite parent) { >- super(name, labelText, parent); >- } >- public void loadDefault() { >- super.loadDefault(); >- this.setPresentsDefaultValue(false); >- } >- } >- /** >- * >- */ >+ public static Signal sig_asv_graphic_style_chgd = new Signal("valueChanged()"); //$NON-NLS-1$ >+ >+ private DStyleRegistry registry = null; >+ > public ReportStylesPreferencePage() { > } > >- /** >- * @see PreferencePage#init >- */ >- DStyleRegistry registry = null; > public void init(IWorkbench workbench) { > this.registry = StylesInitializer.getCurrentReportStyles(); > } >- >- protected void performDefaults() { >- this.recentStylesEditor.loadDefault(); >- } >- >- public static Signal sig_asv_graphic_style_chgd = new Signal("valueChanged()"); //$NON-NLS-1$ >- >+ > public boolean performOk() { > > sig_asv_graphic_style_chgd.setBlocked(true); >@@ -77,43 +67,49 @@ > sig_asv_graphic_style_chgd.emit(); > return true; > } >+ > public void createControl(Composite parent) { > super.createControl(parent); >- //TODO: add call help online >-// SamplesPlugin.getDefault().getWorkbench().getHelpSystem().setHelp(parent, LLCContextIds.PREF_GRP_STYLE_PAGE); >- > } >+ >+ protected void performDefaults() { >+ this.recentStylesEditor.loadDefault(); >+ } >+ > /** > * @see PreferencePage#createContents > */ > protected Control createContents(Composite parent) { >- Composite composite = new Composite(parent, SWT.NULL); >- GridLayout layout = new GridLayout(); >- layout.marginWidth = 0; >- layout.marginHeight = 0; >- composite.setLayout(layout); >- composite.setLayoutData(new GridData(GridData.VERTICAL_ALIGN_FILL | GridData.HORIZONTAL_ALIGN_FILL)); >- composite.setFont(parent.getFont()); >+ >+ SamplesPlugin.getDefault().getWorkbench().getHelpSystem().setHelp(parent, SamplesPlugin.getID() + ".ptrf001"); >+ >+ Composite composite = new Composite(parent, SWT.NONE); >+ composite.setLayoutData(GridDataUtil.createFill()); >+ composite.setLayout(new GridLayout()); >+ >+ final Group sampleReportFontGroup = new Group(composite, SWT.SHADOW_ETCHED_IN); >+ sampleReportFontGroup.setLayout(new GridLayout()); >+ sampleReportFontGroup.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true)); >+ sampleReportFontGroup.setText(SamplesPluginResourceBundle.TEST_REPORT_FONT_PREFERENCES_GROUP_NAME); > >- this.recentStylesEditor = new LocalStylesFieldEditor(ReportStylesPreferencePage.ID, "message", composite); //$NON-NLS-1$ >+ this.recentStylesEditor = new LocalStylesFieldEditor(ReportStylesPreferencePage.ID, "message", sampleReportFontGroup); //$NON-NLS-1$ > this.recentStylesEditor.setStylesRegistry(this.registry); > this.recentStylesEditor.setPreferenceStore(SamplesPlugin.getDefault().getPreferenceStore()); > this.recentStylesEditor.setPage(this); > >- sig_asv_graphic_style_chgd.connect(this,"refreshView()"); //$NON-NLS-1$ > Dialog.applyDialogFont( composite ); > return composite; > } >- >- /** >- * this method is connected to the signal sig_asv_graphic_style_chgd and >- * it is called when the colors are modified in the preferences and >- * refreshes the view if it is visible >- */ >- public void refreshView() >- { >- ReportView view = (ReportView)PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().findView(ReportView.ID); //$NON-NLS-1$ >- if(view!=null) >- view.redrawContent(); >- } >+ >+ private class LocalStylesFieldEditor extends StylesFieldEditor >+ { >+ public LocalStylesFieldEditor(String name, String labelText, >+ Composite parent) { >+ super(name, labelText, parent); >+ } >+ public void loadDefault() { >+ super.loadDefault(); >+ this.setPresentsDefaultValue(false); >+ } >+ } > } >\ No newline at end of file >Index: src/org/eclipse/hyades/test/tools/ui/common/internal/report/ReportView.java >=================================================================== >RCS file: src/org/eclipse/hyades/test/tools/ui/common/internal/report/ReportView.java >diff -N src/org/eclipse/hyades/test/tools/ui/common/internal/report/ReportView.java >--- src/org/eclipse/hyades/test/tools/ui/common/internal/report/ReportView.java 10 Apr 2008 14:53:22 -0000 1.8 >+++ /dev/null 1 Jan 1970 00:00:00 -0000 >@@ -1,208 +0,0 @@ >-/* *********************************************************** >- * Copyright (c) 2005, 2008 IBM Corporation and others. >- * All rights reserved. This program and the accompanying materials >- * are made available under the terms of the Eclipse Public License v1.0 >- * which accompanies this distribution, and is available at >- * http://www.eclipse.org/legal/epl-v10.html >- * $Id: ReportView.java,v 1.8 2008/04/10 14:53:22 paules Exp $ >- * >- * Contributors: >- * IBM - Initial API and implementation >- ************************************************************/ >- >- >-package org.eclipse.hyades.test.tools.ui.common.internal.report; >- >- >-import java.io.File; >- >-import org.eclipse.hyades.test.ui.util.RCPFileEditorInput; >-import org.eclipse.swt.SWT; >-import org.eclipse.swt.graphics.Point; >-import org.eclipse.swt.widgets.Composite; >-import org.eclipse.swt.widgets.Display; >-import org.eclipse.tptp.platform.report.core.internal.DLinkUtil; >-import org.eclipse.tptp.platform.report.core.internal.IDDocument; >-import org.eclipse.tptp.platform.report.core.internal.IDLink; >-import org.eclipse.tptp.platform.report.drivers.ui.internal.SWTViewer; >-import org.eclipse.tptp.platform.report.ui.dialogs.internal.StyleEditorDialog; >-import org.eclipse.tptp.platform.report.ui.dialogs.internal.ZoomEditorDialog; >-import org.eclipse.tptp.test.samples.SamplesPlugin; >-import org.eclipse.tptp.test.samples.internal.resources.SamplesPluginResourceBundle; >-import org.eclipse.ui.IEditorDescriptor; >-import org.eclipse.ui.PlatformUI; >-import org.eclipse.ui.WorkbenchException; >-import org.eclipse.ui.part.ViewPart; >- >-/** >- * This sample class demonstrates how to plug-in a new >- * workbench view. The view shows data obtained from the >- * model. The sample creates a dummy model on the fly, >- * but a real implementation would connect to the model >- * available either in this or another plug-in (e.g. the workspace). >- * The view is connected to the model using a content provider. >- * <p> >- * The view uses a label provider to define how model >- * objects should be presented in the view. Each >- * view can present the same model objects using >- * different labels and icons, if needed. Alternatively, >- * a single label provider can be shared between views >- * in order to ensure that objects of the same type are >- * presented in the same way everywhere. >- * <p> >- */ >- >-public class ReportView extends ViewPart { >- >- >- public static final String ID = "org.eclipse.hyades.test.tools.ui.common.internal.report.ReportView"; //$NON-NLS-$1 >- >- private SWTViewer viewer; >- //private Action actionZoom; >- >- //private Action actionStyles; >- >- >- private static ZoomEditorDialog zd; >- private static StyleEditorDialog styleEditor; >- >- private class ReportViewer extends SWTViewer { >- >- public ReportViewer(Composite parent, int style) >- { >- super(parent, style); >- >- } >- >- public void activateLink(IDLink link, Point p) >- { >- if (DLinkUtil.isInternalLink(link)) >- { >- super.activateLink(link, p); >- } >- else >- { >- //check if the image exists on the disk >- File f = new File(link.getTarget()); >- if (f.exists()) >- { >- IEditorDescriptor editor = PlatformUI.getWorkbench().getEditorRegistry().getDefaultEditor(link.getTarget()); >- >- //FileSystemElement fse = new FileSystemElement(link.getTarget(), null , false); >- //ExtFile fse = new ExtFile(link.getTarget()); >- RCPFileEditorInput rcpfile = new RCPFileEditorInput(f); >- >- try { >- PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().openEditor(rcpfile, editor.getId()); >- } >- catch (WorkbenchException e) >- { >- SamplesPlugin.logError("Unable to open file = " + link.getTarget()); >- } >- //return copyImageFile(link.getTarget()); >- } >- } >- } >- } >- >- >- /** >- * The constructor. >- */ >- public ReportView() { >- } >- >- /** >- * Shows a document in the view >- */ >- public void setDocument(IDDocument doc) >- { >- viewer.setContent(doc); >- } >- >- /** >- * Applies zoom factor to the view >- */ >- public void applyZoom() >- { >- viewer.setZoom(zd.getZoomFactor(), zd.isMaintainRatio()); >- } >- >- >- /** >- * Applies styles factor to the view >- */ >- public void applyStyles() >- { >- >- } >- >- /** >- * This is a callback that will allow us >- * to create the viewer and initialize it. >- */ >- public void createPartControl(Composite parent) { >- viewer = new ReportViewer(parent, SWT.DIALOG_TRIM|SWT.RESIZE ); >- viewer.setBackground( Display.getDefault().getSystemColor( SWT.COLOR_WHITE )); >- setPartName(SamplesPluginResourceBundle.ReportWindow_Title ); >- // Add icon in local toolbar >- /*IToolBarManager bars =*/ getViewSite().getActionBars().getToolBarManager(); >- makeActions(); >- //bars.add(actionZoom); >- //bars.add(actionStyles); >- // Zoom Dialog Creation >- zd = new ZoomEditorDialog(parent.getShell()); >- zd.applied.connect(this, "applyZoom()"); //$NON-NLS-$1 >- // Style Dialog Creation >- styleEditor = new StyleEditorDialog(parent.getShell()); >- styleEditor.applied.connect(this, "applyStyles()"); //$NON-NLS-$1 >- } >- >- private void makeActions() { >- /*actionZoom = new Action() { >- public void run() { >- zd.setData(frame.getViewer().getContentsWidth(), frame.getViewer().getContentsHeight(), >- frame.getViewer().getBounds().width, frame.getViewer().getBounds().height, >- frame.getViewer().getZoom()); >- zd.open(); >- } >- }; >- actionZoom.setText("Zoom"); >- actionZoom.setToolTipText("Zoom..."); >- actionZoom.setImageDescriptor(PlatformUI.getWorkbench().getSharedImages(). >- getImageDescriptor(ISharedImages.IMG_TOOL_NEW_WIZARD)); >- >- actionStyles = new Action() { >- public void run() { >- IDItem doc = viewer.getContentItem(); >- if (doc!=null) >- { >- DStyleRegistry r = new DStyleRegistry(); >- r.merge(doc); >- styleEditor.setStyles(r); >- styleEditor.open(); >- } >- } >- }; >- actionStyles.setText("Styles"); >- actionStyles.setToolTipText("Modify Styles..."); >- actionStyles.setImageDescriptor(PlatformUI.getWorkbench().getSharedImages(). >- getImageDescriptor(ISharedImages.IMG_OBJ_ELEMENT));*/ >- >- } >- >- /** >- * Passing the focus request to the viewer's control. >- */ >- public void setFocus() { >- viewer.setFocus(); >- } >- >- /** >- * Redraw the content >- */ >- public void redrawContent() >- { >- viewer.redraw(); >- } >-} >\ No newline at end of file >Index: src/org/eclipse/tptp/test/samples/internal/resources/SamplesPluginResourceBundle.java >=================================================================== >RCS file: /cvsroot/tptp/test/org.eclipse.tptp.test.samples/src/org/eclipse/tptp/test/samples/internal/resources/SamplesPluginResourceBundle.java,v >retrieving revision 1.8 >diff -u -r1.8 SamplesPluginResourceBundle.java >--- src/org/eclipse/tptp/test/samples/internal/resources/SamplesPluginResourceBundle.java 11 Apr 2008 13:19:46 -0000 1.8 >+++ src/org/eclipse/tptp/test/samples/internal/resources/SamplesPluginResourceBundle.java 11 Apr 2008 18:40:22 -0000 >@@ -36,6 +36,7 @@ > public static String Time_Frame_Historic_ReportWindow_Title; > public static String HTTP_Page_Response_Time_ReportWindow_Title; > public static String HTTP_Page_Hit_Rate_ReportWindow_Title; >+ public static String TEST_REPORT_FONT_PREFERENCES_GROUP_NAME; > public static String ReportWindow_Title; > public static String ReportWindowWizardPage_Title; > public static String ReportWindowWizardPage_Description; >Index: src/org/eclipse/tptp/test/samples/internal/resources/messages.properties >=================================================================== >RCS file: /cvsroot/tptp/test/org.eclipse.tptp.test.samples/src/org/eclipse/tptp/test/samples/internal/resources/messages.properties,v >retrieving revision 1.9 >diff -u -r1.9 messages.properties >--- src/org/eclipse/tptp/test/samples/internal/resources/messages.properties 11 Apr 2008 13:19:46 -0000 1.9 >+++ src/org/eclipse/tptp/test/samples/internal/resources/messages.properties 11 Apr 2008 18:40:22 -0000 >@@ -23,6 +23,8 @@ > HTTP_Page_Response_Time_ReportWindow_Title = HTTP Page Response Time > HTTP_Page_Hit_Rate_ReportWindow_Title = HTTP Page Hit Rate > >+TEST_REPORT_FONT_PREFERENCES_GROUP_NAME = Test Report Fonts >+ > ReportWindowWizardPage_Title = Select a time frame > ReportWindowWizardPage_Description = Enter the start and end date and time ({0}) for the report window. > ReportWindowWizardPage_LABEL_STARTTIME = Start date and time: >Index: plugin.properties >=================================================================== >RCS file: /cvsroot/tptp/test/org.eclipse.tptp.test.samples/plugin.properties,v >retrieving revision 1.19 >diff -u -r1.19 plugin.properties >--- plugin.properties 10 Apr 2008 14:53:24 -0000 1.19 >+++ plugin.properties 11 Apr 2008 18:40:22 -0000 >@@ -22,9 +22,7 @@ > pluginName = TPTP Test Framework and Tools Samples > providerName = Eclipse.org > >-#Report >-REPORT_WINDOW_WTITLE = Test Report >- >+#Sample test reports: > REPORT_WINDOW_WIZ_NAME = Time Frame Historic > REPORT_WINDOW_WIZ_DESC = Create a report with all of the execution results for each selected test within a specified period of time. > >@@ -37,5 +35,5 @@ > HIT_RATE_TITLE = HTTP Page Hit Rate > HIT_RATE_DESC = Create a report with the hits per second for each HTTP page in the the most recent execution results for each selected test. > >-#Test Report font preferences >+#Font preferences for the sample test reports: > TEST_REPORT_FONT_PREFERENCES_PAGE_NAME = Fonts >Index: plugin.xml >=================================================================== >RCS file: /cvsroot/tptp/test/org.eclipse.tptp.test.samples/plugin.xml,v >retrieving revision 1.13 >diff -u -r1.13 plugin.xml >--- plugin.xml 10 Apr 2008 14:53:24 -0000 1.13 >+++ plugin.xml 11 Apr 2008 18:40:22 -0000 >@@ -51,19 +51,6 @@ > id="org.eclipse.hyades.test.tools.ui.http.internal.reports.hitrate.HTTPPageHitRateReportGeneratorWizard.java"/> > </extension> > >- <extension >- point="org.eclipse.ui.views"> >- <category >- name="%REPORT_WINDOW_WTITLE" >- id="org.eclipse.tptp.test.samples.views"/> >- <view >- name="%REPORT_WINDOW_WTITLE" >- icon="icons/full/etool16/report_window_wiz.gif" >- category="org.eclipse.hyades.test.ui.views" >- class="org.eclipse.hyades.test.tools.ui.common.internal.report.ReportView" >- id="org.eclipse.hyades.test.tools.ui.common.internal.report.ReportView"/> >- </extension> >- > <extension > point="org.eclipse.ui.preferencePages"> > <page name="%TEST_REPORT_FONT_PREFERENCES_PAGE_NAME" >@@ -71,4 +58,9 @@ > class="org.eclipse.hyades.test.tools.ui.common.internal.report.ReportStylesPreferencePage" > id="org.eclipse.hyades.test.tools.ui.common.internal.report.ReportStylesPreferencePage"/> > </extension> >+ >+ <extension point="org.eclipse.help.contexts"> >+ <contexts file="infopop\samplesUI.xml"/> >+ </extension> >+ > </plugin> >Index: infopop/samplesUI.xml >=================================================================== >RCS file: infopop/samplesUI.xml >diff -N infopop/samplesUI.xml >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ infopop/samplesUI.xml 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,22 @@ >+<?xml version="1.0" encoding="UTF-8"?> >+<!-- >+Copyright (c) 2008 IBM Corporation and others. >+All rights reserved. This program and the accompanying materials >+are made available under the terms of the Eclipse Public License v1.0 >+which accompanies this distribution, and is available at >+http://www.eclipse.org/legal/epl-v10.html >+$Id$ >+ >+Contributors: >+IBM - Initial contribution >+--> >+<?NLS TYPE="org.eclipse.help.contexts"?> >+<contexts> >+ >+ <!-- Preferences: Test Report Fonts: --> >+ <context id="ptrf001"> >+ <description>Configure the fonts used when generating test reports.</description> >+ <topic href="../org.eclipse.hyades.test.doc.user/tasks/tcreatetestreports.htm" label="Generating test reports"/> >+ <topic href="../org.eclipse.hyades.test.doc.user/tasks/tcreateperformancetestreports.htm" label="Generating performance test reports"/> >+ </context> >+</contexts>
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 201844
:
95705
| 95733