2

I'm writing tests for my app, and one part is involving a widget. I can't find anything on the subject: it is possible to automatically test widgets with Espresso?

Geob-o-matic
  • 5,940
  • 4
  • 35
  • 41

1 Answers1

2

No.

Espresso is made to run tests in the process of an activity. Widgets belong to the home screen (app).

UI automator could be a solution for testing widgets (https://developer.android.com/training/testing/ui-testing/uiautomator-testing.html)

friedger
  • 645
  • 7
  • 21