Google开源Android平台自动化测试框架“Espresso”

谷歌在2013年推出Espresso,一个为Android平台设计的自动化测试框架,简化了UI测试过程,易于学习并提供强大的功能。Espresso已在多个谷歌应用中使用,并提供了详细的指南和示例。

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

2013 GTAC谷歌介绍了Android平台自动化测试框架“Espresso”([url=http://www.youtube.com/watch?v=T7ugmCuNxDU]Video[/url], [url=http://goo.gl/ieunS]Slides[/url]),10月18号谷歌正式开放“Espresso”。在[url=http://googletesting.blogspot.jp/2013/10/espresso-for-android-is-here.html]谷歌测试团队博客[/url]中如下介绍“Espresso”:
[quote]The compelling thing about developing Espresso was making it easy and fun for developers to write reliable UI tests. Espresso has a small, predictable, and easy to learn API, which is still open for customization. But most importantly - Espresso removes the need to think about the complexity of multi-threaded testing. With Espresso, you can think procedurally and write concise, beautiful, and reliable Android UI tests quickly.[/quote]
Google目前已经在超过30多个应用(Drive、Maps、G+)中使用Espresso。

public void testSayHello() {
onView(withId(R.id.name_field))
.perform(typeText("Steve"));
onView(withId(R.id.greet_button))
.perform(click());
onView(withText("Hello Steve!"))
.check(matches(isDisplayed()));
}


Espresso
[url=https://code.google.com/p/android-test-kit/wiki/Espresso]https://code.google.com/p/android-test-kit/wiki/Espresso[/url]
Espresso Start Guide
[url=https://code.google.com/p/android-test-kit/wiki/EspressoStartGuide]https://code.google.com/p/android-test-kit/wiki/EspressoStartGuide[/url]
Espresso Samples
[url=https://code.google.com/p/android-test-kit/wiki/EspressoSamples]https://code.google.com/p/android-test-kit/wiki/EspressoSamples[/url]
Espresso for Android - a Demo
[url=http://www.youtube.com/watch?v=qtKx1WxK7cw]http://www.youtube.com/watch?v=qtKx1WxK7cw[/url]
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值