"""
Test lldb 'process connect' command.
"""

import os, time
import unittest2
import lldb
from lldbtest import *

class ConnectRemoteTestCase(TestBase):

    mydir = "connect_remote"

    def test_connect_remote(self):
        """Test "process connect connect:://localhost:12345"."""

        # First, we'll start a fake debugserver (a simple echo server).
        import subprocess
        fakeserver = subprocess.Popen('./EchoServer.py')
        # This does the cleanup afterwards.
        def cleanup_fakeserver():
            fakeserver.kill()
            fakeserver.wait()
        self.addTearDownHook(cleanup_fakeserver)

        self.runCmd("process connect connect://localhost:12345")


if __name__ == '__main__':
    import atexit
    lldb.SBDebugger.Initialize()
    atexit.register(lambda: lldb.SBDebugger.Terminate())
    unittest2.main()

"""
Test lldb 'process connect' command.
"""

import os, time
import unittest2
import lldb
from lldbtest import *

class ConnectRemoteTestCase(TestBase):

    mydir = "connect_remote"

    @unittest2.expectedFailure
    def test_connect_remote(self):
        """Test "process connect connect:://localhost:12345"."""

        # First, we'll start a fake debugserver (a simple echo server).
        import subprocess
        fakeserver = subprocess.Popen('./EchoServer.py')
        # This does the cleanup afterwards.
        def cleanup_fakeserver():
            fakeserver.kill()
            fakeserver.wait()
        self.addTearDownHook(cleanup_fakeserver)

        self.runCmd("process connect connect://localhost:12345")


if __name__ == '__main__':
    import atexit
    lldb.SBDebugger.Initialize()
    atexit.register(lambda: lldb.SBDebugger.Terminate())
    unittest2.main()

Add an expectedFailure decorator to the test_connect_remote() test case. It fails when running within the context of the test suite, but succeeds when running alone.
Add an expectedFailure decorator to the test_connect_remote() test case.
It fails when running within the context of the test suite, but succeeds
when running alone.


git-svn-id: b33bab8abb5b18c12ee100cd7761ab452d00b2b0@127290 91177308-0d34-0410-b5e6-96231b3b80d8
