JBoss Tools SVN: r40942 - trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet.
by jbosstools-commits@lists.jboss.org
Author: akazakov
Date: 2012-05-10 20:56:21 -0400 (Thu, 10 May 2012)
New Revision: 40942
Modified:
trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java
Log:
https://issues.jboss.org/browse/JBIDE-11490 tests for Seam 2.3
Modified: trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java 2012-05-11 00:52:37 UTC (rev 40941)
+++ trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java 2012-05-11 00:56:21 UTC (rev 40942)
@@ -76,7 +76,7 @@
@Override
protected boolean shouldCheckTestProject() {
- return true;
+ return false;
}
@Override
12 years, 8 months
JBoss Tools SVN: r40941 - in trunk/seam/tests: org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: akazakov
Date: 2012-05-10 20:52:37 -0400 (Thu, 10 May 2012)
New Revision: 40941
Modified:
trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeam2FacetInstallDelegateTest.java
trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java
Log:
https://issues.jboss.org/browse/JBIDE-11490 tests for Seam 2.3
Modified: trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeam2FacetInstallDelegateTest.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeam2FacetInstallDelegateTest.java 2012-05-11 00:50:41 UTC (rev 40940)
+++ trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeam2FacetInstallDelegateTest.java 2012-05-11 00:52:37 UTC (rev 40941)
@@ -262,7 +262,7 @@
return true;
}
- protected boolean checkTestProject() {
+ protected boolean shouldCheckTestProject() {
return true;
}
@@ -295,7 +295,7 @@
SeamProjectsSet seamProjectsSet = new SeamProjectsSet(war);
assertTrue(seamProjectsSet.getWarProject().exists());
- assertTrue(!checkTestProject() || seamProjectsSet.getTestProject().exists());
+ assertTrue(!shouldCheckTestProject() || seamProjectsSet.getTestProject().exists());
assertTrue(seamProjectsSet.getEjbProject().exists());
assertTrue(seamProjectsSet.getEarProject().exists());
@@ -355,7 +355,7 @@
assertOnlyContainsTheseFiles(onlyInWar, warLibs);
- if(checkTestProject()) {
+ if(shouldCheckTestProject()) {
assertOnlyContainsTheseFiles(onlyInTest, testLibs);
}
}else{
@@ -369,7 +369,7 @@
assertContainsNoneOfTheseFiles(onlyInWar, warLibs);
- if(checkTestProject()) {
+ if(shouldCheckTestProject()) {
assertContainsNoneOfTheseFiles(onlyInTest, testLibs);
}
}
Modified: trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java 2012-05-11 00:50:41 UTC (rev 40940)
+++ trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java 2012-05-11 00:52:37 UTC (rev 40941)
@@ -75,6 +75,11 @@
}
@Override
+ protected boolean shouldCheckTestProject() {
+ return true;
+ }
+
+ @Override
protected IDataModel createSeamDataModel(String deployType) {
IDataModel dataModel = super.createSeamDataModel(deployType);
dataModel.setStringProperty(
12 years, 8 months
JBoss Tools SVN: r40940 - trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet.
by jbosstools-commits@lists.jboss.org
Author: akazakov
Date: 2012-05-10 20:50:41 -0400 (Thu, 10 May 2012)
New Revision: 40940
Modified:
trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeam2FacetInstallDelegateTest.java
Log:
https://issues.jboss.org/browse/JBIDE-11490 tests for Seam 2.3
Modified: trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeam2FacetInstallDelegateTest.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeam2FacetInstallDelegateTest.java 2012-05-11 00:46:14 UTC (rev 40939)
+++ trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeam2FacetInstallDelegateTest.java 2012-05-11 00:50:41 UTC (rev 40940)
@@ -262,6 +262,10 @@
return true;
}
+ protected boolean checkTestProject() {
+ return true;
+ }
+
protected void checkEarLibrariesInSeamProject(int caseNumber, String earName) throws CoreException{
IDataModel earModel = createSeamDataModel("ear");
@@ -291,7 +295,7 @@
SeamProjectsSet seamProjectsSet = new SeamProjectsSet(war);
assertTrue(seamProjectsSet.getWarProject().exists());
- assertTrue(seamProjectsSet.getTestProject().exists());
+ assertTrue(!checkTestProject() || seamProjectsSet.getTestProject().exists());
assertTrue(seamProjectsSet.getEjbProject().exists());
assertTrue(seamProjectsSet.getEarProject().exists());
@@ -350,8 +354,10 @@
assertOnlyContainsTheseFiles(onlyInEar, earLibs);
assertOnlyContainsTheseFiles(onlyInWar, warLibs);
-
- assertOnlyContainsTheseFiles(onlyInTest, testLibs);
+
+ if(checkTestProject()) {
+ assertOnlyContainsTheseFiles(onlyInTest, testLibs);
+ }
}else{
assertContainsNoneOfTheseFiles(onlyInEjbSrc, ejbSrc);
@@ -362,8 +368,10 @@
assertContainsNoneOfTheseFiles(onlyInEar, earLibs);
assertContainsNoneOfTheseFiles(onlyInWar, warLibs);
-
- assertContainsNoneOfTheseFiles(onlyInTest, testLibs);
+
+ if(checkTestProject()) {
+ assertContainsNoneOfTheseFiles(onlyInTest, testLibs);
+ }
}
}
12 years, 8 months
JBoss Tools SVN: r40939 - in trunk/common/tests/org.jboss.tools.common.el.core.test: src/org/jboss/tools/common/el/core/test/resolver and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2012-05-10 20:46:14 -0400 (Thu, 10 May 2012)
New Revision: 40939
Added:
trunk/common/tests/org.jboss.tools.common.el.core.test/projects/JavaProject2/src/test/TestD.java
Modified:
trunk/common/tests/org.jboss.tools.common.el.core.test/src/org/jboss/tools/common/el/core/test/resolver/TypeInfoCollectorTest.java
Log:
JBIDE-11837
https://issues.jboss.org/browse/JBIDE-11837
Test is added.
Added: trunk/common/tests/org.jboss.tools.common.el.core.test/projects/JavaProject2/src/test/TestD.java
===================================================================
--- trunk/common/tests/org.jboss.tools.common.el.core.test/projects/JavaProject2/src/test/TestD.java (rev 0)
+++ trunk/common/tests/org.jboss.tools.common.el.core.test/projects/JavaProject2/src/test/TestD.java 2012-05-11 00:46:14 UTC (rev 40939)
@@ -0,0 +1,5 @@
+package test;
+
+public class TestD implements MissingInterface {
+
+}
\ No newline at end of file
Property changes on: trunk/common/tests/org.jboss.tools.common.el.core.test/projects/JavaProject2/src/test/TestD.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: trunk/common/tests/org.jboss.tools.common.el.core.test/src/org/jboss/tools/common/el/core/test/resolver/TypeInfoCollectorTest.java
===================================================================
--- trunk/common/tests/org.jboss.tools.common.el.core.test/src/org/jboss/tools/common/el/core/test/resolver/TypeInfoCollectorTest.java 2012-05-11 00:45:32 UTC (rev 40938)
+++ trunk/common/tests/org.jboss.tools.common.el.core.test/src/org/jboss/tools/common/el/core/test/resolver/TypeInfoCollectorTest.java 2012-05-11 00:46:14 UTC (rev 40939)
@@ -95,6 +95,16 @@
}
}
+ public void testMissingInterface() throws CoreException {
+ IJavaProject jp = JavaCore.create(project2);
+ String className = "test.TestD";
+ IType bean = jp.findType(className);
+ TypeInfoCollector.TypeInfo typeInfo = new TypeInfoCollector.TypeInfo(bean, null, false);
+ TypeInfoCollector collector = typeInfo.getTypeCollector(false, false);
+ //NullPointerException is expected in TypeInfoCollector.initSuperinterfaces()
+ assertNotNull(collector);
+ }
+
private MemberInfo getMethod(TypeInfoCollector collector, String name) {
collector.collectInfo();
List<MemberInfo> mts = collector.getMethods();
12 years, 8 months
JBoss Tools SVN: r40938 - trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2012-05-10 20:45:32 -0400 (Thu, 10 May 2012)
New Revision: 40938
Modified:
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/TypeInfoCollector.java
Log:
JBIDE-11837
https://issues.jboss.org/browse/JBIDE-11837
Super interface is checked for existence.
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/TypeInfoCollector.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/TypeInfoCollector.java 2012-05-11 00:28:41 UTC (rev 40937)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/TypeInfoCollector.java 2012-05-11 00:45:32 UTC (rev 40938)
@@ -994,8 +994,10 @@
break;
}
IType superType = type.getJavaProject().findType(fullySuperclassName);
- result.add(superType);
- initSuperinterfaces(superType, result);
+ if(superType != null) {
+ result.add(superType);
+ initSuperinterfaces(superType, result);
+ }
}
}
}
12 years, 8 months
JBoss Tools SVN: r40937 - trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet.
by jbosstools-commits@lists.jboss.org
Author: akazakov
Date: 2012-05-10 20:28:41 -0400 (Thu, 10 May 2012)
New Revision: 40937
Modified:
trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeam2FacetInstallDelegateTest.java
Log:
https://issues.jboss.org/browse/JBIDE-11490 tests for Seam 2.3
Modified: trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeam2FacetInstallDelegateTest.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeam2FacetInstallDelegateTest.java 2012-05-11 00:20:29 UTC (rev 40936)
+++ trunk/seam/tests/org.jboss.tools.seam.base.test/src/org/jboss/tools/seam/core/test/project/facet/AbstractSeam2FacetInstallDelegateTest.java 2012-05-11 00:28:41 UTC (rev 40937)
@@ -521,7 +521,9 @@
public boolean visit(IResourceProxy proxy) throws CoreException {
if (dir.getName().equals(proxy.getName()))
return true;
- foundFiles.add(proxy.getName());
+ if(proxy.isAccessible()) {
+ foundFiles.add(proxy.getName());
+ }
return false;
}
12 years, 8 months
JBoss Tools SVN: r40936 - trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2012-05-10 20:20:29 -0400 (Thu, 10 May 2012)
New Revision: 40936
Modified:
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/TypeInfoCollector.java
Log:
JBIDE-11838
https://issues.jboss.org/browse/JBIDE-11838
Getter return type is checked to decide if it defines a Java property.
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/TypeInfoCollector.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/TypeInfoCollector.java 2012-05-11 00:18:47 UTC (rev 40935)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/TypeInfoCollector.java 2012-05-11 00:20:29 UTC (rev 40936)
@@ -586,7 +586,7 @@
private String[] fParameterTypeNames;
private String[] fParameterTypeQualifiedNames;
private String[] fParameterNames;
- private IJavaElement fJavaElement;
+ private IMethod fJavaElement;
public MethodInfo(IType sourceType, String declaringTypeQualifiedName, String name,
int modifiers, String[] parameterTypeQualifiedNames,
@@ -674,7 +674,9 @@
}
public boolean isGetter() {
- return getType() != null && BeanUtil.isGetter(getName(), getNumberOfParameters());
+ return getType() != null
+ && BeanUtil.isGetter(getName(), getNumberOfParameters())
+ && BeanUtil.checkPropertyReturnType(getType().getName(), getName());
}
public boolean isSetter() {
12 years, 8 months
JBoss Tools SVN: r40935 - trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/util.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2012-05-10 20:18:47 -0400 (Thu, 10 May 2012)
New Revision: 40935
Modified:
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/util/BeanUtil.java
Log:
JBIDE-11838
https://issues.jboss.org/browse/JBIDE-11838
Public util method for for checking getter return type is added.
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/util/BeanUtil.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/util/BeanUtil.java 2012-05-11 00:13:13 UTC (rev 40934)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/util/BeanUtil.java 2012-05-11 00:18:47 UTC (rev 40935)
@@ -38,15 +38,12 @@
&& checkPropertyReturnType(method);
}
- private static boolean checkPropertyReturnType(IMethod method) {
- if(method == null) {
- return false;
- }
- String typeName = EclipseJavaUtil.getMemberTypeAsString(method);
+
+ public static boolean checkPropertyReturnType(String typeName, String methodName) {
if(typeName == null || typeName.equals("void")) { //$NON-NLS-1$
return false;
}
- if(method.getElementName().startsWith(BeanUtil.IS)) {
+ if(methodName.startsWith(BeanUtil.IS)) {
if(!"boolean".equals(typeName) && !"java.lang.Boolean".equals(typeName)) { //$NON-NLS-1$ //$NON-NLS-2$
return false;
}
@@ -54,6 +51,10 @@
return true;
}
+ private static boolean checkPropertyReturnType(IMethod method) {
+ return method != null && checkPropertyReturnType(EclipseJavaUtil.getMemberTypeAsString(method), method.getElementName());
+ }
+
public static boolean isSetter(IMethod method) {
return method != null && isSetter(method.getElementName(), method.getNumberOfParameters());
}
12 years, 8 months
JBoss Tools SVN: r40934 - trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet.
by jbosstools-commits@lists.jboss.org
Author: akazakov
Date: 2012-05-10 20:13:13 -0400 (Thu, 10 May 2012)
New Revision: 40934
Modified:
trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam20XFacetTestSuite230.java
trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java
Log:
https://issues.jboss.org/browse/JBIDE-11490 tests for Seam 2.3
Modified: trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam20XFacetTestSuite230.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam20XFacetTestSuite230.java 2012-05-11 00:08:22 UTC (rev 40933)
+++ trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam20XFacetTestSuite230.java 2012-05-11 00:13:13 UTC (rev 40934)
@@ -30,7 +30,7 @@
public static class Seam23FacetInstallDelegateTestSetup extends TestSetup {
- AbstractSeam2FacetInstallDelegateTest delegate = new Seam230FacetInstallDelegateTest("Delegate");
+ Seam230FacetInstallDelegateTest delegate = new Seam230FacetInstallDelegateTest("Delegate");
@Override
protected void setUp() throws Exception {
delegate.setUp();
Modified: trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java 2012-05-11 00:08:22 UTC (rev 40933)
+++ trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java 2012-05-11 00:13:13 UTC (rev 40934)
@@ -70,6 +70,11 @@
}
@Override
+ protected void tearDown() throws Exception {
+ super.tearDown();
+ }
+
+ @Override
protected IDataModel createSeamDataModel(String deployType) {
IDataModel dataModel = super.createSeamDataModel(deployType);
dataModel.setStringProperty(
12 years, 8 months
JBoss Tools SVN: r40933 - trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet.
by jbosstools-commits@lists.jboss.org
Author: akazakov
Date: 2012-05-10 20:08:22 -0400 (Thu, 10 May 2012)
New Revision: 40933
Modified:
trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam20XFacetTestSuite230.java
trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java
Log:
https://issues.jboss.org/browse/JBIDE-11490 tests for Seam 2.3
Modified: trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam20XFacetTestSuite230.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam20XFacetTestSuite230.java 2012-05-10 23:23:22 UTC (rev 40932)
+++ trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam20XFacetTestSuite230.java 2012-05-11 00:08:22 UTC (rev 40933)
@@ -30,7 +30,7 @@
public static class Seam23FacetInstallDelegateTestSetup extends TestSetup {
- Seam230FacetInstallDelegateTest delegate = new Seam230FacetInstallDelegateTest("Delegate");
+ AbstractSeam2FacetInstallDelegateTest delegate = new Seam230FacetInstallDelegateTest("Delegate");
@Override
protected void setUp() throws Exception {
delegate.setUp();
Modified: trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java 2012-05-10 23:23:22 UTC (rev 40932)
+++ trunk/seam/tests/org.jboss.tools.seam230.core.test/src/org/jboss/tools/seam/core/test/project/facet/Seam230FacetInstallDelegateTest.java 2012-05-11 00:08:22 UTC (rev 40933)
@@ -79,11 +79,20 @@
return dataModel;
}
- private static Set<String> convertToStrings(AntCopyUtils.FileSet fileSet) {
+ private Set<String> convertToStrings(AntCopyUtils.FileSet fileSet) {
Set<String> seamgenlibs = new HashSet<String>();
+ String libDir = seamRuntime.getLibDir();
+ File libDirFile = new File(libDir);
+ assertTrue(libDirFile.exists());
List<Pattern> list = fileSet.getIncluded();
for (Pattern pattern : list) {
- seamgenlibs.add(pattern.pattern());
+ String jarName = pattern.pattern();
+ File jarFile = new File(libDirFile, jarName);
+ if(jarFile.exists()) {
+ seamgenlibs.add(jarName);
+ } else {
+ System.out.println("WARNING: " + jarName + " jar is mentioned in deploy-*.list file but does not exist in " + libDir);
+ }
}
return seamgenlibs;
}
12 years, 8 months