Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 192028 Details for
Bug 337893
[multi-process][breakpoints] Setting breakpoints on a running target does not work with multi-process
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
Tests for all-stop mode
zpatch.targetAvailTests1.txt (text/plain), 59.25 KB, created by
Marc Khouzam
on 2011-03-28 13:23:01 EDT
(
hide
)
Description:
Tests for all-stop mode
Filename:
MIME Type:
Creator:
Marc Khouzam
Created:
2011-03-28 13:23:01 EDT
Size:
59.25 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.cdt.tests.dsf.gdb >Index: data/launch/src/TargetAvail.cc >=================================================================== >RCS file: data/launch/src/TargetAvail.cc >diff -N data/launch/src/TargetAvail.cc >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ data/launch/src/TargetAvail.cc 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,45 @@ >+ >+#include <stdio.h> >+#include "Sleep.h" >+ >+ >+void PrintHello() >+{ >+ printf("Hello World!\n"); >+ >+ SLEEP(1); >+ >+} >+ >+void PrintHi() >+{ >+ printf("Hi everybody!\n"); >+ >+ SLEEP(1); >+ >+} >+ >+void PrintBonjour() >+{ >+ printf("Bonjour!\n"); >+ >+ SLEEP(1); >+ >+} >+ >+int main(int argc, char *argv[]) >+{ >+ printf("In main\n"); >+ >+ SLEEP(1); >+ >+ SLEEP(1); >+ >+ PrintHello(); >+ >+ PrintHi(); >+ >+ PrintBonjour(); >+ >+ return 0; >+} >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/MIRunControlTargetAvailableTest.java >=================================================================== >RCS file: src/org/eclipse/cdt/tests/dsf/gdb/tests/MIRunControlTargetAvailableTest.java >diff -N src/org/eclipse/cdt/tests/dsf/gdb/tests/MIRunControlTargetAvailableTest.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/MIRunControlTargetAvailableTest.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,913 @@ >+/******************************************************************************* >+ * Copyright (c) 2007, 2010 Ericsson and others. >+ * All rights reserved. This program and the accompanying materials >+ * are made available under the terms of the Eclipse Public License v1.0 >+ * which accompanies this distribution, and is available at >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * Ericsson AB - Initial implementation of Test cases >+ *******************************************************************************/ >+package org.eclipse.cdt.tests.dsf.gdb.tests; >+ >+ >+import static org.junit.Assert.fail; >+ >+import java.util.concurrent.ExecutionException; >+import java.util.concurrent.TimeUnit; >+import java.util.concurrent.TimeoutException; >+ >+import org.eclipse.cdt.debug.core.ICDTLaunchConfigurationConstants; >+import org.eclipse.cdt.dsf.concurrent.CountingRequestMonitor; >+import org.eclipse.cdt.dsf.concurrent.DataRequestMonitor; >+import org.eclipse.cdt.dsf.concurrent.Query; >+import org.eclipse.cdt.dsf.concurrent.RequestMonitor; >+import org.eclipse.cdt.dsf.concurrent.Sequence.Step; >+import org.eclipse.cdt.dsf.datamodel.DMContexts; >+import org.eclipse.cdt.dsf.debug.service.IBreakpoints.IBreakpointsTargetDMContext; >+import org.eclipse.cdt.dsf.debug.service.IProcesses.IProcessDMContext; >+import org.eclipse.cdt.dsf.debug.service.IRunControl.IContainerDMContext; >+import org.eclipse.cdt.dsf.debug.service.IRunControl.ISuspendedDMEvent; >+import org.eclipse.cdt.dsf.gdb.service.command.IGDBControl; >+import org.eclipse.cdt.dsf.mi.service.IMIProcesses; >+import org.eclipse.cdt.dsf.mi.service.IMIRunControl; >+import org.eclipse.cdt.dsf.mi.service.MIProcesses; >+import org.eclipse.cdt.dsf.mi.service.command.output.MIBreakInsertInfo; >+import org.eclipse.cdt.dsf.service.DsfServicesTracker; >+import org.eclipse.cdt.dsf.service.DsfSession; >+import org.eclipse.cdt.tests.dsf.gdb.framework.BackgroundRunner; >+import org.eclipse.cdt.tests.dsf.gdb.framework.BaseTestCase; >+import org.eclipse.cdt.tests.dsf.gdb.framework.ServiceEventWaitor; >+import org.eclipse.cdt.tests.dsf.gdb.framework.SyncUtil; >+import org.eclipse.cdt.tests.dsf.gdb.launching.TestsPlugin; >+import org.junit.After; >+import org.junit.Assert; >+import org.junit.Before; >+import org.junit.BeforeClass; >+import org.junit.Test; >+import org.junit.runner.RunWith; >+ >+ >+/** >+ * Tests MIRunControl class for for the execWhileTargetAvailable() method. >+ */ >+@RunWith(BackgroundRunner.class) >+public class MIRunControlTargetAvailableTest extends BaseTestCase { >+ >+ private static final String TIMEOUT_MESSAGE = "Timeout"; >+ >+ private DsfServicesTracker fServicesTracker; >+ >+ private IGDBControl fGDBCtrl; >+ private IMIRunControl fRunCtrl; >+ >+ private IContainerDMContext fContainerDmc; >+ >+ /* >+ * Path to executable >+ */ >+ private static final String EXEC_PATH = "data/launch/bin/"; >+ /* >+ * Name of the executable >+ */ >+ private static final String EXEC_NAME = "TargetAvail.exe"; >+ private static final String SOURCE_NAME = "TargetAvail.cc"; >+ >+ @Before >+ public void init() throws Exception { >+ final DsfSession session = getGDBLaunch().getSession(); >+ >+ Runnable runnable = new Runnable() { >+ public void run() { >+ fServicesTracker = >+ new DsfServicesTracker(TestsPlugin.getBundleContext(), >+ session.getId()); >+ fGDBCtrl = fServicesTracker.getService(IGDBControl.class); >+ >+ IMIProcesses procService = fServicesTracker.getService(IMIProcesses.class); >+ IProcessDMContext procDmc = procService.createProcessContext(fGDBCtrl.getContext(), MIProcesses.UNIQUE_GROUP_ID); >+ fContainerDmc = procService.createContainerContext(procDmc, MIProcesses.UNIQUE_GROUP_ID); >+ >+ fRunCtrl = fServicesTracker.getService(IMIRunControl.class); >+ } >+ }; >+ session.getExecutor().submit(runnable).get(); >+ } >+ >+ >+ @After >+ public void tearDown() { >+ fServicesTracker.dispose(); >+ } >+ >+ @BeforeClass >+ public static void beforeClassMethod() { >+ setLaunchAttribute(ICDTLaunchConfigurationConstants.ATTR_PROGRAM_NAME, >+ EXEC_PATH + EXEC_NAME); >+ } >+ >+ /** >+ * Test that the executeWhileTargetAvailale interface works properly >+ * for a single operation with a single step when the target is stopped. >+ */ >+ @Test >+ public void executeSingleStepSingleOpWhileTargetStopped() throws Throwable { >+ // The target is currently stopped. >+ >+ // A single step that will set a breakpoint at PrintHello, which we will then make sure hits >+ final Step[] steps = new Step[] { >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, "PrintHello", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }} >+ }; >+ >+ Query<Boolean> query = new Query<Boolean>() { >+ @Override >+ protected void execute(DataRequestMonitor<Boolean> rm) { >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, steps, rm); >+ } >+ }; >+ try { >+ fRunCtrl.getExecutor().execute(query); >+ query.get(500, TimeUnit.MILLISECONDS); >+ } catch (InterruptedException e) { >+ fail(e.getMessage()); >+ } catch (ExecutionException e) { >+ fail(e.getCause().getMessage()); >+ } catch (TimeoutException e) { >+ fail(TIMEOUT_MESSAGE); >+ } >+ >+ // Now resume the target and check that we stop at the breakpoint. >+ >+ ServiceEventWaitor<ISuspendedDMEvent> suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ >+ // Wait up to 3 second for the target to suspend. Should happen within 2 second. >+ suspendedEventWaitor.waitForEvent(TestsPlugin.massageTimeout(3000)); >+ } >+ >+ /** >+ * Test that the executeWhileTargetAvailale interface works properly >+ * for a single operation with a single step when the target is running. >+ */ >+ @Test >+ public void executeSingleStepSingleOpWhileTargetRunning() throws Throwable { >+ // A single step that will set a breakpoint at PrintHello, which we will then make sure hits >+ final Step[] steps = new Step[] { >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, "PrintHello", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }} >+ }; >+ >+ // The target is currently stopped so we resume it >+ ServiceEventWaitor<ISuspendedDMEvent> suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ >+ Query<Boolean> query = new Query<Boolean>() { >+ @Override >+ protected void execute(DataRequestMonitor<Boolean> rm) { >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, steps, rm); >+ } >+ }; >+ try { >+ fRunCtrl.getExecutor().execute(query); >+ query.get(500, TimeUnit.MILLISECONDS); >+ } catch (InterruptedException e) { >+ fail(e.getMessage()); >+ } catch (ExecutionException e) { >+ fail(e.getCause().getMessage()); >+ } catch (TimeoutException e) { >+ fail(TIMEOUT_MESSAGE); >+ } >+ >+ // Now check that the target is stopped at the breakpoint. >+ // Wait up to 3 second for the target to suspend. Should happen at most in 2 seconds. >+ suspendedEventWaitor.waitForEvent(TestsPlugin.massageTimeout(3000)); >+ } >+ >+ /** >+ * Test that the executeWhileTargetAvailale interface works properly >+ * for a single operation with multiple steps when the target is stopped. >+ */ >+ @Test >+ public void executeMultiStepSingleOpWhileTargetStopped() throws Throwable { >+ // The target is currently stopped. >+ >+ // Multiple steps that will set three temp breakpoints at three different lines >+ // We then check that the target will stop three times >+ final Step[] steps = new Step[] { >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, "PrintHello", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }}, >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, "PrintHi", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }}, >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, "PrintBonjour", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }} >+ }; >+ >+ Query<Boolean> query = new Query<Boolean>() { >+ @Override >+ protected void execute(DataRequestMonitor<Boolean> rm) { >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, steps, rm); >+ } >+ }; >+ try { >+ fRunCtrl.getExecutor().execute(query); >+ query.get(500, TimeUnit.MILLISECONDS); >+ } catch (InterruptedException e) { >+ fail(e.getMessage()); >+ } catch (ExecutionException e) { >+ fail(e.getCause().getMessage()); >+ } catch (TimeoutException e) { >+ fail(TIMEOUT_MESSAGE); >+ } >+ >+ // Now resume the target three times and check that we stop three times. >+ for (int i=0; i<steps.length; i++) { >+ ServiceEventWaitor<ISuspendedDMEvent> suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ >+ // Wait up to 3 second for the target to suspend. Should happen within 2 seconds. >+ suspendedEventWaitor.waitForEvent(TestsPlugin.massageTimeout(3000)); >+ } >+ } >+ >+ /** >+ * Test that the executeWhileTargetAvailale interface works properly >+ * for a single operation with multiple steps when the target is stopped >+ * and one of the steps fails. >+ */ >+ @Test >+ public void executeMultiStepSingleOpWhileTargetStoppedWithError() throws Throwable { >+ // The target is currently stopped. >+ >+ // Multiple steps that will set three temp breakpoints at three different lines >+ // We then check that the target will stop three times >+ final Step[] steps = new Step[] { >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, "PrintHello", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }}, >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, "invalid condition", 0, "PrintHi", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }}, >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, "PrintBonjour", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }} >+ }; >+ >+ Query<Boolean> query = new Query<Boolean>() { >+ @Override >+ protected void execute(DataRequestMonitor<Boolean> rm) { >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, steps, rm); >+ } >+ }; >+ try { >+ fRunCtrl.getExecutor().execute(query); >+ query.get(500, TimeUnit.MILLISECONDS); >+ } catch (InterruptedException e) { >+ fail(e.getMessage()); >+ } catch (ExecutionException e) { >+ // We want to detect the error, so this is success >+ return; >+ } catch (TimeoutException e) { >+ fail(TIMEOUT_MESSAGE); >+ } >+ >+ fail("Did not detect the error of the step"); >+ } >+ >+ /** >+ * Test that the executeWhileTargetAvailale interface works properly >+ * for a single operation with multiple steps when the target is running. >+ */ >+ @Test >+ public void executeMultiStepSingleOpWhileTargetRunning() throws Throwable { >+ // Multiple steps that will set three temp breakpoints at three different lines >+ // We then check that the target will stop three times >+ final Step[] steps = new Step[] { >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, "PrintHello", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }}, >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, "PrintHi", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }}, >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, "PrintBonjour", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }} >+ }; >+ >+ // The target is currently stopped so we resume it >+ ServiceEventWaitor<ISuspendedDMEvent> suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ >+ Query<Boolean> query = new Query<Boolean>() { >+ @Override >+ protected void execute(DataRequestMonitor<Boolean> rm) { >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, steps, rm); >+ } >+ }; >+ try { >+ fRunCtrl.getExecutor().execute(query); >+ query.get(500, TimeUnit.MILLISECONDS); >+ } catch (InterruptedException e) { >+ fail(e.getMessage()); >+ } catch (ExecutionException e) { >+ fail(e.getCause().getMessage()); >+ } catch (TimeoutException e) { >+ fail(TIMEOUT_MESSAGE); >+ } >+ >+ // Now resume the target three times and check that we stop three times. >+ for (int i=0; i<steps.length; i++) { >+ // Wait up to 3 second for the target to suspend. Should happen within two seconds. >+ suspendedEventWaitor.waitForEvent(TestsPlugin.massageTimeout(3000)); >+ >+ suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ >+ } >+ } >+ >+ /** >+ * Test that the executeWhileTargetAvailale interface works properly >+ * for a single operation with multiple steps when the target is running >+ * and one of the steps fails. >+ */ >+ @Test >+ public void executeMultiStepSingleOpWhileTargetRunningWithError() throws Throwable { >+ // Multiple steps that will set three temp breakpoints at three different lines >+ // We then check that the target will stop three times >+ final Step[] steps = new Step[] { >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, "PrintHello", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }}, >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, "invalid condition", 0, "PrintHi", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }}, >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, "PrintBonjour", 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }} >+ }; >+ >+ // The target is currently stopped so we resume it >+ ServiceEventWaitor<ISuspendedDMEvent> suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ >+ Query<Boolean> query = new Query<Boolean>() { >+ @Override >+ protected void execute(DataRequestMonitor<Boolean> rm) { >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, steps, rm); >+ } >+ }; >+ >+ boolean caughtError = false; >+ try { >+ fRunCtrl.getExecutor().execute(query); >+ query.get(500, TimeUnit.MILLISECONDS); >+ } catch (InterruptedException e) { >+ fail(e.getMessage()); >+ } catch (ExecutionException e) { >+ caughtError = true; >+ } catch (TimeoutException e) { >+ fail(TIMEOUT_MESSAGE); >+ } >+ >+ Assert.assertTrue("Did not catch the error of the step", caughtError); >+ >+ // Now make sure the target stop of the first breakpoint >+ // Wait up to 3 second for the target to suspend. Should happen within two seconds. >+ suspendedEventWaitor.waitForEvent(TestsPlugin.massageTimeout(3000)); >+ } >+ >+ /** >+ * Test that the executeWhileTargetAvailale interface works properly >+ * for concurrent operations with a single step when the target is stopped. >+ */ >+ @Test >+ public void executeSingleStepConcurrentOpWhileTargetStopped() throws Throwable { >+ // The target is currently stopped. >+ >+ final int NUM_CONCURRENT = 3; >+ >+ String[] locations = { "PrintHello", "PrintHi", "PrintBonjour" }; >+ final Step[][] steps = new Step[NUM_CONCURRENT][1]; // one step for each concurrent operation >+ for (int i=0; i<steps.length; i++) { >+ final String location = locations[i]; >+ steps[i] = new Step[] { >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, location, 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }} >+ }; >+ } >+ >+ Query<Boolean> query = new Query<Boolean>() { >+ @Override >+ protected void execute(final DataRequestMonitor<Boolean> rm) { >+ CountingRequestMonitor crm = new CountingRequestMonitor(fGDBCtrl.getExecutor(), null) { >+ @Override >+ protected void handleCompleted() { >+ rm.done(); >+ }; >+ }; >+ >+ >+ int index; >+ for (index=0; index<steps.length; index++) { >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, steps[index], crm); >+ } >+ >+ crm.setDoneCount(index); >+ } >+ }; >+ try { >+ fRunCtrl.getExecutor().execute(query); >+ query.get(500, TimeUnit.MILLISECONDS); >+ } catch (InterruptedException e) { >+ fail(e.getMessage()); >+ } catch (ExecutionException e) { >+ fail(e.getCause().getMessage()); >+ } catch (TimeoutException e) { >+ fail(TIMEOUT_MESSAGE); >+ } >+ >+ for (int i=0; i<steps.length; i++) { >+ // Now resume the target and check that we stop at all the breakpoints. >+ ServiceEventWaitor<ISuspendedDMEvent> suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ >+ // Wait up to 3 second for the target to suspend. Should happen within 2 second. >+ suspendedEventWaitor.waitForEvent(TestsPlugin.massageTimeout(3000)); >+ } >+ } >+ >+ /** >+ * Test that the executeWhileTargetAvailale interface works properly >+ * for concurrent operations with a single step when the target is running. >+ */ >+ @Test >+ public void executeSingleStepConcurrentOpWhileTargetRunning() throws Throwable { >+ final int NUM_CONCURRENT = 3; >+ >+ String[] locations = { "PrintHello", "PrintHi", "PrintBonjour" }; >+ final Step[][] steps = new Step[NUM_CONCURRENT][1]; // one step for each concurrent operation >+ for (int i=0; i<steps.length; i++) { >+ final String location = locations[i]; >+ steps[i] = new Step[] { >+ new Step() { >+ @Override >+ public void execute(RequestMonitor rm) { >+ IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, location, 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm)); >+ }} >+ }; >+ } >+ >+ // The target is currently stopped so we resume it >+ ServiceEventWaitor<ISuspendedDMEvent> suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ >+ Query<Boolean> query = new Query<Boolean>() { >+ @Override >+ protected void execute(final DataRequestMonitor<Boolean> rm) { >+ CountingRequestMonitor crm = new CountingRequestMonitor(fGDBCtrl.getExecutor(), null) { >+ @Override >+ protected void handleCompleted() { >+ rm.done(); >+ }; >+ }; >+ >+ >+ int index; >+ for (index=0; index<steps.length; index++) { >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, steps[index], crm); >+ } >+ >+ crm.setDoneCount(index); >+ } >+ }; >+ try { >+ fRunCtrl.getExecutor().execute(query); >+ query.get(500, TimeUnit.MILLISECONDS); >+ } catch (InterruptedException e) { >+ fail(e.getMessage()); >+ } catch (ExecutionException e) { >+ fail(e.getCause().getMessage()); >+ } catch (TimeoutException e) { >+ fail(TIMEOUT_MESSAGE); >+ } >+ >+ for (int i=0; i<steps.length; i++) { >+ // Wait up to 3 second for the target to suspend. Should happen within 2 seconds. >+ suspendedEventWaitor.waitForEvent(TestsPlugin.massageTimeout(3000)); >+ >+ // Now resume the target and check that we stop at all the breakpoints. >+ suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ } >+ } >+ >+ /** >+ * Test that the executeWhileTargetAvailale interface works properly >+ * for concurrent operations with a single step when the target is stopped. >+ * This tests verifies that we properly handle concurrent operations that are sent >+ * while other operations are already being run. >+ */ >+ @Test >+ public void executeSingleStepConcurrentButDelayedOpWhileTargetStopped() throws Throwable { >+ // The target is currently stopped. >+ >+ final String location = "PrintHello"; >+ final String location2 = "PrintHi"; >+ final Step[] steps = new Step[] { >+ new Step() { >+ @Override >+ public void execute(final RequestMonitor rm) { >+ final IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, location, 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm) { >+ @Override >+ protected void handleSuccess() { >+ // Now that time has elapsed, send another command >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, new Step[] { >+ new Step() { >+ @Override >+ public void execute(final RequestMonitor rm) { >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, location2, 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), null)); >+ }}}, new RequestMonitor(fGDBCtrl.getExecutor(), null)); >+ >+ // Complete the first operation because the two are supposed to be independent >+ rm.done(); >+ }}); >+ }} >+ }; >+ >+ Query<Boolean> query = new Query<Boolean>() { >+ @Override >+ protected void execute(final DataRequestMonitor<Boolean> rm) { >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, steps, rm); >+ } >+ }; >+ try { >+ fRunCtrl.getExecutor().execute(query); >+ query.get(500, TimeUnit.MILLISECONDS); >+ } catch (InterruptedException e) { >+ fail(e.getMessage()); >+ } catch (ExecutionException e) { >+ fail(e.getCause().getMessage()); >+ } catch (TimeoutException e) { >+ fail(TIMEOUT_MESSAGE); >+ } >+ >+ for (int i=0; i<2; i++) { >+ // The target is currently stopped so we resume it >+ ServiceEventWaitor<ISuspendedDMEvent> suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ >+ // Wait up to 3 second for the target to suspend. Should happen within 2 seconds. >+ suspendedEventWaitor.waitForEvent(TestsPlugin.massageTimeout(3000)); >+ } >+ } >+ >+ /** >+ * Test that the executeWhileTargetAvailale interface works properly >+ * for concurrent operations with a single step when the target is running. >+ * This tests verifies that we properly handle concurrent operations that are sent >+ * while other operations are already being run. >+ */ >+ @Test >+ public void executeSingleStepConcurrentButDelayedOpWhileTargetRunning() throws Throwable { >+ final String location = "PrintHello"; >+ final String location2 = "PrintHi"; >+ final Step[] steps = new Step[] { >+ new Step() { >+ @Override >+ public void execute(final RequestMonitor rm) { >+ final IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, location, 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm) { >+ @Override >+ protected void handleSuccess() { >+ // Now that time has elapsed, send another command >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, new Step[] { >+ new Step() { >+ @Override >+ public void execute(final RequestMonitor otherRm) { >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, location2, 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), otherRm)); >+ }}}, new RequestMonitor(fGDBCtrl.getExecutor(), null)); >+ >+ // Complete the first operation because the two are supposed to be independent >+ rm.done(); >+ }}); >+ }} >+ }; >+ >+ // The target is currently stopped so we resume it >+ ServiceEventWaitor<ISuspendedDMEvent> suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ >+ Query<Boolean> query = new Query<Boolean>() { >+ @Override >+ protected void execute(final DataRequestMonitor<Boolean> rm) { >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, steps, rm); >+ } >+ }; >+ try { >+ fRunCtrl.getExecutor().execute(query); >+ query.get(500, TimeUnit.MILLISECONDS); >+ } catch (InterruptedException e) { >+ fail(e.getMessage()); >+ } catch (ExecutionException e) { >+ fail(e.getCause().getMessage()); >+ } catch (TimeoutException e) { >+ fail(TIMEOUT_MESSAGE); >+ } >+ >+ for (int i=0; i<2; i++) { >+ // Wait up to 3 second for the target to suspend. Should happen within 2 seconds. >+ suspendedEventWaitor.waitForEvent(TestsPlugin.massageTimeout(3000)); >+ >+ // Now resume the target and check that we stop at all the breakpoints. >+ suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ } >+ } >+ >+ /** >+ * Test that the executeWhileTargetAvailale interface works properly >+ * for concurrent operations with a single step when the target is stopped. >+ * This tests verifies that we properly handle concurrent operations that are >+ * dependent on each other; this means that the second operation needs to complete >+ * for the second one to complete. >+ */ >+ @Test >+ public void executeSingleStepConcurrentAndDependentOpWhileTargetStopped() throws Throwable { >+ // The target is currently stopped. >+ >+ final String location = "PrintHello"; >+ final String location2 = "PrintHi"; >+ final Step[] steps = new Step[] { >+ new Step() { >+ @Override >+ public void execute(final RequestMonitor rm) { >+ final IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, location, 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm) { >+ @Override >+ protected void handleSuccess() { >+ // Send another such operation and wait for it to complete to mark the original one as completed >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, new Step[] { >+ new Step() { >+ @Override >+ public void execute(final RequestMonitor otherRm) { >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, location2, 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), otherRm)); >+ }}}, rm); >+ }}); >+ }} >+ }; >+ >+ Query<Boolean> query = new Query<Boolean>() { >+ @Override >+ protected void execute(final DataRequestMonitor<Boolean> rm) { >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, steps, rm); >+ } >+ }; >+ try { >+ fRunCtrl.getExecutor().execute(query); >+ query.get(500, TimeUnit.MILLISECONDS); >+ } catch (InterruptedException e) { >+ fail(e.getMessage()); >+ } catch (ExecutionException e) { >+ fail(e.getCause().getMessage()); >+ } catch (TimeoutException e) { >+ fail(TIMEOUT_MESSAGE); >+ } >+ >+ for (int i=0; i<2; i++) { >+ // The target is currently stopped so we resume it >+ ServiceEventWaitor<ISuspendedDMEvent> suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ >+ // Wait up to 3 second for the target to suspend. Should happen within 2 seconds. >+ suspendedEventWaitor.waitForEvent(TestsPlugin.massageTimeout(3000)); >+ } >+ } >+ >+ /** >+ * Test that the executeWhileTargetAvailale interface works properly >+ * for concurrent operations with a single step when the target is running. >+ * This tests verifies that we properly handle concurrent operations that are >+ * dependent on each other; this means that the second operation needs to complete >+ * for the second one to complete. >+ */ >+ @Test >+ public void executeSingleStepConcurrentAndDependentOpWhileTargetRunning() throws Throwable { >+ final String location = "PrintHello"; >+ final String location2 = "PrintHi"; >+ final Step[] steps = new Step[] { >+ new Step() { >+ @Override >+ public void execute(final RequestMonitor rm) { >+ final IBreakpointsTargetDMContext bpTargetDmc = DMContexts.getAncestorOfType(fContainerDmc, IBreakpointsTargetDMContext.class); >+ >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, location, 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), rm) { >+ @Override >+ protected void handleSuccess() { >+ // Send another such operation and wait for it to complete to mark the original one as completed >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, new Step[] { >+ new Step() { >+ @Override >+ public void execute(final RequestMonitor otherRm) { >+ fGDBCtrl.queueCommand( >+ fGDBCtrl.getCommandFactory().createMIBreakInsert(bpTargetDmc, true, false, null, 0, location2, 0), >+ new DataRequestMonitor<MIBreakInsertInfo> (fGDBCtrl.getExecutor(), otherRm)); >+ }}}, rm); >+ }}); >+ }} >+ }; >+ >+ // The target is currently stopped so we resume it >+ ServiceEventWaitor<ISuspendedDMEvent> suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ >+ Query<Boolean> query = new Query<Boolean>() { >+ @Override >+ protected void execute(final DataRequestMonitor<Boolean> rm) { >+ fRunCtrl.executeWithTargetAvailable(fContainerDmc, steps, rm); >+ } >+ }; >+ try { >+ fRunCtrl.getExecutor().execute(query); >+ query.get(500, TimeUnit.MILLISECONDS); >+ } catch (InterruptedException e) { >+ fail(e.getMessage()); >+ } catch (ExecutionException e) { >+ fail(e.getCause().getMessage()); >+ } catch (TimeoutException e) { >+ fail(TIMEOUT_MESSAGE); >+ } >+ >+ for (int i=0; i<2; i++) { >+ // Wait up to 3 second for the target to suspend. Should happen within 2 seconds. >+ suspendedEventWaitor.waitForEvent(TestsPlugin.massageTimeout(3000)); >+ >+ // Now resume the target and check that we stop at all the breakpoints. >+ suspendedEventWaitor = new ServiceEventWaitor<ISuspendedDMEvent>( >+ getGDBLaunch().getSession(), >+ ISuspendedDMEvent.class); >+ >+ SyncUtil.resume(); >+ } >+ } >+} >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_6/MIRunControlTargetAvailableTest_6_6.java >=================================================================== >RCS file: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_6/MIRunControlTargetAvailableTest_6_6.java >diff -N src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_6/MIRunControlTargetAvailableTest_6_6.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_6/MIRunControlTargetAvailableTest_6_6.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,26 @@ >+/******************************************************************************* >+ * Copyright (c) 2011 Ericsson and others. >+ * All rights reserved. This program and the accompanying materials >+ * are made available under the terms of the Eclipse Public License v1.0 >+ * which accompanies this distribution, and is available at >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * Ericsson AB - Initial implementation of Test cases >+ *******************************************************************************/ >+package org.eclipse.cdt.tests.dsf.gdb.tests.tests_6_6; >+ >+ >+import org.eclipse.cdt.tests.dsf.gdb.framework.BackgroundRunner; >+import org.eclipse.cdt.tests.dsf.gdb.tests.ITestConstants; >+import org.eclipse.cdt.tests.dsf.gdb.tests.MIRunControlTargetAvailableTest; >+import org.junit.BeforeClass; >+import org.junit.runner.RunWith; >+ >+@RunWith(BackgroundRunner.class) >+public class MIRunControlTargetAvailableTest_6_6 extends MIRunControlTargetAvailableTest { >+ @BeforeClass >+ public static void beforeClassMethod_6_6() { >+ setGdbProgramNamesLaunchAttributes(ITestConstants.SUFFIX_GDB_6_6); >+ } >+} >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_6/Suite_6_6.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_6/Suite_6_6.java,v >retrieving revision 1.4 >diff -u -r1.4 Suite_6_6.java >--- src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_6/Suite_6_6.java 1 Feb 2011 19:20:06 -0000 1.4 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_6/Suite_6_6.java 28 Mar 2011 17:14:11 -0000 >@@ -28,6 +28,7 @@ > // We need specific name for the tests of this suite, because of bug https://bugs.eclipse.org/172256 > MIRegistersTest_6_6.class, > MIRunControlTest_6_6.class, >+ MIRunControlTargetAvailableTest_6_6.class, > MIExpressionsTest_6_6.class, > MIMemoryTest_6_6.class, > MIBreakpointsTest_6_6.class, >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_6/Suite_Remote_6_6.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_6/Suite_Remote_6_6.java,v >retrieving revision 1.3 >diff -u -r1.3 Suite_Remote_6_6.java >--- src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_6/Suite_Remote_6_6.java 28 Jan 2011 02:03:46 -0000 1.3 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_6/Suite_Remote_6_6.java 28 Mar 2011 17:14:11 -0000 >@@ -32,6 +32,7 @@ > // We need specific name for the tests of this suite, because of bug https://bugs.eclipse.org/172256 > MIRegistersTest_6_6.class, > MIRunControlTest_6_6.class, >+ MIRunControlTargetAvailableTest_6_6.class, > MIExpressionsTest_6_6.class, > MIMemoryTest_6_6.class, > MIBreakpointsTest_6_6.class, >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_7/MIRunControlTargetAvailableTest_6_7.java >=================================================================== >RCS file: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_7/MIRunControlTargetAvailableTest_6_7.java >diff -N src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_7/MIRunControlTargetAvailableTest_6_7.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_7/MIRunControlTargetAvailableTest_6_7.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,26 @@ >+/******************************************************************************* >+ * Copyright (c) 2011 Ericsson and others. >+ * All rights reserved. This program and the accompanying materials >+ * are made available under the terms of the Eclipse Public License v1.0 >+ * which accompanies this distribution, and is available at >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * Ericsson AB - Initial implementation of Test cases >+ *******************************************************************************/ >+package org.eclipse.cdt.tests.dsf.gdb.tests.tests_6_7; >+ >+ >+import org.eclipse.cdt.tests.dsf.gdb.framework.BackgroundRunner; >+import org.eclipse.cdt.tests.dsf.gdb.tests.ITestConstants; >+import org.eclipse.cdt.tests.dsf.gdb.tests.tests_6_6.MIRunControlTargetAvailableTest_6_6; >+import org.junit.BeforeClass; >+import org.junit.runner.RunWith; >+ >+@RunWith(BackgroundRunner.class) >+public class MIRunControlTargetAvailableTest_6_7 extends MIRunControlTargetAvailableTest_6_6 { >+ @BeforeClass >+ public static void beforeClassMethod_6_7() { >+ setGdbProgramNamesLaunchAttributes(ITestConstants.SUFFIX_GDB_6_7); >+ } >+} >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_7/Suite_6_7.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_7/Suite_6_7.java,v >retrieving revision 1.4 >diff -u -r1.4 Suite_6_7.java >--- src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_7/Suite_6_7.java 1 Feb 2011 19:20:06 -0000 1.4 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_7/Suite_6_7.java 28 Mar 2011 17:14:11 -0000 >@@ -28,6 +28,7 @@ > // We need specific name for the tests of this suite, because of bug https://bugs.eclipse.org/172256 > MIRegistersTest_6_7.class, > MIRunControlTest_6_7.class, >+ MIRunControlTargetAvailableTest_6_7.class, > MIExpressionsTest_6_7.class, > MIMemoryTest_6_7.class, > MIBreakpointsTest_6_7.class, >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_7/Suite_Remote_6_7.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_7/Suite_Remote_6_7.java,v >retrieving revision 1.3 >diff -u -r1.3 Suite_Remote_6_7.java >--- src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_7/Suite_Remote_6_7.java 28 Jan 2011 02:03:46 -0000 1.3 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_7/Suite_Remote_6_7.java 28 Mar 2011 17:14:11 -0000 >@@ -32,6 +32,7 @@ > // We need specific name for the tests of this suite, because of bug https://bugs.eclipse.org/172256 > MIRegistersTest_6_7.class, > MIRunControlTest_6_7.class, >+ MIRunControlTargetAvailableTest_6_7.class, > MIExpressionsTest_6_7.class, > MIMemoryTest_6_7.class, > MIBreakpointsTest_6_7.class, >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_8/MIRunControlTargetAvailableTest_6_8.java >=================================================================== >RCS file: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_8/MIRunControlTargetAvailableTest_6_8.java >diff -N src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_8/MIRunControlTargetAvailableTest_6_8.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_8/MIRunControlTargetAvailableTest_6_8.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,26 @@ >+/******************************************************************************* >+ * Copyright (c) 2011 Ericsson and others. >+ * All rights reserved. This program and the accompanying materials >+ * are made available under the terms of the Eclipse Public License v1.0 >+ * which accompanies this distribution, and is available at >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * Ericsson AB - Initial implementation of Test cases >+ *******************************************************************************/ >+package org.eclipse.cdt.tests.dsf.gdb.tests.tests_6_8; >+ >+ >+import org.eclipse.cdt.tests.dsf.gdb.framework.BackgroundRunner; >+import org.eclipse.cdt.tests.dsf.gdb.tests.ITestConstants; >+import org.eclipse.cdt.tests.dsf.gdb.tests.tests_6_7.MIRunControlTargetAvailableTest_6_7; >+import org.junit.BeforeClass; >+import org.junit.runner.RunWith; >+ >+@RunWith(BackgroundRunner.class) >+public class MIRunControlTargetAvailableTest_6_8 extends MIRunControlTargetAvailableTest_6_7 { >+ @BeforeClass >+ public static void beforeClassMethod_6_8() { >+ setGdbProgramNamesLaunchAttributes(ITestConstants.SUFFIX_GDB_6_8); >+ } >+} >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_8/Suite_6_8.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_8/Suite_6_8.java,v >retrieving revision 1.4 >diff -u -r1.4 Suite_6_8.java >--- src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_8/Suite_6_8.java 1 Feb 2011 19:20:05 -0000 1.4 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_8/Suite_6_8.java 28 Mar 2011 17:14:12 -0000 >@@ -28,6 +28,7 @@ > // We need specific name for the tests of this suite, because of bug https://bugs.eclipse.org/172256 > MIRegistersTest_6_8.class, > MIRunControlTest_6_8.class, >+ MIRunControlTargetAvailableTest_6_8.class, > MIExpressionsTest_6_8.class, > MIMemoryTest_6_8.class, > MIBreakpointsTest_6_8.class, >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_8/Suite_Remote_6_8.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_8/Suite_Remote_6_8.java,v >retrieving revision 1.3 >diff -u -r1.3 Suite_Remote_6_8.java >--- src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_8/Suite_Remote_6_8.java 28 Jan 2011 02:03:45 -0000 1.3 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_8/Suite_Remote_6_8.java 28 Mar 2011 17:14:12 -0000 >@@ -32,6 +32,7 @@ > // We need specific name for the tests of this suite, because of bug https://bugs.eclipse.org/172256 > MIRegistersTest_6_8.class, > MIRunControlTest_6_8.class, >+ MIRunControlTargetAvailableTest_6_8.class, > MIExpressionsTest_6_8.class, > MIMemoryTest_6_8.class, > MIBreakpointsTest_6_8.class, >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_0/MIRunControlTargetAvailableTest_7_0.java >=================================================================== >RCS file: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_0/MIRunControlTargetAvailableTest_7_0.java >diff -N src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_0/MIRunControlTargetAvailableTest_7_0.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_0/MIRunControlTargetAvailableTest_7_0.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,26 @@ >+/******************************************************************************* >+ * Copyright (c) 2011 Ericsson and others. >+ * All rights reserved. This program and the accompanying materials >+ * are made available under the terms of the Eclipse Public License v1.0 >+ * which accompanies this distribution, and is available at >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * Ericsson AB - Initial implementation of Test cases >+ *******************************************************************************/ >+package org.eclipse.cdt.tests.dsf.gdb.tests.tests_7_0; >+ >+ >+import org.eclipse.cdt.tests.dsf.gdb.framework.BackgroundRunner; >+import org.eclipse.cdt.tests.dsf.gdb.tests.ITestConstants; >+import org.eclipse.cdt.tests.dsf.gdb.tests.tests_6_8.MIRunControlTargetAvailableTest_6_8; >+import org.junit.BeforeClass; >+import org.junit.runner.RunWith; >+ >+@RunWith(BackgroundRunner.class) >+public class MIRunControlTargetAvailableTest_7_0 extends MIRunControlTargetAvailableTest_6_8 { >+ @BeforeClass >+ public static void beforeClassMethod_7_0() { >+ setGdbProgramNamesLaunchAttributes(ITestConstants.SUFFIX_GDB_7_0); >+ } >+} >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_0/Suite_7_0.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_0/Suite_7_0.java,v >retrieving revision 1.4 >diff -u -r1.4 Suite_7_0.java >--- src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_0/Suite_7_0.java 1 Feb 2011 19:20:06 -0000 1.4 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_0/Suite_7_0.java 28 Mar 2011 17:14:12 -0000 >@@ -28,6 +28,7 @@ > // We need specific name for the tests of this suite, because of bug https://bugs.eclipse.org/172256 > MIRegistersTest_7_0.class, > MIRunControlTest_7_0.class, >+ MIRunControlTargetAvailableTest_7_0.class, > MIExpressionsTest_7_0.class, > MIMemoryTest_7_0.class, > MIBreakpointsTest_7_0.class, >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_0/Suite_Remote_7_0.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_0/Suite_Remote_7_0.java,v >retrieving revision 1.4 >diff -u -r1.4 Suite_Remote_7_0.java >--- src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_0/Suite_Remote_7_0.java 28 Jan 2011 02:03:45 -0000 1.4 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_0/Suite_Remote_7_0.java 28 Mar 2011 17:14:12 -0000 >@@ -32,6 +32,7 @@ > // We need specific name for the tests of this suite, because of bug https://bugs.eclipse.org/172256 > GDBRemoteTracepointsTest_7_0.class, > MIRegistersTest_7_0.class, >+ MIRunControlTargetAvailableTest_7_0.class, > MIRunControlTest_7_0.class, > MIExpressionsTest_7_0.class, > MIMemoryTest_7_0.class, >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_1/MIRunControlTargetAvailableTest_7_1.java >=================================================================== >RCS file: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_1/MIRunControlTargetAvailableTest_7_1.java >diff -N src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_1/MIRunControlTargetAvailableTest_7_1.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_1/MIRunControlTargetAvailableTest_7_1.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,26 @@ >+/******************************************************************************* >+ * Copyright (c) 2011 Ericsson and others. >+ * All rights reserved. This program and the accompanying materials >+ * are made available under the terms of the Eclipse Public License v1.0 >+ * which accompanies this distribution, and is available at >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * Ericsson AB - Initial implementation of Test cases >+ *******************************************************************************/ >+package org.eclipse.cdt.tests.dsf.gdb.tests.tests_7_1; >+ >+ >+import org.eclipse.cdt.tests.dsf.gdb.framework.BackgroundRunner; >+import org.eclipse.cdt.tests.dsf.gdb.tests.ITestConstants; >+import org.eclipse.cdt.tests.dsf.gdb.tests.tests_7_0.MIRunControlTargetAvailableTest_7_0; >+import org.junit.BeforeClass; >+import org.junit.runner.RunWith; >+ >+@RunWith(BackgroundRunner.class) >+public class MIRunControlTargetAvailableTest_7_1 extends MIRunControlTargetAvailableTest_7_0 { >+ @BeforeClass >+ public static void beforeClassMethod_7_1() { >+ setGdbProgramNamesLaunchAttributes(ITestConstants.SUFFIX_GDB_7_1); >+ } >+} >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_1/Suite_7_1.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_1/Suite_7_1.java,v >retrieving revision 1.3 >diff -u -r1.3 Suite_7_1.java >--- src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_1/Suite_7_1.java 1 Feb 2011 19:20:06 -0000 1.3 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_1/Suite_7_1.java 28 Mar 2011 17:14:12 -0000 >@@ -28,6 +28,7 @@ > // We need specific name for the tests of this suite, because of bug https://bugs.eclipse.org/172256 > MIRegistersTest_7_1.class, > MIRunControlTest_7_1.class, >+ MIRunControlTargetAvailableTest_7_1.class, > MIExpressionsTest_7_1.class, > MIMemoryTest_7_1.class, > MIBreakpointsTest_7_1.class, >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_1/Suite_Remote_7_1.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_1/Suite_Remote_7_1.java,v >retrieving revision 1.2 >diff -u -r1.2 Suite_Remote_7_1.java >--- src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_1/Suite_Remote_7_1.java 28 Jan 2011 02:03:46 -0000 1.2 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_1/Suite_Remote_7_1.java 28 Mar 2011 17:14:12 -0000 >@@ -32,6 +32,7 @@ > // We need specific name for the tests of this suite, because of bug https://bugs.eclipse.org/172256 > GDBRemoteTracepointsTest_7_1.class, > MIRegistersTest_7_1.class, >+ MIRunControlTargetAvailableTest_7_1.class, > MIRunControlTest_7_1.class, > MIExpressionsTest_7_1.class, > MIMemoryTest_7_1.class, >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_2/MIRunControlTargetAvailableTest_7_2.java >=================================================================== >RCS file: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_2/MIRunControlTargetAvailableTest_7_2.java >diff -N src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_2/MIRunControlTargetAvailableTest_7_2.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_2/MIRunControlTargetAvailableTest_7_2.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,26 @@ >+/******************************************************************************* >+ * Copyright (c) 2011 Ericsson and others. >+ * All rights reserved. This program and the accompanying materials >+ * are made available under the terms of the Eclipse Public License v1.0 >+ * which accompanies this distribution, and is available at >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * Ericsson AB - Initial implementation of Test cases >+ *******************************************************************************/ >+package org.eclipse.cdt.tests.dsf.gdb.tests.tests_7_2; >+ >+ >+import org.eclipse.cdt.tests.dsf.gdb.framework.BackgroundRunner; >+import org.eclipse.cdt.tests.dsf.gdb.tests.ITestConstants; >+import org.eclipse.cdt.tests.dsf.gdb.tests.tests_7_1.MIRunControlTargetAvailableTest_7_1; >+import org.junit.BeforeClass; >+import org.junit.runner.RunWith; >+ >+@RunWith(BackgroundRunner.class) >+public class MIRunControlTargetAvailableTest_7_2 extends MIRunControlTargetAvailableTest_7_1 { >+ @BeforeClass >+ public static void beforeClassMethod_7_2() { >+ setGdbProgramNamesLaunchAttributes(ITestConstants.SUFFIX_GDB_7_2); >+ } >+} >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_2/Suite_7_2.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_2/Suite_7_2.java,v >retrieving revision 1.3 >diff -u -r1.3 Suite_7_2.java >--- src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_2/Suite_7_2.java 1 Feb 2011 19:20:06 -0000 1.3 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_2/Suite_7_2.java 28 Mar 2011 17:14:12 -0000 >@@ -28,6 +28,7 @@ > // We need specific name for the tests of this suite, because of bug https://bugs.eclipse.org/172256 > MIRegistersTest_7_2.class, > MIRunControlTest_7_2.class, >+ MIRunControlTargetAvailableTest_7_2.class, > MIExpressionsTest_7_2.class, > MIMemoryTest_7_2.class, > MIBreakpointsTest_7_2.class, >Index: src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_2/Suite_Remote_7_2.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_2/Suite_Remote_7_2.java,v >retrieving revision 1.2 >diff -u -r1.2 Suite_Remote_7_2.java >--- src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_2/Suite_Remote_7_2.java 28 Jan 2011 02:03:46 -0000 1.2 >+++ src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_2/Suite_Remote_7_2.java 28 Mar 2011 17:14:12 -0000 >@@ -33,6 +33,7 @@ > GDBRemoteTracepointsTest_7_2.class, > MIRegistersTest_7_2.class, > MIRunControlTest_7_2.class, >+ MIRunControlTargetAvailableTest_7_2.class, > MIExpressionsTest_7_2.class, > MIMemoryTest_7_2.class, > MIBreakpointsTest_7_2.class,
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
marc.khouzam
:
iplog-
Actions:
View
|
Diff
Attachments on
bug 337893
: 192028 |
192029
|
192038
|
192202
|
192418
|
192419
|
192606
|
192993
|
193212