1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-08-29 19:23:38 +02:00

RESOLVED - bug 226738: [terminal] Terminal Unit Tests Fail

https://bugs.eclipse.org/bugs/show_bug.cgi?id=226738
This commit is contained in:
Michael Scharf 2009-01-30 04:13:18 +00:00
parent b22279e09b
commit 1ad2dd5a3d
2 changed files with 4 additions and 0 deletions

View file

@ -16,6 +16,7 @@ import java.io.OutputStream;
import junit.framework.TestCase; import junit.framework.TestCase;
import org.eclipse.core.runtime.Platform;
import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Shell; import org.eclipse.swt.widgets.Shell;
import org.eclipse.tm.internal.terminal.provisional.api.ISettingsPage; import org.eclipse.tm.internal.terminal.provisional.api.ISettingsPage;
@ -175,6 +176,7 @@ public class TerminalConnectorFactoryTest extends TestCase {
assertFalse(c.isInitialized()); assertFalse(c.isInitialized());
c.save(null); c.save(null);
assertFalse(c.isInitialized()); assertFalse(c.isInitialized());
if (!Platform.isRunning()) return;
c.getAdapter(ConnectorMock.class); c.getAdapter(ConnectorMock.class);
assertFalse(c.isInitialized()); assertFalse(c.isInitialized());
} }
@ -254,6 +256,7 @@ public class TerminalConnectorFactoryTest extends TestCase {
} }
public void testGetAdapter() { public void testGetAdapter() {
if (!Platform.isRunning()) return;
ConnectorMock mock=new ConnectorMock(); ConnectorMock mock=new ConnectorMock();
TerminalConnector c = makeTerminalConnector(mock); TerminalConnector c = makeTerminalConnector(mock);
assertNull(c.getAdapter(ConnectorMock.class)); assertNull(c.getAdapter(ConnectorMock.class));

View file

@ -25,6 +25,7 @@ public class AutomatedPluginTests extends TestCase {
public static Test suite() { public static Test suite() {
TestSuite suite = new TestSuite(AutomatedPluginTests.class.getName()); TestSuite suite = new TestSuite(AutomatedPluginTests.class.getName());
suite.addTestSuite(org.eclipse.tm.internal.terminal.connector.TerminalConnectorPluginTest.class); suite.addTestSuite(org.eclipse.tm.internal.terminal.connector.TerminalConnectorPluginTest.class);
suite.addTestSuite(org.eclipse.tm.internal.terminal.connector.TerminalConnectorFactoryTest.class);
return suite; return suite;
} }