alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  

What this is

This file is included in the DevDaily.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Other links

The source code

/*
 *                 Sun Public License Notice
 *
 * The contents of this file are subject to the Sun Public License
 * Version 1.0 (the "License"). You may not use this file except in
 * compliance with the License. A copy of the License is available at
 * http://www.sun.com/
 *
 * The Original Code is NetBeans. The Initial Developer of the Original
 * Code is Sun Microsystems, Inc. Portions Copyright 1997-2003 Sun
 * Microsystems, Inc. All Rights Reserved.
 */
package org.netbeans.modules.xml.catalog;

import java.lang.reflect.Method;
import junit.framework.Test;
import junit.framework.TestSuite;
import junit.textui.TestRunner;
import org.netbeans.api.xml.services.UserCatalog;
import org.netbeans.jellytools.Bundle;
import org.netbeans.jellytools.EditorOperator;
import org.netbeans.jellytools.NbDialogOperator;
import org.netbeans.jellytools.modules.xml.catalog.MountCatalogDialogOperator;
import org.netbeans.jellytools.modules.xml.catalog.NbCatalogCustomizerDialogOperator;
import org.netbeans.jellytools.modules.xml.catalog.OASISCatalogCustomizerDialogOperator;
import org.netbeans.jellytools.modules.xml.catalog.XMLCatalogCustomizerDialogOperator;
import org.netbeans.jellytools.modules.xml.catalog.nodes.CatalogEntryNode;
import org.netbeans.jellytools.modules.xml.catalog.nodes.CatalogNode;
import org.netbeans.jellytools.modules.xml.catalog.nodes.XMLEntityCatalogsNode;
import org.netbeans.jemmy.JemmyException;
import org.netbeans.jemmy.JemmyProperties;
import org.netbeans.junit.NbTestSuite;
import org.netbeans.tests.xml.JXTest;
import org.openide.filesystems.FileObject;
import org.xml.sax.EntityResolver;
import org.xml.sax.InputSource;



/**
 * 

*

* * *
XML Module Jelly Test: XCatalog *
*
*

What it tests:
* * The test tests all the XCatalog's features. * *

How it works:
* The test executes all the actions mentoined in Manual Test Suite for XCatalog. *

    *
  1. Check if XCatalog is present
  2. *
  3. Mount XCatalog
  4. *
  5. Check Refresh action
  6. *
  7. Check Customize dialog
  8. *
  9. Check Properties
  10. *
  11. Copy and Paste
  12. *
  13. Unmount XCatalog
  14. * *
*

Settings:
* none
* *

Created on March 08, 2001, 12:33 PM *

*/ public class CatalogTest extends JXTest { /** Creates new CatalogTest */ public CatalogTest(String testName) { super(testName); } // TESTS /////////////////////////////////////////////////////////////////// public void testMountCatalogDialog() throws Exception { XMLEntityCatalogsNode.getInstance().mountCatalog(); // Nb Dialog modification MountCatalogDialogOperator mcdo = new MountCatalogDialogOperator(); mcdo.selectCatalogType(mcdo.ITEM_NETBEANSCATALOG); mcdo.verifyNb(); // OASIS Dialog modification mcdo.selectCatalogType(mcdo.ITEM_OASISCATALOGRESOLVER); mcdo.verifyOASIS(); // XML Dialog modification mcdo.selectCatalogType(mcdo.ITEM_XMLCATALOG); mcdo.verifyXML(); mcdo.cancel(); } public void testNetbeansCatalog() throws Exception { String catType = MountCatalogDialogOperator.ITEM_NETBEANSCATALOG; String catUrl = null; String catName = Bundle.getString("org.netbeans.modules.xml.catalog.impl.Bundle" , "NAME_system_catalog"); String checkEntity = "-//NetBeans//DTD Filesystem 1.0//EN"; String checkStr = "

... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.