Add option to exclude line patterns#117
Merged
Merged
Conversation
myint
requested changes
Jul 11, 2017
Collaborator
myint
left a comment
There was a problem hiding this comment.
It looks good to me outside of my one comment.
|
|
||
| args.exclude_lines_pattern.extend([ | ||
| r'\bLCOV_EXCL_LINE\b', | ||
| r'^\s*};?\s*$', |
Collaborator
There was a problem hiding this comment.
The original text.strip() == '}' did not have a semicolon.
Contributor
Author
There was a problem hiding this comment.
Intended, for cases like:
auto my_lambda = [](){
do_stuff();
};
Collaborator
There was a problem hiding this comment.
Oh, I didn't notice the ?. I thought you were only handling };.
myint
approved these changes
Jul 12, 2017
Contributor
Author
|
Any timeline on a release with that patch? I'm using pip to install cpp-coveralls on travis, I'd like to avoid having to clone it manually. |
Owner
|
@nitnelave Thanks a lot for the contribution! a fresh 0.4.0 version is released. Enjoy :) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This extends the functionality already provided of ignoring LCOV_EXCL_LINE and lines with only '}'.
You can now give on the command line (or in the yml) exclude-lines-pattern, a list of regex matching lines to ignore.
Moreover, this adds the default of also ignoring lines with only '};' (as created by the end of an array or a lambda).