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

IndexFile.GetByNameAndVersion -> IndexFile.FindFirst with Tests #1277

Merged
merged 1 commit into from
Jan 15, 2020

Conversation

kensipe
Copy link
Member

@kensipe kensipe commented Jan 15, 2020

Refactored name to findfirst which is what it is doing and added test to confirm that it is finding first

Signed-off-by: Ken Sipe kensipe@gmail.com

… to confirm that it is finding first

Signed-off-by: Ken Sipe <kensipe@gmail.com>
@kensipe kensipe changed the title IndexFile. GetByNameAndVersion -> IndexFile.FindFirst with Tests IndexFile.GetByNameAndVersion -> IndexFile.FindFirst with Tests Jan 15, 2020
Copy link
Contributor

@zen-dog zen-dog left a comment

Choose a reason for hiding this comment

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

  ___________________
< SemVer for the win! >
  -------------------
         \   ^__^ 
          \  (oo)\_______
             (__)\       )\/\
                 ||----w |
                 ||     ||

Copy link
Member

@nfnt nfnt left a comment

Choose a reason for hiding this comment

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

❤️ the rename, though the test case is already covered by TestParseIndexFile in index_test.go. Happy to keep the new tests though

@kensipe
Copy link
Member Author

kensipe commented Jan 15, 2020

@nfnt the reason I liked the new test file is that it is a test of FindFirst specifically and the function under test is in resolver_repo.go. It seemed easier to discover the test if under resolver_repo_test.go.

@kensipe kensipe merged commit 60afdc3 into master Jan 15, 2020
@kensipe kensipe deleted the ken/pkg-resolve branch January 15, 2020 14:24
ANeumann82 pushed a commit that referenced this pull request Feb 13, 2020
…sion is resolved. (#1277)

Signed-off-by: Ken Sipe <kensipe@gmail.com>
Signed-off-by: Andreas Neumann <aneumann@mesosphere.com>
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.

None yet

3 participants