Community
Participate
Working Groups
Created attachment 188071 [details] New tests I wrote some new JUnit tests that cover some of the launching and restarting of a DSF-GDB debug session. These tests make sure that the launch respects parameter set by the user such as arguments, environment variables, gdbinit file, and more. There are 27 new tests in total. 4 of which are currently ignored because I haven't figured out how to get them to do what I want, while another 4 actually fail. The ones that fail seem to be because of a real bug in DSF-GDB, which I will address in a separate bugzilla. These tests will prove useful as I will be changing the code that takes care of the launching, as part of the multi-process effort.
I committed the patch to HEAD. I have added the tests to all test suites (6.6 to 7.2) but I didn't add them to the remoteSuite yet. This is a pretty large patch, but maybe John can have a quick look at the overall approach?
*** cdt cvs genie on behalf of mkhouzam *** Bug 336008: [tests] JUnit tests for launch configuration and restart [*] AllSuites.java 1.4 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/AllSuites.java?root=Tools_Project&r1=1.3&r2=1.4 [+] LaunchConfigurationAndRestartTest.java http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/LaunchConfigurationAndRestartTest.java?root=Tools_Project&revision=1.1&view=markup [*] AllTests.java 1.4 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/AllTests.java?root=Tools_Project&r1=1.3&r2=1.4 [*] Suite_6_8.java 1.4 http://dev.eclipse.org/viewcvs/index.cgi/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?root=Tools_Project&r1=1.3&r2=1.4 [+] LaunchConfigurationAndRestartTest_6_8.java http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_8/LaunchConfigurationAndRestartTest_6_8.java?root=Tools_Project&revision=1.1&view=markup [*] Suite_7_1.java 1.3 http://dev.eclipse.org/viewcvs/index.cgi/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?root=Tools_Project&r1=1.2&r2=1.3 [+] LaunchConfigurationAndRestartTest_7_1.java http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_1/LaunchConfigurationAndRestartTest_7_1.java?root=Tools_Project&revision=1.1&view=markup [*] SyncUtil.java 1.14 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/framework/SyncUtil.java?root=Tools_Project&r1=1.13&r2=1.14 [*] BaseTestCase.java 1.15 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/framework/BaseTestCase.java?root=Tools_Project&r1=1.14&r2=1.15 [+] launchConfigTestGdbinit http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/data/launch/src/launchConfigTestGdbinit?root=Tools_Project&revision=1.1&view=markup [+] LaunchConfigurationAndRestartTestApp.cc http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/data/launch/src/LaunchConfigurationAndRestartTestApp.cc?root=Tools_Project&revision=1.1&view=markup [*] Suite_6_6.java 1.4 http://dev.eclipse.org/viewcvs/index.cgi/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?root=Tools_Project&r1=1.3&r2=1.4 [+] LaunchConfigurationAndRestartTest_6_6.java http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_6/LaunchConfigurationAndRestartTest_6_6.java?root=Tools_Project&revision=1.1&view=markup [+] LaunchConfigurationAndRestartTest_6_7.java http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_6_7/LaunchConfigurationAndRestartTest_6_7.java?root=Tools_Project&revision=1.1&view=markup [*] Suite_6_7.java 1.4 http://dev.eclipse.org/viewcvs/index.cgi/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?root=Tools_Project&r1=1.3&r2=1.4 [+] LaunchConfigurationAndRestartTest_7_0.java http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_0/LaunchConfigurationAndRestartTest_7_0.java?root=Tools_Project&revision=1.1&view=markup [*] Suite_7_0.java 1.4 http://dev.eclipse.org/viewcvs/index.cgi/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?root=Tools_Project&r1=1.3&r2=1.4 [+] LaunchConfigurationAndRestartTest_7_2.java http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/tests_7_2/LaunchConfigurationAndRestartTest_7_2.java?root=Tools_Project&revision=1.1&view=markup [*] Suite_7_2.java 1.3 http://dev.eclipse.org/viewcvs/index.cgi/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?root=Tools_Project&r1=1.2&r2=1.3
(In reply to comment #0) > ... another 4 actually fail. The ones that fail seem to be because of a real bug in DSF-GDB, which I will address in a separate bugzilla. I have fixed this issue with Bug 336013. So, all new tests should now pass (with 4 ignored ones).
*** cdt cvs genie on behalf of mkhouzam *** Bug 336008: [tests] JUnit tests for launch configuration and restart [*] .cvsignore 1.5 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/data/launch/bin/.cvsignore?root=Tools_Project&r1=1.4&r2=1.5 [-] LaunchConfigurationAndRestartTestApp.exe http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/data/launch/bin/LaunchConfigurationAndRestartTestApp.exe?root=Tools_Project&view=markup