Skip to content

Conversation

@dpastor
Copy link
Contributor

@dpastor dpastor commented Feb 25, 2025

🎟️ Jira ticket

ANDROID-15781

🥅 What's the goal?

With this PR i'm solving two issues:

  1. In cases where loggerazzi plugin was applied before the android application/library plugin, plugin tasks were not executed.
  2. In case a test is executed without a previous emulator files cleanup, test app won't be available to overwrite any previously generated files. (This is done by loggerazzi plugin before all tests execution, but can happen also in cases like test retries)

🚧 How do we do it?

  • Now, Loggerazzi will fail in configuration time if no instrumentation tasks are found for the project where it is added.
  • Loggerazzi writes in the "Download" public directory, as public directories are the only places where the generated files live after the test execution. Apps can create files in public directories but cannot delete/overwrite them, these was being controlled by the loggerazzi plugin before test execution, removing any previous files in the emulator, but there are some cases (like test retries) where the plugin cannot interfere to delete previous generated files. So, i'm changing the behavior to always generate a new file with a timestamp appended to the end of the file name, so, when the loggerazzi plugin pulls all files, it filters by the most recent generated files for each test case, generating proper filenames for reports and baseline updates.

📘 Documentation changes?

  • No docs to update nor create

🧪 How can I test this?

  • Tested with Latch project

…n and fix issues with file overwriting in emulators.
Comment on lines -90 to -95
<div id="imageBottomSheet" class="modal bottom-sheet max-height">
<div class="modal-content center-align">
<img id="modalImage" src="" alt="">
</div>
</div>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unrelated, just not needed

@dpastor dpastor requested review from jeprubio and jeslat February 25, 2025 11:17
Copy link
Contributor

@jeslat jeslat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job!

@dpastor dpastor merged commit 9f32d0c into main Feb 25, 2025
1 check passed
@dpastor dpastor deleted the fail_overwrite branch February 25, 2025 14:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants