-
Notifications
You must be signed in to change notification settings - Fork 512
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 issue #1497: Set up code coverage for Robolectric tests #2466
Conversation
@peculiaruc thanks for uploading this. A couple of things to note:
Going to try to run the code coverage now and see how it goes. |
Noted. Thank |
Just an update, this result is not from this pr, I tried something else a bit. Will try this pr also. |
I see, that thing you tried is what i am missing, i think |
Thanks for following up on this @anandwana001. Haven't had a chance to run this myself. |
To capture some of my findings when looking into this today:
This leads us to getting a bit stuck. I think the correct way to do this is to build code coverage support into Bazel while we wait for the new rules (especially since the new rules won't support coverage out of the box), but I just don't have the bandwidth to do that right now. Given that, I think we can still use JaCoCo in the interim:
That second bit is the most important thing that we can still create. While we may change the means by which we generate the reports, being able to generate them is still a fundamental first step. Does this sound good to you @peculiaruc? |
Yes please. Thanks. I going to implement the changes, then finish up the documentation |
I see, that thing you tried is what i am missing, i think |
Please i mistakenly closed the Pr before. sorry about that |
Ack thanks @peculiaruc. Assigning this back over to you since it seems like per your last response the next steps here are on your plate. Please let me know if you need my input on anything or run into any problems. Also, I think it would be really helpful if you compiled your findings & analyses in a document & shared that in this PR since it will help bring context to future team members. |
Noted . I am on it |
1.The document below contains my findings about running code coverages to determine the percentage of the app code covered by each unit test. https://docs.google.com/document/d/1oSIY-12lGl28MVgGxs0mbuJFTORkjGqypeiOGq95jLc/edit It also await review from reviewers. |
Thanks @peculiaruc! @anandwana001 can you take a first pass on the document? |
Thanks for clarifying @anandwana001. Your plan SGTM to confirm that code coverage is working. Deferring to you to drive this PR to completion (please loop me in if needed). @peculiaruc feel free to continue to reach out to me if you have questions, otherwise Akshay will probably be your main point of contact as part of finishing this PR. |
@peculiaruc are the next steps clear to you from Akshay's comment above? |
@ben Henning <henning.benmax@gmail.com> Yes, I have started working on it
…On Fri, 29 Jan 2021 at 02:49, Ben Henning ***@***.***> wrote:
@peculiaruc <https://github.com/peculiaruc> are the next steps clear to
you from Akshay's comment above?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2466 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AIOVAVYOJRUFKMB5FORMELLS4IHY3ANCNFSM4V7NMR7Q>
.
|
Hi! @anandwana001 <https://github.com/anandwana001>.
Below is github gist for task no 1-6. The document has also been updated.
Please take a look
https://gist.github.com/peculiaruc/2e63953249c1af8d731246f737fec588
Thanks
Peculiar
On Fri, 29 Jan 2021 at 03:06, Peculiar C. Umeh <peculiarumeh02@gmail.com>
wrote:
… @ben Henning ***@***.***> Yes, I have started working on it
On Fri, 29 Jan 2021 at 02:49, Ben Henning ***@***.***>
wrote:
> @peculiaruc <https://github.com/peculiaruc> are the next steps clear to
> you from Akshay's comment above?
>
> —
> You are receiving this because you were mentioned.
> Reply to this email directly, view it on GitHub
> <#2466 (comment)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AIOVAVYOJRUFKMB5FORMELLS4IHY3ANCNFSM4V7NMR7Q>
> .
>
|
Done |
Done. PTAL |
@peculiaruc have you checked my comment here - https://gist.github.com/peculiaruc/2e63953249c1af8d731246f737fec588#gistcomment-3616265 Also, include the AudioTest file mentioned in the gist if you are fixing that file for code coverage. |
Alright. This PR stopped running since I observed it was made a draft so i
thought that's why it doesn't sync. Please can i get any help with it
…On Wed, 3 Feb 2021 at 04:32, Akshay Nandwana ***@***.***> wrote:
@peculiaruc <https://github.com/peculiaruc> have you checked my comment
here -
https://gist.github.com/peculiaruc/2e63953249c1af8d731246f737fec588#gistcomment-3616265
Also, include the AudioTest file mentioned in the gist if you are fixing
that file for code coverage.
Also, please remove the .idea/gradle.xml from this PR as we don't change
that file.
Please check why the GitHub actions are not running, I guess something is
blocking to run the GitHub actions.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2466 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AIOVAV6RSCGXRNC5YJFSZATS5C7TFANCNFSM4V7NMR7Q>
.
|
Making a draft PR doesn't stop the GitHub actions to run.
|
There are some conflicts in this PR, please resolve them and see if GitHub actions run. |
Alright
…On Mon, 8 Feb 2021, 5:29 AM Akshay Nandwana, ***@***.***> wrote:
There are some conflicts in this PR, please resolve them and see if GitHub
actions run.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2466 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AIOVAV4CRQLD7RBHEKQNKELS55SDRANCNFSM4V7NMR7Q>
.
|
.idea/gradle.xml
Outdated
@@ -1,26 +0,0 @@ | |||
<?xml version="1.0" encoding="UTF-8"?> | |||
<project version="4"> |
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.
dont' delete this file, just remove it from this PR only.
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.
Noted
Conflicts are resolved |
Looks like pr has a lot of unwanted changes, it's showing 4k files. |
Yes this happened when i merge develop into my branch. Now my branch is up to date but static checks didn't still pass |
@peculiaruc it looks like you copied in an entirely other project into your branch. None of these files seem relevant to Oppia Android. Did you accidentally merge another project with your Oppia Android repository then push that? |
This happened accidentally. I didn't know. So sorry about it. I will need
to clone a new one
…On Thu, 11 Feb 2021, 1:42 AM Ben Henning, ***@***.***> wrote:
@peculiaruc <https://github.com/peculiaruc> it looks like you copied in
an entirely other project into your branch. None of these files seem
relevant to Oppia Android. Did you accidentally merge another project with
your Oppia Android repository then push that?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2466 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AIOVAVZSL5BIOHLNTNJOILDS6MRXZANCNFSM4V7NMR7Q>
.
|
Explanation
Code Coverage SetUp: Configure the build,gradle file to use Jacoco to generate Code coverage report.
Choose coverage runner as Jacoco in Edit Configuration in Android Studio
Checklist