-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Fixed #6445? #6685
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixed #6445? #6685
Conversation
Hi @dimwight! We'll hopefully get to looking at this in the next week or so. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DELETED
@dbemke could you take a quick look and verify this fixes the issue? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This could be tested by adding a case to AudioVideoImageTextLabelTest
that checks that the image view is GONE
if setImage
is passed a file that doesn't exist.
Thanks for the suggestion, hope this is what is wanted. |
I verified the issue - works as expected. |
File imageFile = new File("file://image.png"); | ||
|
||
AudioVideoImageTextLabel audioVideoImageTextLabel = new AudioVideoImageTextLabel(activity); | ||
audioVideoImageTextLabel.getImageView().setVisibility(VISIBLE); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't want to manipulate "internal" state for the object under test here, but I do see that you're trying to make sure that the image view is still GONE
in the case where it was previously visible (like in the case where it's used in a RecyclerView
for select choices). I'd tend to split this into two tests - one for an initial call of setImage
and another to test the "recycling" flow. The latter could call setImage
with an image that does exist first to check that the following call with an image that doesn't exist gets us the state we want.
I'm closing this for the moment as we haven't heard back for a while. |
Fixes #6445
Why is this the best possible solution? Were any other approaches considered?
Obvious code improvement seems to fix issue.
How does this change affect users? Describe intentional changes to behavior and behavior that could have accidentally been affected by code changes. In other words, what are the regression risks?
None?
Do we need any specific form for testing your changes? If so, please attach one.
Issue form selects new.xlsx.txt and single image a.png.txt demonstrate issue and fix.
Does this change require updates to documentation? If so, please file an issue here and include the link below.
No.
Before submitting this PR, please make sure you have:
If this needs a test I'd welcome advice on a class to start from or add to.
./gradlew connectedAndroidTest
(or./gradlew testLab
) and confirmed all checks still passDateFormatsTest