Author: vrubezhny
Date: 2012-04-27 11:27:24 -0400 (Fri, 27 Apr 2012)
New Revision: 40574
Added:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.classpath
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.project
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/.jsdtscope
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.jdt.core.prefs
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.common.component
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.common.project.facet.core.xml
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.jsdt.ui.superType.container
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.jsdt.ui.superType.name
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/META-INF/
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/META-INF/MANIFEST.MF
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/WEB-INF/
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/WEB-INF/lib/
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/WEB-INF/web.xml
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/src/
Modified:
trunk/tests/tests/org.jboss.tools.tests.tests/META-INF/MANIFEST.MF
trunk/tests/tests/org.jboss.tools.tests.tests/src/org/jboss/tools/tests/tests/AllTests.java
trunk/tests/tests/org.jboss.tools.tests.tests/src/org/jboss/tools/tests/tests/UtilsTest.java
Log:
JBIDE-11600
Implement a meaningful Test for tests/ module, instead of
org.jboss.tools.tests.tests.UtilsTest
The JUnit Test is added for test component
Modified: trunk/tests/tests/org.jboss.tools.tests.tests/META-INF/MANIFEST.MF
===================================================================
--- trunk/tests/tests/org.jboss.tools.tests.tests/META-INF/MANIFEST.MF 2012-04-27 14:32:00
UTC (rev 40573)
+++ trunk/tests/tests/org.jboss.tools.tests.tests/META-INF/MANIFEST.MF 2012-04-27 15:27:24
UTC (rev 40574)
@@ -5,4 +5,8 @@
Bundle-Version: 3.2.0.qualifier
Bundle-Vendor: JBoss by Red Hat
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
-Require-Bundle: org.junit
+Require-Bundle: org.junit,
+ org.jboss.tools.tests,
+ org.eclipse.core.resources,
+ org.eclipse.core.runtime,
+ org.eclipse.wst.validation
Added:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.classpath
===================================================================
--- trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.classpath
(rev 0)
+++
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.classpath 2012-04-27
15:27:24 UTC (rev 40574)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="src"/>
+ <classpathentry kind="con"
path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/java-6-sun-1.6.0.26">
+ <attributes>
+ <attribute name="owner.project.facets" value="java"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="con"
path="org.eclipse.jst.server.core.container/org.jboss.ide.eclipse.as.core.server.runtime.runtimeTarget/JBoss
EAP 6.0 Runtime">
+ <attributes>
+ <attribute name="owner.project.facets" value="jst.web"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="con"
path="org.eclipse.jst.j2ee.internal.web.container"/>
+ <classpathentry kind="con"
path="org.eclipse.jst.j2ee.internal.module.container"/>
+ <classpathentry kind="output" path="build/classes"/>
+</classpath>
Property changes on:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.classpath
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.project
===================================================================
--- trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.project
(rev 0)
+++
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.project 2012-04-27
15:27:24 UTC (rev 40574)
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>DynamicWebProject</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.wst.jsdt.core.javascriptValidator</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.wst.common.project.facet.core.builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.wst.validation.validationbuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jem.workbench.JavaEMFNature</nature>
+ <nature>org.eclipse.wst.common.modulecore.ModuleCoreNature</nature>
+ <nature>org.eclipse.wst.common.project.facet.core.nature</nature>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ <nature>org.eclipse.wst.jsdt.core.jsNature</nature>
+ </natures>
+</projectDescription>
Property changes on:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.project
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/.jsdtscope
===================================================================
---
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/.jsdtscope
(rev 0)
+++
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/.jsdtscope 2012-04-27
15:27:24 UTC (rev 40574)
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" path="WebContent"/>
+ <classpathentry kind="con"
path="org.eclipse.wst.jsdt.launching.JRE_CONTAINER"/>
+ <classpathentry kind="con"
path="org.eclipse.wst.jsdt.launching.WebProject">
+ <attributes>
+ <attribute name="hide" value="true"/>
+ </attributes>
+ </classpathentry>
+ <classpathentry kind="con"
path="org.eclipse.wst.jsdt.launching.baseBrowserLibrary"/>
+ <classpathentry kind="output" path=""/>
+</classpath>
Added:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.jdt.core.prefs
===================================================================
---
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.jdt.core.prefs
(rev 0)
+++
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.jdt.core.prefs 2012-04-27
15:27:24 UTC (rev 40574)
@@ -0,0 +1,7 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
+org.eclipse.jdt.core.compiler.compliance=1.6
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.source=1.6
Property changes on:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.jdt.core.prefs
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.common.component
===================================================================
---
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.common.component
(rev 0)
+++
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.common.component 2012-04-27
15:27:24 UTC (rev 40574)
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project-modules id="moduleCoreId" project-version="1.5.0">
+ <wb-module deploy-name="DynamicWebProject">
+ <wb-resource deploy-path="/" source-path="/WebContent"
tag="defaultRootSource"/>
+ <wb-resource deploy-path="/WEB-INF/classes"
source-path="/src"/>
+ <property name="context-root"
value="DynamicWebProject"/>
+ <property name="java-output-path"
value="/DynamicWebProject/build/classes"/>
+ </wb-module>
+</project-modules>
Added:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.common.project.facet.core.xml
===================================================================
---
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.common.project.facet.core.xml
(rev 0)
+++
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.common.project.facet.core.xml 2012-04-27
15:27:24 UTC (rev 40574)
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<faceted-project>
+ <runtime name="JBoss EAP 6.0 Runtime"/>
+ <fixed facet="java"/>
+ <fixed facet="wst.jsdt.web"/>
+ <fixed facet="jst.web"/>
+ <installed facet="java" version="1.6"/>
+ <installed facet="jst.web" version="3.0"/>
+ <installed facet="wst.jsdt.web" version="1.0"/>
+</faceted-project>
Property changes on:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.common.project.facet.core.xml
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.jsdt.ui.superType.container
===================================================================
---
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.jsdt.ui.superType.container
(rev 0)
+++
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.jsdt.ui.superType.container 2012-04-27
15:27:24 UTC (rev 40574)
@@ -0,0 +1 @@
+org.eclipse.wst.jsdt.launching.baseBrowserLibrary
\ No newline at end of file
Added:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.jsdt.ui.superType.name
===================================================================
---
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.jsdt.ui.superType.name
(rev 0)
+++
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/.settings/org.eclipse.wst.jsdt.ui.superType.name 2012-04-27
15:27:24 UTC (rev 40574)
@@ -0,0 +1 @@
+Window
\ No newline at end of file
Added:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/META-INF/MANIFEST.MF
===================================================================
---
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/META-INF/MANIFEST.MF
(rev 0)
+++
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/META-INF/MANIFEST.MF 2012-04-27
15:27:24 UTC (rev 40574)
@@ -0,0 +1,3 @@
+Manifest-Version: 1.0
+Class-Path:
+
Property changes on:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/META-INF/MANIFEST.MF
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/WEB-INF/web.xml
===================================================================
---
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/WEB-INF/web.xml
(rev 0)
+++
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/WEB-INF/web.xml 2012-04-27
15:27:24 UTC (rev 40574)
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" id="WebApp_ID"
version="3.0">
+ <display-name>DynamicWebProject</display-name>
+ <welcome-file-list>
+ <welcome-file>index.html</welcome-file>
+ <welcome-file>index.htm</welcome-file>
+ <welcome-file>index.jsp</welcome-file>
+ <welcome-file>default.html</welcome-file>
+ <welcome-file>default.htm</welcome-file>
+ <welcome-file>default.jsp</welcome-file>
+ </welcome-file-list>
+</web-app>
\ No newline at end of file
Property changes on:
trunk/tests/tests/org.jboss.tools.tests.tests/projects/DynamicWebProject/WebContent/WEB-INF/web.xml
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified:
trunk/tests/tests/org.jboss.tools.tests.tests/src/org/jboss/tools/tests/tests/AllTests.java
===================================================================
---
trunk/tests/tests/org.jboss.tools.tests.tests/src/org/jboss/tools/tests/tests/AllTests.java 2012-04-27
14:32:00 UTC (rev 40573)
+++
trunk/tests/tests/org.jboss.tools.tests.tests/src/org/jboss/tools/tests/tests/AllTests.java 2012-04-27
15:27:24 UTC (rev 40574)
@@ -9,5 +9,4 @@
UtilsTest.class
})
public class AllTests {
-
}
Modified:
trunk/tests/tests/org.jboss.tools.tests.tests/src/org/jboss/tools/tests/tests/UtilsTest.java
===================================================================
---
trunk/tests/tests/org.jboss.tools.tests.tests/src/org/jboss/tools/tests/tests/UtilsTest.java 2012-04-27
14:32:00 UTC (rev 40573)
+++
trunk/tests/tests/org.jboss.tools.tests.tests/src/org/jboss/tools/tests/tests/UtilsTest.java 2012-04-27
15:27:24 UTC (rev 40574)
@@ -1,14 +1,25 @@
package org.jboss.tools.tests.tests;
-import static org.junit.Assert.*;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+import org.eclipse.core.resources.IProject;
+import org.jboss.tools.test.util.TestProjectProvider;
import org.junit.Test;
public class UtilsTest {
+ private static final String PROJECT_NAME = "DynamicWebProject";
+
@Test
- public void test() {
- fail("Not yet implemented");
+ public void testProjectProvider() throws Exception {
+ TestProjectProvider provider = new TestProjectProvider(
+ "org.jboss.tools.tests.tests", null, PROJECT_NAME, false);
+ IProject project = provider.getProject();
+ assertNotNull("Project is not imported: " + PROJECT_NAME, project);
+ assertTrue("Project doesn't exist: " + PROJECT_NAME, project.exists());
+ assertTrue("Project isn't accessible: " + PROJECT_NAME,
project.isAccessible());
+ assertTrue("Project isn't open: " + PROJECT_NAME, project.isOpen());
+ provider.dispose();
}
-
}