forked from OSchip/llvm-project
Add a missing return in SBPlatform::IsConnected and test
for the behavior - using the fact that the Host platform is always present & connected. llvm-svn: 327448
This commit is contained in:
parent
0805b80a73
commit
ca38766c9c
|
@ -49,6 +49,14 @@ class PlatformPythonTestCase(TestBase):
|
|||
break
|
||||
self.assertTrue(platform_found)
|
||||
|
||||
@add_test_categories(['pyapi'])
|
||||
@no_debug_info_test
|
||||
def test_host_is_connected(self):
|
||||
# We've already tested that this one IS the host platform.
|
||||
host_platform = self.dbg.GetPlatformAtIndex(0)
|
||||
self.assertTrue(host_platform.IsConnected(), "The host platform is always connected")
|
||||
|
||||
|
||||
@add_test_categories(['pyapi'])
|
||||
@no_debug_info_test
|
||||
def test_available_platform_list(self):
|
||||
|
|
|
@ -271,7 +271,7 @@ void SBPlatform::DisconnectRemote() {
|
|||
bool SBPlatform::IsConnected() {
|
||||
PlatformSP platform_sp(GetSP());
|
||||
if (platform_sp)
|
||||
platform_sp->IsConnected();
|
||||
return platform_sp->IsConnected();
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue