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

Fix Candidates method file match #234

Merged
merged 1 commit into from
Aug 20, 2024
Merged

Fix Candidates method file match #234

merged 1 commit into from
Aug 20, 2024

Conversation

shuheiktgw
Copy link
Contributor

@shuheiktgw shuheiktgw commented Aug 20, 2024

strings.HasSuffix(file.GetName(), loc.FileName) could match the wrong file if there are multiple files with the same name. Instead, set the fileName field to the full file path and use that.

Copy link

Code Metrics Report

main (bec3655) #234 (f42aa18) +/-
Coverage 65.5% 65.5% -0.0%
Code to Test Ratio 1:0.3 1:0.3 0.0
Test Execution Time 7m2s 7m9s +7s
Details
  |                     | main (bec3655) | #234 (f42aa18) |  +/-  |
  |---------------------|----------------|----------------|-------|
- | Coverage            |          65.5% |          65.5% | -0.0% |
  |   Files             |             71 |             71 |     0 |
  |   Lines             |          11825 |          11825 |     0 |
- |   Covered           |           7747 |           7746 |    -1 |
  | Code to Test Ratio  |          1:0.3 |          1:0.3 |   0.0 |
  |   Code              |          37064 |          37064 |     0 |
  |   Test              |          12892 |          12892 |     0 |
- | Test Execution Time |           7m2s |           7m9s |   +7s |

Code coverage of files in pull request scope (66.5% → 66.4%)

Files Coverage +/-
resolver/candidates.go 78.2% -0.6%
source/file.go 64.2% 0.0%

Reported by octocov

Copy link
Member

@goccy goccy left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@shuheiktgw
Copy link
Contributor Author

🙏

@shuheiktgw shuheiktgw merged commit c201922 into main Aug 20, 2024
4 checks passed
@shuheiktgw shuheiktgw deleted the fix_candidates_match branch August 20, 2024 09:55
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.

2 participants