expectCanGoBack method
Implementation
void expectCanGoBack(bool expected) {
final history = ScreenTracker().screenHistory;
final canPop = history.isNotEmpty;
if (canPop != expected) {
throw EnsembleTestFailure(
'Expected canGoBack=$expected, but history length is '
'${history.length}.',
);
}
}