Skip to content
This repository has been archived by the owner on Jun 20, 2023. It is now read-only.

Fix images not shown in screenshots (DEV) #3318

Merged
merged 44 commits into from Jun 2, 2021

Conversation

LukasLechnerDev
Copy link
Contributor

@LukasLechnerDev LukasLechnerDev commented May 28, 2021

Some images in ImageViews don't show up in our screenshot tests.
We could fix this by replacing these ImageViews with AppCompatImageViews.
However, there could be other issues as well, so I decided against this solution and instead now launch the fragments in our screenshot tests in an AppCompatActivity.

The issue described was related to not using AppCompatActivity, because we used FragmentScenario which uses the non-AppCompatActivity called EmptyFragmentActivity. Unfortunately, its not possible to use custom Activities with FragmentScenario => https://issuetracker.google.com/issues/121347222

That's why we now use ActivityScenario and provide our own Empty AppCompatActivity.
Now all images show up.

TODO before merging

  • Revert 789d4dc (Run firebase_screenshots in CI pipeline)

@LukasLechnerDev LukasLechnerDev added bug Something isn't working maintainers Tag pull requests created by maintainers labels May 28, 2021
@LukasLechnerDev LukasLechnerDev added this to the 2.3.0 milestone May 28, 2021
@LukasLechnerDev LukasLechnerDev requested review from a team May 28, 2021 11:31
@LukasLechnerDev LukasLechnerDev changed the base branch from main to release/2.3.x May 28, 2021 11:31
Copy link
Contributor

@ChristinaTsigganos ChristinaTsigganos left a comment

Choose a reason for hiding this comment

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

UA approved, no text changes to review

@mtwalli mtwalli self-assigned this May 31, 2021
@mtwalli
Copy link
Contributor

mtwalli commented May 31, 2021

@LukasLechnerDev Please run the firebase_screenshots job in CI to make sure these changes did not break anything?

@LukasLechnerDev
Copy link
Contributor Author

@mtwalli Screenshots are now here: https://126387-268027139-gh.circle-artifacts.com/0/zips/CWA-Android-Screenshots-789d4dcd64e53da7742cd44f73adf6caf1a92420.zip. Images are now all visible as far as I can tell, but the weird "grey pressed state" issue is still there.

@mtwalli
Copy link
Contributor

mtwalli commented May 31, 2021

@mtwalli Screenshots are now here: https://126387-268027139-gh.circle-artifacts.com/0/zips/CWA-Android-Screenshots-789d4dcd64e53da7742cd44f73adf6caf1a92420.zip. Images are now all visible as far as I can tell, but the weird "grey pressed state" issue is still there.

Thanks!, Did you figure out why the pressed state are appearing in screens ?

@LukasLechnerDev
Copy link
Contributor Author

@mtwalli Screenshots are now here: https://126387-268027139-gh.circle-artifacts.com/0/zips/CWA-Android-Screenshots-789d4dcd64e53da7742cd44f73adf6caf1a92420.zip. Images are now all visible as far as I can tell, but the weird "grey pressed state" issue is still there.

Thanks!, Did you figure out why the pressed state are appearing in screens ?

No, unfortunately not. It doesn't happen locally on my devices, so its very hard to fix for me. I guess a potential solution would be to tweak the device on which the screenshots are taken in the CI pipeline (maybe try other Android Versions or a different device altogether, etc. )

@mtwalli mtwalli changed the base branch from release/2.3.x to release/2.4.x June 2, 2021 08:50
@mtwalli mtwalli dismissed their stale review June 2, 2021 08:50

The base branch was changed.

@mtwalli mtwalli modified the milestones: 2.3.0, 2.4.0 Jun 2, 2021
@mtwalli mtwalli removed their assignment Jun 2, 2021
Copy link
Member

@d4rken d4rken left a comment

Choose a reason for hiding this comment

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

lgtm

@d4rken d4rken self-assigned this Jun 2, 2021
@sonarcloud
Copy link

sonarcloud bot commented Jun 2, 2021

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@BMItr BMItr self-assigned this Jun 2, 2021
@mtwalli mtwalli merged commit 1e11b6c into release/2.4.x Jun 2, 2021
@mtwalli mtwalli deleted the dev/fix-images-not-shown-in-screenshots branch June 2, 2021 09:52
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working maintainers Tag pull requests created by maintainers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants