Stay organized with collections Save and categorize content based on your preferences.

DrawerActions

public final class DrawerActions


Espresso actions for using a DrawerLayout.

See also
<a href="http://developer.android.com/design/patterns/navigation-drawer.html">Navigation

drawer design guide

Summary

Public constructors

Public methods

static ViewAction

Creates an action which closes the DrawerLayout with gravity START.

static ViewAction
close(int gravity)

Creates an action which closes the DrawerLayout with the gravity.

static void
closeDrawer(int drawerLayoutId, int gravity)

This method is deprecated.

Use open with perform after matching a view.

static void
closeDrawer(int drawerLayoutId)

This method is deprecated.

Use close with perform after matching a view.

static ViewAction

Creates an action which opens the DrawerLayout drawer with gravity START.

static ViewAction
open(int gravity)

Creates an action which opens the DrawerLayout drawer with the gravity.

static void
openDrawer(int drawerLayoutId, int gravity)

This method is deprecated.

Use open with perform after matching a view.

static void
openDrawer(int drawerLayoutId)

This method is deprecated.

Use open with perform after matching a view.

Public constructors

DrawerActions

public DrawerActions()

Public methods

close

public static ViewAction close()

Creates an action which closes the DrawerLayout with gravity START. This method blocks until the drawer is fully closed. No operation if the drawer is already closed.

close

public static ViewAction close(int gravity)

Creates an action which closes the DrawerLayout with the gravity. This method blocks until the drawer is fully closed. No operation if the drawer is already closed.

closeDrawer

public static void closeDrawer(int drawerLayoutId, int gravity)

closeDrawer

public static void closeDrawer(int drawerLayoutId)

open

public static ViewAction open()

Creates an action which opens the DrawerLayout drawer with gravity START. This method blocks until the drawer is fully open. No operation if the drawer is already open.

open

public static ViewAction open(int gravity)

Creates an action which opens the DrawerLayout drawer with the gravity. This method blocks until the drawer is fully open. No operation if the drawer is already open.

openDrawer

public static void openDrawer(int drawerLayoutId, int gravity)

openDrawer

public static void openDrawer(int drawerLayoutId)