code: def is_adb_root(self):
          
          try:
              return '0' == self.adb.shell('id -u').decode('utf-8').strip()
          except adb.AdbError:
              # Wait a bit and retry to work around adb flakiness for this cmd.
              time.sleep(0.2)
              return '0' == self.adb.shell('id -u').decode('utf-8').strip()
docs: True if adb is running as root for this device.