dismissNotification

suspend fun dismissNotification(title: String? = null, text: String? = null, mode: MatchMode = MatchMode.EXACT, packageName: String? = null, timeout: Duration? = null)(source)

Dismisses the one active notification that matches (as for awaitNotification) as a swipe does. No match or several matches throw CommandException (NOT_FOUND / AMBIGUOUS), and an ongoing notification ACTION_REJECTED (NOT_CLEARABLE), before anything changes.