Android Testing(Android 测试)

本文介绍了Android测试的基础,包括基于JUnit的测试组件、Android JUnit扩展提供的特定组件测试用例类、测试套件的组织方式以及SDK提供的构建和测试工具。内容还提及了Eclipse与ADT中的SDK工具,以及命令行工具Monkeyrunner和UI/Application Exerciser Monkey用于设备测试。创建测试项目可以通过Eclipse的Android tools或新建Test Project实现。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Testing Fundamentals

Testing framework包含以下几种资源:

1 Android 的测试组件是基于JUnit的

The Android JUnit extensions provide component-specific test case classes

Test suites are contained in test packages that are similar to main application packages

The SDK tools for building and tests are available in Eclipse with ADT, and also in command-line form for use with other IDEs.

The SDK also provides monkeyrunner, an API for testing devices with Python programs, and UI/Application Exerciser Monkey, a command-line tool for stress-testing UIs by sending pseudo-random events to a device

项目右键 Android tools->add new Test Project,也可以直接eclipse新建一个Test Project。

android ApiDemo导入的时候,tests项目需要在java build path->project 中添加ApiDemo。


评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值