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

fix: typo #286

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pkg/personname/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ func renderWithSeps(sections []string, separator string, nullSepLevel uint) stri
// Add the section to the dcm string
dcmString = section + dcmString

// If this section is non-emtpy, we need to add all remaining separators, so
// If this section is non-empty, we need to add all remaining separators, so
// remember that we have encountered a non-zero value.
if section != "" {
nonZeroFound = true
Expand Down
6 changes: 3 additions & 3 deletions read_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -690,7 +690,7 @@ func TestReadHeader_TryAllowErrorMetaElementGroupLength(t *testing.T) {
t.Run("NoFileMetaInformationGroupLength", func(t *testing.T) {
dcmheaderNoInfoGrpLen, err := headerWithNoFileMetaInformationGroupLength()
if err != nil {
t.Fatalf("unsuccesful generation of fake header data")
t.Fatalf("unsuccessful generation of fake header data")
} else {
r := &reader{
rawReader: dicomio.NewReader(bufio.NewReader(dcmheaderNoInfoGrpLen.HeaderBytes), binary.LittleEndian, int64(dcmheaderNoInfoGrpLen.HeaderBytes.Len())),
Expand All @@ -711,7 +711,7 @@ func TestReadHeader_TryAllowErrorMetaElementGroupLength(t *testing.T) {
t.Run("WithFileMetaInformationGroupLength", func(t *testing.T) {
dcmHeaderInfoGrpLen, err := headerWithFileMetaInformationGroupLength()
if err != nil {
t.Fatalf("unsuccesful generation of fake header data with FileMetaInformationGroupLength")
t.Fatalf("unsuccessful generation of fake header data with FileMetaInformationGroupLength")
} else {
r := &reader{
rawReader: dicomio.NewReader(bufio.NewReader(dcmHeaderInfoGrpLen.HeaderBytes), binary.LittleEndian, int64(dcmHeaderInfoGrpLen.HeaderBytes.Len())),
Expand All @@ -720,7 +720,7 @@ func TestReadHeader_TryAllowErrorMetaElementGroupLength(t *testing.T) {
r.rawReader.SetTransferSyntax(binary.LittleEndian, true)
wantElements, err := r.readHeader()
if err != nil {
t.Errorf("unsuccesful readHeader when parse option %v is turned on and header has no MetaElementGroupLength tag", opts.allowMissingMetaElementGroupLength)
t.Errorf("unsuccessful readHeader when parse option %v is turned on and header has no MetaElementGroupLength tag", opts.allowMissingMetaElementGroupLength)
}
// Ensure dataset read from readHeader and the test header are the same except for the ValueLength field.
if diff := cmp.Diff(wantElements, dcmHeaderInfoGrpLen.Elements, cmp.AllowUnexported(allValues...), cmpopts.IgnoreFields(Element{}, "ValueLength")); diff != "" {
Expand Down