[issue-573] unify parse_from_file tests for all formats#574
Merged
armintaenzertng merged 2 commits intospdx:mainfrom Apr 13, 2023
Merged
[issue-573] unify parse_from_file tests for all formats#574armintaenzertng merged 2 commits intospdx:mainfrom
parse_from_file tests for all formats#574armintaenzertng merged 2 commits intospdx:mainfrom
Conversation
54bfc9d to
83ff11a
Compare
meretp
previously approved these changes
Apr 12, 2023
Collaborator
meretp
left a comment
There was a problem hiding this comment.
Thanks! Two comments from my side, that are rather optional.
| class TestParseFromFile: | ||
| def test_parse_from_file_not_found(self, parser, format_name, extension): | ||
| with pytest.raises(FileNotFoundError) as err: | ||
| wrong_file_path = os.path.join(os.path.dirname(__file__), "hnjfkjsedhnflsiafg.json") |
Collaborator
There was a problem hiding this comment.
You could use extension here. Doesn't make a difference but feels more consistent regarding the different parsers
Collaborator
Author
There was a problem hiding this comment.
This feels necessary and unnecessary at the same time :D
I'll add it
Collaborator
There was a problem hiding this comment.
I am wondering if we really need the folder formats. Right now this gives an additional depth, that is not really needed.
Collaborator
Author
There was a problem hiding this comment.
I had the same thought. I'll remove it for now.
Signed-off-by: Armin Tänzer <armin.taenzer@tngtech.com>
83ff11a to
5feba30
Compare
Signed-off-by: Armin Tänzer <armin.taenzer@tngtech.com>
0a28990 to
8ae5a89
Compare
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.
Fixes #573.
I went a little further and unified the general parsing tests for all formats into a single test class, also adding the v2.2 tag-value example.