[tests] Read FastTiming dump from file - #12492
Open
simonrozsival wants to merge 2 commits into
Open
Conversation
Avoid relying on logcat to transport thousands of timing events before the dump completion marker. Configure the existing file output, read it through run-as, and restore both debug properties after the test. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 8de803be-c212-4d54-8309-da5e339f193c
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the FastTimingTests.ConcurrentEventsCanGrowAndDump device test to validate FastTiming dump completion via a file in the app’s cache directory (read with run-as), avoiding flaky logcat truncation when thousands of timing events are emitted.
Changes:
- Configure FastTiming to write dump output to a cache-backed file via
debug.mono.timing(to-file,filename=...). - Trigger the dump via broadcast, then read the resulting file with
adb exec-out run-as ... cat ...and assert the completion marker is present. - Preserve and restore both
debug.mono.loganddebug.mono.timingsystem properties after the test.
Show a summary per file
| File | Description |
|---|---|
| tests/MSBuildDeviceIntegration/Tests/FastTimingTests.cs | Switches dump verification from logcat monitoring to reading a file from app cache via run-as, and restores timing-related system properties after the test. |
Review details
- Files reviewed: 1/1 changed files
- Comments generated: 1
- Review effort level: Lite
| ); | ||
|
|
||
| Assert.IsTrue (dumpCompleted, $"Output did not contain {dumpCompletedMessage}."); | ||
| string timingOutput = RunAdbCommand ($"exec-out run-as {proj.PackageName} cat cache/{timingFileName}"); |
Remove the generated timing dump in the test cleanup path so it does not remain in the application cache after either a passing or failing run. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 8de803be-c212-4d54-8309-da5e339f193c
Member
Author
|
Final local validation on API 36 arm64:
Cleanup is included in commit |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ConcurrentEventsCanGrowAndDumprun-asinstead of waiting for thousands of events through logcatdebug.mono.loganddebug.mono.timingafter the testThe test still verifies concurrent storage growth through the
4096to8192log message and verifies complete traversal through the final[2/8] Assembly decompressionaggregate in the file.Validation
make prepare && make allMSBuildDeviceIntegration.csprojin DebugFixes #12491