import 'package:core/presentation/views/text/type_ahead_form_field_builder.dart'; import 'package:flutter/material.dart'; import 'package:tmail_ui_user/features/login/domain/model/recent_login_username.dart'; import 'package:tmail_ui_user/features/login/presentation/login_view.dart'; import 'package:tmail_ui_user/features/login/presentation/widgets/login_text_input_builder.dart'; import '../base/core_robot.dart'; class LoginRobot extends CoreRobot { LoginRobot(super.$); Future expectLoginViewVisible() => ensureViewVisible($(LoginView)); Future enterEmail(String email) async { final finder = $(LoginView).$(TextField); await finder.enterText(email); await $('Next').tap(); } Future enterHostUrl(String url) async { final finder = $(LoginView).$(TextField); await finder.enterText(url); await $('Next').tap(); } Future enterBasicAuthEmail(String email) async { await $(LoginView) .$(TypeAheadFormFieldBuilder) .$(TextField) .enterText(email); } Future enterBasicAuthPassword(String password) async { await $(LoginView) .$(LoginTextInputBuilder) .$(TextField) .enterText(password); } Future loginBasicAuth() async { await $(Container).$(ElevatedButton).tap(); } }