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

Don't recurse into submodules #731

Merged
merged 1 commit into from
Nov 14, 2023
Merged

Conversation

devnev
Copy link
Contributor

@devnev devnev commented Nov 12, 2023

Description

Submodules can cause load errors and are skipped by a regular go list ./...

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Version of Golang used when building/testing:

  • 1.11
  • 1.12
  • 1.13
  • 1.14
  • 1.15
  • 1.16
  • 1.17
  • 1.18
  • 1.19
  • 1.20
  • 1.21

How Has This Been Tested?

go test github.com/vektra/mockery/v2/pkg/config

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

@LandonTClipp
Copy link
Collaborator

Thank you for the PR, this looks great. I'll review in the coming days.

Copy link

codecov bot commented Nov 14, 2023

Codecov Report

Attention: 16 lines in your changes are missing coverage. Please review.

Comparison is base (deb4860) 75.25042% compared to head (fc10b9c) 75.12500%.

Files Patch % Lines
pkg/config/config.go 48.38710% 13 Missing and 3 partials ⚠️
Additional details and impacted files
@@                 Coverage Diff                 @@
##              master        #731         +/-   ##
===================================================
- Coverage   75.25042%   75.12500%   -0.12543%     
===================================================
  Files              9           9                 
  Lines           2396        2400          +4     
===================================================
  Hits            1803        1803                 
- Misses           455         458          +3     
- Partials         138         139          +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@LandonTClipp
Copy link
Collaborator

The coverage tests are failing but I don't think that's relevant to this PR since you've clearly tested the changes. I don't have any concerns, we can go ahead and merge this. Thanks again for the contribution.

In the future, thinking about your original issue, we might want to also exclude paths with .mockery.yaml, but hopefully this will get you enough lift.

@LandonTClipp LandonTClipp merged commit 0e27e93 into vektra:master Nov 14, 2023
3 of 5 checks passed
@LandonTClipp
Copy link
Collaborator

@devnev I had to revert this unfortunately as a regression was found (see linked reversion PR for details).

I'm quite astonished this slipped through as the tests we have are quite robust. Let me know if you're able to look into the reproducer. I'll look as well when I get some free time. Really need to find why the tests didn't catch this.

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.

error when loading package, can only [...] in module-aware mode
2 participants