HOTFIX Integration test v0.18.2 (#3980)
This commit is contained in:
@@ -3,4 +3,12 @@
|
||||
to allow setting breakpoints, to provide hot reload, etc.
|
||||
-->
|
||||
<uses-permission android:name="android.permission.INTERNET"/>
|
||||
|
||||
<application>
|
||||
<!-- Will remove after upgrade to Flutter 3.29.x or above.
|
||||
Detail here https://github.com/flutter/flutter/issues/160442 -->
|
||||
<meta-data
|
||||
android:name="io.flutter.embedding.android.EnableImpeller"
|
||||
android:value="false" />
|
||||
</application>
|
||||
</manifest>
|
||||
|
||||
@@ -404,7 +404,15 @@ class HtmlContentViewState extends State<HtmlContentViewer> with AutomaticKeepAl
|
||||
void dispose() {
|
||||
_loadingBarNotifier.dispose();
|
||||
_htmlData = null;
|
||||
_webViewController.dispose();
|
||||
if (kDebugMode) {
|
||||
try {
|
||||
_webViewController.dispose();
|
||||
} catch (e) {
|
||||
logError('_HtmlContentViewState:dispose:_webViewController.dispose: $e');
|
||||
}
|
||||
} else {
|
||||
_webViewController.dispose();
|
||||
}
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import 'package:flutter/painting.dart';
|
||||
import 'package:flutter_test/flutter_test.dart';
|
||||
import 'package:patrol/patrol.dart';
|
||||
|
||||
@@ -8,8 +9,11 @@ abstract class BaseScenario {
|
||||
|
||||
Future<void> execute();
|
||||
|
||||
Future<void> expectViewVisible(PatrolFinder patrolFinder) async {
|
||||
await $.waitUntilVisible(patrolFinder);
|
||||
Future<void> expectViewVisible(
|
||||
PatrolFinder patrolFinder, {
|
||||
Alignment alignment = Alignment.center,
|
||||
}) async {
|
||||
await $.waitUntilVisible(patrolFinder, alignment: alignment);
|
||||
expect(patrolFinder, findsWidgets);
|
||||
}
|
||||
|
||||
|
||||
@@ -13,7 +13,7 @@ class EmailRobot extends CoreRobot {
|
||||
}
|
||||
|
||||
Future<void> tapDownloadAllButton() async {
|
||||
await $(AppLocalizations().downloadAll).tap();
|
||||
await $(AppLocalizations().archiveAndDownload).tap();
|
||||
await $.pumpAndSettle();
|
||||
}
|
||||
|
||||
|
||||
@@ -81,4 +81,8 @@ class SearchRobot extends CoreRobot {
|
||||
await email.tap();
|
||||
await $.pump(const Duration(seconds: 2));
|
||||
}
|
||||
|
||||
Future<void> tapBackButton() async {
|
||||
await $(#search_email_back_button).tap();
|
||||
}
|
||||
}
|
||||
@@ -45,7 +45,7 @@ class CalendarEventCounterScenario extends BaseTestScenario {
|
||||
}
|
||||
|
||||
Future<void> _expectEmailViewVisible() async {
|
||||
await expectViewVisible($(EmailView));
|
||||
await expectViewVisible($(EmailView), alignment: Alignment.topCenter);
|
||||
}
|
||||
|
||||
Future<void> _expectYesButtonVisible(
|
||||
|
||||
+2
-1
@@ -57,6 +57,7 @@ class ReplyEmailWithContentContainImageBase64DataScenario extends BaseTestScenar
|
||||
|
||||
await emailRobot.onTapBackButton();
|
||||
await $.pumpAndSettle(duration: const Duration(seconds: 3));
|
||||
await searchRobot.tapBackButton();
|
||||
await _expectEmailCidWithSubject(emailSubject);
|
||||
|
||||
await threadRobot.openEmailWithSubject(
|
||||
@@ -77,7 +78,7 @@ class ReplyEmailWithContentContainImageBase64DataScenario extends BaseTestScenar
|
||||
}
|
||||
|
||||
Future<void> _expectEmailViewVisible() async {
|
||||
await expectViewVisible($(EmailView));
|
||||
await expectViewVisible($(EmailView), alignment: Alignment.topCenter);
|
||||
}
|
||||
|
||||
Future<void> _expectReplyEmailButtonVisible() async {
|
||||
|
||||
@@ -209,7 +209,7 @@ class SearchEmailController extends BaseController
|
||||
|
||||
void _setUpDefaultSortOrder(EmailSortOrderType sortOrderType) {
|
||||
emailSortOrderType.value = sortOrderType;
|
||||
searchEmailFilter.value = SearchEmailFilter.withSortOrder(sortOrderType);
|
||||
_updateSimpleSearchFilter(sortOrderTypeOption: Some(sortOrderType));
|
||||
}
|
||||
|
||||
void _initializeDebounceTimeTextSearchChange() {
|
||||
|
||||
@@ -181,6 +181,7 @@ class SearchEmailView extends GetWidget<SearchEmailController>
|
||||
children: [
|
||||
buildIconWeb(
|
||||
icon: SvgPicture.asset(
|
||||
key: const ValueKey('search_email_back_button'),
|
||||
DirectionUtils.isDirectionRTLByLanguage(context) ? controller.imagePaths.icCollapseFolder : controller.imagePaths.icBack,
|
||||
colorFilter: AppColor.colorTextButton.asFilter(),
|
||||
fit: BoxFit.fill
|
||||
|
||||
@@ -60,6 +60,5 @@ gcloud firebase test android run \
|
||||
--app build/app/outputs/apk/debug/app-debug.apk \
|
||||
--test build/app/outputs/apk/androidTest/debug/app-debug-androidTest.apk \
|
||||
--device 'model=MediumPhone.arm,version=33,locale=en,orientation=portrait' \
|
||||
--timeout 10m \
|
||||
--use-orchestrator \
|
||||
--environment-variables clearPackageData=true
|
||||
|
||||
Reference in New Issue
Block a user