1 19 20 package org.netbeans.core.windows.awt; 21 22 import java.io.InputStream ; 23 import junit.framework.*; 24 import org.netbeans.junit.*; 25 import org.openide.cookies.InstanceCookie; 26 27 import org.openide.filesystems.*; 28 import org.openide.loaders.*; 29 30 34 public class ValidateLayerToolbarTest extends ValidateLayerMenuTest { 35 36 37 public ValidateLayerToolbarTest(String name) { 38 super (name); 39 } 40 41 44 public static void main(java.lang.String [] args) { 45 junit.textui.TestRunner.run(suite()); 46 } 47 48 public static Test suite() { 49 TestSuite suite = new NbTestSuite(ValidateLayerToolbarTest.class); 50 51 return suite; 52 } 53 54 58 protected String rootName () { 59 return "Toolbars"; 60 } 61 62 63 protected boolean skipFile (FileObject fo) { 64 return false; 65 } 66 67 protected boolean correctInstance (Object obj) { 68 if (obj instanceof javax.swing.Action ) { 69 return true; 70 } 71 if (obj instanceof org.openide.util.actions.Presenter.Toolbar) { 72 return true; 73 } 74 if (obj instanceof javax.swing.JToolBar.Separator) { 75 return true; 76 } 77 if (obj instanceof org.openide.awt.ToolbarPool.Configuration) { 78 return true; 80 } 81 if (obj instanceof java.awt.Component ) { 82 return true; 84 } 85 86 return false; 87 } 88 89 93 } 94 95 | Popular Tags |