|
From: <caw...@us...> - 2007-01-19 21:17:26
|
Revision: 1825
http://svn.sourceforge.net/rubyeclipse/?rev=1825&view=rev
Author: cawilliams
Date: 2007-01-19 13:17:23 -0800 (Fri, 19 Jan 2007)
Log Message:
-----------
just try to get back to building properly...
Modified Paths:
--------------
trunk/org.rubypeople.rdt.debug.core.tests/src/org/rubypeople/rdt/debug/core/tests/FTC_RubyDebugCommunicationTest.java
trunk/org.rubypeople.rdt.launching.tests/plugin.xml
trunk/org.rubypeople.rdt.launching.tests/src/org/rubypeople/rdt/internal/launching/TC_RunnerLaunching.java
Modified: trunk/org.rubypeople.rdt.debug.core.tests/src/org/rubypeople/rdt/debug/core/tests/FTC_RubyDebugCommunicationTest.java
===================================================================
--- trunk/org.rubypeople.rdt.debug.core.tests/src/org/rubypeople/rdt/debug/core/tests/FTC_RubyDebugCommunicationTest.java 2007-01-19 21:12:12 UTC (rev 1824)
+++ trunk/org.rubypeople.rdt.debug.core.tests/src/org/rubypeople/rdt/debug/core/tests/FTC_RubyDebugCommunicationTest.java 2007-01-19 21:17:23 UTC (rev 1825)
@@ -2,7 +2,6 @@
import org.rubypeople.rdt.core.RubyCore;
import org.rubypeople.rdt.internal.debug.core.SuspensionPoint;
-import org.rubypeople.rdt.internal.launching.DebuggerRunner;
import org.rubypeople.rdt.internal.launching.LaunchingPlugin;
public class FTC_RubyDebugCommunicationTest extends FTC_ClassicDebuggerCommunicationTest {
@@ -84,7 +83,7 @@
protected String getDirectoryOfRubyDebuggerFile() {
String result = null;
if (RubyCore.getPlugin() != null) {
- result = DebuggerRunner.getDirectoryOfRubyDebuggerFile();
+ result = RubyCore.getOSDirectory(LaunchingPlugin.getDefault()) + "ruby";
} else {
result = LaunchingPlugin.class.getResource(".").getPath() + "/../../../../../../ruby";
}
Modified: trunk/org.rubypeople.rdt.launching.tests/plugin.xml
===================================================================
--- trunk/org.rubypeople.rdt.launching.tests/plugin.xml 2007-01-19 21:12:12 UTC (rev 1824)
+++ trunk/org.rubypeople.rdt.launching.tests/plugin.xml 2007-01-19 21:17:23 UTC (rev 1825)
@@ -19,6 +19,7 @@
<import plugin="org.rubypeople.rdt.launching"/>
<import plugin="org.eclipse.core.resources"/>
<import plugin="org.rubypeople.eclipse.testutils"/>
+ <import plugin="org.rubypeople.rdt.core"/>
</requires>
</plugin>
Modified: trunk/org.rubypeople.rdt.launching.tests/src/org/rubypeople/rdt/internal/launching/TC_RunnerLaunching.java
===================================================================
--- trunk/org.rubypeople.rdt.launching.tests/src/org/rubypeople/rdt/internal/launching/TC_RunnerLaunching.java 2007-01-19 21:12:12 UTC (rev 1824)
+++ trunk/org.rubypeople.rdt.launching.tests/src/org/rubypeople/rdt/internal/launching/TC_RunnerLaunching.java 2007-01-19 21:17:23 UTC (rev 1825)
@@ -23,6 +23,7 @@
import org.eclipse.debug.core.Launch;
import org.rubypeople.eclipse.shams.debug.core.ShamLaunchConfigurationType;
import org.rubypeople.eclipse.testutils.ResourceTools;
+import org.rubypeople.rdt.core.RubyCore;
import org.rubypeople.rdt.launching.IVMInstall;
import org.rubypeople.rdt.launching.IVMInstallType;
import org.rubypeople.rdt.launching.RubyRuntime;
@@ -66,7 +67,7 @@
}
// The include paths and the executed ruby file is quoted on windows
if (debug) {
- String dirOfRubyDebuggerFile = DebuggerRunner.getDirectoryOfRubyDebuggerFile().replace('/', File.separatorChar) ;
+ String dirOfRubyDebuggerFile = getDirectoryOfRubyDebuggerFile().replace('/', File.separatorChar) ;
if (dirOfRubyDebuggerFile.startsWith("\\")) {
dirOfRubyDebuggerFile = dirOfRubyDebuggerFile.substring(1) ;
}
@@ -85,6 +86,10 @@
return commandLine;
}
+ private String getDirectoryOfRubyDebuggerFile() {
+ return RubyCore.getOSDirectory(LaunchingPlugin.getDefault()) + "ruby";
+ }
+
public void testDebugEnabled() throws Exception {
// check if debugging is enabled in plugin.xml
ILaunchConfigurationType launchConfigurationType =
@@ -100,7 +105,7 @@
IProject project = ResourceTools.createProject(PROJECT_NAME);
- ShamInterpreter interpreter = new ShamInterpreter("", new File(""));
+ IVMInstall interpreter = new VMStandin((IVMInstallType)null, "");
ILaunchConfiguration configuration = new ShamLaunchConfiguration();
ILaunch launch = new Launch(configuration, debug ? ILaunchManager.DEBUG_MODE : ILaunchManager.RUN_MODE, null);
@@ -115,11 +120,11 @@
assertEquals("One process has been spawned", 1, launch.getProcesses().length);
List expected = getCommandLine(project, debug);
- List actual = interpreter.getArguments();
+ String[] actual = interpreter.getVMArguments();
if (debug) {
// we must cheat with the first argument, because it is a temporary file which
// contains is different for every call
- expected.add(0, actual.get(0)) ;
+ expected.add(0, actual[0]) ;
}
assertEquals("Assembled command line.", expected, actual);
assertEquals(
@@ -264,21 +269,4 @@
}
}
- public class ShamInterpreter extends RubyInterpreter {
- public ShamInterpreter(String aName, File validInstallLocation) {
- super(aName, validInstallLocation);
- }
- private List arguments;
- public List getArguments() {
- return arguments;
- }
- public String getCommand() {
- return RUBY_COMMAND;
- }
- public Process exec(List args, File workingDirectory) {
- arguments = args;
- return new ShamProcess();
- }
- }
-
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|