From c6e1061b11b201e015fe249dc1d4a9b79e2d67a6 Mon Sep 17 00:00:00 2001 From: shleh Date: Thu, 27 May 2004 05:25:04 +0000 Subject: [PATCH] added textArea as a temporary report area. will be replaced by a tree at some point (like junit) defining class skeleton. --- .../phpeclipse/phpunit/PHPUnitView.java | 29 ++++++++++++++++++- 1 files changed, 27 insertions(+), 2 deletions(-) diff --git a/net.sourceforge.phpeclipse.phpunit/src/net/sourceforge/phpeclipse/phpunit/PHPUnitView.java b/net.sourceforge.phpeclipse.phpunit/src/net/sourceforge/phpeclipse/phpunit/PHPUnitView.java index 5d8e181..94605d5 100644 --- a/net.sourceforge.phpeclipse.phpunit/src/net/sourceforge/phpeclipse/phpunit/PHPUnitView.java +++ b/net.sourceforge.phpeclipse.phpunit/src/net/sourceforge/phpeclipse/phpunit/PHPUnitView.java @@ -4,8 +4,15 @@ package net.sourceforge.phpeclipse.phpunit; import org.eclipse.swt.SWT; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Label; +import org.eclipse.swt.widgets.Text; import org.eclipse.ui.part.ViewPart; +/** + * @author Ali Echihabi + * + * To change the template for this generated type comment go to + * Window>Preferences>Java>Code Generation>Code and Comments + */ /* * Created on May 22, 2004 * @@ -45,6 +52,7 @@ public class PHPUnitView extends ViewPart { Label labelErrors, labelErrorsVal; Label labelFailures, labelFailuresVal; + Text reportArea; // TODO: replace with Tree display like JUnit public PHPUnitView() { @@ -68,16 +76,33 @@ public class PHPUnitView extends ViewPart { labelErrorsVal = new Label(parent, SWT.WRAP); labelErrorsVal.setText("0"); + reportArea = new Text(parent, SWT.MULTI | SWT.BORDER | + SWT.WRAP | SWT.V_SCROLL | SWT.READ_ONLY); + + // TODO layout! } /* (non-Javadoc) * @see org.eclipse.ui.IWorkbenchPart#setFocus() */ public void setFocus() { - + markTestPass("hello"); } - + /** + * mark the given test as passed in the GUI. + * + * @param testID + */ + private void markTestPass(String testID) { + + // testid, use it in hashmap to retrieve tree item of test and + // change icon color, increment pass counter, etc... + + + //for now: + reportArea.append("test passed"); + } -- 1.7.1