Example #1
0
def is_emulator():
    result = adb.getserialno()
    if re.search('emulator.*', result[1]):
        print('True')
        return True
    else:
        print('False')
        return False
Example #2
0
def is_emulator():
    result = adb.getserialno()
    if re.search("emulator.*", result[1]):
        print("True")
        return True
    else:
        print("False")
        return False
Example #3
0
 def test_getserialno_p(self):
     result = adb.getserialno()
     self.assertNotRegexpMatches(result[1], 'unknown')
Example #4
0
def is_device_available():
    result = adb.getserialno()
    if re.search('unknown', result[1]):
        return False
    else:
        return True
Example #5
0
def is_emulator():
    result = adb.getserialno()
    if re.search('emulator.*', result[1]):
        return True
    else:
        return False
Example #6
0
 def test_getserialno(self):
     result = adb.getserialno()
     self.assertNotRegexpMatches(result[1], 'unknown')
Example #7
0
def is_device_available():
    result = adb.getserialno()
    if re.search('unknown', result[1]):
        return False
    else:
        return True
Example #8
0
 def test_getserialno(self):
     result = adb.getserialno()
     result[1].should_not.match(r'unknown')