Testing Fundamentals
Testing framework包含以下几种资源:
1 Android 的测试组件是基于JUnit的
2 The Android JUnit extensions provide component-specific test case classes
3 Test suites are contained in test packages that are similar to main application packages
4 The SDK tools for building and tests are available in Eclipse with ADT, and also in command-line form for use with other IDEs.
5 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。
本文介绍了Android测试的基础,包括基于JUnit的测试组件、Android JUnit扩展提供的特定组件测试用例类、测试套件的组织方式以及SDK提供的构建和测试工具。内容还提及了Eclipse与ADT中的SDK工具,以及命令行工具Monkeyrunner和UI/Application Exerciser Monkey用于设备测试。创建测试项目可以通过Eclipse的Android tools或新建Test Project实现。
314

被折叠的 条评论
为什么被折叠?



