Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
7e2c15d6
Unverified
Commit
7e2c15d6
authored
Nov 08, 2021
by
Gary Qian
Committed by
GitHub
Nov 08, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Dynamic logcat piping for deferred components test (#93080)
parent
9c1a87e6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
8 deletions
+17
-8
run_release_test.sh
...ration_tests/deferred_components_test/run_release_test.sh
+17
-8
No files found.
dev/integration_tests/deferred_components_test/run_release_test.sh
View file @
7e2c15d6
...
...
@@ -19,6 +19,7 @@ adb_path=$2
# Store the time to prevent capturing logs from previous runs.
script_start_time
=
$(
$adb_path
shell
'date +"%m-%d %H:%M:%S.0"'
)
script_start_time_seconds
=
$(
date
+%s
)
$adb_path
uninstall
"io.flutter.integration.deferred_components_test"
...
...
@@ -32,15 +33,23 @@ java -jar $bundletool_jar_path install-apks --apks=build/app/outputs/bundle/rele
$adb_path
shell
"
am start -n io.flutter.integration.deferred_components_test/.MainActivity
sleep 30
exit
"
$adb_path
logcat
-d
-t
"
$script_start_time
"
>
build/app/outputs/bundle/release/run_logcat.log
echo
""
if
cat
build/app/outputs/bundle/release/run_logcat.log |
grep
-q
"Running deferred code"
;
then
echo
"All tests passed."
exit
0
fi
cat
build/app/outputs/bundle/release/run_logcat.log
while
read
LOGLINE
do
if
[[
"
${
LOGLINE
}
"
==
*
"Running deferred code"
*
]]
;
then
echo
"Found
${
LOGLINE
}
"
pkill
-P
$$
echo
"All tests passed."
exit
0
fi
# Timeout if expected log not found
current_time
=
$(
date
+%s
)
if
[[
$((
current_time
-
script_start_time_seconds
))
-ge
150
]]
;
then
echo
"Failure: Deferred component did not load."
exit
1
fi
done
< <
(
adb logcat
-T
"
$script_start_time
"
)
echo
"Failure: Deferred component did not load."
exit
1
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment