Author: dgolovin
Date: 2009-11-23 20:11:08 -0500 (Mon, 23 Nov 2009)
New Revision: 18793
Added:
trunk/seam/features/org.jboss.tools.seam.feature/license.html
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/Seam20XCreateTestProjectTest.java
Modified:
trunk/archives/features/org.jboss.ide.eclipse.archives.test.feature/feature.xml
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/META-INF/MANIFEST.MF
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/build.properties
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/ArchivesUITestSuite.java
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/preferences/MainPreferencePageTest.java
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/views/ProjectsArchiveViewTest.java
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/wizards/NewJARWizardTest.java
trunk/common/features/org.jboss.tools.common.all.tests.feature/feature.xml
trunk/jst/plugins/org.jboss.tools.jst.jsp/plugin.xml
trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/wizards/project/NewWebProjectWizardPage.java
trunk/seam/features/org.jboss.tools.seam.feature/build.properties
trunk/seam/features/org.jboss.tools.seam.feature/feature.xml
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/builder/ToggleSeamNatureAction.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/dialog/AbstractFileSetContentProvider.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/dialog/SeamFacetVersionChangeDialog.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamActionProvider.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/OpenSeamComponentDialog.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/RenameComponentWizard.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/RenameSeamContextVariableWizard.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamActionWizard.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamBaseOperation.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamConversationWizardPage1.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamProjectWizard.java
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SelectJavaPackageAction.java
trunk/seam/tests/org.jboss.tools.seam.core.test/META-INF/MANIFEST.MF
trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeamFacetTest.java
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/SeamUiAllTests.java
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamCreateTestProjectTest.java
Log:
JUnit tests fixes:
1. Errors in tests to create seam project with/without tetsts
2. Archives UI tests enabled in build
Modified: trunk/archives/features/org.jboss.ide.eclipse.archives.test.feature/feature.xml
===================================================================
---
trunk/archives/features/org.jboss.ide.eclipse.archives.test.feature/feature.xml 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/archives/features/org.jboss.ide.eclipse.archives.test.feature/feature.xml 2009-11-24
01:11:08 UTC (rev 18793)
@@ -13,20 +13,26 @@
[Enter Copyright Description here.]
</copyright>
- <license>Red Hat, Inc. licenses these features and plugins to you under
+ <license>
+ Red Hat, Inc. licenses these features and plugins to you under
certain open source licenses (or aggregations of such licenses), which
in a particular case may include the Eclipse Public License, the GNU
Lesser General Public License, and/or certain other open source
licenses. For precise licensing details, consult the corresponding
source code, or contact Red Hat Legal Affairs, 1801 Varsity Drive,
Raleigh NC 27606 USA.
-</license>
+ </license>
-
<plugin
id="org.jboss.ide.eclipse.archives.test"
download-size="0"
install-size="0"
version="0.0.0"/>
+ <plugin
+ id="org.jboss.ide.eclipse.archives.ui.test"
+ download-size="0"
+ install-size="0"
+ version="0.0.0"/>
+
</feature>
Modified:
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/META-INF/MANIFEST.MF
===================================================================
---
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/META-INF/MANIFEST.MF 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/META-INF/MANIFEST.MF 2009-11-24
01:11:08 UTC (rev 18793)
@@ -14,3 +14,8 @@
org.eclipse.core.runtime;bundle-version="3.5.0",
org.jboss.ide.eclipse.archives.core;bundle-version="2.0.0",
org.eclipse.ui.navigator;bundle-version="3.4.1"
+Bundle-ClassPath: archives-ui-test.jar
+Export-Package: org.jboss.ide.eclipse.archives.ui.test,
+ org.jboss.ide.eclipse.archives.ui.test.preferences,
+ org.jboss.ide.eclipse.archives.ui.test.views,
+ org.jboss.ide.eclipse.archives.ui.test.wizards
Modified: trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/build.properties
===================================================================
---
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/build.properties 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/build.properties 2009-11-24
01:11:08 UTC (rev 18793)
@@ -1,4 +1,6 @@
-source.. = src/
-output.. = bin/
+output.archives-ui-test.jar = bin/
bin.includes = META-INF/,\
- .
+ archives-ui-test.jar,\
+ projects/
+source.archives-ui-test.jar = src/
+jars.compile.order = archives-ui-test.jar
Modified:
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/ArchivesUITestSuite.java
===================================================================
---
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/ArchivesUITestSuite.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/ArchivesUITestSuite.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -1,23 +1,21 @@
package org.jboss.ide.eclipse.archives.ui.test;
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
import org.jboss.ide.eclipse.archives.ui.test.preferences.MainPreferencePageTest;
-import org.jboss.ide.eclipse.archives.ui.test.wizards.FilesetWizardTest;
+import org.jboss.ide.eclipse.archives.ui.test.views.ProjectsArchiveViewTest;
import org.jboss.ide.eclipse.archives.ui.test.wizards.NewJARWizardTest;
-import org.jboss.ide.eclipse.archives.ui.views.ProjectArchivesCommonView;
import org.jboss.tools.test.util.ProjectImportTestSetup;
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
public class ArchivesUITestSuite {
public static final String TEST_SUITE_BUNDLE_ID =
"org.jboss.ide.eclipse.archives.ui.test";
public static Test suite() {
TestSuite suite = new TestSuite();
suite.addTestSuite(MainPreferencePageTest.class);
- suite.addTestSuite(ProjectArchivesCommonView.class);
- suite.addTestSuite(FilesetWizardTest.class);
+ suite.addTestSuite(ProjectsArchiveViewTest.class);
+ //suite.addTestSuite(FilesetWizardTest.class);
suite.addTestSuite(NewJARWizardTest.class);
- return new ProjectImportTestSetup(suite,
TEST_SUITE_BUNDLE_ID,"projects/archive-test", "archive-test");
+ return new ProjectImportTestSetup(suite,
TEST_SUITE_BUNDLE_ID,"projects/archives-test", "archives-test");
}
-}
-
+}
\ No newline at end of file
Modified:
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/preferences/MainPreferencePageTest.java
===================================================================
---
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/preferences/MainPreferencePageTest.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/preferences/MainPreferencePageTest.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -2,6 +2,19 @@
import junit.framework.TestCase;
+import org.eclipse.jface.preference.PreferenceDialog;
+import org.jboss.ide.eclipse.archives.ui.preferences.MainPreferencePage;
+import org.jboss.tools.test.util.WorkbenchUtils;
+
public class MainPreferencePageTest extends TestCase {
-
+ public void testArchivesPreferencePageIsShown() {
+ PreferenceDialog dialog =
WorkbenchUtils.createPreferenceDialog("org.jboss.ide.eclipse.archives.ui.archivesPreferencePage");
+ try {
+ dialog.open();
+ Object page = dialog.getSelectedPage();
+ assertTrue(page instanceof MainPreferencePage);
+ } finally {
+ dialog.close();
+ }
+ }
}
Modified:
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/views/ProjectsArchiveViewTest.java
===================================================================
---
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/views/ProjectsArchiveViewTest.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/views/ProjectsArchiveViewTest.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -1,7 +1,20 @@
package org.jboss.ide.eclipse.archives.ui.test.views;
+import org.eclipse.ui.IPageLayout;
+import org.eclipse.ui.IViewPart;
+import org.eclipse.ui.IWorkbenchPage;
+import org.eclipse.ui.PartInitException;
+import org.eclipse.ui.PlatformUI;
+import org.jboss.ide.eclipse.archives.ui.views.ProjectArchivesCommonView;
+
import junit.framework.TestCase;
public class ProjectsArchiveViewTest extends TestCase {
+ public void testArchivesViewIsOpened() throws PartInitException {
+ IWorkbenchPage page=
PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
+
+ IViewPart view = page.showView(ProjectArchivesCommonView.ID);
+ assertTrue(view instanceof ProjectArchivesCommonView);
+ }
}
Modified:
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/wizards/NewJARWizardTest.java
===================================================================
---
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/wizards/NewJARWizardTest.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/archives/tests/org.jboss.ide.eclipse.archives.ui.test/src/org/jboss/ide/eclipse/archives/ui/test/wizards/NewJARWizardTest.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -30,7 +30,7 @@
@Override
protected void setUp() throws Exception {
- project =
ResourcesPlugin.getWorkspace().getRoot().getProject("archive-test");
+ project =
ResourcesPlugin.getWorkspace().getRoot().getProject("archives-test");
IWorkbenchPage page=
PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
IViewPart view= page.showView(IPageLayout.ID_RES_NAV);
Modified: trunk/common/features/org.jboss.tools.common.all.tests.feature/feature.xml
===================================================================
--- trunk/common/features/org.jboss.tools.common.all.tests.feature/feature.xml 2009-11-23
20:46:27 UTC (rev 18792)
+++ trunk/common/features/org.jboss.tools.common.all.tests.feature/feature.xml 2009-11-24
01:11:08 UTC (rev 18793)
@@ -33,19 +33,6 @@
</requires>
<plugin
- id="org.eclipse.ant.optional.junit"
- download-size="0"
- install-size="0"
- version="0.0.0"
- fragment="true"/>
-
- <plugin
- id="org.eclipse.test"
- download-size="0"
- install-size="0"
- version="0.0.0"/>
-
- <plugin
id="org.jboss.tools.tests"
download-size="0"
install-size="0"
Modified: trunk/jst/plugins/org.jboss.tools.jst.jsp/plugin.xml
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.jsp/plugin.xml 2009-11-23 20:46:27 UTC (rev
18792)
+++ trunk/jst/plugins/org.jboss.tools.jst.jsp/plugin.xml 2009-11-24 01:11:08 UTC (rev
18793)
@@ -137,7 +137,7 @@
<editor
class="org.jboss.tools.jst.jsp.jspeditor.JSPMultiPageEditor"
contributorClass="org.jboss.tools.jst.jsp.jspeditor.JSPMultiPageContributor"
- extensions="html, htm, jsf"
+ extensions="html, htm, jsf, xhtml"
icon="$nl$/images/xstudio/editors/html_file.gif"
id="org.jboss.tools.jst.jsp.jspeditor.HTMLTextEditor"
matchingStrategy =
"org.jboss.tools.common.core.resources.MatchingStrategyImpl"
@@ -591,4 +591,4 @@
point="org.eclipse.core.runtime.preferences">
<initializer
class="org.jboss.tools.jst.jsp.preferences.VpePreferencesInitializer"/>
</extension>
-</plugin>
\ No newline at end of file
+</plugin>
Modified:
trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/wizards/project/NewWebProjectWizardPage.java
===================================================================
---
trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/wizards/project/NewWebProjectWizardPage.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/jst/plugins/org.jboss.tools.jst.web.ui/src/org/jboss/tools/jst/web/ui/wizards/project/NewWebProjectWizardPage.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -138,15 +138,7 @@
layout.marginHeight = 4;
layout.marginWidth = 4;
composite.setLayout(layout);
-
- introduction = new Label(composite, SWT.NO_FOCUS);
- String text = "" + WizardKeys.getString(getKey() +
"_introduction"); //$NON-NLS-1$ //$NON-NLS-2$
- text = insertBreaks(introduction, text, 380);
- introduction.setText(text);
- gd = new GridData(GridData.FILL_HORIZONTAL);
- gd.horizontalSpan = 2;
- introduction.setLayoutData(gd);
-
+
// nameEditor
editor = nameEditor.getFieldEditor(composite);
editor.fillIntoGrid(composite, 2);
Modified: trunk/seam/features/org.jboss.tools.seam.feature/build.properties
===================================================================
--- trunk/seam/features/org.jboss.tools.seam.feature/build.properties 2009-11-23 20:46:27
UTC (rev 18792)
+++ trunk/seam/features/org.jboss.tools.seam.feature/build.properties 2009-11-24 01:11:08
UTC (rev 18793)
@@ -1,2 +1,3 @@
bin.includes = feature.xml,\
- feature.properties
+ feature.properties,\
+ license.html
Modified: trunk/seam/features/org.jboss.tools.seam.feature/feature.xml
===================================================================
--- trunk/seam/features/org.jboss.tools.seam.feature/feature.xml 2009-11-23 20:46:27 UTC
(rev 18792)
+++ trunk/seam/features/org.jboss.tools.seam.feature/feature.xml 2009-11-24 01:11:08 UTC
(rev 18793)
@@ -14,203 +14,8 @@
%copyright
</copyright>
- <license
url="http://www.eclipse.org/legal/epl-v10.html">
- Eclipse Public License - v 1.0
-THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS
-ECLIPSE PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR
-DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE
-OF THIS AGREEMENT.
-1. DEFINITIONS
-"Contribution" means:
-a) in the case of the initial Contributor, the initial code and
-documentation distributed under this Agreement, and
-b) in the case of each subsequent Contributor:
-i) changes to the Program, and
-ii) additions to the Program;
-where such changes and/or additions to the Program originate
-from and are distributed by that particular Contributor. A Contribution
-'originates' from a Contributor if it was added to the Program
-by such Contributor itself or anyone acting on such Contributor's
-behalf. Contributions do not include additions to the Program
-which: (i) are separate modules of software distributed in conjunction
-with the Program under their own license agreement, and (ii)
-are not derivative works of the Program.
-"Contributor" means any person or entity that distributes the
-Program.
-"Licensed Patents " mean patent claims licensable by a Contributor
-which are necessarily infringed by the use or sale of its Contribution
-alone or when combined with the Program.
-"Program" means the Contributions distributed in accordance with
-this Agreement.
-"Recipient" means anyone who receives the Program under this
-Agreement, including all Contributors.
-2. GRANT OF RIGHTS
-a) Subject to the terms of this Agreement, each Contributor hereby
-grants Recipient a non-exclusive, worldwide, royalty-free copyright
-license to reproduce, prepare derivative works of, publicly display,
-publicly perform, distribute and sublicense the Contribution
-of such Contributor, if any, and such derivative works, in source
-code and object code form.
-b) Subject to the terms of this Agreement, each Contributor hereby
-grants Recipient a non-exclusive, worldwide, royalty-free patent
-license under Licensed Patents to make, use, sell, offer to sell,
-import and otherwise transfer the Contribution of such Contributor,
-if any, in source code and object code form. This patent license
-shall apply to the combination of the Contribution and the Program
-if, at the time the Contribution is added by the Contributor,
-such addition of the Contribution causes such combination to
-be covered by the Licensed Patents. The patent license shall
-not apply to any other combinations which include the Contribution.
-No hardware per se is licensed hereunder.
-c) Recipient understands that although each Contributor grants
-the licenses to its Contributions set forth herein, no assurances
-are provided by any Contributor that the Program does not infringe
-the patent or other intellectual property rights of any other
-entity. Each Contributor disclaims any liability to Recipient
-for claims brought by any other entity based on infringement
-of intellectual property rights or otherwise. As a condition
-to exercising the rights and licenses granted hereunder, each
-Recipient hereby assumes sole responsibility to secure any other
-intellectual property rights needed, if any. For example, if
-a third party patent license is required to allow Recipient to
-distribute the Program, it is Recipient's responsibility to acquire
-that license before distributing the Program.
-d) Each Contributor represents that to its knowledge it has sufficient
-copyright rights in its Contribution, if any, to grant the copyright
-license set forth in this Agreement.
-3. REQUIREMENTS
-A Contributor may choose to distribute the Program in object
-code form under its own license agreement, provided that:
-a) it complies with the terms and conditions of this Agreement;
-and
-b) its license agreement:
-i) effectively disclaims on behalf of all Contributors all warranties
-and conditions, express and implied, including warranties or
-conditions of title and non-infringement, and implied warranties
-or conditions of merchantability and fitness for a particular
-purpose;
-ii) effectively excludes on behalf of all Contributors all liability
-for damages, including direct, indirect, special, incidental
-and consequential damages, such as lost profits;
-iii) states that any provisions which differ from this Agreement
-are offered by that Contributor alone and not by any other party;
-and
-iv) states that source code for the Program is available from
-such Contributor, and informs licensees how to obtain it in a
-reasonable manner on or through a medium customarily used for
-software exchange.
-When the Program is made available in source code form:
-a) it must be made available under this Agreement; and
-b) a copy of this Agreement must be included with each copy of
-the Program.
-Contributors may not remove or alter any copyright notices contained
-within the Program.
-Each Contributor must identify itself as the originator of its
-Contribution, if any, in a manner that reasonably allows subsequent
-Recipients to identify the originator of the Contribution.
-4. COMMERCIAL DISTRIBUTION
-Commercial distributors of software may accept certain responsibilities
-with respect to end users, business partners and the like. While
-this license is intended to facilitate the commercial use of
-the Program, the Contributor who includes the Program in a commercial
-product offering should do so in a manner which does not create
-potential liability for other Contributors. Therefore, if a Contributor
-includes the Program in a commercial product offering, such Contributor
-("Commercial Contributor") hereby agrees to defend and indemnify
-every other Contributor ("Indemnified Contributor") against any
-losses, damages and costs (collectively "Losses") arising from
-claims, lawsuits and other legal actions brought by a third party
-against the Indemnified Contributor to the extent caused by the
-acts or omissions of such Commercial Contributor in connection
-with its distribution of the Program in a commercial product
-offering. The obligations in this section do not apply to any
-claims or Losses relating to any actual or alleged intellectual
-property infringement. In order to qualify, an Indemnified Contributor
-must: a) promptly notify the Commercial Contributor in writing
-of such claim, and b) allow the Commercial Contributor to control,
-and cooperate with the Commercial Contributor in, the defense
-and any related settlement negotiations. The Indemnified Contributor
-may participate in any such claim at its own expense.
-For example, a Contributor might include the Program in a commercial
-product offering, Product X. That Contributor is then a Commercial
-Contributor. If that Commercial Contributor then makes performance
-claims, or offers warranties related to Product X, those performance
-claims and warranties are such Commercial Contributor's responsibility
-alone. Under this section, the Commercial Contributor would have
-to defend claims against the other Contributors related to those
-performance claims and warranties, and if a court requires any
-other Contributor to pay any damages as a result, the Commercial
-Contributor must pay those damages.
-5. NO WARRANTY
-EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM
-IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS
-OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION,
-ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY
-OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely
-responsible for determining the appropriateness of using and
-distributing the Program and assumes all risks associated with
-its exercise of rights under this Agreement , including but not
-limited to the risks and costs of program errors, compliance
-with applicable laws, damage to or loss of data, programs or
-equipment, and unavailability or interruption of operations.
-6. DISCLAIMER OF LIABILITY
-EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT
-NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT,
-INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
-(INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND
-ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE
-OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY
-OF SUCH DAMAGES.
-7. GENERAL
-If any provision of this Agreement is invalid or unenforceable
-under applicable law, it shall not affect the validity or enforceability
-of the remainder of the terms of this Agreement, and without
-further action by the parties hereto, such provision shall be
-reformed to the minimum extent necessary to make such provision
-valid and enforceable.
-If Recipient institutes patent litigation against any entity
-(including a cross-claim or counterclaim in a lawsuit) alleging
-that the Program itself (excluding combinations of the Program
-with other software or hardware) infringes such Recipient's patent(s),
-then such Recipient's rights granted under Section 2(b) shall
-terminate as of the date such litigation is filed.
-All Recipient's rights under this Agreement shall terminate if
-it fails to comply with any of the material terms or conditions
-of this Agreement and does not cure such failure in a reasonable
-period of time after becoming aware of such noncompliance. If
-all Recipient's rights under this Agreement terminate, Recipient
-agrees to cease use and distribution of the Program as soon as
-reasonably practicable. However, Recipient's obligations under
-this Agreement and any licenses granted by Recipient relating
-to the Program shall continue and survive.
-Everyone is permitted to copy and distribute copies of this Agreement,
-but in order to avoid inconsistency the Agreement is copyrighted
-and may only be modified in the following manner. The Agreement
-Steward reserves the right to publish new versions (including
-revisions) of this Agreement from time to time. No one other
-than the Agreement Steward has the right to modify this Agreement.
-The Eclipse Foundation is the initial Agreement Steward. The
-Eclipse Foundation may assign the responsibility to serve as
-the Agreement Steward to a suitable separate entity. Each new
-version of the Agreement will be given a distinguishing version
-number. The Program (including Contributions) may always be distributed
-subject to the version of the Agreement under which it was received.
-In addition, after a new version of the Agreement is published,
-Contributor may elect to distribute the Program (including its
-Contributions) under the new version. Except as expressly stated
-in Sections 2(a) and 2(b) above, Recipient receives no rights
-or licenses to the intellectual property of any Contributor under
-this Agreement, whether expressly, by implication, estoppel or
-otherwise. All rights in the Program not expressly granted under
-this Agreement are reserved.
-This Agreement is governed by the laws of the State of New York
-and the intellectual property laws of the United States of America.
-No party to this Agreement will bring a legal action under this
-Agreement more than one year after the cause of action arose.
-Each party waives its rights to a jury trial in any resulting
-litigation.
+ <license url="%licenseURL">
+ %license
</license>
<url>
Added: trunk/seam/features/org.jboss.tools.seam.feature/license.html
===================================================================
--- trunk/seam/features/org.jboss.tools.seam.feature/license.html
(rev 0)
+++ trunk/seam/features/org.jboss.tools.seam.feature/license.html 2009-11-24 01:11:08 UTC
(rev 18793)
@@ -0,0 +1,14 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
+<html>
+
+<body>
+<p>Red Hat, Inc. licenses these features and plugins to you under
+certain open source licenses (or aggregations of such licenses), which
+in a particular case may include the Eclipse Public License, the GNU
+Lesser General Public License, and/or certain other open source
+licenses. For precise licensing details, consult the corresponding
+source code, or contact Red Hat Legal Affairs, 1801 Varsity Drive,
+Raleigh NC 27606 USA.
+</p>
+</body>
+</html>
\ No newline at end of file
Property changes on: trunk/seam/features/org.jboss.tools.seam.feature/license.html
___________________________________________________________________
Name: svn:executable
+ *
Name: svn:mime-type
+ text/plain
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/builder/ToggleSeamNatureAction.java
===================================================================
---
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/builder/ToggleSeamNatureAction.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/builder/ToggleSeamNatureAction.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -41,7 +41,7 @@
*/
public void run(IAction action) {
if (selection instanceof IStructuredSelection) {
- for (Iterator it = ((IStructuredSelection) selection).iterator(); it
+ for (Iterator<?> it = ((IStructuredSelection) selection).iterator(); it
.hasNext();) {
Object element = it.next();
IProject project = null;
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/dialog/AbstractFileSetContentProvider.java
===================================================================
---
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/dialog/AbstractFileSetContentProvider.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/dialog/AbstractFileSetContentProvider.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -28,12 +28,12 @@
protected static File[] ZERO_ARRAY = new File[0];
protected Object[] elements = ZERO_ARRAY;
- private final Comparator comparer = new Comparator() {
+ private final Comparator<File> comparer = new Comparator<File>() {
private Collator collator = Collator.getInstance();
- public int compare(Object arg0, Object arg1) {
- String s1 = ((File) arg0).getName();
- String s2 = ((File) arg1).getName();
+ public int compare(File arg0, File arg1) {
+ String s1 = arg0.getName();
+ String s2 = arg1.getName();
return collator.compare(s1, s2);
}
};
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/dialog/SeamFacetVersionChangeDialog.java
===================================================================
---
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/dialog/SeamFacetVersionChangeDialog.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/dialog/SeamFacetVersionChangeDialog.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -79,8 +79,6 @@
import org.jboss.tools.seam.core.project.facet.SeamRuntimeManager;
import org.jboss.tools.seam.core.project.facet.SeamVersion;
import org.jboss.tools.seam.internal.core.project.facet.ISeamFacetDataModelProperties;
-import org.jboss.tools.seam.ui.widget.editor.CompositeEditor;
-import org.jboss.tools.seam.ui.widget.editor.ITaggedFieldEditor;
import
org.jboss.tools.seam.ui.widget.editor.SeamRuntimeListFieldEditor.SeamRuntimeNewWizard;
import org.jboss.tools.seam.ui.wizard.SeamFormWizard;
import org.jboss.tools.seam.ui.wizard.SeamWizardUtils;
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamActionProvider.java
===================================================================
---
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamActionProvider.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/views/actions/SeamActionProvider.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -12,12 +12,10 @@
import org.eclipse.jdt.ui.actions.JdtActionConstants;
import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.commands.ActionHandler;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.ui.IActionBars;
import org.eclipse.ui.actions.ActionContext;
-import org.eclipse.ui.handlers.IHandlerService;
import org.eclipse.ui.navigator.CommonActionProvider;
import org.eclipse.ui.navigator.ICommonActionConstants;
import org.jboss.tools.seam.core.IOpenableElement;
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/OpenSeamComponentDialog.java
===================================================================
---
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/OpenSeamComponentDialog.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/OpenSeamComponentDialog.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -17,7 +17,6 @@
import java.io.IOException;
import java.util.Collections;
import java.util.Comparator;
-import java.util.Iterator;
import java.util.List;
import org.eclipse.core.resources.IProject;
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/RenameComponentWizard.java
===================================================================
---
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/RenameComponentWizard.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/RenameComponentWizard.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -16,7 +16,6 @@
import org.eclipse.core.resources.IProject;
import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
import org.eclipse.jface.wizard.IWizardPage;
import org.eclipse.ltk.core.refactoring.Refactoring;
import org.eclipse.ltk.core.refactoring.RefactoringStatus;
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/RenameSeamContextVariableWizard.java
===================================================================
---
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/RenameSeamContextVariableWizard.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/RenameSeamContextVariableWizard.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -15,9 +15,7 @@
import java.util.Map;
import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
import org.eclipse.jface.wizard.IWizardPage;
import org.eclipse.ltk.core.refactoring.Refactoring;
import org.eclipse.ltk.core.refactoring.RefactoringStatus;
@@ -28,10 +26,8 @@
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Composite;
-import org.jboss.tools.seam.core.ISeamComponent;
import org.jboss.tools.seam.core.ISeamProject;
import org.jboss.tools.seam.core.SeamCorePlugin;
-import org.jboss.tools.seam.internal.core.refactoring.RenameComponentProcessor;
import
org.jboss.tools.seam.internal.core.refactoring.RenameSeamContextVariableProcessor;
import org.jboss.tools.seam.internal.core.refactoring.SeamRenameProcessor;
import org.jboss.tools.seam.ui.SeamUIMessages;
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamActionWizard.java
===================================================================
---
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamActionWizard.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamActionWizard.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -15,19 +15,13 @@
import java.util.Map;
import org.eclipse.core.commands.operations.IUndoableOperation;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.runtime.Path;
import org.eclipse.core.runtime.preferences.IEclipsePreferences;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Display;
import org.eclipse.ui.INewWizard;
-import org.eclipse.ui.PartInitException;
import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.ide.IDE;
import org.jboss.tools.seam.internal.core.project.facet.ISeamFacetDataModelProperties;
import org.jboss.tools.seam.ui.ISeamHelpContextIds;
-import org.jboss.tools.seam.ui.SeamGuiPlugin;
import org.jboss.tools.seam.ui.SeamUIMessages;
import org.jboss.tools.seam.ui.widget.editor.INamedElement;
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamBaseOperation.java
===================================================================
---
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamBaseOperation.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamBaseOperation.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -154,7 +154,7 @@
}
private Map<String, Object> loadParameters(IAdaptable info, SeamProjectsSet
seamPrjSet) throws BackingStoreException {
- Map<String, INamedElement> params = (Map)info.getAdapter(Map.class);
+ Map<String, INamedElement> params = (Map<String,
INamedElement>)info.getAdapter(Map.class);
IEclipsePreferences seamFacetPrefs =
SeamCorePlugin.getSeamPreferences(seamPrjSet.getWarProject());
Map<String, Object> vars = new HashMap<String, Object>();
@@ -250,7 +250,7 @@
}
protected IProject getProject(IAdaptable info) {
- Map<String, INamedElement> params = (Map)info.getAdapter(Map.class);
+ Map<String, INamedElement> params = (Map<String,
INamedElement>)info.getAdapter(Map.class);
return ResourcesPlugin.getWorkspace().getRoot().getProject(
params.get(IParameter.SEAM_PROJECT_NAME).getValueAsString());
@@ -295,7 +295,7 @@
* @param vars
* @return
*/
- public FilterSetCollection getFilterSetCollection(Map vars) {
+ public FilterSetCollection getFilterSetCollection(Map<String, Object> vars) {
return new
FilterSetCollection(SeamFacetFilterSetFactory.createFiltersFilterSet(vars));
}
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamConversationWizardPage1.java
===================================================================
---
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamConversationWizardPage1.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamConversationWizardPage1.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -11,13 +11,8 @@
package org.jboss.tools.seam.ui.wizard;
-import java.util.Map;
-
import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.swt.widgets.Composite;
import org.jboss.tools.seam.ui.SeamUIMessages;
-import org.jboss.tools.seam.ui.internal.project.facet.IValidator;
-import org.jboss.tools.seam.ui.internal.project.facet.ValidatorFactory;
/**
* @author eskimo
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamProjectWizard.java
===================================================================
---
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamProjectWizard.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SeamProjectWizard.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -470,13 +470,13 @@
protected String[] getValidationPropertyNames() {
String[] superProperties = super.getValidationPropertyNames();
- List list = Arrays.asList(superProperties);
- ArrayList arrayList = new ArrayList();
+ List<String> list = Arrays.asList(superProperties);
+ ArrayList<String> arrayList = new ArrayList<String>();
arrayList.addAll( list );
arrayList.add( ISeamFacetDataModelProperties.JBOSS_AS_TARGET_RUNTIME);
arrayList.add( ISeamFacetDataModelProperties.JBOSS_AS_TARGET_SERVER);
arrayList.add( ISeamFacetDataModelProperties.SEAM_PROJECT_NAME);
- return (String[])arrayList.toArray( new String[0] );
+ return arrayList.toArray( new String[0] );
}
public boolean launchNewServerWizard(Shell shell, IDataModel model) {
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SelectJavaPackageAction.java
===================================================================
---
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SelectJavaPackageAction.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/wizard/SelectJavaPackageAction.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -92,7 +92,7 @@
String initialValue = getFieldEditor().getValue().toString();
IJavaElement initialElement = null;
- ArrayList packagesWithoutDefaultPackage = new ArrayList();
+ ArrayList<IJavaElement> packagesWithoutDefaultPackage = new
ArrayList<IJavaElement>();
for (IJavaElement packageElement : packages) {
String packageName = packageElement.getElementName();
if(packageName.length()>0) {
@@ -103,7 +103,7 @@
}
}
- packages = (IJavaElement[])packagesWithoutDefaultPackage.toArray(new
IJavaElement[packagesWithoutDefaultPackage.size()]);
+ packages = packagesWithoutDefaultPackage.toArray(new
IJavaElement[packagesWithoutDefaultPackage.size()]);
ElementListSelectionDialog dialog = new
ElementListSelectionDialog(Display.getCurrent().getActiveShell(), new
JavaElementLabelProvider(
JavaElementLabelProvider.SHOW_DEFAULT));
dialog.setTitle(J2EEUIMessages.PACKAGE_SELECTION_DIALOG_TITLE);
Modified: trunk/seam/tests/org.jboss.tools.seam.core.test/META-INF/MANIFEST.MF
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam.core.test/META-INF/MANIFEST.MF 2009-11-23
20:46:27 UTC (rev 18792)
+++ trunk/seam/tests/org.jboss.tools.seam.core.test/META-INF/MANIFEST.MF 2009-11-24
01:11:08 UTC (rev 18793)
@@ -11,7 +11,6 @@
Require-Bundle:
org.junit,
org.jboss.tools.seam.core,
- org.jboss.tools.seam.xml,
org.jboss.tools.common.test,
org.jboss.tools.jsf,
org.eclipse.wst.common.project.facet.core,
Modified:
trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeamFacetTest.java
===================================================================
---
trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeamFacetTest.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeamFacetTest.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -3,6 +3,7 @@
import java.io.File;
import java.text.MessageFormat;
import java.util.ArrayList;
+import java.util.Arrays;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
@@ -10,6 +11,7 @@
import junit.framework.TestCase;
import org.eclipse.core.resources.IProject;
+import org.eclipse.core.resources.IProjectNature;
import org.eclipse.core.resources.IResource;
import org.eclipse.core.resources.IWorkspace;
import org.eclipse.core.resources.IWorkspaceRunnable;
@@ -70,7 +72,7 @@
}
- protected final Set<IResource> resourcesToCleanup = new
HashSet<IResource>();
+ protected final ArrayList<IResource> resourcesToCleanup = new
ArrayList<IResource>();
protected final List<Runnable> tearDownOperations = new
ArrayList<Runnable>();
protected AbstractSeamFacetTest(final String name) {
@@ -123,8 +125,15 @@
for (IResource r : this.resourcesToCleanup) {
try {
System.out.println("Deleting resource " + r.getLocation());
+ if(r instanceof IProject) {
+ IProject project = (IProject)r;
+ for (String natureId : project.getDescription().getNatureIds()) {
+ IProjectNature nature = project.getNature(natureId);
+ nature.deconfigure();
+ }
+ }
r.delete(true, null);
- JobUtils.waitForIdle();
+// JobUtils.delay(5000);
} catch(Exception e) {
e.printStackTrace();
last = e;
@@ -142,9 +151,16 @@
}
protected final void addResourceToCleanup(final IResource resource) {
+ if(resource==null) throw new IllegalArgumentException();
+ if(resourcesToCleanup.contains(resource)) throw new IllegalArgumentException();
this.resourcesToCleanup.add(resource);
}
+ protected final void addResourcesToCleanup(final IResource[] resource) {
+ if(resource==null) throw new IllegalArgumentException();
+ this.resourcesToCleanup.addAll(Arrays.asList(resource));
+ }
+
protected final void addTearDownOperation(final Runnable runnable) {
this.tearDownOperations.add(runnable);
}
@@ -220,9 +236,10 @@
}
},new NullProgressMonitor());
- this.addResourceToCleanup(proj);
- this.addResourceToCleanup(ResourcesPlugin.getWorkspace().getRoot().getProject(baseProjectName
+ "-test"));
+
+ this.addResourcesToCleanup(seamProjectsSet.getAllProjects());
+
return fproj;
}
@@ -236,31 +253,21 @@
assertTrue(proj.getWorkspace().getRoot().getProject(proj.getName() +
"-test").exists());
IProject testProject = proj.getWorkspace().getRoot().getProject(proj.getName() +
"-test");
- this.addResourceToCleanup(testProject);
- this.addResourceToCleanup(proj);
+
return fproj;
}
protected IFacetedProject createSeamEarProject(String name) throws CoreException {
final IFacetedProject fproj = createSeamProject(name,
createSeamDataModel("ear"));
-
+ SeamProjectsSet seamProjectsSet = new SeamProjectsSet(fproj.getProject());
final IProject proj = fproj.getProject();
assertNotNull(proj);
-
- IProject testProject = proj.getWorkspace().getRoot().getProject(proj.getName() +
"-test");
- IProject ejbProject = proj.getWorkspace().getRoot().getProject(proj.getName() +
"-ejb");
- IProject earProject = proj.getWorkspace().getRoot().getProject(proj.getName() +
"-ear");
-
- this.resourcesToCleanup.add(proj);
- this.resourcesToCleanup.add(testProject);
- this.resourcesToCleanup.add(ejbProject);
- this.resourcesToCleanup.add(earProject);
- assertTrue(proj.exists());
- assertTrue(testProject.exists());
- assertTrue(ejbProject.exists());
- assertTrue(earProject.exists());
+ assertTrue(seamProjectsSet.getWarProject().exists());
+ assertTrue(seamProjectsSet.getTestProject().exists());
+ assertTrue(seamProjectsSet.getEjbProject().exists());
+ assertTrue(seamProjectsSet.getEarProject().exists());
return fproj;
}
Modified:
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/SeamUiAllTests.java
===================================================================
---
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/SeamUiAllTests.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/SeamUiAllTests.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -24,6 +24,7 @@
import org.jboss.tools.seam.ui.test.view.SeamComponentsViewAllTests;
import org.jboss.tools.seam.ui.test.wizard.OpenSeamComponentDialogTest;
import org.jboss.tools.seam.ui.test.wizard.PackageNamesTest;
+import org.jboss.tools.seam.ui.test.wizard.Seam20XCreateTestProjectTest;
import org.jboss.tools.seam.ui.test.wizard.SeamActionNewWizardTest;
import org.jboss.tools.seam.ui.test.wizard.SeamCreateTestProjectTest;
import org.jboss.tools.seam.ui.test.wizard.SeamFormNewWizardTest;
@@ -55,6 +56,7 @@
suite.addTestSuite(PackageNamesTest.class);
suite.addTestSuite(JBide3989Test.class);
suite.addTestSuite(SeamCreateTestProjectTest.class);
+ suite.addTestSuite(Seam20XCreateTestProjectTest.class);
return suite;
}
}
\ No newline at end of file
Added:
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/Seam20XCreateTestProjectTest.java
===================================================================
---
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/Seam20XCreateTestProjectTest.java
(rev 0)
+++
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/Seam20XCreateTestProjectTest.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -0,0 +1,53 @@
+package org.jboss.tools.seam.ui.test.wizard;
+
+import java.io.File;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.wst.common.project.facet.core.IProjectFacet;
+import org.eclipse.wst.common.project.facet.core.IProjectFacetVersion;
+import org.eclipse.wst.common.project.facet.core.ProjectFacetsManager;
+import org.jboss.tools.seam.core.project.facet.SeamRuntimeManager;
+import org.jboss.tools.seam.core.project.facet.SeamVersion;
+import org.jboss.tools.seam.core.test.project.facet.AbstractSeamFacetTest;
+
+public class Seam20XCreateTestProjectTest extends SeamCreateTestProjectTest {
+
+ public Seam20XCreateTestProjectTest(String name) {
+ super(name);
+ }
+
+ @Override
+ protected void setUp() throws Exception {
+ assertSeamHomeAvailable();
+ File folder = getSeamHomeFolder();
+ SeamRuntimeManager.getInstance().addRuntime(SEAM_2_0_0, folder.getAbsolutePath(),
SeamVersion.SEAM_2_0, true);
+ }
+
+ @Override
+ protected IProjectFacetVersion getSeamFacetVersion() {
+ IProjectFacet seamFacet = ProjectFacetsManager.getProjectFacet("jst.seam");
+ return seamFacet.getVersion("2.0");
+ }
+
+ @Override
+ protected String getSystemPropertyName() {
+ // TODO Auto-generated method stub
+ return AbstractSeamFacetTest.SEAM_2_0_HOME;
+ }
+
+ public void testSeamWarProjectWithTestProject() throws CoreException{
+ checkTestProjectCreation("test_seam20_war_t", SEAM_2_0_0, WAR, true);
+ }
+
+ public void testSeamWarProjectWithoutTestProject() throws CoreException{
+ checkTestProjectCreation("test_seam20_war", SEAM_2_0_0, WAR, false);
+ }
+
+ public void testSeamEarProjectWithTestProject() throws CoreException{
+ checkTestProjectCreation("test_seam20_ear_t", SEAM_2_0_0, EAR, true);
+ }
+
+ public void testSeamEarProjectWithoutTestProject() throws CoreException{
+ checkTestProjectCreation("test_seam20_ear", SEAM_2_0_0, EAR, false);
+ }
+}
Property changes on:
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/Seam20XCreateTestProjectTest.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified:
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamCreateTestProjectTest.java
===================================================================
---
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamCreateTestProjectTest.java 2009-11-23
20:46:27 UTC (rev 18792)
+++
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/wizard/SeamCreateTestProjectTest.java 2009-11-24
01:11:08 UTC (rev 18793)
@@ -10,10 +10,17 @@
******************************************************************************/
package org.jboss.tools.seam.ui.test.wizard;
+import java.io.File;
+
import org.eclipse.core.resources.IProject;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.wst.common.frameworks.datamodel.IDataModel;
import org.eclipse.wst.common.project.facet.core.IFacetedProject;
+import org.eclipse.wst.common.project.facet.core.IProjectFacet;
+import org.eclipse.wst.common.project.facet.core.IProjectFacetVersion;
+import org.eclipse.wst.common.project.facet.core.ProjectFacetsManager;
+import org.jboss.tools.seam.core.project.facet.SeamRuntimeManager;
+import org.jboss.tools.seam.core.project.facet.SeamVersion;
import org.jboss.tools.seam.core.test.project.facet.AbstractSeamFacetTest;
import org.jboss.tools.seam.internal.core.project.facet.ISeamFacetDataModelProperties;
@@ -28,8 +35,8 @@
public SeamCreateTestProjectTest(String name) {
super(name);
}
-
- private void checkTestProjectCreation(String name, String seamVersion, String
deployType, boolean createTestProject){
+
+ protected void checkTestProjectCreation(String name, String seamVersion, String
deployType, boolean createTestProject) throws CoreException{
IDataModel model = createSeamDataModel(deployType);
// set property to create test project
@@ -37,56 +44,34 @@
model.setStringProperty(ISeamFacetDataModelProperties.SEAM_RUNTIME_NAME, seamVersion);
- try{
- final IFacetedProject fproj = createSeamProject(name, model);
-
- final IProject proj = fproj.getProject();
-
- assertNotNull(proj);
- assertTrue(proj.exists());
- if(createTestProject){
- assertTrue(proj.getWorkspace().getRoot().getProject(proj.getName() +
"-test").exists());
- IProject testProject = proj.getWorkspace().getRoot().getProject(proj.getName() +
"-test");
- this.addResourceToCleanup(testProject);
- }else{
- assertFalse(proj.getWorkspace().getRoot().getProject(proj.getName() +
"-test").exists());
- }
- this.addResourceToCleanup(proj);
- }catch(CoreException ex){
- fail(ex.getMessage());
+
+ final IFacetedProject fproj = createSeamProject(name, model);
+
+ final IProject proj = fproj.getProject();
+
+ assertNotNull(proj);
+ assertTrue(proj.exists());
+ if(createTestProject){
+ assertTrue(proj.getWorkspace().getRoot().getProject(proj.getName() +
"-test").exists());
+ IProject testProject = proj.getWorkspace().getRoot().getProject(proj.getName() +
"-test");
+ }else{
+ assertFalse(proj.getWorkspace().getRoot().getProject(proj.getName() +
"-test").exists());
}
}
- public void testSeam12WarProjectWithTestProject(){
+ public void testSeamWarProjectWithTestProject() throws CoreException{
checkTestProjectCreation("test_seam12_war_t", SEAM_1_2_0, WAR, true);
}
- public void testSeam12WarProjectWithoutTestProject(){
+ public void testSeamWarProjectWithoutTestProject() throws CoreException{
checkTestProjectCreation("test_seam12_war", SEAM_1_2_0, WAR, false);
}
- public void testSeam20WarProjectWithTestProject(){
- checkTestProjectCreation("test_seam20_war_t", SEAM_2_0_0, WAR, true);
- }
-
- public void testSeam20WarProjectWithoutTestProject(){
- checkTestProjectCreation("test_seam20_war", SEAM_2_0_0, WAR, false);
- }
-
- public void testSeam12EarProjectWithTestProject(){
+ public void testSeamEarProjectWithTestProject() throws CoreException{
checkTestProjectCreation("test_seam12_ear_t", SEAM_1_2_0, EAR, true);
}
- public void testSeam12EarProjectWithoutTestProject(){
+ public void testSeamEarProjectWithoutTestProject() throws CoreException{
checkTestProjectCreation("test_seam12_ear", SEAM_1_2_0, EAR, false);
}
-
- public void testSeam20EarProjectWithTestProject(){
- checkTestProjectCreation("test_seam20_ear_t", SEAM_2_0_0, EAR, true);
- }
-
- public void testSeam20EarProjectWithoutTestProject(){
- checkTestProjectCreation("test_seam20_ear", SEAM_2_0_0, EAR, false);
- }
-
}