JBoss Tools SVN: r33575 - trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2011-08-03 20:54:46 -0400 (Wed, 03 Aug 2011)
New Revision: 33575
Modified:
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/XModelFactory.java
Log:
Factory method changed to use singleton holder pattern instead of double check pattern
Modified: trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/XModelFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/XModelFactory.java 2011-08-04 00:53:22 UTC (rev 33574)
+++ trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/XModelFactory.java 2011-08-04 00:54:46 UTC (rev 33575)
@@ -13,21 +13,22 @@
import org.jboss.tools.common.model.util.*;
/**
- * Factory class to create instances of XModel interface.
- * See getDefaultInstance() method for details.
+ * Factory class to create instances of XModel interface. See
+ * getDefaultInstance() method for details.
+ *
* @author IShabalov
*/
public class XModelFactory {
-
- static public final String META_PATH = "/meta"; //$NON-NLS-1$
-
+
+ static public final String META_PATH = "/meta"; //$NON-NLS-1$
+
private static XModel defaultInstance = null;
private static Object monitor = new Object();
-
+
public static XModel getModel(Properties p) {
return createInstance(p);
}
-
+
private static final XModel createInstance(Properties p) {
XModelConstants.validate(p);
XModelMetaData meta = XModelMetaDataImpl.getInstance();
@@ -35,22 +36,21 @@
model.load();
return model;
}
-
- /** Use this method to obtain default instance of interface org.jboss.tools.common.model.XModel
- * This implementation return single instance and create it if it was not created yet.
+
+ /**
+ * Use this method to obtain default instance of interface
+ * org.jboss.tools.common.model.XModel This implementation return single
+ * instance and create it if it was not created yet.
+ *
* @return default XModel instance.
- *
- */
+ *
+ */
public static final XModel getDefaultInstance() {
- if (defaultInstance != null) {
- return defaultInstance;
- } else {
- synchronized (monitor) {
- if (defaultInstance == null) {
- defaultInstance = createInstance(ClassLoaderUtil.getProperties());
- }
- }
- return defaultInstance;
- }
+ return DefaultModelHolder.DEFAULT_INSTANCE;
}
+
+ private static final class DefaultModelHolder {
+ static final XModel DEFAULT_INSTANCE = defaultInstance = createInstance(ClassLoaderUtil
+ .getProperties());
+ }
}
13 years, 5 months
JBoss Tools SVN: r33574 - trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/filesystems/impl.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2011-08-03 20:53:22 -0400 (Wed, 03 Aug 2011)
New Revision: 33574
Modified:
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/filesystems/impl/FolderImpl.java
Log:
removed unnecessary null checks and file.exists() methods
Modified: trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/filesystems/impl/FolderImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/filesystems/impl/FolderImpl.java 2011-08-04 00:52:19 UTC (rev 33573)
+++ trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/filesystems/impl/FolderImpl.java 2011-08-04 00:53:22 UTC (rev 33574)
@@ -71,7 +71,6 @@
// protected Map<String, IResource> linkedResources = new HashMap<String, IResource>();
public static File toFile(IResource resource) {
- if(resource == null) return null;
File f = null;
IPath path = resource.getLocation();
if(path == null || true) {
@@ -154,8 +153,7 @@
File f = getFile();
if(f == null) return null;
if (!f.isDirectory()) return new File[0];
- File[] fs = f.listFiles();
- return (fs == null) ? new File[0] : fs;
+ return f.listFiles();
}
public void set(String name, String value) {
13 years, 5 months
JBoss Tools SVN: r33573 - trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/filesystems/impl.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2011-08-03 20:52:19 -0400 (Wed, 03 Aug 2011)
New Revision: 33573
Modified:
trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/filesystems/impl/FileSystemPeer.java
Log:
changed(File) method uses file directly without wrapping it with Info object first. For cdi ui tests it is called about 500000 times and it is one of 4 methods with top execution time
Modified: trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/filesystems/impl/FileSystemPeer.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/filesystems/impl/FileSystemPeer.java 2011-08-04 00:20:33 UTC (rev 33572)
+++ trunk/common/plugins/org.jboss.tools.common.model/src/org/jboss/tools/common/model/filesystems/impl/FileSystemPeer.java 2011-08-04 00:52:19 UTC (rev 33573)
@@ -64,16 +64,20 @@
long lastModified;
long length;
Info(File f) {
- lastModified = !f.exists() ? 0 : f.lastModified();
- length = f.isFile() && f.exists() ? f.length() : 0;
+ lastModified = f.lastModified();
+ length = f.length();
}
public boolean equals(Info other) {
return lastModified != other.lastModified || length != other.length;
}
-
+
+ public boolean equals(File other) {
+ return lastModified != other.lastModified() || length != other.length();
+ }
+
public boolean changed(File f) {
- return equals(new Info(f));
+ return equals(f);
}
}
13 years, 5 months
JBoss Tools SVN: r33572 - trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation.
by jbosstools-commits@lists.jboss.org
Author: akazakov
Date: 2011-08-03 20:20:33 -0400 (Wed, 03 Aug 2011)
New Revision: 33572
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDICoreValidator.java
Log:
https://issues.jboss.org/browse/JBIDE-9451
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDICoreValidator.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDICoreValidator.java 2011-08-04 00:12:27 UTC (rev 33571)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDICoreValidator.java 2011-08-04 00:20:33 UTC (rev 33572)
@@ -203,11 +203,11 @@
projectTree = validationHelper.getValidationContextManager().getValidatingProjectTree(this);
projectSet = projectTree.getBrunches().get(rootProject);
cdiProject = null;
- CDICoreNature nature = CDICorePlugin.getCDI(projectSet.getRootProject(), false);
+ CDICoreNature nature = CDICorePlugin.getCDI(projectSet.getRootProject(), true);
if(nature!=null) {
cdiProject = nature.getDelegate();
if(cdiProject==null) {
- CDICorePlugin.getDefault().logError("Trying to validate " + rootProject + " but CDI Tools model for the project is not buit.");
+ CDICorePlugin.getDefault().logError("Trying to validate " + rootProject + " but CDI Tools model for the project is not built.");
}
injectionValidationFeatures = nature.getExtensionManager().getFeatures(IInjectionPointValidatorFeature.class);
}
13 years, 5 months
JBoss Tools SVN: r33571 - in trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US: images and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: irooskov(a)redhat.com
Date: 2011-08-03 20:12:27 -0400 (Wed, 03 Aug 2011)
New Revision: 33571
Added:
trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog_02.png
trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog_03.png
Modified:
trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/Book_Info.xml
trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog.png
trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/setting_preferences-task.xml
Log:
updated for TOOLSDOC-231
Modified: trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/Book_Info.xml
===================================================================
--- trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/Book_Info.xml 2011-08-04 00:08:29 UTC (rev 33570)
+++ trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/Book_Info.xml 2011-08-04 00:12:27 UTC (rev 33571)
@@ -9,7 +9,7 @@
<productname>JBoss Developer Studio</productname>
<productnumber>4.1</productnumber>
<edition>4.1.0</edition>
- <pubsnumber>1</pubsnumber>
+ <pubsnumber>2</pubsnumber>
<abstract>
<para>
ModeShape Tools provides the ability to publish and remove content from ModeShape repositories.
Modified: trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog.png
===================================================================
(Binary files differ)
Added: trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog_02.png
===================================================================
(Binary files differ)
Property changes on: trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog_02.png
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog_03.png
===================================================================
(Binary files differ)
Property changes on: trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog_03.png
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Modified: trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/setting_preferences-task.xml
===================================================================
--- trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/setting_preferences-task.xml 2011-08-04 00:08:29 UTC (rev 33570)
+++ trunk/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/setting_preferences-task.xml 2011-08-04 00:12:27 UTC (rev 33571)
@@ -6,7 +6,11 @@
<section id="sect-ModeShape_Tools_Reference_Guide-Tasks-Setting_preferences">
<title>Setting preferences</title>
<para>
- The ModeShape <guilabel>Preferences</guilabel> dialog allows you to set specific file types and folders that you never wish to have published to or unpublished from a ModeShape repository. This dialog is accessed by navigating to <menuchoice><guimenuitem>Window</guimenuitem><guimenuitem>Preferences</guimenuitem><guimenuitem>ModeShape</guimenuitem></menuchoice>.
+ The ModeShape <guilabel>Preferences</guilabel> dialog allows for resource versioning to be set along with specific file types and folders that you never wish to have published to or unpublished from a ModeShape repository. This dialog is accessed by navigating to <menuchoice>
+ <guimenuitem>Window</guimenuitem>
+ <guimenuitem>Preferences</guimenuitem>
+ <guimenuitem>ModeShape</guimenuitem>
+ </menuchoice>.
</para>
<figure id="Preferences_dialog">
<title>ModeShape preferences dialog</title>
@@ -17,10 +21,35 @@
</mediaobject>
</figure>
<para>
- To add a new file extension type or folder name to be filtered from publishing, click on the corresponding <guibutton>New</guibutton> button, enter the details and click the <guibutton>Apply</guibutton> button so that your preference changes are saved.
- </para>
+ This dialog allows you to set whether resource versioning will be used for your ModeShape repository or not. Ensure the <guilabel>Enable resource versioning</guilabel> checkbox is ticked for resource versioning to be activated.
+ </para>
+ <para>
+ To manage the resources to be published to the repository, click on the <guimenuitem>Ignored Resources</guimenuitem> menu item under <guimenuitem>ModeShape</guimenuitem> in the main left <guilabel>Preferences</guilabel> menu.
+ </para>
+ <figure id="Preferences_dialog_02">
+ <title>ModeShape: Ignored Resources preferences dialog</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/Preferences_dialog_02.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ <para>
+ At this screen you can manage the resources that will not be published to your ModeShape repository. The current excluded file types and folders is presented in the list of checkbox items that appears under the <guilabel>Ignored Resources</guilabel> heading.
+ </para>
+ <para>
+ To add a new file extension type or folder name to be filtered from publishing, click on the <guibutton>New</guibutton> button, enter the details and click the <guibutton>Apply</guibutton> button so that your preference changes are saved.
+ </para>
+ <figure id="Preferences_dialog_03">
+ <title>ModeShape: Ignored Resources preferences dialog</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/Preferences_dialog_03.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
<para>
- Removing an entry is conducted by selecting an entry from one of the lists in the <guilabel>Preferences</guilabel> dialog and clicking on the <guibutton>Remove</guibutton> button. Ensure that you click the <guibutton>Apply</guibutton> button so that your preference changes are saved.
+ Removing an entry is conducted by selecting an entry from the list in the <guilabel>Preferences</guilabel> dialog and clicking on the <guibutton>Remove</guibutton> button. Ensure that you click the <guibutton>Apply</guibutton> button so that your preference changes are saved.
</para>
<para>
As the <guilabel>Preferences</guilabel> dialog lists file types and folders that will never be published to a repository, it follows that those listed will never be unpublished. If you decide to never have a certain file type or folder publishable, though it has been in the past, ensure that all instances of these are unpublished before setting any preferences for the file type or folder.
13 years, 5 months
JBoss Tools SVN: r33570 - branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US.
by jbosstools-commits@lists.jboss.org
Author: irooskov(a)redhat.com
Date: 2011-08-03 20:08:29 -0400 (Wed, 03 Aug 2011)
New Revision: 33570
Modified:
branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/setting_preferences-task.xml
Log:
updated to fix two id errors
Modified: branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/setting_preferences-task.xml
===================================================================
--- branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/setting_preferences-task.xml 2011-08-04 00:06:37 UTC (rev 33569)
+++ branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/setting_preferences-task.xml 2011-08-04 00:08:29 UTC (rev 33570)
@@ -26,7 +26,7 @@
<para>
To manage the resources to be published to the repository, click on the <guimenuitem>Ignored Resources</guimenuitem> menu item under <guimenuitem>ModeShape</guimenuitem> in the main left <guilabel>Preferences</guilabel> menu.
</para>
- <figure id="Preferences_dialog">
+ <figure id="Preferences_dialog_02">
<title>ModeShape: Ignored Resources preferences dialog</title>
<mediaobject>
<imageobject>
@@ -40,7 +40,7 @@
<para>
To add a new file extension type or folder name to be filtered from publishing, click on the <guibutton>New</guibutton> button, enter the details and click the <guibutton>Apply</guibutton> button so that your preference changes are saved.
</para>
- <figure id="Preferences_dialog">
+ <figure id="Preferences_dialog_03">
<title>ModeShape: Ignored Resources preferences dialog</title>
<mediaobject>
<imageobject>
13 years, 5 months
JBoss Tools SVN: r33569 - in branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US: images and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: irooskov(a)redhat.com
Date: 2011-08-03 20:06:37 -0400 (Wed, 03 Aug 2011)
New Revision: 33569
Added:
branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog_02.png
branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog_03.png
Modified:
branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/Book_Info.xml
branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog.png
branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/setting_preferences-task.xml
Log:
updated for TOOLSDOC-231
Modified: branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/Book_Info.xml
===================================================================
--- branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/Book_Info.xml 2011-08-03 23:11:39 UTC (rev 33568)
+++ branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/Book_Info.xml 2011-08-04 00:06:37 UTC (rev 33569)
@@ -9,7 +9,7 @@
<productname>JBoss Developer Studio</productname>
<productnumber>4.1</productnumber>
<edition>4.1.0</edition>
- <pubsnumber>1</pubsnumber>
+ <pubsnumber>2</pubsnumber>
<abstract>
<para>
ModeShape Tools provides the ability to publish and remove content from ModeShape repositories.
Modified: branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog.png
===================================================================
(Binary files differ)
Added: branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog_02.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog_02.png
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog_03.png
===================================================================
(Binary files differ)
Property changes on: branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/images/Preferences_dialog_03.png
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Modified: branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/setting_preferences-task.xml
===================================================================
--- branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/setting_preferences-task.xml 2011-08-03 23:11:39 UTC (rev 33568)
+++ branches/jbosstools-3.2.x/modeshape/docs/ModeShape_Tools_Reference_Guide/en-US/setting_preferences-task.xml 2011-08-04 00:06:37 UTC (rev 33569)
@@ -6,7 +6,11 @@
<section id="sect-ModeShape_Tools_Reference_Guide-Tasks-Setting_preferences">
<title>Setting preferences</title>
<para>
- The ModeShape <guilabel>Preferences</guilabel> dialog allows you to set specific file types and folders that you never wish to have published to or unpublished from a ModeShape repository. This dialog is accessed by navigating to <menuchoice><guimenuitem>Window</guimenuitem><guimenuitem>Preferences</guimenuitem><guimenuitem>ModeShape</guimenuitem></menuchoice>.
+ The ModeShape <guilabel>Preferences</guilabel> dialog allows for resource versioning to be set along with specific file types and folders that you never wish to have published to or unpublished from a ModeShape repository. This dialog is accessed by navigating to <menuchoice>
+ <guimenuitem>Window</guimenuitem>
+ <guimenuitem>Preferences</guimenuitem>
+ <guimenuitem>ModeShape</guimenuitem>
+ </menuchoice>.
</para>
<figure id="Preferences_dialog">
<title>ModeShape preferences dialog</title>
@@ -17,10 +21,35 @@
</mediaobject>
</figure>
<para>
- To add a new file extension type or folder name to be filtered from publishing, click on the corresponding <guibutton>New</guibutton> button, enter the details and click the <guibutton>Apply</guibutton> button so that your preference changes are saved.
- </para>
+ This dialog allows you to set whether resource versioning will be used for your ModeShape repository or not. Ensure the <guilabel>Enable resource versioning</guilabel> checkbox is ticked for resource versioning to be activated.
+ </para>
+ <para>
+ To manage the resources to be published to the repository, click on the <guimenuitem>Ignored Resources</guimenuitem> menu item under <guimenuitem>ModeShape</guimenuitem> in the main left <guilabel>Preferences</guilabel> menu.
+ </para>
+ <figure id="Preferences_dialog">
+ <title>ModeShape: Ignored Resources preferences dialog</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/Preferences_dialog_02.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+ <para>
+ At this screen you can manage the resources that will not be published to your ModeShape repository. The current excluded file types and folders is presented in the list of checkbox items that appears under the <guilabel>Ignored Resources</guilabel> heading.
+ </para>
+ <para>
+ To add a new file extension type or folder name to be filtered from publishing, click on the <guibutton>New</guibutton> button, enter the details and click the <guibutton>Apply</guibutton> button so that your preference changes are saved.
+ </para>
+ <figure id="Preferences_dialog">
+ <title>ModeShape: Ignored Resources preferences dialog</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/Preferences_dialog_03.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
<para>
- Removing an entry is conducted by selecting an entry from one of the lists in the <guilabel>Preferences</guilabel> dialog and clicking on the <guibutton>Remove</guibutton> button. Ensure that you click the <guibutton>Apply</guibutton> button so that your preference changes are saved.
+ Removing an entry is conducted by selecting an entry from the list in the <guilabel>Preferences</guilabel> dialog and clicking on the <guibutton>Remove</guibutton> button. Ensure that you click the <guibutton>Apply</guibutton> button so that your preference changes are saved.
</para>
<para>
As the <guilabel>Preferences</guilabel> dialog lists file types and folders that will never be published to a repository, it follows that those listed will never be unpublished. If you decide to never have a certain file type or folder publishable, though it has been in the past, ensure that all instances of these are unpublished before setting any preferences for the file type or folder.
13 years, 5 months
JBoss Tools SVN: r33568 - trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/ui/test.
by jbosstools-commits@lists.jboss.org
Author: vrubezhny
Date: 2011-08-03 19:11:39 -0400 (Wed, 03 Aug 2011)
New Revision: 33568
Modified:
trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/ui/test/JsfUiAllTests.java
Log:
JBIDE-9414
CA incorrectly inserts a long-named properties from resource bundles
JUnit test is added
Modified: trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/ui/test/JsfUiAllTests.java
===================================================================
--- trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/ui/test/JsfUiAllTests.java 2011-08-03 22:45:42 UTC (rev 33567)
+++ trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/ui/test/JsfUiAllTests.java 2011-08-03 23:11:39 UTC (rev 33568)
@@ -61,8 +61,6 @@
suite.addTestSuite(JsfJspJbide1704Test.class);
suite.addTestSuite(JsfJspJbide1717Test.class);
suite.addTestSuite(JsfJBide3845Test.class);
-// suite.addTestSuite(JsfJspLongResourceBundlePropertyNamesTest.class);
-
suite.addTest(
new ProjectImportTestSetup(JsfJspLongResourceBundlePropertyNamesTest.suite(),
13 years, 5 months
JBoss Tools SVN: r33567 - trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/jsp/ca/test.
by jbosstools-commits@lists.jboss.org
Author: vrubezhny
Date: 2011-08-03 18:45:42 -0400 (Wed, 03 Aug 2011)
New Revision: 33567
Modified:
trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/jsp/ca/test/JsfJspLongResourceBundlePropertyNamesTest.java
Log:
JBIDE-9414
CA incorrectly inserts a long-named properties from resource bundles
JUnit test is added
Modified: trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/jsp/ca/test/JsfJspLongResourceBundlePropertyNamesTest.java
===================================================================
--- trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/jsp/ca/test/JsfJspLongResourceBundlePropertyNamesTest.java 2011-08-03 22:45:10 UTC (rev 33566)
+++ trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/jsp/ca/test/JsfJspLongResourceBundlePropertyNamesTest.java 2011-08-03 22:45:42 UTC (rev 33567)
@@ -44,9 +44,6 @@
project.build(IncrementalProjectBuilder.FULL_BUILD, new NullProgressMonitor());
}
- protected void tearDown() throws Exception {
- }
-
public static Test suite() {
return new TestSuite(JsfJspLongResourceBundlePropertyNamesTest.class);
}
13 years, 5 months
JBoss Tools SVN: r33566 - in trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf: ui/test and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: vrubezhny
Date: 2011-08-03 18:45:10 -0400 (Wed, 03 Aug 2011)
New Revision: 33566
Modified:
trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/jsp/ca/test/JsfJspLongResourceBundlePropertyNamesTest.java
trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/ui/test/JsfUiAllTests.java
Log:
JBIDE-9414
CA incorrectly inserts a long-named properties from resource bundles
JUnit test is added
Modified: trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/jsp/ca/test/JsfJspLongResourceBundlePropertyNamesTest.java
===================================================================
--- trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/jsp/ca/test/JsfJspLongResourceBundlePropertyNamesTest.java 2011-08-03 22:11:59 UTC (rev 33565)
+++ trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/jsp/ca/test/JsfJspLongResourceBundlePropertyNamesTest.java 2011-08-03 22:45:10 UTC (rev 33566)
@@ -15,14 +15,14 @@
import junit.framework.Test;
import junit.framework.TestSuite;
-import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.resources.IncrementalProjectBuilder;
+import org.eclipse.core.runtime.NullProgressMonitor;
import org.eclipse.jface.text.contentassist.ICompletionProposal;
import org.jboss.tools.common.base.test.contentassist.CATestUtil;
import org.jboss.tools.jst.jsp.contentassist.AutoContentAssistantProposal;
import org.jboss.tools.jst.jsp.test.ca.ContentAssistantTestCase;
-import org.jboss.tools.jst.jsp.test.ca.JstJspJbide1641Test;
import org.jboss.tools.test.util.JobUtils;
-import org.jboss.tools.test.util.TestProjectProvider;
+import org.jboss.tools.test.util.ProjectImportTestSetup;
/**
* The JUnit test cases for https://issues.jboss.org/browse/JBIDE-9414 issue
@@ -31,8 +31,6 @@
*
*/
public class JsfJspLongResourceBundlePropertyNamesTest extends ContentAssistantTestCase {
- TestProjectProvider provider = null;
- boolean makeCopy = false;
private static final String PROJECT_NAME = "CAForCompositeComponentTest";
private static final String PAGE_NAME = "WebContent/pages/greetingLong.xhtml";
private static final String PROPOSAL_TO_APPLY_STRING = "['org.jboss.long.named.Property']";
@@ -41,39 +39,18 @@
private static final String TEXT_PREFIX_STRING = "<ui:define name=\"body\"";
private static final String COMPARE_STRING = "#{msg['org.jboss.long.named.Property']";
-// public JsfJspLongResourceBundlePropertyNamesTest() {
-// try {
-// provider = new TestProjectProvider("org.jboss.tools.jsf.ui.test", null, PROJECT_NAME, makeCopy);
-// project = provider.getProject();
-// } catch (CoreException e) {
-// e.printStackTrace();
-// project = null;
-// }
-// }
-
public void setUp() throws Exception {
- provider = new TestProjectProvider("org.jboss.tools.jsf.ui.test", null, PROJECT_NAME, makeCopy);
- project = provider.getProject();
+ project = ProjectImportTestSetup.loadProject(PROJECT_NAME);
+ project.build(IncrementalProjectBuilder.FULL_BUILD, new NullProgressMonitor());
}
protected void tearDown() throws Exception {
- if(provider != null) {
- provider.dispose();
- }
}
public static Test suite() {
- return new TestSuite(JstJspJbide1641Test.class);
+ return new TestSuite(JsfJspLongResourceBundlePropertyNamesTest.class);
}
-// @Override
-// protected void finalize() throws Throwable {
-// if(provider != null) {
-// provider.dispose();
-// }
-// super.finalize();
-// }
-
private void doTestLongResourceBundlePropertyNames(String tagName, String prefix, String proposalToApply, String compareString) {
// Find start of <ui:composition> tag
String documentContent = document.get();
Modified: trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/ui/test/JsfUiAllTests.java
===================================================================
--- trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/ui/test/JsfUiAllTests.java 2011-08-03 22:11:59 UTC (rev 33565)
+++ trunk/jsf/tests/org.jboss.tools.jsf.ui.test/src/org/jboss/tools/jsf/ui/test/JsfUiAllTests.java 2011-08-03 22:45:10 UTC (rev 33566)
@@ -61,9 +61,15 @@
suite.addTestSuite(JsfJspJbide1704Test.class);
suite.addTestSuite(JsfJspJbide1717Test.class);
suite.addTestSuite(JsfJBide3845Test.class);
- suite.addTestSuite(JsfJspLongResourceBundlePropertyNamesTest.class);
+// suite.addTestSuite(JsfJspLongResourceBundlePropertyNamesTest.class);
+
suite.addTest(
+ new ProjectImportTestSetup(JsfJspLongResourceBundlePropertyNamesTest.suite(),
+ "org.jboss.tools.jsf.ui.test",
+ new String[] { "projects/CAForCompositeComponentTest", }, //$NON-NLS-1$
+ new String[] { "CAForCompositeComponentTest" })); //$NON-NLS-1$
+ suite.addTest(
new ProjectImportTestSetup(WebContentAssistProviderTest.suite(),
"org.jboss.tools.jsf.ui.test",
new String[] { "projects/TestsWebArtefacts", }, //$NON-NLS-1$
13 years, 5 months