Skip to main content

Automation test for phone

Project description

README: UIAutomator2 Dump Screen Project

Mục đích

Dự án này sử dụng uiautomator2 để kết nối từ laptop tới server trên điện thoại Android, thực hiện dump màn hình và trả dữ liệu về laptop.

Sơ đồ kết nối

Sơ đồ kết nối

  • Laptop: Gửi yêu cầu dump màn hình qua uiautomator2.
  • Điện thoại (Server UIAutomator2): Nhận yêu cầu, thực hiện dump màn hình và gửi kết quả về laptop.

Cài đặt

  1. Cài đặt qa_phone_automation trên laptop:
pip install -U qaautomation
  1. Kết nối điện thoại với qaautomation:
import uiautomator2 as u2

device = u2.connect('device_ip')
print(device.info)

Cách sử dụng

from coreapp import get_xml_content

xml_data = get_xml_content('device_id', type='uiautomator')
print(xml_data)

Lưu ý

  • Điện thoại cần bật chế độ nhà phát triển và cấp quyền ADB.
  • Đảm bảo uiautomator2 server đang chạy trên điện thoại.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

qa_automation_phone-0.1.0.tar.gz (4.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

qa_automation_phone-0.1.0-py3-none-any.whl (5.5 kB view details)

Uploaded Python 3

File details

Details for the file qa_automation_phone-0.1.0.tar.gz.

File metadata

  • Download URL: qa_automation_phone-0.1.0.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.5

File hashes

Hashes for qa_automation_phone-0.1.0.tar.gz
Algorithm Hash digest
SHA256 d284b9a00c7498500b0cf79c6098c85ed06663f04f2e00d59e946b628f54454e
MD5 b78e80fcd063b93de04baf4b2d6f4b8c
BLAKE2b-256 d82f96a68b2c3e2e697597fce157fddfded784f28fe39a285a7e128a07d42f9d

See more details on using hashes here.

File details

Details for the file qa_automation_phone-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for qa_automation_phone-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 66ebcb8a33f915f92b52897ec358cdaf063cd5cbcb153c501fa610721c3875d7
MD5 6af35445ad604fde8fc04390171aafa3
BLAKE2b-256 e227a408cb4e7e706ec7f7cf2c2716e8e667de265ac90877d818f4d03e220fd2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page