-
Notifications
You must be signed in to change notification settings - Fork 1.3k
user talk and dialog box fix #3014
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
Conversation
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.
✅ A review job has been created and sent to the PullRequest network.
@sherlockbeard you can click here to see the review status or cancel the code review job.
Codecov Report
@@ Coverage Diff @@
## master #3014 +/- ##
=========================================
- Coverage 3.74% 3.74% -0.01%
=========================================
Files 249 249
Lines 12090 12102 +12
Branches 1070 1070
=========================================
Hits 453 453
- Misses 11603 11615 +12
Partials 34 34
Continue to review full report at Codecov.
|
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.
Looks good!
And now I understand that it was not just a reformatting, the code was really indented due to the new if/else block, sorry about that!
| "Commons:Deletion_requests/" + date, summary); | ||
| mwApi.appendEdit(editToken, userPageString + "\n", | ||
| "User_Talk:" + sessionManager.getCurrentAccount().name, summary); | ||
| "User_Talk:" + media.getCreator(), summary); |
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.
Can you add/update the corresponding unit test
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.
@maskaravivek can you help me with unit test. i have never done a test. like what should be the result and where should it be placed .
|
@sherlockbeard Can you add/update unit tests in a different PR. :) |
| else{ | ||
| AlertDialog.Builder alert = new AlertDialog.Builder(getActivity()); | ||
| alert.setMessage("Why should this fileckathon-2018 be deleted?"); | ||
| alert.setMessage("Why should "+ media.getDisplayTitle() +" be deleted?"); |
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.
It would be great if you move this hard coded string into strings.xml file in another pull request @sherlockbeard
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.
@neslihanturan i added the string value in #3015
|
@maskaravivek i am sorry i about know much about unit test. |
|
@sherlockbeard You can take a look at other tests in our repo and go through other online resources to get started. |
|
@maskaravivek @neslihanturan Sorry I merged too early :-/ |
|
Separate pull requests should be okay @nicolas-raoul if they will be sent in a few days so that we don't forget about these 2 minor issues :) |
|
@maskaravivek ok i will try do it. :) |
|
@sherlockbeard Unit testing is not very difficult, please see https://github.com/commons-app/apps-android-commons/tree/fb3136ab191424ecae86410fc243f9eb63a7b68c/app/src/test/kotlin/fr/free/nrw/commons for examples :-) |
fixes the error of user talk and dialog box
Fixes #2827
Fixes #2703
previous pull request #3009