diff options
author | Steve Winslow <steve@swinslow.net> | 2021-07-04 10:54:31 -0400 |
---|---|---|
committer | Steve Winslow <steve@swinslow.net> | 2021-07-04 10:54:31 -0400 |
commit | b238c888559fcfaba7abc4d73741b633746c10d2 (patch) | |
tree | 9533e565af699fe44069e9ee3b1e3f02061191f3 /tvloader/parser2v2/parse_file_test.go | |
parent | b5d120102fa763bbe482a85a00d9a4d4b4e34657 (diff) | |
download | spdx-tools-b238c888559fcfaba7abc4d73741b633746c10d2.tar.gz |
Minor cleanup edits to text and comments
Signed-off-by: Steve Winslow <steve@swinslow.net>
Diffstat (limited to 'tvloader/parser2v2/parse_file_test.go')
-rw-r--r-- | tvloader/parser2v2/parse_file_test.go | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/tvloader/parser2v2/parse_file_test.go b/tvloader/parser2v2/parse_file_test.go index c0cbe92..689a2df 100644 --- a/tvloader/parser2v2/parse_file_test.go +++ b/tvloader/parser2v2/parse_file_test.go @@ -919,7 +919,7 @@ func TestParser2_2FailsIfArtifactURIBeforeArtifactName(t *testing.T) { } func TestParser2_2FilesWithoutSpdxIdThrowError(t *testing.T) { - // case 1 : The previous file (packaged or unpackaged does not contain spdxID) + // case 1: The previous file (packaged or unpackaged) does not contain spdx ID parser1 := tvParser2_2{ doc: &spdx.Document2_2{Packages: map[spdx.ElementID]*spdx.Package2_2{}}, st: psFile2_2, @@ -928,12 +928,11 @@ func TestParser2_2FilesWithoutSpdxIdThrowError(t *testing.T) { err := parser1.parsePair2_2("FileName", "f2") if err == nil { - t.Errorf("files withoutSpdx Identifiers getting accepted") + t.Errorf("file without SPDX Identifier getting accepted") } - // case 2 : Invalid file with snippet + // case 2: Invalid file with snippet // Last unpackaged file before the snippet start - // Last file of a package and New package starts fileName := "f2.txt" sid1 := spdx.ElementID("s1") parser2 := tvParser2_2{ @@ -943,11 +942,11 @@ func TestParser2_2FilesWithoutSpdxIdThrowError(t *testing.T) { } err = parser2.parsePair2_2("SnippetSPDXID", string(sid1)) if err == nil { - t.Errorf("files withoutSpdx Identifiers getting accepted") + t.Errorf("file without SPDX Identifier getting accepted") } - // case 3 : Invalid File without snippets - // Last unpackaged file before the packges start + // case 3: Invalid File without snippets + // Last unpackaged file before the package starts // Last file of a package and New package starts parser3 := tvParser2_2{ doc: &spdx.Document2_2{}, @@ -960,6 +959,6 @@ func TestParser2_2FilesWithoutSpdxIdThrowError(t *testing.T) { } err = parser3.parsePair2_2("PackageName", "p2") if err == nil { - t.Errorf("files withoutSpdx Identifiers getting accepted") + t.Errorf("file without SPDX Identifier getting accepted") } } |