Skip to content
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

Adding coverage task configuration #174

Closed
wants to merge 2 commits into from

Conversation

mattinger
Copy link

No description provided.

@mattinger
Copy link
Author

The intent here is to add the task to do coverage verification, but not necessarily tie it to the check lifecycle. That may be a decision best left up to the build file author on whether or not they want it tied to the lifecycle, or to call it explicitly.

@codecov
Copy link

codecov bot commented May 8, 2020

Codecov Report

Merging #174 into master will decrease coverage by 10.18%.
The diff coverage is 45.90%.

Impacted file tree graph

@@              Coverage Diff              @@
##             master     #174       +/-   ##
=============================================
- Coverage     84.06%   73.87%   -10.19%     
- Complexity       43       46        +3     
=============================================
  Files             1        4        +3     
  Lines           182      245       +63     
  Branches         24       28        +4     
=============================================
+ Hits            153      181       +28     
- Misses           21       54       +33     
- Partials          8       10        +2     
Impacted Files Coverage Δ Complexity Δ
...h/android/junit/jacoco/JunitJacocoExtension.groovy 50.00% <ø> (ø) 1.00 <0.00> (?)
...vy/com/vanniktech/android/junit/jacoco/Rule.groovy 0.00% <0.00%> (ø) 0.00 <0.00> (?)
...nniktech/android/junit/jacoco/RuleContainer.groovy 20.00% <20.00%> (ø) 1.00 <1.00> (?)
...ktech/android/junit/jacoco/GenerationPlugin.groovy 77.72% <55.10%> (-6.34%) 44.00 <1.00> (+1.00) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update feb9fa4...62acc88. Read the comment docs.

@alexeisele
Copy link

Any timeline for the release of this change by chance?
Would love to incorporate it into an application I'm working on

Copy link
Owner

@vanniktech vanniktech left a comment

Choose a reason for hiding this comment

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

Sorry, lost track of this. Have you been able to test it out? @alexeisele

assert sourceDirectories.contains(project.file("src/debug/$it"))
}

// TODO: Validate Rules
Copy link
Owner

Choose a reason for hiding this comment

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

Is this something you want to do?

- Task `jacocoTestCoverageVerification<Flavor><BuildType>`
- Depends on the `jacocoTestReport<Flavor><BuildType>` task
- Verifies that your code coverage limits have not been violated
- Must be manually specified in your gradle targets to execute
Copy link
Owner

Choose a reason for hiding this comment

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

How about?

Suggested change
- Must be manually specified in your gradle targets to execute
- Must be manually invoked

- Task `jacocoTestCoverageVerification`
- Depends on the `jacocoTestReport` task
- Verifies that your code coverage limits have not been violated
- Must be manually specified in your gradle targets to execute
Copy link
Owner

Choose a reason for hiding this comment

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

Suggested change
- Must be manually specified in your gradle targets to execute
- Must be manually invoked

failOnViolation = true
rule {
enabled = true
element = "BUNDLE"
Copy link
Owner

Choose a reason for hiding this comment

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

What's this one for?

@alexeisele
Copy link

@vanniktech thanks for following up!

Have not been able to test as my project is behind a corporate proxy, however if I have time this weekend I will try on a separate test protect.

@athkalia
Copy link

@mattinger has there been any update on this?

@geft
Copy link

geft commented Mar 5, 2021

@alexeisele @mattinger Any update?

@vanniktech
Copy link
Owner

@mattinger want to resolve the conflicts?

@vanniktech
Copy link
Owner

I'm closing this issue due to inactivity. If you have any further input on the issue, don't hesitate to reopen this issue or post a new one.

@vanniktech vanniktech closed this Sep 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants