Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStephan Herrmann2010-09-27 19:47:41 +0000
committerStephan Herrmann2010-09-27 19:47:41 +0000
commit284e6f7accc7f23be0a7191f84a03273087354ca (patch)
tree00aac46e2a26dbd505be41ac95db2c271525fefd /testplugins/org.eclipse.objectteams.otdt.ui.tests.refactoring
parentebd7cf42d18f126b8c42dbb330352d8e8902e006 (diff)
downloadorg.eclipse.objectteams-284e6f7accc7f23be0a7191f84a03273087354ca.tar.gz
org.eclipse.objectteams-284e6f7accc7f23be0a7191f84a03273087354ca.tar.xz
org.eclipse.objectteams-284e6f7accc7f23be0a7191f84a03273087354ca.zip
try to avoid one more inline patch by using a role.
Diffstat (limited to 'testplugins/org.eclipse.objectteams.otdt.ui.tests.refactoring')
-rw-r--r--testplugins/org.eclipse.objectteams.otdt.ui.tests.refactoring/plugin.xml5
-rw-r--r--testplugins/org.eclipse.objectteams.otdt.ui.tests.refactoring/src/org/eclipse/objectteams/otdt/ui/tests/refactoring/OTRefactoringTestSetup.java22
2 files changed, 21 insertions, 6 deletions
diff --git a/testplugins/org.eclipse.objectteams.otdt.ui.tests.refactoring/plugin.xml b/testplugins/org.eclipse.objectteams.otdt.ui.tests.refactoring/plugin.xml
index a0eaa6dc0..02cfb41d8 100644
--- a/testplugins/org.eclipse.objectteams.otdt.ui.tests.refactoring/plugin.xml
+++ b/testplugins/org.eclipse.objectteams.otdt.ui.tests.refactoring/plugin.xml
@@ -14,6 +14,11 @@
class="org.eclipse.objectteams.otdt.ui.tests.refactoring.JdtTests"
icon="platform:/plugin/org.eclipse.objectteams.otdt.ui/icons/ot/team_obj.gif">
</team>
+ <team
+ activation="NONE"
+ class="org.eclipse.objectteams.otdt.ui.tests.refactoring.OTRefactoringTestSetup"
+ icon="platform:/plugin/org.eclipse.objectteams.otdt.ui/icons/ot/team_obj.gif">
+ </team>
</aspectBinding>
</extension>
diff --git a/testplugins/org.eclipse.objectteams.otdt.ui.tests.refactoring/src/org/eclipse/objectteams/otdt/ui/tests/refactoring/OTRefactoringTestSetup.java b/testplugins/org.eclipse.objectteams.otdt.ui.tests.refactoring/src/org/eclipse/objectteams/otdt/ui/tests/refactoring/OTRefactoringTestSetup.java
index 98436ac2c..02632d0b7 100644
--- a/testplugins/org.eclipse.objectteams.otdt.ui.tests.refactoring/src/org/eclipse/objectteams/otdt/ui/tests/refactoring/OTRefactoringTestSetup.java
+++ b/testplugins/org.eclipse.objectteams.otdt.ui.tests.refactoring/src/org/eclipse/objectteams/otdt/ui/tests/refactoring/OTRefactoringTestSetup.java
@@ -25,18 +25,28 @@ import junit.framework.Test;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.jdt.core.IJavaProject;
import org.eclipse.jdt.ui.tests.refactoring.RefactoringTestSetup;
-import org.eclipse.objectteams.otdt.ui.tests.util.JavaProjectHelper;
+import base org.eclipse.jdt.testplugin.JavaProjectHelper;
@SuppressWarnings("restriction")
-public class OTRefactoringTestSetup extends RefactoringTestSetup {
+public team class OTRefactoringTestSetup extends RefactoringTestSetup {
public OTRefactoringTestSetup(Test test) {
super(test);
}
-//{ObjectTeams: changed project creation:
- protected IJavaProject createJavaProject(String string, String string2) throws CoreException {
- return JavaProjectHelper.createOTJavaProject("TestProject"+System.currentTimeMillis(), "bin");
-// SH}
+ @Override
+ protected void setUp() throws Exception {
+ within (this)
+ super.setUp();
+ }
+
+ protected class ProjectHelper playedBy JavaProjectHelper {
+
+ IJavaProject createJavaProject(String projectName, String binFolderName) <- replace IJavaProject createJavaProject(String projectName, String binFolderName);
+
+ @SuppressWarnings("basecall")
+ static callin IJavaProject createJavaProject(String projectName, String binFolderName) throws CoreException {
+ return org.eclipse.objectteams.otdt.ui.tests.util.JavaProjectHelper.createOTJavaProject(projectName, binFolderName);
+ }
}
}

Back to the top