-
Notifications
You must be signed in to change notification settings - Fork 499
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
Fix #3099: Test suite for DrawableBindingAdapters #4077
Fix #3099: Test suite for DrawableBindingAdapters #4077
Conversation
… test-suit-for-drawablebindingadapters
Thanks for submitting this pull request! Some main reviewers |
@rt4914 @BenHenning last three |
@rishidyno that should be fine. |
@rt4914 @BenHenning all test passed PTAL. |
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.
Thanks @rishidyno. Took a first pass review and left some comments.
For your main PR comment:
- Please add an explanation that includes a justification for the test file exemption change (you checked that item the checklist but didn't actually fill in the explanation)
- Please add a video showing the new test suite running on an emulator or real device via Espresso, and a screenshot showing that the test passes
app/src/sharedTest/java/org/oppia/android/app/databinding/DrawableBindingAdaptersTest.kt
Outdated
Show resolved
Hide resolved
app/src/sharedTest/java/org/oppia/android/app/databinding/DrawableBindingAdaptersTest.kt
Outdated
Show resolved
Hide resolved
app/src/sharedTest/java/org/oppia/android/app/databinding/DrawableBindingAdaptersTest.kt
Outdated
Show resolved
Hide resolved
app/src/sharedTest/java/org/oppia/android/app/databinding/DrawableBindingAdaptersTest.kt
Show resolved
Hide resolved
app/src/main/java/org/oppia/android/app/testing/DrawableBindingAdaptersTestActivity.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/org/oppia/android/app/databinding/DrawableBindingAdapters.java
Show resolved
Hide resolved
app/src/main/java/org/oppia/android/app/activity/ActivityComponentImpl.kt
Outdated
Show resolved
Hide resolved
app/src/sharedTest/java/org/oppia/android/app/databinding/DrawableBindingAdaptersTest.kt
Outdated
Show resolved
Hide resolved
app/src/sharedTest/java/org/oppia/android/app/databinding/DrawableBindingAdaptersTest.kt
Outdated
Show resolved
Hide resolved
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.
@rishidyno PTAL thanks.
android:layout_width="match_parent" | ||
android:layout_height="320dp" /> | ||
</LinearLayout> | ||
|
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.
Remove this blank line
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.
Done
Intents.release() | ||
} | ||
|
||
// from a color int |
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 comment does not make sense. Can you please make it more clear ?
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 means that we are declaring an integer color. Makes sense @rt4914 ? I think we don't need this, so removed it.
app/src/sharedTest/java/org/oppia/android/app/databinding/DrawableBindingAdaptersTest.kt
Show resolved
Hide resolved
… test-suit-for-drawablebindingadapters
I added
oppia-android.DrawableBindingAdaptersTest.kt.oppia-android.app.2022-01-18.14-48-08.mp4 |
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.
@BenHenning PTAL.
app/src/main/java/org/oppia/android/app/databinding/DrawableBindingAdapters.java
Show resolved
Hide resolved
app/src/sharedTest/java/org/oppia/android/app/databinding/ImageViewBindingAdaptersTest.kt
Show resolved
Hide resolved
import org.oppia.android.app.activity.ActivityComponentImpl | ||
import org.oppia.android.app.activity.InjectableAppCompatActivity | ||
|
||
/** Test activity for DrawableBindingAdapters. */ |
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.
@anandwana001 Actually, I checked for other data binding test activities but none of them are doing this, so I just left as it is. It can be confirmed if you look into these files. I have linked these 2, but there are more.
https://github.com/oppia/oppia-android/blob/3a0afb4eb8222d4ff3acd2e2e660b85911d35229/app/src/main/java/org/oppia/android/app/testing/StateAssemblerMarginBindingAdaptersTestActivity.kt#L16-L15
@BenHenning Please confirm what to do.
… test-suit-for-drawablebindingadapters
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.
Thanks @rishidyno. This LGTM for codeowners.
import org.oppia.android.app.activity.ActivityComponentImpl | ||
import org.oppia.android.app.activity.InjectableAppCompatActivity | ||
|
||
/** Test activity for DrawableBindingAdapters. */ |
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 reference won't work since the class isn't being imported. I suggest either using backticks, i.e.:
``DrawableBindingAdapters``
Or, fully qualify the type: [org.oppia.android.app.databinding.DrawableBindingAdapters]
(Note that you can check if a Markdown reference is correct by control clicking on the class name; if it doesn't open or has a squiggly underneath it, the reference isn't correct).
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.
LGTM, thanks.
@BenHenning PTAL |
Unassigning @rishidyno since a re-review was requested. @rishidyno, please make sure you have addressed all review comments. Thanks! |
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.
Thanks @rishidyno. LGTM.
Unassigning @BenHenning since they have already approved the PR. |
Everything appears resolved, so merging this. |
Fix #3099
Explanation
Essential Checklist
For UI-specific PRs only
If your PR includes UI-related changes, then: