0001: /*
0002: * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
0003: *
0004: * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
0005: *
0006: * The contents of this file are subject to the terms of either the GNU
0007: * General Public License Version 2 only ("GPL") or the Common
0008: * Development and Distribution License("CDDL") (collectively, the
0009: * "License"). You may not use this file except in compliance with the
0010: * License. You can obtain a copy of the License at
0011: * http://www.netbeans.org/cddl-gplv2.html
0012: * or nbbuild/licenses/CDDL-GPL-2-CP. See the License for the
0013: * specific language governing permissions and limitations under the
0014: * License. When distributing the software, include this License Header
0015: * Notice in each file and include the License file at
0016: * nbbuild/licenses/CDDL-GPL-2-CP. Sun designates this
0017: * particular file as subject to the "Classpath" exception as provided
0018: * by Sun in the GPL Version 2 section of the License file that
0019: * accompanied this code. If applicable, add the following below the
0020: * License Header, with the fields enclosed by brackets [] replaced by
0021: * your own identifying information:
0022: * "Portions Copyrighted [year] [name of copyright owner]"
0023: *
0024: * Contributor(s):
0025: *
0026: * The Original Software is NetBeans. The Initial Developer of the Original
0027: * Software is Sun Microsystems, Inc. Portions Copyright 1997-2007 Sun
0028: * Microsystems, Inc. All Rights Reserved.
0029: *
0030: * If you wish your version of this file to be governed by only the CDDL
0031: * or only the GPL Version 2, indicate your decision by adding
0032: * "[Contributor] elects to include this software in this distribution
0033: * under the [CDDL or GPL Version 2] license." If you do not indicate a
0034: * single choice of license, a recipient has the option to distribute
0035: * your version of this file under either the CDDL, the GPL Version 2 or
0036: * to extend the choice of license to its licensees as provided above.
0037: * However, if you add GPL Version 2 code and therefore, elected the GPL
0038: * Version 2 license, then the option applies only if the new code is
0039: * made subject to such option by the copyright holder.
0040: */
0041:
0042: /*
0043: * AcceptanceTest.java
0044: *
0045: * Created on May 11, 2006, 9:58 AM
0046: *
0047: * To change this template, choose Tools | Template Manager
0048: * and open the template in the editor.
0049: */
0050:
0051: package org.netbeans.modules.visualweb.test.components.input.textfield;
0052:
0053: import junit.framework.Test;
0054: import junit.framework.TestSuite;
0055: import org.netbeans.junit.NbTestSuite;
0056: import org.netbeans.jellytools.OutputOperator;
0057: import org.netbeans.jemmy.Waiter;
0058: import org.netbeans.jemmy.Waitable;
0059: import org.netbeans.jemmy.QueueTool;
0060: import org.netbeans.jemmy.operators.JTreeOperator;
0061:
0062: import org.netbeans.jemmy.operators.*;
0063:
0064: import java.io.File;
0065: import java.io.IOException;
0066: import java.awt.Point;
0067:
0068: import org.netbeans.modules.visualweb.gravy.*;
0069: import org.netbeans.modules.visualweb.gravy.designer.DesignerPaneOperator;
0070: import org.netbeans.modules.visualweb.gravy.properties.SheetTableOperator;
0071: import org.netbeans.modules.visualweb.gravy.toolbox.PaletteContainerOperator;
0072: import org.netbeans.modules.visualweb.gravy.DocumentOutlineOperator;
0073: import org.netbeans.modules.visualweb.gravy.EditorOperator;
0074: import org.netbeans.modules.visualweb.test.components.util.ComponentUtils;
0075: import org.netbeans.modules.visualweb.gravy.dataconnectivity.ServerNavigatorOperator;
0076:
0077: import java.util.Hashtable;
0078:
0079: import org.netbeans.jemmy.drivers.text.SwingTextKeyboardDriver;
0080:
0081: /**
0082: *
0083: * @author <a href="mailto:lark.fitzgerald@sun.com">lfitzger</a>
0084: */
0085: public class AcceptanceTest extends RaveTestCase {
0086:
0087: //Shared Variables
0088: public static DesignerPaneOperator designer;
0089: public static PaletteContainerOperator palette;
0090: public static DocumentOutlineOperator outline;
0091: public static SheetTableOperator sheet;
0092: public static DeploymentDialogOperator deploy;
0093: public static ServerNavigatorOperator explorer;
0094: Point clickPoint, dropPoint;
0095:
0096: //Project variables
0097: public String _sharedBundle = "org.netbeans.modules.visualweb.test.components.Component";
0098: public String _privateBundle = "org.netbeans.modules.visualweb.test.components.input.textfield.Acceptance";
0099: public String _projectName = Bundle.getStringTrimmed(
0100: _privateBundle, "projectName");
0101: public String _projectServer = Bundle.getStringTrimmed(
0102: _sharedBundle, "projectServer");
0103: public String _logFileLocation = Bundle.getStringTrimmed(
0104: _sharedBundle, "logFile");
0105: public String _logFile = System.getProperty("xtest.workdir")
0106: + File.separator + _logFileLocation;
0107: public String _exception = Bundle.getStringTrimmed(_sharedBundle,
0108: "Exception");
0109: public String _close = Bundle.getStringTrimmed(_sharedBundle,
0110: "close");
0111: public String _run = Bundle.getStringTrimmed(_sharedBundle, "Run");
0112: public String _buildSuccess = Bundle.getStringTrimmed(
0113: _sharedBundle, "buildSuccess");
0114: public String _true = Bundle
0115: .getStringTrimmed(_sharedBundle, "true");
0116:
0117: //Outline variables
0118: public String _outlinePage1 = Bundle.getStringTrimmed(
0119: _sharedBundle, "outlinePage1");
0120:
0121: //Palette variables
0122: public String _basicPalette = Bundle.getStringTrimmed(
0123: _sharedBundle, "basicPalette");
0124: public String _basicButton = Bundle.getStringTrimmed(_sharedBundle,
0125: "basicButton");
0126: public String _basicTextField = Bundle.getStringTrimmed(
0127: _sharedBundle, "basicTextField");
0128: public String _basicLabel = Bundle.getStringTrimmed(_sharedBundle,
0129: "basicLabel");
0130: public String _basicStaticText = Bundle.getStringTrimmed(
0131: _sharedBundle, "basicStaticText");
0132: public String _basicMessage = Bundle.getStringTrimmed(
0133: _sharedBundle, "basicMessage");
0134:
0135: public String _validatorPalette = Bundle.getStringTrimmed(
0136: _sharedBundle, "validatorPalette");
0137: public String _validatorLength = Bundle.getStringTrimmed(
0138: _sharedBundle, "validatorLength");
0139:
0140: public String _converterPalette = Bundle.getStringTrimmed(
0141: _sharedBundle, "converterPalette"); // Bug with palette has this in lowercase
0142: public String _converterInteger = Bundle.getStringTrimmed(
0143: _sharedBundle, "converterInteger");
0144:
0145: //Editor variables
0146: public String _page1 = Bundle.getStringTrimmed(_sharedBundle,
0147: "webPage1");
0148: public String _reformatCode = Bundle.getStringTrimmed(
0149: _sharedBundle, "reformatCode");
0150:
0151: //Property variables
0152: public String _propertyText = Bundle.getStringTrimmed(
0153: _sharedBundle, "propertyText");
0154: public String _propertyLabel = Bundle.getStringTrimmed(
0155: _sharedBundle, "propertyLabel");
0156: public String _propertyMaxLength = Bundle.getStringTrimmed(
0157: _sharedBundle, "propertyMaxLength");
0158: public String _propertyFor = Bundle.getStringTrimmed(_sharedBundle,
0159: "propertyFor");
0160: public String _propertyRequired = Bundle.getStringTrimmed(
0161: _sharedBundle, "propertyRequired");
0162: public String _propertyRendered = Bundle.getStringTrimmed(
0163: _sharedBundle, "propertyRendered");
0164: public String _propertyValidator = Bundle.getStringTrimmed(
0165: _sharedBundle, "propertyValidator");
0166: public String _propertyConverter = Bundle.getStringTrimmed(
0167: _sharedBundle, "propertyConverter");
0168: public String _propertyMaximum = Bundle.getStringTrimmed(
0169: _sharedBundle, "propertyMaximum");
0170: public String _propertyMinimum = Bundle.getStringTrimmed(
0171: _sharedBundle, "propertyMinimum");
0172: public String _propertyDisabled = Bundle.getStringTrimmed(
0173: _sharedBundle, "propertyDisabled");
0174: public String _properties = Bundle.getStringTrimmed(_sharedBundle,
0175: "properties");
0176: public String _propertySheet = Bundle.getStringTrimmed(
0177: _sharedBundle, "propertySheet");
0178:
0179: //component variables
0180: public String _button1 = Bundle.getStringTrimmed(_sharedBundle,
0181: "button1");
0182: public String _label1 = Bundle.getStringTrimmed(_sharedBundle,
0183: "label1");
0184: public String _message1 = Bundle.getStringTrimmed(_sharedBundle,
0185: "message1");
0186:
0187: public String _textfield1 = Bundle.getStringTrimmed(_sharedBundle,
0188: "textfield1");
0189: public String _textfield2 = Bundle.getStringTrimmed(_sharedBundle,
0190: "textfield2");
0191: public String _textfield3 = Bundle.getStringTrimmed(_sharedBundle,
0192: "textfield3");
0193: public String _textfield4 = Bundle.getStringTrimmed(_sharedBundle,
0194: "textfield4");
0195: public String _textfield5 = Bundle.getStringTrimmed(_sharedBundle,
0196: "textfield5");
0197: public String _textfield6 = Bundle.getStringTrimmed(_sharedBundle,
0198: "textfield6");
0199: public String _textfield7 = Bundle.getStringTrimmed(_sharedBundle,
0200: "textfield7");
0201: public String _textfield8 = Bundle.getStringTrimmed(_sharedBundle,
0202: "textfield8");
0203: public String _textfield9 = Bundle.getStringTrimmed(_sharedBundle,
0204: "textfield9");
0205: public String _textField1 = Bundle.getStringTrimmed(_sharedBundle,
0206: "textField1");
0207: public String _textField3 = Bundle.getStringTrimmed(_sharedBundle,
0208: "textField3");
0209: public String _textField4 = Bundle.getStringTrimmed(_sharedBundle,
0210: "textField4");
0211: public String _textField5 = Bundle.getStringTrimmed(_sharedBundle,
0212: "textField5");
0213: public String _textField6 = Bundle.getStringTrimmed(_sharedBundle,
0214: "textField6");
0215: public String _textField7 = Bundle.getStringTrimmed(_sharedBundle,
0216: "textField7");
0217: public String _textField8 = Bundle.getStringTrimmed(_sharedBundle,
0218: "textField8");
0219: public String _textField9 = Bundle.getStringTrimmed(_sharedBundle,
0220: "textField9");
0221:
0222: public String _textValue0 = Bundle.getStringTrimmed(_privateBundle,
0223: "textValue0");
0224: public String _textValue1 = Bundle.getStringTrimmed(_privateBundle,
0225: "textValue1");
0226: public String _textValue2 = Bundle.getStringTrimmed(_privateBundle,
0227: "textValue2");
0228: public String _textValue3 = Bundle.getStringTrimmed(_privateBundle,
0229: "textValue3");
0230: public String _textValue4 = Bundle.getStringTrimmed(_privateBundle,
0231: "textValue4");
0232:
0233: public String _labelValue1 = Bundle.getStringTrimmed(
0234: _privateBundle, "labelValue1");
0235: public String _labelValue2 = Bundle.getStringTrimmed(
0236: _privateBundle, "labelValue2");
0237: public String _labelValue3 = Bundle.getStringTrimmed(
0238: _privateBundle, "labelValue3");
0239: public String _labelValue4 = Bundle.getStringTrimmed(
0240: _privateBundle, "labelValue4");
0241: public String _labelValue5 = Bundle.getStringTrimmed(
0242: _privateBundle, "labelValue5");
0243: public String _labelValue6 = Bundle.getStringTrimmed(
0244: _privateBundle, "labelValue6");
0245:
0246: public String _newValidatorLength = Bundle.getStringTrimmed(
0247: _sharedBundle, "newValidatorLength");
0248: public String _newIntegerConverter = Bundle.getStringTrimmed(
0249: _sharedBundle, "newIntegerConverter");
0250: public String _lengthValidator1 = Bundle.getStringTrimmed(
0251: _privateBundle, "lengthValidator1");
0252: public String _integerConverter1 = Bundle.getStringTrimmed(
0253: _sharedBundle, "integerConverter1");
0254:
0255: //General
0256: public String _false = Bundle.getStringTrimmed(_sharedBundle,
0257: "false");
0258: public String _two = Bundle.getStringTrimmed(_sharedBundle, "two");
0259: public String _five = Bundle
0260: .getStringTrimmed(_sharedBundle, "five");
0261: public String _six = Bundle.getStringTrimmed(_sharedBundle, "six");
0262: public String _separator = Bundle.getStringTrimmed(_sharedBundle,
0263: "separator");
0264: public String _menuProcessValueChange = Bundle.getStringTrimmed(
0265: _sharedBundle, "menuProcessValueChange");
0266:
0267: //Position variables
0268: public int _x = Integer.parseInt(Bundle.getStringTrimmed(
0269: _privateBundle, "x"));
0270: public int _button1y = Integer.parseInt(Bundle.getStringTrimmed(
0271: _privateBundle, "button1y"));
0272: public int _textfield1y = Integer.parseInt(Bundle.getStringTrimmed(
0273: _privateBundle, "textfield1y"));
0274: public int _textfield2y = Integer.parseInt(Bundle.getStringTrimmed(
0275: _privateBundle, "textfield2y"));
0276: public int _textfield3y = Integer.parseInt(Bundle.getStringTrimmed(
0277: _privateBundle, "textfield3y"));
0278: public int _textfield4y = Integer.parseInt(Bundle.getStringTrimmed(
0279: _privateBundle, "textfield4y"));
0280: public int _textfield5y = Integer.parseInt(Bundle.getStringTrimmed(
0281: _privateBundle, "textfield5y"));
0282: public int _textfield6y = Integer.parseInt(Bundle.getStringTrimmed(
0283: _privateBundle, "textfield6y"));
0284: public int _textfield7y = Integer.parseInt(Bundle.getStringTrimmed(
0285: _privateBundle, "textfield7y"));
0286: public int _textfield8y = Integer.parseInt(Bundle.getStringTrimmed(
0287: _privateBundle, "textfield8y"));
0288: public int _textfield9y = Integer.parseInt(Bundle.getStringTrimmed(
0289: _privateBundle, "textfield9y"));
0290: public int _message1y = Integer.parseInt(Bundle.getStringTrimmed(
0291: _privateBundle, "message1y"));
0292: public int _message2y = Integer.parseInt(Bundle.getStringTrimmed(
0293: _privateBundle, "message2y"));
0294: public int _message3y = Integer.parseInt(Bundle.getStringTrimmed(
0295: _privateBundle, "message3y"));
0296: public int _message4y = Integer.parseInt(Bundle.getStringTrimmed(
0297: _privateBundle, "message4y"));
0298: public int _label1y = Integer.parseInt(Bundle.getStringTrimmed(
0299: _privateBundle, "label1y"));
0300: public int _label2y = Integer.parseInt(Bundle.getStringTrimmed(
0301: _privateBundle, "label2y"));
0302: public int _statictext1y = Integer.parseInt(Bundle
0303: .getStringTrimmed(_privateBundle, "statictext1y"));
0304:
0305: //undeployment
0306: public String _undeploy = Bundle.getStringTrimmed(_sharedBundle,
0307: "undeploy");
0308: public String _refresh = Bundle.getStringTrimmed(_sharedBundle,
0309: "refresh");
0310: public String _serverPath = Bundle.getStringTrimmed(_sharedBundle,
0311: "serverPath");
0312: public String _deploymentPath = Bundle.getStringTrimmed(
0313: _sharedBundle, "deploymentPathGlassfish");
0314:
0315: /** Creates a new instance of AcceptanceTest*/
0316: public AcceptanceTest(String testName) {
0317: super (testName);
0318: }
0319:
0320: public static Test suite() {
0321: TestSuite suite = new NbTestSuite();
0322: suite.addTest(new AcceptanceTest("createWebProject"));
0323:
0324: //Make Page
0325: suite.addTest(new AcceptanceTest("testAddButton"));
0326: suite.addTest(new AcceptanceTest("testAddTextField1"));
0327: suite.addTest(new AcceptanceTest("testAddTextField2"));
0328: suite.addTest(new AcceptanceTest("testAddTextField3"));
0329: suite.addTest(new AcceptanceTest("testAddTextField4"));
0330: suite.addTest(new AcceptanceTest("testAddTextField5"));
0331: suite.addTest(new AcceptanceTest("testAddTextField6"));
0332: suite.addTest(new AcceptanceTest("testAddTextField7"));
0333: suite.addTest(new AcceptanceTest("testAddTextField8"));
0334: suite.addTest(new AcceptanceTest("testAddTextField9"));
0335:
0336: //Deploy
0337: suite.addTest(new AcceptanceTest("testDeploy"));
0338: suite.addTest(new AcceptanceTest("testCheckIDELog"));
0339:
0340: //Verify Runtime
0341: // suite.addTest(new AcceptanceTest("testRuntimeScenario1"));
0342:
0343: //Clean up
0344: suite.addTest(new AcceptanceTest("testCloseWebProject"));
0345: suite.addTest(new AcceptanceTest("testUndeploy"));
0346: return suite;
0347: }
0348:
0349: /** method called before each testcase
0350: */
0351: protected void setUp() {
0352: System.out.println("######## " + getName() + " #######");
0353: }
0354:
0355: /** method called after each testcase
0356: */
0357: protected void tearDown() {
0358: System.out.println("######## " + getName()
0359: + " Finished #######");
0360: }
0361:
0362: /*
0363: * Create Web Project
0364: *
0365: */
0366: public void createWebProject() {
0367: startTest();
0368: log("**Creating Project");
0369: //Create Project
0370: try {
0371: ComponentUtils.createNewProject(_projectName);
0372: } catch (Exception e) {
0373: log(">> Project Creation Failed");
0374: e.printStackTrace();
0375: log(e.toString());
0376: fail();
0377: }
0378: log("**Done");
0379: endTest();
0380: }
0381:
0382: /*
0383: * Add button to designer
0384: * set its value to Execute
0385: *
0386: */
0387: public void testAddButton() {
0388: startTest();
0389: log("**Initialize");
0390: designer = new DesignerPaneOperator(RaveWindowOperator
0391: .getDefaultRave());
0392: palette = new PaletteContainerOperator(_basicPalette);
0393: try {
0394: Thread.sleep(5000);
0395: } catch (Exception e) {
0396: }
0397:
0398: log("**Add Button to designer");
0399: clickPoint = palette.getClickPoint(_basicButton);
0400: dropPoint = new Point(_x, _button1y);
0401: palette.dndPaletteComponent(_basicButton, designer, dropPoint);
0402: try {
0403: Thread.sleep(2000);
0404: } catch (Exception e) {
0405: }
0406:
0407: log("**Set Button text inline");
0408: JTextFieldOperator field = new JTextFieldOperator(designer);
0409: SwingTextKeyboardDriver keyboard = new SwingTextKeyboardDriver();
0410: keyboard.enterText(field, _textValue0);
0411:
0412: log("**Done.");
0413: endTest();
0414: }
0415:
0416: /*
0417: * add textField1,
0418: * set the text value to 'I am a textField'.
0419: *
0420: */
0421: public void testAddTextField1() {
0422: startTest();
0423:
0424: log("**Initialize");
0425: designer = new DesignerPaneOperator(RaveWindowOperator
0426: .getDefaultRave());
0427: palette = new PaletteContainerOperator(_basicPalette);
0428: try {
0429: Thread.sleep(5000);
0430: } catch (Exception e) {
0431: }
0432:
0433: log("**Add textField1 to designer");
0434: clickPoint = palette.getClickPoint(_basicTextField);
0435: dropPoint = new Point(_x, _textfield1y);
0436: palette.dndPaletteComponent(_basicTextField, designer,
0437: dropPoint);
0438: // palette.addComponent(_basicTextField, designer, dropPoint);
0439: try {
0440: Thread.sleep(2000);
0441: } catch (Exception e) {
0442: }
0443:
0444: log("make sure property sheet is visible");
0445: Util.getMainMenu().pushMenu(_propertySheet, _separator);
0446: try {
0447: Thread.sleep(2000);
0448: } catch (Exception e) {
0449: }
0450:
0451: log("**Set Text value via property sheet");
0452: sheet = new SheetTableOperator();
0453: sheet.clickForEdit(sheet.findCell(_propertyText, 2).y, 1);
0454: sheet.clickForEdit(sheet.findCell(_propertyText, 2).y, 1);
0455: new JTextComponentOperator(sheet).enterText(_textValue1);
0456:
0457: log("**Done.");
0458: endTest();
0459:
0460: }
0461:
0462: /*
0463: * add textField2,
0464: * set the label to 'I am a textField label'.
0465: *
0466: */
0467: public void testAddTextField2() {
0468: startTest();
0469:
0470: log("**Initialize");
0471: designer = new DesignerPaneOperator(RaveWindowOperator
0472: .getDefaultRave());
0473: PaletteContainerOperator palette = new PaletteContainerOperator(
0474: _basicPalette);
0475: try {
0476: Thread.sleep(5000);
0477: } catch (Exception e) {
0478: }
0479:
0480: log("**Add TextField2 to Designer");
0481: Point clickPoint = palette.getClickPoint(_basicTextField);
0482: Point dropPoint = new Point(_x, _textfield2y);
0483: palette.dndPaletteComponent(_basicTextField, designer,
0484: dropPoint);
0485: try {
0486: Thread.sleep(2000);
0487: } catch (Exception e) {
0488: }
0489:
0490: log("**Set TextField2 Label property");
0491: sheet = new SheetTableOperator();
0492: int row = sheet.findCellRow(_propertyLabel);
0493: sheet.clickForEdit(row, 1);
0494: sheet.clickForEdit(row, 1);
0495: new JTextComponentOperator(sheet).enterText(_textValue2);
0496:
0497: log("**Done.");
0498: endTest();
0499:
0500: }
0501:
0502: /*
0503: * add textField3
0504: * add a label for textfield3 and give it a name.
0505: * mark textField3 required.
0506: * add a message component linked to textField3
0507: */
0508: public void testAddTextField3() {
0509: startTest();
0510:
0511: log("**Initialize");
0512: designer = new DesignerPaneOperator(RaveWindowOperator
0513: .getDefaultRave());
0514: PaletteContainerOperator palette = new PaletteContainerOperator(
0515: _basicPalette);
0516: try {
0517: Thread.sleep(5000);
0518: } catch (Exception e) {
0519: }
0520:
0521: log("**Add Textfield3 to designer");
0522: Point clickPoint = palette.getClickPoint(_basicTextField);
0523: Point dropPoint = new Point(_x, _textfield3y); //leave room for label
0524: palette.dndPaletteComponent(_basicTextField, designer,
0525: dropPoint);
0526: try {
0527: Thread.sleep(2000);
0528: } catch (Exception e) {
0529: }
0530:
0531: log("**Add label to designer");
0532: clickPoint = palette.getClickPoint(_basicLabel);
0533: dropPoint = new Point(_x, _label1y);
0534: palette.dndPaletteComponent(_basicLabel, designer, dropPoint);
0535: try {
0536: Thread.sleep(2000);
0537: } catch (Exception e) {
0538: }
0539:
0540: log("**Set Label text property");
0541: sheet = new SheetTableOperator();
0542: int row = sheet.findCellRow(_propertyText);
0543: sheet.clickForEdit(row, 1);
0544: sheet.clickForEdit(row, 1);
0545: new JTextComponentOperator(sheet).enterText(_labelValue1);
0546:
0547: log("**Set Label for property to textField3");
0548: row = sheet.findCellRow(_propertyFor);
0549: sheet.clickForEdit(row, 1);
0550: sheet.setComboBoxValue(_propertyFor, _textField3);
0551: try {
0552: Thread.sleep(1000);
0553: } catch (Exception e) {
0554: }
0555:
0556: log("**Select textfield");
0557: designer.clickMouse(_x, _textfield3y, 1);
0558: try {
0559: Thread.sleep(3000);
0560: } catch (Exception e) {
0561: }
0562:
0563: log("**Set required option to true");
0564: row = sheet.findCellRow(_propertyRequired);
0565: sheet.clickForEdit(row, 1);
0566: sheet.setCheckBoxValue(_propertyRequired, _true);
0567: try {
0568: Thread.sleep(2000);
0569: } catch (Exception e) {
0570: }
0571:
0572: log("**Drag Message onto designer");
0573: clickPoint = palette.getClickPoint(_basicMessage);
0574: dropPoint = new Point(_x, _message1y);
0575: palette.dndPaletteComponent(_basicMessage, designer, dropPoint);
0576: try {
0577: Thread.sleep(2000);
0578: } catch (Exception e) {
0579: }
0580:
0581: // log("**Set message via shift-drag and drop onto textField3");
0582:
0583: log("**Set message for property via property sheet");
0584: row = sheet.findCellRow(_propertyFor);
0585: sheet.clickForEdit(row, 1);
0586: sheet.setComboBoxValue(_propertyFor, _textField3);
0587:
0588: log("**Done.");
0589: endTest();
0590:
0591: }
0592:
0593: /*
0594: * add a textField4
0595: * add a staticText field
0596: * add a processValueChange event with code:
0597: * staticText1.setValue(textField4.getValue());
0598: */
0599: public void testAddTextField4() {
0600: startTest();
0601:
0602: log("**Initialize");
0603: designer = new DesignerPaneOperator(RaveWindowOperator
0604: .getDefaultRave());
0605: JToggleButtonOperator toggleButton = new JToggleButtonOperator(
0606: Util.getMainWindow(), "Java");
0607: PaletteContainerOperator palette = new PaletteContainerOperator(
0608: _basicPalette);
0609: try {
0610: Thread.sleep(5000);
0611: } catch (Exception e) {
0612: }
0613:
0614: log("**Add Textfield4 to designer");
0615: Point clickPoint = palette.getClickPoint(_basicTextField);
0616: Point dropPoint = new Point(_x, _textfield4y); //leave room for label
0617: palette.addComponent(_basicTextField, designer, dropPoint);
0618: try {
0619: Thread.sleep(2000);
0620: } catch (Exception e) {
0621: }
0622:
0623: log("**Add StaticText1 to designer");
0624: clickPoint = palette.getClickPoint(_basicStaticText);
0625: dropPoint = new Point(_x, _statictext1y); //leave room for label
0626: palette.addComponent(_basicStaticText, designer, dropPoint);
0627:
0628: log("**select textfield4"); //(25, 175)
0629: // designer.clickMouse(_x+5, _textfield4y+5, 1);
0630: // try { Thread.sleep(2000); } catch(Exception e) {} //wait or sub-menu won't be present.
0631: log("**right click menu on textfield4"); //(25, 175)
0632: //designer = new DesignerPaneOperator(RaveWindowOperator.getDefaultRave());
0633: designer.clickForPopup(_x + 5, _textfield4y + 5);
0634: //wont work either designer.clickForPopup(_textField4);
0635: //stopped working?!? designer.clickForPopup(_x, _textfield4y);
0636: new JPopupMenuOperator().pushMenuNoBlock(
0637: _menuProcessValueChange, _separator);
0638: try {
0639: Thread.sleep(3000);
0640: } catch (Exception e) {
0641: }
0642:
0643: log("**Add code to textfield4_processValueChange");
0644: EditorOperator editor = new EditorOperator(
0645: Util.getMainWindow(), _page1);
0646: editor.requestFocus();
0647: editor.pushDownArrowKey();
0648: editor.txtEditorPane().setText("log(\"Action Performed\");\n");
0649: try {
0650: Thread.sleep(2000);
0651: } catch (Exception e) {
0652: }
0653: designer.switchToDesignerPane();
0654:
0655: log("**Done.");
0656: endTest();
0657: }
0658:
0659: /*
0660: * add a textField5
0661: * set its label text to disabled
0662: * set its value to 'I am disabled'
0663: * mark it disabled
0664: * add a message component linked to textField5
0665: */
0666: public void testAddTextField5() {
0667: startTest();
0668: log("**Initialize");
0669: designer = new DesignerPaneOperator(RaveWindowOperator
0670: .getDefaultRave());
0671: PaletteContainerOperator palette = new PaletteContainerOperator(
0672: _basicPalette);
0673: try {
0674: Thread.sleep(5000);
0675: } catch (Exception e) {
0676: }
0677:
0678: log("**Add Textfield5 to designer");
0679: Point clickPoint = palette.getClickPoint(_basicTextField);
0680: Point dropPoint = new Point(_x, _textfield5y);
0681: palette.dndPaletteComponent(_basicTextField, designer,
0682: dropPoint);
0683:
0684: log("**set its label to 'disabled'");
0685: sheet = new SheetTableOperator();
0686: int row = sheet.findCellRow(_propertyLabel);
0687: sheet.clickForEdit(row, 1);
0688: sheet.clickForEdit(row, 1);
0689: new JTextComponentOperator(sheet).enterText(_labelValue2);
0690:
0691: log("**set its value to 'I am disabled'");
0692: sheet.clickForEdit(sheet.findCell(_propertyText, 2).y, 1);
0693: sheet.clickForEdit(sheet.findCell(_propertyText, 2).y, 1);
0694: new JTextComponentOperator(sheet).enterText(_textValue3);
0695:
0696: log("**mark it disabled");
0697: row = sheet.findCellRow(_propertyDisabled);
0698: sheet.clickForEdit(row, 1);
0699: sheet.setCheckBoxValue(_propertyDisabled, _true);
0700: try {
0701: Thread.sleep(2000);
0702: } catch (Exception e) {
0703: }
0704:
0705: log("**Drag Message onto designer");
0706: clickPoint = palette.getClickPoint(_basicMessage);
0707: dropPoint = new Point(_x, _message2y);
0708: palette.dndPaletteComponent(_basicMessage, designer, dropPoint);
0709: try {
0710: Thread.sleep(2000);
0711: } catch (Exception e) {
0712: }
0713:
0714: log("**Set message for property via property sheet");
0715: row = sheet.findCellRow(_propertyFor);
0716: sheet.clickForEdit(row, 1);
0717: sheet.setComboBoxValue(_propertyFor, _textfield5);
0718:
0719: log("**Done.");
0720: endTest();
0721: }
0722:
0723: /*
0724: * add textField6,
0725: * set its label to max = 5.
0726: * change its maxLength property to 5
0727: */
0728: public void testAddTextField6() {
0729: startTest();
0730:
0731: log("**Initialize");
0732: designer = new DesignerPaneOperator(RaveWindowOperator
0733: .getDefaultRave());
0734: PaletteContainerOperator palette = new PaletteContainerOperator(
0735: _basicPalette);
0736: try {
0737: Thread.sleep(5000);
0738: } catch (Exception e) {
0739: }
0740:
0741: log("**Add Textfield6 to designer");
0742: Point clickPoint = palette.getClickPoint(_basicTextField);
0743: Point dropPoint = new Point(_x, _textfield6y);
0744: palette.dndPaletteComponent(_basicTextField, designer,
0745: dropPoint);
0746: try {
0747: Thread.sleep(2000);
0748: } catch (Exception e) {
0749: }
0750:
0751: log("**set its label to 'max = 5'");
0752: sheet = new SheetTableOperator();
0753: int row = sheet.findCellRow(_propertyLabel);
0754: sheet.clickForEdit(row, 1);
0755: sheet.clickForEdit(row, 1);
0756: new JTextComponentOperator(sheet).enterText(_labelValue3);
0757:
0758: log("**set its value to 5");
0759: row = sheet.findCellRow(_propertyMaxLength);
0760: sheet.clickForEdit(row, 1);
0761: sheet.clickForEdit(row, 1);
0762: new JTextComponentOperator(sheet).enterText(_five);
0763:
0764: log("**Done.");
0765: endTest();
0766: }
0767:
0768: /*
0769: * add in a label with text Not rendered
0770: * add textField7
0771: * set rendered=false (though visible is more frequently used)
0772: */
0773: public void testAddTextField7() {
0774: startTest();
0775:
0776: log("**Initialize");
0777: designer = new DesignerPaneOperator(RaveWindowOperator
0778: .getDefaultRave());
0779: PaletteContainerOperator palette = new PaletteContainerOperator(
0780: _basicPalette);
0781: try {
0782: Thread.sleep(5000);
0783: } catch (Exception e) {
0784: }
0785:
0786: log("**Add label to designer");
0787: Point clickPoint = palette.getClickPoint(_basicLabel);
0788: Point dropPoint = new Point(_x, _label2y);
0789: palette.dndPaletteComponent(_basicLabel, designer, dropPoint);
0790: try {
0791: Thread.sleep(2000);
0792: } catch (Exception e) {
0793: }
0794:
0795: // Doesnt seem to work the same as button so used property sheet instead
0796: // log("**Set label value inline");
0797:
0798: log("**Set Label text property");
0799: sheet = new SheetTableOperator();
0800: int row = sheet.findCellRow(_propertyText);
0801: sheet.clickForEdit(row, 1);
0802: sheet.clickForEdit(row, 1);
0803: new JTextComponentOperator(sheet).enterText(_labelValue4);
0804:
0805: log("**Add Textfield7 to designer");
0806: clickPoint = palette.getClickPoint(_basicTextField);
0807: dropPoint = new Point(_x, _textfield7y); //leave room for label
0808: palette.dndPaletteComponent(_basicTextField, designer,
0809: dropPoint);
0810: // designer.clickMouse(_x, textfield7y, 1);
0811: try {
0812: Thread.sleep(2000);
0813: } catch (Exception e) {
0814: }
0815:
0816: log("**set textfield rendered property to false");
0817: row = sheet.findCellRow(_propertyRendered);
0818: sheet.clickForEdit(row, 1);
0819: sheet.setCheckBoxValue(_propertyRendered, _false);
0820:
0821: log("**Done.");
0822: endTest();
0823: }
0824:
0825: /*
0826: * add a length validator to designer
0827: * set the max=6
0828: * set the min=2
0829: * add textField8,
0830: * set label to 'length validator,
0831: * set validator = lengthValidator1
0832: * Add a message component linked to textField8
0833: */
0834: public void testAddTextField8() {
0835: startTest();
0836:
0837: log("**Initialize");
0838: designer = new DesignerPaneOperator(RaveWindowOperator
0839: .getDefaultRave());
0840: PaletteContainerOperator palette = new PaletteContainerOperator(
0841: _basicPalette);
0842: PaletteContainerOperator validatorPalette = new PaletteContainerOperator(
0843: _validatorPalette);
0844: try {
0845: Thread.sleep(5000);
0846: } catch (Exception e) {
0847: }
0848:
0849: log("**Add Textfield8 to designer");
0850: Point clickPoint = palette.getClickPoint(_basicTextField);
0851: Point dropPoint = new Point(_x, _textfield8y); //leave room for label
0852: palette.dndPaletteComponent(_basicTextField, designer,
0853: dropPoint);
0854: try {
0855: Thread.sleep(2000);
0856: } catch (Exception e) {
0857: }
0858:
0859: log("**set its label to 'length validator'");
0860: int row = sheet.findCellRow(_propertyLabel);
0861: sheet.clickForEdit(row, 1);
0862: sheet.clickForEdit(row, 1);
0863: new JTextComponentOperator(sheet).enterText(_labelValue5);
0864:
0865: log("**Set validator property to '(new lengthValidator)'");
0866: row = sheet.findCellRow(_propertyValidator);
0867: sheet.clickForEdit(row, 1);
0868: sheet.setComboBoxValue(_propertyValidator, _newValidatorLength);
0869:
0870: log("**Select lengthValidator1 from Outline window");
0871: String path = _outlinePage1 + _lengthValidator1;
0872: DocumentOutlineOperator doo = new DocumentOutlineOperator(Util
0873: .getMainWindow());
0874: Util.wait(2000);
0875: doo.verify();
0876: // doo.clickOnPath(path);
0877: doo.selectPath(path);
0878: Util.wait(5000);
0879:
0880: log("**set its max value '6'");
0881: row = sheet.findCellRow(_propertyMaximum);
0882: sheet.clickForEdit(row, 1);
0883: sheet.clickForEdit(row, 1);
0884: new JTextComponentOperator(sheet).enterText(_six);
0885:
0886: log("**set its min value '2'");
0887: row = sheet.findCellRow(_propertyMinimum);
0888: sheet.clickForEdit(row, 1);
0889: sheet.clickForEdit(row, 1);
0890: new JTextComponentOperator(sheet).enterText(_two);
0891:
0892: log("**Drag Message onto designer");
0893: clickPoint = palette.getClickPoint(_basicMessage);
0894: dropPoint = new Point(_x, _message3y);
0895: palette.dndPaletteComponent(_basicMessage, designer, dropPoint);
0896: try {
0897: Thread.sleep(2000);
0898: } catch (Exception e) {
0899: }
0900:
0901: log("**Set message for property via property sheet");
0902: row = sheet.findCellRow(_propertyFor);
0903: sheet.clickForEdit(row, 1);
0904: sheet.setComboBoxValue(_propertyFor, _textfield8);
0905:
0906: log("**Done.");
0907: endTest();
0908: }
0909:
0910: /*
0911: * add a integer converter to the designer
0912: * add textField9,
0913: * set label to 'integer converter',
0914: * set converter = integerConverter1
0915: * Add a message component linked to textField9
0916: */
0917: public void testAddTextField9() {
0918: startTest();
0919:
0920: log("**Initialize");
0921: designer = new DesignerPaneOperator(RaveWindowOperator
0922: .getDefaultRave());
0923: PaletteContainerOperator palette = new PaletteContainerOperator(
0924: _basicPalette);
0925: try {
0926: Thread.sleep(5000);
0927: } catch (Exception e) {
0928: }
0929:
0930: //Drag & drop converter from palette fails, used properties new converter instead
0931: /*
0932: PaletteContainerOperator converterPalette = new PaletteContainerOperator(_converterPalette);
0933: try { Thread.sleep(5000); } catch(Exception e) {}
0934:
0935: log("**Add Integer converter to designer");
0936: Point clickPoint = converterPalette.getClickPoint(_converterInteger);
0937: log(_converterInteger + " can be found at" + clickPoint.toString());
0938: Point dropPoint = new Point(10, 20); //empty space
0939: palette.clickMouse(clickPoint.x, clickPoint.y, 1);
0940: designer.clickMouse(dropPoint.x, dropPoint.y, 1);
0941: // palette.addComponent(_converterInteger, designer, dropPoint);
0942: // palette.dndPaletteComponent(_converterInteger, designer, dropPoint);
0943: try { Thread.sleep(2000); } catch(Exception e) {}
0944: */
0945:
0946: log("**Add Textfield9 to designer");
0947: Point clickPoint = palette.getClickPoint(_basicTextField);
0948: Point dropPoint = new Point(_x, _textfield9y);
0949: palette.dndPaletteComponent(_basicTextField, designer,
0950: dropPoint);
0951: try {
0952: Thread.sleep(2000);
0953: } catch (Exception e) {
0954: }
0955:
0956: log("**set its label to 'integer converter'");
0957: sheet = new SheetTableOperator();
0958: int row = sheet.findCellRow(_propertyLabel);
0959: sheet.clickForEdit(row, 1);
0960: sheet.clickForEdit(row, 1);
0961: new JTextComponentOperator(sheet).enterText(_labelValue6);
0962:
0963: log("**Set converter property to '(new IntegerConverter)'");
0964: row = sheet.findCellRow(_newIntegerConverter);
0965: sheet.clickForEdit(row, 1);
0966: sheet
0967: .setComboBoxValue(_propertyConverter,
0968: _newIntegerConverter);
0969:
0970: log("**Drag Message onto designer");
0971: clickPoint = palette.getClickPoint(_basicMessage);
0972: dropPoint = new Point(_x, _message4y);
0973: palette.dndPaletteComponent(_basicMessage, designer, dropPoint);
0974: try {
0975: Thread.sleep(2000);
0976: } catch (Exception e) {
0977: }
0978:
0979: log("**Set message for property via property sheet");
0980: row = sheet.findCellRow(_propertyFor);
0981: sheet.clickForEdit(row, 1);
0982: //combobox is no longer present when you get more than 8 textFields so this line fails
0983: // sheet.setComboBoxValue(_propertyFor, _textField9);
0984: sheet.setTextValue(_propertyFor, _textField9);
0985:
0986: log("**Done.");
0987: endTest();
0988: }
0989:
0990: /*
0991: * Deploy application
0992: */
0993: public void testDeploy() {
0994: startTest();
0995: //need to wait responce
0996: Waiter deploymentWaiter = new Waiter(new Waitable() {
0997: public Object actionProduced(Object output) {
0998: String text = ((OutputOperator) output).getText();
0999: if (text.indexOf(_buildSuccess) != -1)
1000: return _true;
1001: return null;
1002:
1003: }
1004:
1005: public String getDescription() {
1006: return ("Waiting Project Deployed");
1007: }
1008: });
1009: log("Deploy from menu");
1010: ProjectNavigatorOperator.pressPopupItemOnNode(_projectName,
1011: _run);
1012: TestUtils.wait(2000);
1013: OutputOperator outputWindow = new OutputOperator();
1014: deploymentWaiter.getTimeouts().setTimeout("Waiter.WaitingTime",
1015: 240000);
1016: log("wait until " + _buildSuccess);
1017: try {
1018: deploymentWaiter.waitAction(outputWindow);
1019: } catch (InterruptedException e) {
1020: log(outputWindow.getText());
1021: e.printStackTrace();
1022: fail("Deployment error: " + e);
1023: }
1024: log("Deployment complete");
1025: endTest();
1026: }
1027:
1028: /*
1029: * Runtime testing
1030: *
1031: */
1032: public void runtimeScenario1() {
1033: startTest();
1034: endTest();
1035: /*
1036:
1037: log("**Verify insync changes jsp");
1038: designer.switchToJSPSource();
1039: //This string should present in JSP editor
1040: String verStr = _propertyText + "=\"" + _textValue0 +"\"";
1041: Util.saveAllAPICall();
1042: assertFalse("There is no \"verStr\" string in jsp editor",
1043: new org.netbeans.jellytools.EditorOperator(_page1).getText().indexOf(verStr)==-1);
1044:
1045: log("**Done. Return to designer");
1046: designer.switchToDesignerPane();
1047:
1048: log("**Verify insync changes jsp");
1049: designer.switchToJSPSource();
1050: //This string should present in JSP editor
1051: String verStr = _propertyText + "=\"" + _textValue1 +"\"";
1052: Util.saveAllAPICall();
1053: assertFalse("There is no \"verStr\" string in jsp editor",
1054: new org.netbeans.jellytools.EditorOperator(_page1).getText().indexOf(verStr)==-1);
1055:
1056: log("**Done. Return to designer");
1057: designer.switchToDesignerPane();
1058:
1059:
1060: log("**Verify insync made changes to jsp");
1061: designer.switchToJSPSource();
1062: //This string should present in JSP editor
1063: String verStr = _propertyLabel + "=\"" + _textValue2 +"\"";
1064: Util.saveAllAPICall();
1065: assertFalse("There is no \"verStr\" string in jsp editor",
1066: new org.netbeans.jellytools.EditorOperator(_page1).getText().indexOf(verStr)==-1);
1067:
1068: log("**Done. Return to designer");
1069: designer.switchToDesignerPane();
1070:
1071: log("**Set message for property via property sheet");
1072: // sheet = new SheetTableOperator();
1073: row = sheet.findCellRow(_propertyFor);
1074: sheet.clickForEdit(row, 1);
1075: sheet.setComboBoxValue(_propertyFor, _textfield3);
1076:
1077: log("**Verify insync changes to jsp");
1078: designer.switchToJSPSource();
1079: //This string should present in JSP editor
1080: String verStr = _propertyText + "=\"" + _labelValue1 +"\"";
1081: Util.saveAllAPICall();
1082: assertFalse("There is no \"verStr\" string in jsp editor",
1083: new org.netbeans.jellytools.EditorOperator(_page1).getText().indexOf(verStr)==-1);
1084: log("Found: " + verStr);
1085:
1086: verStr = _propertyFor + "=\"" + _textField3 +"\"";
1087: Util.saveAllAPICall();
1088: assertFalse("There is no \"verStr\" string in jsp editor",
1089: new org.netbeans.jellytools.EditorOperator(_page1).getText().indexOf(verStr)==-1);
1090: log("Found: " + verStr);
1091:
1092: verStr = _propertyRequired + "=\"" + _true +"\"";
1093: Util.saveAllAPICall();
1094: assertFalse("There is no \"verStr\" string in jsp editor",
1095: new org.netbeans.jellytools.EditorOperator(_page1).getText().indexOf(verStr)==-1);
1096: log("Found: " + verStr);
1097:
1098: verStr = _propertyFor + "=\"" + _textField3 +"\"";
1099: Util.saveAllAPICall();
1100: assertFalse("There is no \"verStr\" string in jsp editor",
1101: new org.netbeans.jellytools.EditorOperator(_page1).getText().indexOf(verStr)==-1);
1102: log("Found: " + verStr);
1103:
1104: log("**Return to designer");
1105: designer.switchToDesignerPane();
1106:
1107: log("**Verify insync changes to jsp");
1108: designer.switchToJSPSource();
1109: //This string should present in JSP editor
1110: String verStr = _propertyLabel + "=\"" + _labelValue2 +"\"";
1111: Util.saveAllAPICall();
1112: assertFalse("There is no \"verStr\" string in jsp editor",
1113: new org.netbeans.jellytools.EditorOperator(_page1).getText().indexOf(verStr)==-1);
1114: log("Found: " + verStr);
1115:
1116: verStr = _propertyDisabled + "=\"" + _true +"\"";
1117: Util.saveAllAPICall();
1118: assertFalse("There is no \"verStr\" string in jsp editor",
1119: new org.netbeans.jellytools.EditorOperator(_page1).getText().indexOf(verStr)==-1);
1120: log("Found: " + verStr);
1121:
1122: verStr = _propertyText + "=\"" + _textValue3 +"\"";
1123: Util.saveAllAPICall();
1124: assertFalse("There is no \"verStr\" string in jsp editor",
1125: new org.netbeans.jellytools.EditorOperator(_page1).getText().indexOf(verStr)==-1);
1126: log("Found: " + verStr);
1127:
1128: log("**Return to designer");
1129: designer.switchToDesignerPane();
1130:
1131: */
1132: }
1133:
1134: //should echo values at runtime
1135: //submit should occur error free even though disabled. text should appear, even if disable, user should not be able to change value.
1136: //user should not be able to type in more than 5 characters.
1137: //should not render in designer, if view source it should not be in html.
1138: //values less than 2 and greater than 6 should give validation errors.
1139:
1140: /*
1141: * Undeploy Web Project
1142: *
1143: */
1144: public void undeployWebProject() {
1145: startTest();
1146: endTest();
1147: }
1148:
1149: /*
1150: * Close Project
1151: *
1152: */
1153: public void testCloseWebProject() {
1154: startTest();
1155: Util.saveAllAPICall();
1156: new ProjectNavigatorOperator().pressPopupItemOnNode(
1157: _projectName, _close);
1158: //TestUtils.closeCurrentProject();
1159: TestUtils.wait(5000);
1160: endTest();
1161: }
1162:
1163: /* Need to undeploy project to finish tests correctly */
1164: public void testUndeploy() {
1165: startTest();
1166: log("Initialize");
1167: explorer = ServerNavigatorOperator.showNavigatorOperator();
1168: String serverPath = _serverPath + _projectServer; //Current deployment server
1169: String deploymentPath = serverPath + _deploymentPath; //glassfish specific
1170: String applicationPath = deploymentPath + _separator
1171: + _projectName; //project name
1172:
1173: // Select the Server Navigator and set the JTreeOperator
1174: log("get explorer");
1175: new QueueTool().waitEmpty(100); //??
1176: explorer.requestFocus();
1177: JTreeOperator tree = explorer.getTree();
1178: try {
1179: Thread.sleep(4000);
1180: } catch (Exception e) {
1181: } // Sleep 4 secs to make sure Server Navigator is in focus
1182:
1183: // Need to refresh J2EE AppServer node
1184: log("refresh");
1185: explorer.pushPopup(tree, serverPath, _refresh);
1186: TestUtils.wait(1000);
1187:
1188: log("refresh deployment path: " + deploymentPath);
1189: TestUtils.wait(1000);
1190: explorer.selectPath(deploymentPath);
1191: explorer.getTree().expandPath(
1192: explorer.getTree().findPath(deploymentPath));
1193: explorer.pushPopup(tree, deploymentPath, _refresh);
1194: TestUtils.wait(1000);
1195:
1196: log("undeploy Path: " + applicationPath);
1197: explorer.selectPath(applicationPath);
1198: TestUtils.wait(1000);
1199:
1200: log("Push Menu Undeploy...");
1201: explorer.pushPopup(explorer.getTree(), applicationPath,
1202: _undeploy);
1203: TestUtils.wait(5000);
1204: endTest();
1205: }
1206:
1207: public void testCheckIDELog() {
1208: startTest();
1209: try {
1210: String err = ComponentUtils.hasUnexpectedException();
1211: String str = "";
1212: if (!(err.equals(""))) {
1213: assertTrue(
1214: "Unexpected exceptions found in message.log: "
1215: + err, str.equals(""));
1216: }
1217: } catch (IOException ioe) {
1218: ioe.printStackTrace();
1219: fail("Failed to open message.log : " + ioe);
1220: }
1221: endTest();
1222: }
1223: }
|