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

add desiutil.depend.mergedep + tests #164

Merged
merged 3 commits into from Feb 13, 2021
Merged

add desiutil.depend.mergedep + tests #164

merged 3 commits into from Feb 13, 2021

Conversation

sbailey
Copy link
Contributor

@sbailey sbailey commented Feb 12, 2021

This PR adds desiutil.depend.mergedep as a utility function to merge DEPNAMnn + DEPVERnn dependencies+versions from one header into another. We messed this up with the blanc run by simply copying header keywords from one to the other, resulting in the same DEPNAMnn being listed more than once for different dependencies. This mergedep function takes care of rearranging numbers as needed. See the tests for examples.

@coveralls
Copy link

coveralls commented Feb 12, 2021

Coverage Status

Coverage increased (+0.2%) to 68.046% when pulling 4d6af27 on mergedeps into 9581e6e on master.

@weaverba137
Copy link
Member

I'll try to review this evening.

Copy link
Member

@weaverba137 weaverba137 left a comment

Choose a reason for hiding this comment

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

A couple of minor comments that can be easily fixed. Merge when ready.

Raises
------
ValueError
If `conflict == 'exception'` and the same dependency name appears
Copy link
Member

Choose a reason for hiding this comment

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

In RST, double backticks are equivalent to <code></code>, unlike MarkDown.

in both headers with different values; or if `conflict` isn't one
of 'src', 'dst', or 'exception'.
'''
if not conflict in ('src', 'dst', 'exception'):
Copy link
Member

Choose a reason for hiding this comment

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

conflict not in is the more typical idiom.

@sbailey
Copy link
Contributor Author

sbailey commented Feb 13, 2021

thanks, comments addressed, merging.

@sbailey sbailey merged commit fbba73a into master Feb 13, 2021
@sbailey sbailey deleted the mergedeps branch February 13, 2021 04:46
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