~ubuntu-branches/debian/sid/kdevelop/sid

« back to all changes in this revision

Viewing changes to debuggers/gdb/unittests/gdbtest.cpp

  • Committer: Package Import Robot
  • Author(s): Lisandro Damián Nicanor Pérez Meyer, Pino Toscano, Sune Vuorela, Lisandro Damián Nicanor Pérez Meyer
  • Date: 2015-09-02 21:10:24 UTC
  • mfrom: (1.3.24)
  • Revision ID: package-import@ubuntu.com-20150902211024-ntruxcyb574f3xuk
Tags: 4:4.7.1-1
* Team upload.

[ Pino Toscano ]
* Change section of kdevelop-dev to libdevel.
* Add ${misc:Depends} in kdevelop-dbg and kdevelop-l10n.

[ Sune Vuorela ]
* Make KDevelop recommend kapptemplate to have more meaningful project
  templates available.

[ Lisandro Damián Nicanor Pérez Meyer ]
* New upstream release.
  - Bump kdevplatform-dev build dependency to 1.7.1.
* Remove kde-workspace from build dependencies. We no longer provide
  a KDE 4 based workspace.
  - Add libsoprano-dev as a build dependency, it was probably previously
    pulled in by kde-workspace.

Show diffs side-by-side

added added

removed removed

Lines of Context:
106
106
class TestLaunchConfiguration : public KDevelop::ILaunchConfiguration
107
107
{
108
108
public:
109
 
    TestLaunchConfiguration(KUrl executable = findExecutable("debugee") ) {
 
109
    TestLaunchConfiguration(const KUrl& executable = findExecutable("debugee"),
 
110
                            const KUrl& workingDirectory = KUrl())
 
111
    {
110
112
        c = new KConfig();
111
113
        c->deleteGroup("launch");
112
114
        cfg = c->group("launch");
113
115
        cfg.writeEntry("isExecutable", true);
114
116
        cfg.writeEntry("Executable", executable);
 
117
        cfg.writeEntry("Working Directory", workingDirectory);
115
118
    }
116
119
    ~TestLaunchConfiguration() {
117
120
        delete c;
1829
1832
    }
1830
1833
}
1831
1834
 
 
1835
// see: https://bugs.kde.org/show_bug.cgi?id=339231
 
1836
void GdbTest::testPathWithSpace()
 
1837
{
 
1838
#ifdef HAVE_PATH_WITH_SPACES_TEST
 
1839
    TestDebugSession* session = new TestDebugSession;
 
1840
 
 
1841
    auto debugee = findExecutable("path with space/spacedebugee");
 
1842
    TestLaunchConfiguration c(debugee, debugee.upUrl());
 
1843
    KDevelop::Breakpoint* b = breakpoints()->addCodeBreakpoint("spacedebugee.cpp:30");
 
1844
    QCOMPARE(session->breakpointController()->breakpointState(b), KDevelop::Breakpoint::NotStartedState);
 
1845
    session->startProgram(&c, m_iface);
 
1846
 
 
1847
    WAIT_FOR_STATE(session, DebugSession::PausedState);
 
1848
    QCOMPARE(session->breakpointController()->breakpointState(b), KDevelop::Breakpoint::CleanState);
 
1849
    session->run();
 
1850
    WAIT_FOR_STATE(session, DebugSession::EndedState);
 
1851
#endif
 
1852
}
 
1853
 
1832
1854
void GdbTest::waitForState(GDBDebugger::DebugSession *session, DebugSession::DebuggerState state,
1833
1855
                            const char *file, int line, bool expectFail)
1834
1856
{